qpid-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Robert Greig" <robert.j.gr...@gmail.com>
Subject Re: Java M3 Qpid broker memory consumption
Date Sat, 08 Nov 2008 18:06:32 GMT
2008/11/8 Robert Greig <robert.j.greig@gmail.com>:

> This is not a particularly good solution from a performance
> perspective since the broker will make a lot more system calls as a
> result - particularly when you have smaller messages. However with a
> low rate such as 200 messages/second this should be fine I think.
>
> If you try this, you should see that messages do build up in the queues.

I meant to mention that one reason you would want to do this is that
it should lower the memory consumption of the broker. The reason for
that is due to a performance optimisation that the broker does. If the
broker thinks it can push a message straight out to a consumer, it
just takes a slice of the heap buffer used to read from the socket -
which will be 32k by default. This is to avoid the overhead of copying
to another buffer. Note that the broker does think it can push the
message straight out to a consumer because what MINA is doing is
hidden.

If the messages are kept on a queue, then it will copy them to an
appropriately sized buffer to reduce memory consumption. In your case
where your messages are 250 bytes this will be particuarly noticable.

RG

Mime
View raw message