I have a web server that asynchronously publishes messages to rabbitMQ after sending 200 OK to the client. But before it does that, it gets that queue count because I don't want the queue to be overloaded or my rabbitMQ's heap memory reach water mark level.
The web server, based on nodeJS, also does a redis hit after it. The server was performing ridiculously bad (not even 1k req/s on a c4.xlarge and being run in cluster mode). I dug a little deeper and found that the queue count was taking around 5-6 minutes under heavy load. I went ahead using x-max-length
argument during queue generation and got rid of the queue count check after finding an appropriate value for the x-max-length
argument.
Can somebody please explain why the getQueueCount was taking such a long time on rabbitMQ cluster? I do not have that deeper understanding of rabbitMQ internals.
via Vidur Khanna
No comments:
Post a Comment