BrokerAmqpConnector class

This ActiveBrokerInterface implementation uses the native messaging protocol of the S3I-Broker: AMQP.

For more information about AMQP see their specification or refer to the documentation of the used dart_amqp package.

Inheritance

Constructors

BrokerAmqpConnector.new(AuthenticationManager authManager, {required String brokerHost, required int port, required String virtualHost, required int maxConnectionAttempts, required Duration reconnectWaitTime, required int prefetchCount, required String exchangeName, required ExchangeType exchangeType})
Creates a BrokerAmqpConnector which uses the authManager to receive tokens.

Properties

authManager AuthenticationManager
The authentication manager used by this instance to get valid access tokens.
finalinherited
brokerHost String
The host to connect to.
final
exchangeName String
The name of the amqp broker exchange.
final
exchangeType → ExchangeType
The type of the exchange, see here for more information.
final
hashCode int
The hash code for this object.
no setterinherited
maxConnectionAttempts int
The max number of reconnection attempts.
final
port int
The port of the amqp broker.
final
prefetchCount int
The number of messages loaded to the client without ACK.
final
reconnectWaitTime Duration
The time between each reconnect attempt.
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
virtualHost String
The connection vhost that will be sent to the server.
final

Methods

connectToBroker() Future<String>
Starts the connection to the S3I-Broker.
disconnectFromBroker() Future<void>
Disconnects from the S3I-Broker.
newMessageReceived(String messageString) → void
PROTECTED: DO NOT USE THIS METHOD UNLESS YOU ARE AN ActiveBrokerInterface !
inherited
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
notifyConsumingFailed(String endpoint, Exception error) → void
PROTECTED: DO NOT USE UNLESS YOU ARE AN ActiveBrokerInterface.
inherited
notifySendMessageFailed(Message message, Exception error) → void
PROTECTED: DO NOT USE UNLESS YOU ARE AN ActiveBrokerInterface.
inherited
notifySendMessageSucceeded(Message message) → void
PROTECTED: DO NOT USE UNLESS YOU ARE AN ActiveBrokerInterface.
inherited
sendMessage(Message message, Set<String> endpoints) Future<void>
Publishes the given message to all endpoints.
override
startConsuming(String endpoint) Future<void>
Starts consuming on the endpoint.
override
stopConsuming(String endpoint) Future<void>
Stops consuming on the endpoint.
override
subscribeConsumingFailed(dynamic callback(String, Exception)) → void
Subscribes to all errors during consuming from the endpoints. (ConsumingFailed-Event).
inherited
subscribeEventMessageReceived(dynamic callback(EventMessage)) → void
Subscribes to all received event messages (EventMessageReceived-Event).
inherited
subscribeEventSubscriptionRequestReceived(dynamic callback(EventSubscriptionRequest)) → void
Subscribes to all received EventSubscriptionRequest (EventSubscriptionRequestReceived-Event).
inherited
subscribeEventSubscriptionResponseReceived(dynamic callback(EventSubscriptionResponse)) → void
Subscribes to all received EventSubscriptionResponse (EventSubscriptionResponseReceived-Event).
inherited
subscribeGetValueReplyReceived(dynamic callback(GetValueReply)) → void
Subscribes to all GetValueReplyReceived-Events.
inherited
subscribeGetValueRequestReceived(dynamic callback(GetValueRequest)) → void
Subscribes to all GetValueRequestReceived-Events.
inherited
subscribeInvalidMessageReceived(dynamic callback(String, Exception)) → void
Subscribes to all received messages which can't be parsed correctly (InvalidMessageReceived-Event).
inherited
subscribeSendMessageFailed(dynamic callback(Message, Exception)) → void
Subscribes to all messages which couldn't be sent correctly (SendMessageFailed-Event).
inherited
subscribeSendMessageSucceeded(dynamic callback(Message)) → void
Subscribes to all received messages which can't be parsed correctly (SendMessageSucceeded-Event).
inherited
subscribeServiceReplyReceived(dynamic callback(ServiceReply)) → void
Subscribes to all ServiceReplyReceived-Events.
inherited
subscribeServiceRequestReceived(dynamic callback(ServiceRequest)) → void
Subscribes to all ServiceRequestReceived-Events.
inherited
subscribeUserMessageReceived(dynamic callback(UserMessage)) → void
Subscribes to all received user messages (UserMessageReceived-Event).
inherited
toString() String
A string representation of this object.
inherited
unsubscribeConsumingFailed(dynamic callback(String, Exception)) → void
Unsubscribes the callback from the ConsumingFailed-Event.
inherited
unsubscribeEventMessageReceived(dynamic callback(EventMessage)) → void
Unsubscribes the callback from the EventMessageReceived-Event.
inherited
unsubscribeEventSubscriptionRequestReceived(dynamic callback(EventSubscriptionRequest)) → void
Unsubscribes the callback from the EventSubscriptionRequestReceived-Event.
inherited
unsubscribeEventSubscriptionResponseReceived(dynamic callback(EventSubscriptionResponse)) → void
Unsubscribes the callback from the EventSubscriptionResponseReceived-Event.
inherited
unsubscribeGetValueReplyReceived(dynamic callback(GetValueReply)) → void
Unsubscribes the callback from the GetValueReplyReceived-Event.
inherited
unsubscribeGetValueRequestReceived(dynamic callback(GetValueRequest)) → void
Unsubscribes the callback from the GetValueRequestReceived-Event.
inherited
unsubscribeInvalidMessageReceived(dynamic callback(String, Exception)) → void
Unsubscribes the callback from the InvalidMessageReceived-Event.
inherited
unsubscribeSendMessageFailed(dynamic callback(Message, Exception)) → void
Unsubscribes the callback from the SendMessageFailed-Event.
inherited
unsubscribeSendMessageSucceeded(dynamic callback(Message)) → void
Unsubscribes the callback from the SendMessageSucceeded-Event.
inherited
unsubscribeServiceReplyReceived(dynamic callback(ServiceReply)) → void
Unsubscribes the callback from the ServiceReplyReceived-Event.
inherited
unsubscribeServiceRequestReceived(dynamic callback(ServiceRequest)) → void
Unsubscribes the callback from the ServiceRequestReceived-Event.
inherited
unsubscribeUserMessageReceived(dynamic callback(UserMessage)) → void
Unsubscribes the callback from the UserMessageReceived-Event.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited