org.jboss.messaging.core.postoffice.impl
Class PostOfficeImpl

java.lang.Object
  extended by org.jboss.messaging.core.postoffice.impl.PostOfficeImpl
All Implemented Interfaces:
NotificationListener, PostOffice, MessagingComponent

public class PostOfficeImpl
extends java.lang.Object
implements PostOffice, NotificationListener

A PostOfficeImpl

Author:
Tim Fox, Jeff Mesnil, Clebert Suconic

Field Summary
static SimpleString HDR_RESET_QUEUE_DATA
           
 
Constructor Summary
PostOfficeImpl(MessagingServer server, StorageManager storageManager, PagingManager pagingManager, QueueFactory bindableFactory, ManagementService managementService, long reaperPeriod, int reaperPriority, boolean enableWildCardRouting, boolean backup, int idCacheSize, boolean persistIDCache, ExecutorFactory orderedExecutorFactory, HierarchicalRepository<AddressSettings> addressSettingsRepository)
           
 
Method Summary
 java.util.List<Queue> activate()
           
 void addBinding(Binding binding)
           
 Binding getBinding(SimpleString name)
           
 Bindings getBindingsForAddress(SimpleString address)
           
 DuplicateIDCache getDuplicateIDCache(SimpleString address)
           
 Bindings getMatchingBindings(SimpleString address)
           
 java.lang.Object getNotificationLock()
           
 PagingManager getPagingManager()
           
 boolean isStarted()
           
 void onNotification(Notification notification)
           
 boolean redistribute(ServerMessage message, Queue originatingQueue, Transaction tx)
           
 Binding removeBinding(SimpleString uniqueName)
           
 void route(ServerMessage message)
           
 void route(ServerMessage message, Transaction tx)
           
 void sendQueueInfoToQueue(SimpleString queueName, SimpleString address)
           
 void start()
           
 void stop()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

HDR_RESET_QUEUE_DATA

public static final SimpleString HDR_RESET_QUEUE_DATA
Constructor Detail

PostOfficeImpl

public PostOfficeImpl(MessagingServer server,
                      StorageManager storageManager,
                      PagingManager pagingManager,
                      QueueFactory bindableFactory,
                      ManagementService managementService,
                      long reaperPeriod,
                      int reaperPriority,
                      boolean enableWildCardRouting,
                      boolean backup,
                      int idCacheSize,
                      boolean persistIDCache,
                      ExecutorFactory orderedExecutorFactory,
                      HierarchicalRepository<AddressSettings> addressSettingsRepository)
Method Detail

start

public void start()
           throws java.lang.Exception
Specified by:
start in interface MessagingComponent
Throws:
java.lang.Exception

stop

public void stop()
          throws java.lang.Exception
Specified by:
stop in interface MessagingComponent
Throws:
java.lang.Exception

isStarted

public boolean isStarted()
Specified by:
isStarted in interface MessagingComponent

onNotification

public void onNotification(Notification notification)
Specified by:
onNotification in interface NotificationListener

addBinding

public void addBinding(Binding binding)
                throws java.lang.Exception
Specified by:
addBinding in interface PostOffice
Throws:
java.lang.Exception

removeBinding

public Binding removeBinding(SimpleString uniqueName)
                      throws java.lang.Exception
Specified by:
removeBinding in interface PostOffice
Throws:
java.lang.Exception

getBindingsForAddress

public Bindings getBindingsForAddress(SimpleString address)
Specified by:
getBindingsForAddress in interface PostOffice

getBinding

public Binding getBinding(SimpleString name)
Specified by:
getBinding in interface PostOffice

getMatchingBindings

public Bindings getMatchingBindings(SimpleString address)
Specified by:
getMatchingBindings in interface PostOffice

route

public void route(ServerMessage message,
                  Transaction tx)
           throws java.lang.Exception
Specified by:
route in interface PostOffice
Throws:
java.lang.Exception

route

public void route(ServerMessage message)
           throws java.lang.Exception
Specified by:
route in interface PostOffice
Throws:
java.lang.Exception

redistribute

public boolean redistribute(ServerMessage message,
                            Queue originatingQueue,
                            Transaction tx)
                     throws java.lang.Exception
Specified by:
redistribute in interface PostOffice
Throws:
java.lang.Exception

getPagingManager

public PagingManager getPagingManager()
Specified by:
getPagingManager in interface PostOffice

activate

public java.util.List<Queue> activate()
Specified by:
activate in interface PostOffice

getDuplicateIDCache

public DuplicateIDCache getDuplicateIDCache(SimpleString address)
Specified by:
getDuplicateIDCache in interface PostOffice

getNotificationLock

public java.lang.Object getNotificationLock()
Specified by:
getNotificationLock in interface PostOffice

sendQueueInfoToQueue

public void sendQueueInfoToQueue(SimpleString queueName,
                                 SimpleString address)
                          throws java.lang.Exception
Specified by:
sendQueueInfoToQueue in interface PostOffice
Throws:
java.lang.Exception


Copyright © 2006 JBoss Inc. All Rights Reserved.