camel-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From rickaroni <>
Subject Re: Claus - Need better understanding of Camel "bean" tag usage with Spring prototype beans
Date Wed, 10 Sep 2014 17:45:10 GMT
Many (belated) thanks, Claus + Matt.

I think I'm finally getting the fact that the Exchange itself provides an
object with the scope I was seeking (i.e. from when the input message
received by Camel an input transport to when the output message sent from
Camel to the output transport).  

[i.e. Javadoc:


Hence, there may not be a need to create a custom spring bean scope that has
that same lifespan.

I've converted my (route-specific) service beans to be Spring prototype
beans, and now use Exchange properties (i.e. custom, per-route properties
that my routes then use) to store all intermediate results.  

By using ONLY the Exchange properties to store state, the (route-specific,
Spring) service beans become stateless.

So far, it looks good.

Much obliged for all the help.

View this message in context:
Sent from the Camel - Users mailing list archive at

View raw message