How to check if Producer is still connected?

46 views
Skip to first unread message

Jindra Kadoun

unread,
Feb 15, 2024, 12:39:26 AM2/15/24
to rabbitmq-c-users

Hello there, I was wondering how should I check my connection status in my producer?

If the RabbitMQ server is shut down in the process of publishing the messages how am I able to recognize that? The only solution I found is amqp_simple_wait_frame for a basic.ack, however this is extremely detrimental to the performance.

I am aware that I cannot share the amqp_connection_state_t between two threads so even second thread sniffing the DISCONNECT packet isn’t an option. Is there anything else left I can do?

Reply all
Reply to author
Forward
0 new messages