[ https://issues.apache.org/jira/browse/CAMEL-3285?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12988630#action_12988630 ]
Ashwin Karpe commented on CAMEL-3285: ------------------------------------- Hi Claus & Kristof, I do take onboard your recommendation to look at ways to avoid registries and spring beans/code. I will look into package scanning and using routeIds to select inner routes for payload routing. Using routeIds (not endpoint consumer names) could get rid of the dispatchMap as we have it now. Also package scanning could take care not needing to add routebuilders into the context. The inner Context creation or injection is optional. With a forkContext flag set to false, the current camel context will be reused. I agree that the CamelContext was not originally intended to be embeddable in another context. It is also possible to abuse this capability by nesting camel contexts within other nested camel contexts with the relationships not immediately clear from a JMX standpoint. Is this where you are coming from? I am happy to add the "subject to change" note on the routebox documentation page. Please let me know if you agree with my package scanning and routeId based routing recommendations. It will cut down URI options and be more intuitive. Cheers, Ashwin... > Create a new blackbox component which can encapsulate routes using a > specialized ProtocolBuilder endpoint (similar to RouteBuilder) > ----------------------------------------------------------------------------------------------------------------------------------- > > Key: CAMEL-3285 > URL: https://issues.apache.org/jira/browse/CAMEL-3285 > Project: Camel > Issue Type: New Feature > Reporter: Ashwin Karpe > Assignee: Ashwin Karpe > Fix For: 2.6.0 > > Attachments: camel-routebox-20101220.zip, routebox.diff > > > Given below is the discussion forum thread that spawned this thought. > http://camel.465427.n5.nabble.com/Abstracting-Routes-using-Components-td3234703.html#a3234703 > Component requirements: > Need a Camel component (called Backbox, maybe) that can nicely expose a > ProtocolBuilder endpoint that does the following > a> Instantiate route definitions/route(s) configured in Spring or DSL at > startup > b> Launch a Producer or Consumer with a well known protocol(s) so that a > client can invoke it (could be direct or seda initially but could be any > protocol... really) . Must support multiple consumer endpoints and routes > using a URI scheme. > c> redirect received payloads (with marshalling into an exchange if > necessary) to the inner route(s) since they are launched and started. If > there are multiple inner routes with many consumers, we could expect the user > to provide a clue using the payload and/or an exchange property as to how the > payload should be routed. > d> Extend from a Default Consumer, Producer, Endpoint and Component. > e> Internally manage inner route lifecycles and operations. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.