Listener -
rabbitmq
: Listener
Public Ballerina API - Ballerina RabbitMQ Message Listener. To provide a listener to consume messages from RabbitMQ.
Constructor
__init
(ConnectionConfiguration | Connection connectionOrConnectionConfig, int prefetchCount, int prefetchSize)
- connectionOrConnectionConfig ConnectionConfiguration | Connection
-
Holds a Ballerina RabbitMQ Connection object or the connection parameters.
- prefetchCount int ()
-
Maximum number of messages that the server will deliver, 0 if unlimited. Unless explicitly given, this value is 10 by default.
- prefetchSize int ()
-
Maximum amount of content (measured in octets) that the server will deliver, 0 if unlimited.
Methods
Stops consuming messages through ChannelListener endpoint.
Retrieve the Channel which initializes this listener.
LifeCycle Methods
Methods
Stops consuming messages through ChannelListener endpoint.
-
Return Type
(error) Nil or error upon failure to close ChannelListener.
Retrieve the Channel which initializes this listener.
-
Return Type
(Channel | error) RabbitMQ Channel object or error if an I/O problem is encountered.
LifeCycle Methods
Starts the endpoint. Function is ignored by the ChannelListener.
-
Return Type
(error) Nil or error upon failure to start.