Hi Cesar,

it would be great if you could submit your benchmark to ServiceMix! We are in the process of adding benchmark system tests - but this will take a while - and it would help us tune the internals in the mean time.

You're sample size (300) is quite small to get an accurate picture of the marshaling/routing speed of ServiceMix, and you've probably not getting a true picture of the overhead of sending messages through JBI. 
Internally for routing the default flow type is seda, which uses internal queues for dispatching messages between different Components. The queue size by default is 1000, so a bigger sample size will provide a more accurate picture of the overhead.

Seda flow does provide some benefits for scaling with some deployment patterns - but you could try setting the flow used to straight through - st. See http://servicemix.codehaus.org/NMR+Flows

You can change the flow type when configuring ServiceMix - see http://servicemix.codehaus.org/Configuration

cheers,

Rob

On 11 Sep 2005, at 23:49, Cesar Delgado wrote:

Hi

 

I’m measuring the time spent between deliveryChannel.send(exchange) in MySender and exchange.getMessage("in") in MyReceiver and I found that it is more than 100 times slower than sending a message between 2 JVM using JMS or Hessian over HTTP. Even if ServiceMix/JBI is not designed for high performance, the performance that I found is unacceptable.

My test consists in sending 400 messages from MySender to MyReceiver (example on http://servicemix.codehaus.org/POJO+support). The time spent for the last 300 messages is used to get the statistics (average). I start a timer just before deliveryChannel.send(exchange) and stop the timer immediately after exchange.getMessage("in") trying to measure the time spent in marshalling and transport inside the JBI ESB. I’m using a timer API that provides a resolution of at least 5 microseconds on my hardware. The messages sent are as simple as:

            message.setProperty("id", new Integer(gen_counter));           

            message.setContent(new StringSource("<example id='" + gen_counter + "'/>"));

            message.setProperty("time", Double.toString(microTimer.getTicks()));

 

MySender and MyReceiver are executed inside the same ServiceMix instance (the same JVM); but the communication between these two components is slower by a factor greater than 100 when I compare my benchmark for a similar message interchange between 2 applications running in different JVM but using other protocols.

 

I really hope I am wrong. I’d appreciate somebody’s help in providing me with some guidelines about how to tune ServiceMix in order to get better performance.

 

Best regard,

 

Cesar



Reply via email to