Healthchecking the consumers

434 views
Skip to first unread message

Alexander Veysov

unread,
Apr 22, 2021, 8:28:51 AM4/22/21
to Pika
Hi,

We are running an application that has several consumers (all isolated in different containers running separately) communicating via RabbitMQ and the container network. There may be one or N cosumers of each type depending on the consumer.

We used this consumer as a reference and added a few features on top, the most important of which are (i) batching and (ii) RPC (we use aio-pika as publisher, but I guess this is not really important here).

When there is only one consumer, doing a rudimentary healthcheck is easy - you can just send a test message and get all the necessary information back including the exceptions via RPC (or not receive anything, which would mean that either RabbitMQ or the consumer is dead). 

But when you have N consumers, this becomes more problematic. We would like to be able to run a docker-like healthcheck (these healthchecks are easily picked up by compose or swarm) on each of our consumers separately not relying on RabbitMQ.

I see several non-elegant solutions, but maybe someone has faced this and knows an elegant solution?

Many thanks for your resposes in advance!

Best,
Alex


Анна Слижикова

unread,
Apr 22, 2021, 8:54:30 AM4/22/21
to Pika
Hi,
The same problem here. It's somehow difficult to healthcheck several connected RPC consumers.

четверг, 22 апреля 2021 г. в 15:28:51 UTC+3, ave...@gmail.com:
Reply all
Reply to author
Forward
0 new messages