You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@camel.apache.org by "Claus Ibsen (Updated) (JIRA)" <ji...@apache.org> on 2011/11/14 19:05:51 UTC

[jira] [Updated] (CAMEL-4678) Allow lifecycle strategy to veto starting CamelContext, but to suppress exception to ensure bundle is in valid state in OSGi

     [ https://issues.apache.org/jira/browse/CAMEL-4678?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Claus Ibsen updated CAMEL-4678:
-------------------------------

    Description: 
A custom lifecycle strategy can veto starting CamelContext in case something is wrong etc.
This can be done by throwing the VetoCamelContextStartException in the onCamelContextStart method.

However currently the exception is re-thrown all the way causing the osgi container to regard the bundle in failure state.
Where as you may want the bundle to start properly, but what you intend to do is to prevent CamelContext itself from starting.

For example currently you will get this state
 [ 218] [Active     ] [Failure     ] [       ] [   60] Camel Demo App for Veto starting a CamelContext (1.0.0)

And this error in the log
 15:58:13,057 | ERROR | rint Extender: 1 | BlueprintContainerImpl           | ?                                   ? | 10 - org.apache.aries.blueprint - 0.3.1 | Unable to start blueprint container for bundle foo


  was:
A custom lifecycle strategy can veto starting CamelContext in case something is wrong etc.
This can be done by throwing the VetoCamelContextStartException in the onCamelContextStart method.

However currently the exception is re-thrown all the way causing the osgi container to regard the bundle in failure state.
Where as you may want the bundle to start properly, but what you intend to do is to prevent CamelContext itself from starting.

For example currently you will get this state
{code}
 15:58:13,057 | ERROR | rint Extender: 1 | BlueprintContainerImpl           | ?                                   ? | 10 - org.apache.aries.blueprint - 0.3.1 | Unable to start blueprint container for bundle foo
{code}

    
> Allow lifecycle strategy to veto starting CamelContext, but to suppress exception to ensure bundle is in valid state in OSGi
> ----------------------------------------------------------------------------------------------------------------------------
>
>                 Key: CAMEL-4678
>                 URL: https://issues.apache.org/jira/browse/CAMEL-4678
>             Project: Camel
>          Issue Type: Improvement
>          Components: camel-core
>            Reporter: Claus Ibsen
>            Assignee: Claus Ibsen
>            Priority: Minor
>             Fix For: 2.8.3, 2.9.0
>
>
> A custom lifecycle strategy can veto starting CamelContext in case something is wrong etc.
> This can be done by throwing the VetoCamelContextStartException in the onCamelContextStart method.
> However currently the exception is re-thrown all the way causing the osgi container to regard the bundle in failure state.
> Where as you may want the bundle to start properly, but what you intend to do is to prevent CamelContext itself from starting.
> For example currently you will get this state
>  [ 218] [Active     ] [Failure     ] [       ] [   60] Camel Demo App for Veto starting a CamelContext (1.0.0)
> And this error in the log
>  15:58:13,057 | ERROR | rint Extender: 1 | BlueprintContainerImpl           | ?                                   ? | 10 - org.apache.aries.blueprint - 0.3.1 | Unable to start blueprint container for bundle foo

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira