On Fri, May 2, 2008 at 10:50 AM, seven_ephors <[EMAIL PROTECTED]> wrote: > > I will give it a try later, but it seems to me that it probably won't solve > the problem since the consumer fetches the message as soon as it is > published, and when I increase the message size, the number of message that > can be send decrease accordingly. For example, when the BytesMessage has > the payload doubled, the number of BytesMessages that were send almost > halved (but not exactly).
Well besides what I described for the configuring prefetch on the client side, the broker side can be configured as well. By default, ActiveMQ will start to slow down producers when memory limits are being reached, as described here: http://activemq.apache.org/my-producer-blocks.html ActiveMQ limits itself to consuming 20mb of memory by default, not much if you're dealing with large messages or large amounts of messages. You should probably consider increasing this to more appropriately address your situation. This can be achieved in the activemq.xml configuration file using the memoryUsage element. See the default activemq.xml for some examples. Also bear in mind that this has a direct impact on the JVM memory, so you may need to tune that as well. Bruce -- perl -e 'print unpack("u30","D0G)[EMAIL PROTECTED]&5R\"F)R=6-E+G-N>61E<D\!G;6%I;\"YC;VT*" );' Apache ActiveMQ - http://activemq.org/ Apache Camel - http://activemq.org/camel/ Apache ServiceMix - http://servicemix.org/ Apache Geronimo - http://geronimo.apache.org/ Blog: http://bruceblog.org/