There is a thread pool in the NMR to deal with the message, and camel-nmr consumer just leverage the NMR thread pool to do its daily job.
So my answer is the multiple request to nmr:myDynamicRouter endpoint can be handled parallelly.
Mmm, are you sure?
I have this route deployed in FUSE esb 4.2:
JETTY -> CXF with NMR address
if I send multiple requests to the jetty url they are served 1 by 1.
If I expose CXF service directly on an url address multiple requests are served at the same time.
So I think that the NRM endpoints are not multithreaded "out of the box".
Do I need to activate this behavior in some configuration file?
My exact sentiment. This is because I have tested this and it seems to use a single thread which blocks incoming requests.
Here is my test
When it gets to D, the system blocks and throw timeout exception, because it is waiting for B to end. Of course it will never end until this flow returns.
Edited by: lekkie on Apr 15, 2010 7:41 AM
Edited by: lekkie on Apr 16, 2010 7:56 AM
Can I have a look at your Jetty and NMR route?
Are you using the Jetty as a proxy to send the request to the CXF ?
camel-jetty endpoint support the server the multi request at the same time.
How did you send the request to "nmr:consumer" ?
If you just use the client.sendSync(e) to send the request in a loop, the camel route will server the request one by one.
The camel snippet below calls the nmr:consumer.
This is the definition of the jaxws endpoint:
<jaxws:endpoint id="cxfNMRService" implementor="xx.yyy.zzz.CxfNmrService" address="nmr:cxfNMR" />
and this is the route:
from("jetty:http://0.0.0.0:8390/xxx/yy?matchOnUriPrefix=true") //logging stuff .beanRef("myTx", "log") //call to the CXF endpoind on the NMR .to("nmr:cxfNMR") //logging stuff .beanRef("myTx", "log");