camel-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Willem Jiang (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (CAMEL-3521) OsgiLifecycleStrategy - To register and unregister camel services in OSGi service registry on-the-fly
Date Thu, 01 Sep 2011 07:50:10 GMT

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

Willem Jiang commented on CAMEL-3521:
-------------------------------------

I did some experiment on this task by using the LifecyleStrategy to publish the CamelContext.
When I running some OSGi tests, I got some tests hang for a dead lock. After digging the issue
I found the LifecycleStrategy is not suit for this case. 
First we need to make sure that CamelContext is started already when we publish it as a OSGi
service.
Second it is not a good practice to put all the instance into OSGi service, we just put the
service factory or the important instance into the OSGi service registry. 
Third we can find the components, endpoints, routes from CamelContext.

I will close this task as the event notification solution is just working.
  

> OsgiLifecycleStrategy - To register and unregister camel services in OSGi service registry
on-the-fly
> -----------------------------------------------------------------------------------------------------
>
>                 Key: CAMEL-3521
>                 URL: https://issues.apache.org/jira/browse/CAMEL-3521
>             Project: Camel
>          Issue Type: New Feature
>          Components: osgi
>    Affects Versions: 2.5.0
>            Reporter: Claus Ibsen
>            Assignee: Willem Jiang
>             Fix For: 2.9.0, Future
>
>
> In camel-core-osgi we got the osgi integration with Camel.
> Currently we got OsgiCamelContextPublisher which can register/unregister CamelContext
in OSGi service registry.
> Its based on Camel's EventNotifier.
> Instead we should use org.apache.camel.spi.LifecycleStrategy instead. It has more fine
grained events.
> That allows us to register much more
> - CamelContext
> - Component
> - Endpoint
> - Route
> - Service
> - ThreadPool
> - ErrorHandler

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

Mime
View raw message