Turns out I already output info to basically notice if the consumer is blocking:<div><br></div><div><div>2009-10-01 20:55:27,935 INFO [id: 99704402] Processing complete, acknowledged.</div><div>2009-10-01 20:55:27,939 INFO [id: 99704402] Received queue item, processing...</div>
<div><br></div><div>2009-10-01 20:55:29,215 INFO [id: 99704402] Processing complete, acknowledged.</div><div>2009-10-01 20:55:29,215 INFO [id: 99704402] Received queue item, processing...</div><div><br></div><div>You'll notice there's a gap between receiving and processing so that means the consumer is just waiting for an item. So it really does look like rabbitmq is not able to get items to me fast enough with lots of items backed in the queue.</div>
<div><br></div><div>Suhail</div><br><div class="gmail_quote">On Thu, Oct 1, 2009 at 1:40 PM, Suhail Doshi <span dir="ltr"><<a href="mailto:suhail@mixpanel.com">suhail@mixpanel.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">
<br><br><div class="gmail_quote"><div class="im">On Thu, Oct 1, 2009 at 1:32 PM, Matthias Radestock <span dir="ltr"><<a href="mailto:matthias@lshift.net" target="_blank">matthias@lshift.net</a>></span> wrote:<br></div>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div class="im">
Suhail,<div><br>
<br>
Suhail Doshi wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
Does anyone know what rabbitmq throughput is from items sitting in the queue to sending them to a consumer?<br>
<br>
Lets say we're doing 200 items in the queue a second with 50 consumers waiting to process the item, usually they do in < 30ms.<br>
</blockquote>
<br></div>
So that's ~7kHz, which doesn't look unreasonable, but there are many factors at play here which we'd need to know about in order to make a better assessment:<br>
<br></div>
- are these messages persistent or transient? Persistent </blockquote><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
- how big are the messages? Less than 500 bytes usually<br>
- do the consumer consume in no-ack mode, or ack mode? ack mode<br>
- are the consumers sharing a connection (or even channel) or do they all have their separate connection/channel? do not share a channel/connection<br>
- where are the consumers in the network topology in relation to the server? very close, same rack presumably<br>
- what's the hardware spec of the server machine? quad core, 4 GB of RAM<br>
- what version of Erlang are you running? 5.7.2<br>
- what AMQP client are you using? Python library created by Barry Pederson<div class="im"><br>
<br>
Also, ...<div><br>
<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
Watching our consumer logs, it feels like they don't get items fast<br>
enough from rabbitmq, is that possible or is it me?<br>
</blockquote>
<br></div></div>
Can you instrument the consumers to measure how long they are blocked waiting for messages from RabbitMQ? Yes possibly, I should check you're right.<div class="im"><br>
<br>
Also, with 200 messages shared across 50 consumers each consumer will only get four items, which is a rather small figure to do any meaningful statistical analysis with.<br>
<br>
<br>
Regards,<br><font color="#888888">
<br>
Matthias.<br>
</font></div></blockquote></div><font color="#888888"><br><br clear="all"><br>-- <br><a href="http://mixpanel.com" target="_blank">http://mixpanel.com</a><br>Blog: <a href="http://blog.mixpanel.com" target="_blank">http://blog.mixpanel.com</a><br>
</font></blockquote></div><br><br clear="all"><br>-- <br><a href="http://mixpanel.com">http://mixpanel.com</a><br>Blog: <a href="http://blog.mixpanel.com">http://blog.mixpanel.com</a><br>
</div>