Hi,I'd like to use akka-camel with my own camel context rather than using the private one defined in the CamelExtension (to reuse routes defined in spring xml)As discussed in this thread: https://groups.google.com/d/topic/akka-user/ZvF6zQqrCvo/discussion, the camel context is not injectable in the extension.I would be happy to propose a pull-request. However I need some help on how to pass the context to the extension. At the moment I'm thinking at:- adding a public useContext(ctx) method on the CamelExtension object, making it mutable, not very clean.
- using a config option to define a classname, that will be dynamically loaded to find the context: seems too complicated.
Nothing really satisfying to me. Any other idea or guidance is welcomed :)Context: I have an existing application written with camel with many routes defined using the spring dsl.
We are migrating part of this application to akka, replacing camel processors with akka actors.Regards,Thibaut
--
>>>>>>>>>> Read the docs: http://akka.io/docs/
>>>>>>>>>> Check the FAQ: http://akka.io/faq/
>>>>>>>>>> Search the archives: https://groups.google.com/group/akka-user
---
You received this message because you are subscribed to the Google Groups "Akka User List" group.
To unsubscribe from this group and stop receiving emails from it, send an email to akka-user+...@googlegroups.com.
To post to this group, send email to akka...@googlegroups.com.
Visit this group at http://groups.google.com/group/akka-user.
For more options, visit https://groups.google.com/groups/opt_out.
On Wed, Feb 12, 2014 at 4:56 PM, Thibaut Robert <thibaut...@gmail.com> wrote:
Hi,I'd like to use akka-camel with my own camel context rather than using the private one defined in the CamelExtension (to reuse routes defined in spring xml)As discussed in this thread: https://groups.google.com/d/topic/akka-user/ZvF6zQqrCvo/discussion, the camel context is not injectable in the extension.I would be happy to propose a pull-request. However I need some help on how to pass the context to the extension. At the moment I'm thinking at:- adding a public useContext(ctx) method on the CamelExtension object, making it mutable, not very clean.- using a config option to define a classname, that will be dynamically loaded to find the context: seems too complicated.I'd go for that, it is how everything else works in Akka.
On Wed, Feb 12, 2014 at 5:08 PM, √iktor Ҡlang <viktor...@gmail.com> wrote:
On Wed, Feb 12, 2014 at 4:56 PM, Thibaut Robert <thibaut...@gmail.com> wrote:
Hi,I'd like to use akka-camel with my own camel context rather than using the private one defined in the CamelExtension (to reuse routes defined in spring xml)As discussed in this thread: https://groups.google.com/d/topic/akka-user/ZvF6zQqrCvo/discussion, the camel context is not injectable in the extension.I would be happy to propose a pull-request. However I need some help on how to pass the context to the extension. At the moment I'm thinking at:- adding a public useContext(ctx) method on the CamelExtension object, making it mutable, not very clean.- using a config option to define a classname, that will be dynamically loaded to find the context: seems too complicated.I'd go for that, it is how everything else works in Akka.+1Strange that setting the Registry on the CamelContext does not work, have you verified this yourself that it does not work?
On Wednesday, February 12, 2014 5:57:35 PM UTC+1, Raymond Roestenburg wrote:On Wed, Feb 12, 2014 at 5:08 PM, √iktor Ҡlang <viktor...@gmail.com> wrote:
On Wed, Feb 12, 2014 at 4:56 PM, Thibaut Robert <thibaut...@gmail.com> wrote:
Hi,I'd like to use akka-camel with my own camel context rather than using the private one defined in the CamelExtension (to reuse routes defined in spring xml)As discussed in this thread: https://groups.google.com/d/topic/akka-user/ZvF6zQqrCvo/discussion, the camel context is not injectable in the extension.I would be happy to propose a pull-request. However I need some help on how to pass the context to the extension. At the moment I'm thinking at:- adding a public useContext(ctx) method on the CamelExtension object, making it mutable, not very clean.- using a config option to define a classname, that will be dynamically loaded to find the context: seems too complicated.I'd go for that, it is how everything else works in Akka.+1Strange that setting the Registry on the CamelContext does not work, have you verified this yourself that it does not work?Setting the registry is not enough. It does not allow to define routes in xml, unless I missed something.I'll have a deeper look tomorrow, maybe we can take the route definition from spring (inside a routeContext tag) and apply them to the akka camel context.
On Wednesday, February 12, 2014 6:58:53 PM UTC+1, Thibaut Robert wrote:
On Wednesday, February 12, 2014 5:57:35 PM UTC+1, Raymond Roestenburg wrote:On Wed, Feb 12, 2014 at 5:08 PM, √iktor Ҡlang <viktor...@gmail.com> wrote:
On Wed, Feb 12, 2014 at 4:56 PM, Thibaut Robert <thibaut...@gmail.com> wrote:
Hi,I'd like to use akka-camel with my own camel context rather than using the private one defined in the CamelExtension (to reuse routes defined in spring xml)As discussed in this thread: https://groups.google.com/d/topic/akka-user/ZvF6zQqrCvo/discussion, the camel context is not injectable in the extension.I would be happy to propose a pull-request. However I need some help on how to pass the context to the extension. At the moment I'm thinking at:- adding a public useContext(ctx) method on the CamelExtension object, making it mutable, not very clean.- using a config option to define a classname, that will be dynamically loaded to find the context: seems too complicated.I'd go for that, it is how everything else works in Akka.+1Strange that setting the Registry on the CamelContext does not work, have you verified this yourself that it does not work?Setting the registry is not enough. It does not allow to define routes in xml, unless I missed something.I'll have a deeper look tomorrow, maybe we can take the route definition from spring (inside a routeContext tag) and apply them to the akka camel context.I looked at this. This seems to me to be a wrong approach. xml-defined routes are supposed to be used with an xml-defined context.So I give a try to allow context injection in akka.
On Thu, Feb 13, 2014 at 11:03 AM, Thibaut Robert <thibaut...@gmail.com> wrote:
On Wednesday, February 12, 2014 6:58:53 PM UTC+1, Thibaut Robert wrote:
On Wednesday, February 12, 2014 5:57:35 PM UTC+1, Raymond Roestenburg wrote:On Wed, Feb 12, 2014 at 5:08 PM, √iktor Ҡlang <viktor...@gmail.com> wrote:
On Wed, Feb 12, 2014 at 4:56 PM, Thibaut Robert <thibaut...@gmail.com> wrote:
Hi,I'd like to use akka-camel with my own camel context rather than using the private one defined in the CamelExtension (to reuse routes defined in spring xml)As discussed in this thread: https://groups.google.com/d/topic/akka-user/ZvF6zQqrCvo/discussion, the camel context is not injectable in the extension.I would be happy to propose a pull-request. However I need some help on how to pass the context to the extension. At the moment I'm thinking at:- adding a public useContext(ctx) method on the CamelExtension object, making it mutable, not very clean.- using a config option to define a classname, that will be dynamically loaded to find the context: seems too complicated.I'd go for that, it is how everything else works in Akka.+1Strange that setting the Registry on the CamelContext does not work, have you verified this yourself that it does not work?Setting the registry is not enough. It does not allow to define routes in xml, unless I missed something.I'll have a deeper look tomorrow, maybe we can take the route definition from spring (inside a routeContext tag) and apply them to the akka camel context.I looked at this. This seems to me to be a wrong approach. xml-defined routes are supposed to be used with an xml-defined context.So I give a try to allow context injection in akka.Cool, looking forward to it.
On Sunday, 23 February 2014 at 14:12, Matteo Cusmai wrote:
Can I see more about your proposal?Please share the pr.
You received this message because you are subscribed to a topic in the Google Groups "Akka User List" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/akka-user/TrAmYLrTFKo/unsubscribe.
To unsubscribe from this group and all its topics, send an email to akka-user+...@googlegroups.com.
On 3 March 2014 at 16:06:20, mtsui (kawai...@gmail.com) wrote:
Hi,Is there any documentation or examples out there to get this to work with the snapshot? I'm very interested in using akka with an external spring camel context.Thanks,mtsui
On Sunday, February 23, 2014 10:28:45 AM UTC-5, Konrad Malawski wrote:@Matteo PR’s are public => https://github.com/akka/akka/pull/2014 :-)--KonradOn Sunday, 23 February 2014 at 14:12, Matteo Cusmai wrote:
Can I see more about your proposal?Please share the pr.