public class MultiQueueDispatcher extends AbstractDispatcher
Dispatcher implementation that decouples message processing by CCS from message processing by JGroups.AbstractDispatcher.TaskDispatcher.AlertEvent, Dispatcher.Event, Dispatcher.Listener, Dispatcher.Order, Dispatcher.Stagealerts, config, serviceExec| Constructor and Description |
|---|
MultiQueueDispatcher(String args)
Constructs an instance.
|
| Modifier and Type | Method and Description |
|---|---|
void |
in(Runnable run,
Bus bus,
String... agents)
Submits a task to process an incoming message or disconnection notification.
|
void |
initialize()
Initializes this dispatcher.
|
void |
out(Runnable run,
Bus bus,
Dispatcher.Order order)
Submits a task to process an outgoing message.
|
void |
shutdown()
Orderly shuts down this dispatcher.
|
addListener, deliverEvent, fireEvent, getBooleanArg, getIntArg, getIntArrayArg, getIntArrayArg, getLogger, getRegisteredAlerts, raiseAlert, raiseAlert, registerAlert, removeListenerpublic MultiQueueDispatcher(String args)
Recognized configuration parameters:
args - Configuration string in "key[=value]&...&key[=value]" format, where value may be a comma-separated array.public void initialize()
initialize in interface Dispatcherinitialize in class AbstractDispatcherpublic void shutdown()
shutdown in interface Dispatchershutdown in class AbstractDispatcherpublic void in(Runnable run, Bus bus, String... agents)
If one or more agent names are given, the task if guaranteed to be executed after any previously submitted
tasks for the same bus and agent. If no agents are specified, the task is independent of other tasks,
subject to capacity controls imposed by this service. If the agents argument
is null, the task is independent of other tasks, not subject to capacity controls.
run - Task to be executed.bus - Bus (LOG, STATUS, or COMMAND).agents - Names of affected agents (source or disconnected).TransportStateException - If this Dispatcher is unable to accept the
request for reasons other than being uninitialized or shut down.public void out(Runnable run, Bus bus, Dispatcher.Order order)
Tasks submitted with outOfBand equal to false for the same bus are guaranteed to be
processed in the order of submission. If outOfBand equals true, the task is executed
independently of others, subject to capacity controls imposed by this service.
If outOfBand equals null, the task is independent, not subject to capacity controls.
run - Task to be executed.bus - Bus (LOG, STATUS, or COMMAND).order - Order of execution and capacity control policies.TransportStateException - If this Dispatcher is unable to accept the
request for reasons other than being uninitialized or shut down.Copyright © 2024 LSST. All rights reserved.