Hi Camel folks

I would like to have some advices/recommandations about the following
requirement.

We have a webapp with *many* Camel routes (started with Camel-CDI). This war
is deployed on various application servers for various customers.
Some of theses routes are common to all customers, while other routes are
limited/dedicated to a single customer (and should therefore not be
"deployed" for all customers)

What would be the best solution to have a conditional (> depending on
props/conf file) registration of my routes ?
Please note I wish a conditional *registration* and not *starting* (> I do
not want the unused routes to be part of my CamelContext, nor to be visible
in hawt-io).
So disabling autostart + manually starting needed routes is not an option...

Any idea  ? - of something different from this:


I was thinking about a new annotation on the routebuilder, eg



Another alternative (but which requires a lot more refactoring) would be to
have a more "micro-services" oriented approach, to break my monolithic war
into a set of jars (each jar embedding a SINGLE RouteBuilder), and than in
the war assembly phase, build a customer-specific artifact (that is, exclude
the jars containing unneeded routes).



--
View this message in context: 
http://camel.465427.n5.nabble.com/Conditional-registration-of-routes-or-route-builders-tp5795589.html
Sent from the Camel - Users mailing list archive at Nabble.com.

Reply via email to