You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@camel.apache.org by "Sergey Beryozkin (JIRA)" <ji...@apache.org> on 2010/01/06 14:35:17 UTC

[jira] Issue Comment Edited: (CAMEL-2137) Beans can not be used in Camel routes deployed as JBI service units to ServiceMix

    [ https://issues.apache.org/activemq/browse/CAMEL-2137?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=56786#action_56786 ] 

Sergey Beryozkin edited comment on CAMEL-2137 at 1/6/10 1:34 PM:
-----------------------------------------------------------------

Hi Willem

It is ServiceMix 4.1, Camel 2.x (not entirely sure what specific Camel version I was using at a time) 

The pseudo camel route will look like this:

<route>
<!-- quartz is defined in a separate JBI SU, see SMC quartz demo -->
<from:jbi:the-quartz-endpoint-output/>

<!-- see my transform bean in SMX camel demos -->
<to "MyTransformBean"/>

<to: log>
</route>

It all works really well when a Camel route is deployed as OSGI bundle. But the bean part is missed if it is deployed as JBI SU. 

This is something I spotted awhile back so I do not have a complete SA at hand. I'm not sure how critical this issue is given that camel routes are better be directly deployed as OSGI bundles. 
Feel free to close this issue if you find out that it is not possible to fix it at the JBI level. Perhaps it can be closed as wont-fix and docs can be updated advising users (like me :-)) not to use JBI SU to deploy routes containing beans but rather pure OSGI bundles 

      was (Author: sergey_beryozkin):
    Hi Willem

The pseudo camel route will look like this:

<route>
<!-- quartz is defined in a separate JBI SU -->
<from:jbi:the-quartz-endpoint-output/>

<!-- see my transform bean in SMX camel demos -->
<to "MyTransformBean"/>

<to: log>
</route>

It all works really well when a Camel route is deployed as OSGI bundle. But the bean part is missed if it is deployed as JBI SU. 

This is something I spotted awhile back so I do not have a complete SA at hand. I'm not sure how critical this issue is given that camel routes are better be directly deployed as OSGI bundles. 
Feel free to close this issue if you find out that it is not possible to fix it at the JBI level

  
> Beans can not be used in Camel routes deployed as JBI service units to ServiceMix
> ---------------------------------------------------------------------------------
>
>                 Key: CAMEL-2137
>                 URL: https://issues.apache.org/activemq/browse/CAMEL-2137
>             Project: Apache Camel
>          Issue Type: Bug
>          Components: camel-jbi
>            Reporter: Sergey Beryozkin
>             Fix For: 2.2.0
>
>
> Create a JBI SU containing a quartz timer.
> Create a JBI SU cointaining a Camel route which, for ex, includes, a custom transformation part executed by MyTransform bean class (similarly to that shipped with a number of camel examples). Start from a from: rule which gets the events from a quartz endpoint and delegates to MyTransfrom and let the output from MyTransfrom go to log:test.
> This bean won't be invoked and after deploying the assembly and doing
> log:display | grep test
> you'll see that quartz events are indeed picked up but they're transmitted directly to log:test

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.