Class AMQPFederationCommandDispatcher
java.lang.Object
org.apache.activemq.artemis.protocol.amqp.connect.federation.AMQPFederationCommandDispatcher
- All Implemented Interfaces:
SenderController
A
SenderController implementation used by the AMQP federation control link to encode and send federation
policies or other commands to the remote side of the AMQP federation instance.-
Nested Class Summary
Nested classes/interfaces inherited from interface SenderController
SenderController.RejectingOutgoingMessageWriter -
Field Summary
Fields inherited from interface SenderController
REJECTING_MESSAGE_WRITER -
Method Summary
Modifier and TypeMethodDescriptionvoidclose(boolean remoteClose) Handle close of the sever sender AMQP resources either from remote link detach or local close usually due to connection drop.org.apache.activemq.artemis.core.server.Consumerinit(ProtonServerSenderContext senderContext) Initialize sender controller state and handle open of AMQP sender resourcesvoidsendCommand(AMQPMessage command) Raw send command that accepts andAMQPMessageinstance and routes it using the server post office instance.voidSends the givenFederationReceiveFromAddressPolicyinstance using the control link which should instruct the remote to begin federation operations back to this peer for matching remote address.voidSends the givenFederationReceiveFromQueuePolicyinstance using the control link which should instruct the remote to begin federation operations back to this peer for matching remote queues with demand.Methods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface SenderController
close, selectOutgoingMessageWriter
-
Method Details
-
sendPolicy
Sends the givenFederationReceiveFromQueuePolicyinstance using the control link which should instruct the remote to begin federation operations back to this peer for matching remote queues with demand.- Parameters:
policy- The policy to encode and send over the federation control link.- Throws:
Exception- if an error occurs during the control and send operation.
-
sendPolicy
Sends the givenFederationReceiveFromAddressPolicyinstance using the control link which should instruct the remote to begin federation operations back to this peer for matching remote address.- Parameters:
policy- The policy to encode and send over the federation control link.- Throws:
Exception- if an error occurs during the control and send operation.
-
sendCommand
Raw send command that accepts andAMQPMessageinstance and routes it using the server post office instance.- Parameters:
command- The command message to send to the previously created control address.- Throws:
Exception- if an error occurs during the message send.
-
init
public org.apache.activemq.artemis.core.server.Consumer init(ProtonServerSenderContext senderContext) throws Exception Description copied from interface:SenderControllerInitialize sender controller state and handle open of AMQP sender resources- Specified by:
initin interfaceSenderController- Parameters:
senderContext- The sender context that is requesting controller initialization.- Returns:
- a server consumer that has been initialize by the controller
- Throws:
Exception- if an error occurs during initialization.
-
close
Description copied from interface:SenderControllerHandle close of the sever sender AMQP resources either from remote link detach or local close usually due to connection drop.- Specified by:
closein interfaceSenderController- Parameters:
remoteClose- Indicates if the remote link detached the sender or local action closed it.- Throws:
Exception- if an error occurs during close.
-