Consumer blocking other consumers?

classic Classic list List threaded Threaded
4 messages Options
Reply | Threaded
Open this post in threaded view
|

Consumer blocking other consumers?

sanjan
Hi,

I have a router network setup as below. and recently we had an issue with one of the consumers.
where the consumer process was hung due to an "out of memory error" while processing message.

Let's say the consumer process was "consumer 1"
which pickup messages from "queue 1" in router "queue router 1"
and "queue 1" in "queue router 3"

This actually prevented both the producers sending out the messages to any queue in "queue router 1" and "queue router 3"

Producers were throwing time out errors.

May I know, If a consumer consumes from a queue in a router, does it lock the whole router?. or just the queue?

I tried to login to the affected routers via CLI when the issue was on. and I could not login.
There was no error.. but it was just hanging....

I had to kill the two routers and restart to resolve the issue.

Reply | Threaded
Open this post in threaded view
|

Re: Consumer blocking other consumers?

IIT Software
Administrator
Where was the OOM - at the router process or at the client process?
Reply | Threaded
Open this post in threaded view
|

Re: Consumer blocking other consumers?

sanjan
The OOM exception was at the consumer process (not the router) .
its a java application which picks up messages from swiftmq router and do some processing.  
eg: "consumer 1" in the diagram
Reply | Threaded
Open this post in threaded view
|

Re: Consumer blocking other consumers?

IIT Software
Administrator
If the client gets an OOM, one of its threads dies. The client will not process further messages so the queue will grow and may then generate flow control delays that throttle producers. All messages in the client's consumer cache (within the client process) remain locked in the queue and can't be accessed by other consumers.

That's all what may happen. A non-functional consumer will not interfere other clients except as mentioned above.