![]() Message 11 could not be confirmed, exception = UnroutableError, e = 1 unroutable message(s) returned Message 10 could not be confirmed, exception = UnroutableError, e = 1 unroutable message(s) returned Message 9 could not be confirmed, exception = UnroutableError, e = 1 unroutable message(s) returned When the queue is deleted, the message cannot be confirmed. Message 9 could not be confirmed, exception = ChannelWrongStateError, e = Channel is closed. Message 8 could not be confirmed, exception = ChannelWrongStateError, e = Channel is closed. Message 6 could not be confirmed, exception = ChannelClosedByBroker, e = (404, "NOT_FOUND - no exchange 'my_test_exchange' in vhost '/'") When the exchange is deleted, the message cannot be confirmed. Message 7 could not be confirmed, exception = ChannelWrongStateError, e = Channel is closed. Message 6 could not be confirmed, exception = ChannelWrongStateError, e = Channel is closed. Message 5 could not be confirmed, exception = ChannelWrongStateError, e = Channel is closed. Message 4 could not be confirmed, exception = ConnectionClosedByBroker, e = (320, "CONNECTION_FORCED - broker forced connection closure with reason 'shutdown'") When RabbitMQ is terminated, the message cannot be confirmed. # Open a connection to RabbitMQ on localhost using all default parameters # - added to queue_declare: durable=True, exclusive=False, auto_delete=Falseįrom pika.exchange_type import ExchangeType # - added to exchange_declare: durable=True, auto_delete=False # Using Delivery Confirmations with the BlockingConnection Synchronous publishing using BlockingConnection Deleting the exchange and deleting the queue is done from the RabbitMQ management interface. Terminating RabbitMQ is done by killing the Docker container. When a script is running (publishing messages to a queue) I create the following conditions: The scripts keep publishing messages every 2 seconds. ![]() asynchronous publishing, using SelectConnection.synchronous publishing, using BlockingConnection.I created two Python scripts based on Pika examples: I changed the credentials here to 'user'/'password'. We use the RabbitMQ with management Docker image, the management interface is at: To my surprise, the Pika asynchronous example did not detect when the queue was removed, it kept sending messages. Using examples included with Pika, the RabbitMQ (AMQP 0-9-1) client library for Python. As this is my first time using RabbitMQ, I wanted to try both the synchronous and asynchronous publishing versions, A lot has been written about synchronous vs asynchronous publishing with RabbitMQ, see links below, I am not going to repeat this here.
0 Comments
Leave a Reply. |