You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@camel.apache.org by champel <ch...@gmail.com> on 2014/08/31 01:58:18 UTC

'Could not unregister error handler' warning destroying a BlueprintCamelContext

Hello,

using Camel 2.13.2 over a Karaf 3.0.1, I’m executing a route defined in a
blueprint that references to an error handler. It starts without any
warning, but when the bundle is stopped I get the following warning:

2014-08-30 16:33:50,770 | INFO  | e ssh user karaf | BlueprintExtender               
| 19 - org.apache.aries.blueprint.core - 1.4.0 | Destroying
BlueprintContainer for bundle blueprintErrorHandlerTest
2014-08-30 16:33:50,773 | INFO  | e ssh user karaf | BlueprintCamelContext           
| 84 - org.apache.camel.camel-core - 2.13.2 | Apache Camel 2.13.2
(CamelContext: blueprintContext) is shutting down
2014-08-30 16:33:50,774 | INFO  | e ssh user karaf | DefaultShutdownStrategy         
| 84 - org.apache.camel.camel-core - 2.13.2 | Starting to graceful shutdown
1 routes (timeout 300 seconds)
2014-08-30 16:33:50,775 | INFO  | 1 - ShutdownTask | DefaultShutdownStrategy         
| 84 - org.apache.camel.camel-core - 2.13.2 | Route: timerToLog shutdown
complete, was consuming from: Endpoint[timer://foo?period=5000]
2014-08-30 16:33:50,775 | INFO  | e ssh user karaf | DefaultShutdownStrategy         
| 84 - org.apache.camel.camel-core - 2.13.2 | Graceful shutdown of 1 routes
completed in 0 seconds
2014-08-30 16:33:50,775 | WARN  | e ssh user karaf |
faultManagementLifecycleStrategy | 84 - org.apache.camel.camel-core - 2.13.2
| Could not unregister error handler:
org.apache.camel.management.mbean.ManagedErrorHandler@1008da34 as
ErrorHandler MBean.
org.apache.camel.NoSuchBeanException: No bean could be found in the registry
for: deadLetterErrorHandler of type:
org.apache.camel.builder.ErrorHandlerBuilder
at
org.apache.camel.util.CamelContextHelper.mandatoryLookup(CamelContextHelper.java:151)
at
org.apache.camel.impl.DefaultRouteContext.mandatoryLookup(DefaultRouteContext.java:144)
at
org.apache.camel.builder.ErrorHandlerBuilderRef.lookupErrorHandlerBuilder(ErrorHandlerBuilderRef.java:125)
at
org.apache.camel.management.DefaultManagementNamingStrategy.getObjectNameForErrorHandler(DefaultManagementNamingStrategy.java:154)
at
org.apache.camel.management.ManagedManagementStrategy.getManagedObjectName(ManagedManagementStrategy.java:104)
at
org.apache.camel.management.ManagedManagementStrategy.unmanageObject(ManagedManagementStrategy.java:143)
at
org.apache.camel.management.DefaultManagementLifecycleStrategy.unmanageObject(DefaultManagementLifecycleStrategy.java:827)
at
org.apache.camel.management.DefaultManagementLifecycleStrategy.onErrorHandlerRemove(DefaultManagementLifecycleStrategy.java:626)
at
org.apache.camel.impl.RouteService.stopChildService(RouteService.java:345)
at org.apache.camel.impl.RouteService.doStop(RouteService.java:222)
at
org.apache.camel.support.ChildServiceSupport.stop(ChildServiceSupport.java:74)
at
org.apache.camel.support.ChildServiceSupport.stop(ChildServiceSupport.java:98)
at org.apache.camel.util.ServiceHelper.stopService(ServiceHelper.java:141)
at
org.apache.camel.util.ServiceHelper.stopAndShutdownService(ServiceHelper.java:204)
at
org.apache.camel.impl.DefaultCamelContext.shutdownServices(DefaultCamelContext.java:2005)
at
org.apache.camel.impl.DefaultCamelContext.shutdownServices(DefaultCamelContext.java:2030)
at
org.apache.camel.impl.DefaultCamelContext.shutdownServices(DefaultCamelContext.java:2018)
at
org.apache.camel.impl.DefaultCamelContext.doStop(DefaultCamelContext.java:1870)
at org.apache.camel.support.ServiceSupport.stop(ServiceSupport.java:102)
at
org.apache.camel.blueprint.BlueprintCamelContext.destroy(BlueprintCamelContext.java:119)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)[:1.7.0_60]
at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)[:1.7.0_60]
at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)[:1.7.0_60]
at java.lang.reflect.Method.invoke(Method.java:606)[:1.7.0_60]
at
org.apache.aries.blueprint.utils.ReflectionUtils.invoke(ReflectionUtils.java:297)
at
org.apache.aries.blueprint.container.BeanRecipe.invoke(BeanRecipe.java:958)
at
org.apache.aries.blueprint.container.BeanRecipe.destroy(BeanRecipe.java:863)
at
org.apache.aries.blueprint.container.BlueprintRepository.destroy(BlueprintRepository.java:320)
at
org.apache.aries.blueprint.container.BlueprintContainerImpl.destroyComponents(BlueprintContainerImpl.java:722)
at
org.apache.aries.blueprint.container.BlueprintContainerImpl.tidyupComponents(BlueprintContainerImpl.java:916)
at
org.apache.aries.blueprint.container.BlueprintContainerImpl.destroy(BlueprintContainerImpl.java:866)
at
org.apache.aries.blueprint.container.BlueprintExtender$3.run(BlueprintExtender.java:301)
at
java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:471)[:1.7.0_60]
at java.util.concurrent.FutureTask.run(FutureTask.java:262)[:1.7.0_60]
at
org.apache.aries.blueprint.container.BlueprintExtender.destroyContainer(BlueprintExtender.java:322)
at
org.apache.aries.blueprint.container.BlueprintExtender.modifiedBundle(BlueprintExtender.java:218)
at
org.apache.aries.util.tracker.hook.BundleHookBundleTracker$Tracked.customizerModified(BundleHookBundleTracker.java:500)
at
org.apache.aries.util.tracker.hook.BundleHookBundleTracker$Tracked.customizerModified(BundleHookBundleTracker.java:433)
at
org.apache.aries.util.tracker.hook.BundleHookBundleTracker$AbstractTracked.track(BundleHookBundleTracker.java:725)
at
org.apache.aries.util.tracker.hook.BundleHookBundleTracker$Tracked.bundleChanged(BundleHookBundleTracker.java:463)
at
org.apache.aries.util.tracker.hook.BundleHookBundleTracker$BundleEventHook.event(BundleHookBundleTracker.java:422)
at
org.apache.felix.framework.util.SecureAction.invokeBundleEventHook(SecureAction.java:1103)
at
org.apache.felix.framework.util.EventDispatcher.createWhitelistFromHooks(EventDispatcher.java:695)
at
org.apache.felix.framework.util.EventDispatcher.fireBundleEvent(EventDispatcher.java:483)
at org.apache.felix.framework.Felix.fireBundleEvent(Felix.java:4403)
at org.apache.felix.framework.Felix.stopBundle(Felix.java:2520)
at org.apache.felix.framework.BundleImpl.stop(BundleImpl.java:991)
at org.apache.felix.framework.BundleImpl.stop(BundleImpl.java:978)
at org.apache.karaf.bundle.command.Stop.executeOnBundle(Stop.java:38)
at
org.apache.karaf.bundle.command.BundlesCommandWithConfirmation.doExecute(BundlesCommandWithConfirmation.java:53)
at
org.apache.karaf.bundle.command.BundlesCommand.doExecute(BundlesCommand.java:50)
at
org.apache.karaf.bundle.command.BundlesCommandWithConfirmation.doExecute(BundlesCommandWithConfirmation.java:41)
at
org.apache.karaf.shell.console.AbstractAction.execute(AbstractAction.java:33)
at
org.apache.karaf.shell.console.OsgiCommandSupport.execute(OsgiCommandSupport.java:39)
at
org.apache.karaf.shell.commands.basic.AbstractCommand.execute(AbstractCommand.java:33)
at sun.reflect.GeneratedMethodAccessor30.invoke(Unknown Source)
at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)[:1.7.0_60]
at java.lang.reflect.Method.invoke(Method.java:606)[:1.7.0_60]
at org.apache.aries.proxy.impl.ProxyHandler$1.invoke(ProxyHandler.java:54)
at org.apache.aries.proxy.impl.ProxyHandler.invoke(ProxyHandler.java:119)
at
org.apache.karaf.shell.console.commands.$BlueprintCommand627362708.execute(Unknown
Source)[37:org.apache.karaf.shell.console:3.0.1]
at sun.reflect.GeneratedMethodAccessor30.invoke(Unknown Source)
at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)[:1.7.0_60]
at java.lang.reflect.Method.invoke(Method.java:606)[:1.7.0_60]
at org.apache.aries.proxy.impl.ProxyHandler$1.invoke(ProxyHandler.java:54)
at org.apache.aries.proxy.impl.ProxyHandler.invoke(ProxyHandler.java:119)
at
org.apache.karaf.shell.console.commands.$BlueprintCommand627362708.execute(Unknown
Source)[37:org.apache.karaf.shell.console:3.0.1]
at
org.apache.felix.gogo.runtime.CommandProxy.execute(CommandProxy.java:78)[37:org.apache.karaf.shell.console:3.0.1]
at
org.apache.felix.gogo.runtime.Closure.executeCmd(Closure.java:477)[37:org.apache.karaf.shell.console:3.0.1]
at
org.apache.felix.gogo.runtime.Closure.executeStatement(Closure.java:403)[37:org.apache.karaf.shell.console:3.0.1]
at
org.apache.felix.gogo.runtime.Pipe.run(Pipe.java:108)[37:org.apache.karaf.shell.console:3.0.1]
at
org.apache.felix.gogo.runtime.Closure.execute(Closure.java:183)[37:org.apache.karaf.shell.console:3.0.1]
at
org.apache.felix.gogo.runtime.Closure.execute(Closure.java:120)[37:org.apache.karaf.shell.console:3.0.1]
at
org.apache.felix.gogo.runtime.CommandSessionImpl.execute(CommandSessionImpl.java:89)
at
org.apache.karaf.shell.console.impl.jline.ConsoleImpl$DelegateSession.execute(ConsoleImpl.java:521)
at
org.apache.karaf.shell.console.impl.jline.ConsoleImpl.run(ConsoleImpl.java:212)
at java.lang.Thread.run(Thread.java:745)[:1.7.0_60]
at
org.apache.karaf.shell.console.impl.jline.ConsoleFactoryService$3.doRun(ConsoleFactoryService.java:126)[37:org.apache.karaf.shell.console:3.0.1]
at
org.apache.karaf.shell.console.impl.jline.ConsoleFactoryService$3$1.run(ConsoleFactoryService.java:117)
at java.security.AccessController.doPrivileged(Native Method)[:1.7.0_60]
at
org.apache.karaf.jaas.modules.JaasHelper.doAs(JaasHelper.java:47)[38:org.apache.karaf.jaas.modules:3.0.1]
at
org.apache.karaf.shell.console.impl.jline.ConsoleFactoryService$3.run(ConsoleFactoryService.java:115)[37:org.apache.karaf.shell.console:3.0.1]


To reproduce this issue I created a simple blueprint based on the
camel-archetype-blueprint and added the error handler:

<?xml version="1.0" encoding="UTF-8"?>
<blueprint xmlns="http://www.osgi.org/xmlns/blueprint/v1.0.0"
       xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
       xmlns:camel="http://camel.apache.org/schema/blueprint"
       xsi:schemaLocation="
       http://www.osgi.org/xmlns/blueprint/v1.0.0
http://www.osgi.org/xmlns/blueprint/v1.0.0/blueprint.xsd
       http://camel.apache.org/schema/blueprint
http://camel.apache.org/schema/blueprint/camel-blueprint.xsd">
  <bean id="helloBean" class="cat.champel.tests.HelloBean">
      <property name="say" value="Hi from Camel"/>
  </bean>
  <camelContext id="blueprintContext" trace="false"
xmlns="http://camel.apache.org/schema/blueprint">
*    <errorHandler id="deadLetterErrorHandler" type="DeadLetterChannel"
deadLetterUri="mock:error">
      <camel:redeliveryPolicy logHandled="true" logStackTrace="true"/>
    </errorHandler>
    <route id="timerToLog" errorHandlerRef="deadLetterErrorHandler">
*      <from uri="timer:foo?period=5000"/>
      <setBody>
          <method ref="helloBean" method="hello"/>
      </setBody>
      <log message="The message contains ${body}"/>
      <to uri="mock:result"/>
    </route>
  </camelContext>
</blueprint>

Is there any solution to avoid this exception?

Thanks, 
Ch.



--
View this message in context: http://camel.465427.n5.nabble.com/Could-not-unregister-error-handler-warning-destroying-a-BlueprintCamelContext-tp5755881.html
Sent from the Camel - Users mailing list archive at Nabble.com.

Re: 'Could not unregister error handler' warning destroying a BlueprintCamelContext

Posted by champel <ch...@gmail.com>.
Thank you Charles,

it would be great to investigate why the class is not found in the registry.
The exception is written three times by stop and it fills the log with a lot
of warnings.



--
View this message in context: http://camel.465427.n5.nabble.com/Could-not-unregister-error-handler-warning-destroying-a-BlueprintCamelContext-tp5755881p5755927.html
Sent from the Camel - Users mailing list archive at Nabble.com.

Re: 'Could not unregister error handler' warning destroying a BlueprintCamelContext

Posted by Charles Moulliard <ch...@gmail.com>.
Hi Sergio,

This is a WARNING message and not an ERROR message. Nevertheless, it could
be interesting that we investigate why Blueprint report that the Bean is
not of type 'deadLetterErrorHandler of type:
org.apache.camel.builder.ErrorHandlerBuilder' as the Class
'DeadLetterChannelBuilder' used to instantiate a DeadLetterErrorHandler
extends the DefaultErrorHandlerBuilder extending
'ErrorHandlerBuilderSupport' which finally instantiates
'ErrorHandlerBuilderSupport implementing ErrorHandlerBuilder '

Regards,



On Sun, Aug 31, 2014 at 1:58 AM, champel <ch...@gmail.com> wrote:

> Hello,
>
> using Camel 2.13.2 over a Karaf 3.0.1, I’m executing a route defined in a
> blueprint that references to an error handler. It starts without any
> warning, but when the bundle is stopped I get the following warning:
>
> 2014-08-30 16:33:50,770 | INFO  | e ssh user karaf | BlueprintExtender
> | 19 - org.apache.aries.blueprint.core - 1.4.0 | Destroying
> BlueprintContainer for bundle blueprintErrorHandlerTest
> 2014-08-30 16:33:50,773 | INFO  | e ssh user karaf | BlueprintCamelContext
> | 84 - org.apache.camel.camel-core - 2.13.2 | Apache Camel 2.13.2
> (CamelContext: blueprintContext) is shutting down
> 2014-08-30 16:33:50,774 | INFO  | e ssh user karaf |
> DefaultShutdownStrategy
> | 84 - org.apache.camel.camel-core - 2.13.2 | Starting to graceful shutdown
> 1 routes (timeout 300 seconds)
> 2014-08-30 16:33:50,775 | INFO  | 1 - ShutdownTask |
> DefaultShutdownStrategy
> | 84 - org.apache.camel.camel-core - 2.13.2 | Route: timerToLog shutdown
> complete, was consuming from: Endpoint[timer://foo?period=5000]
> 2014-08-30 16:33:50,775 | INFO  | e ssh user karaf |
> DefaultShutdownStrategy
> | 84 - org.apache.camel.camel-core - 2.13.2 | Graceful shutdown of 1 routes
> completed in 0 seconds
> 2014-08-30 16:33:50,775 | WARN  | e ssh user karaf |
> faultManagementLifecycleStrategy | 84 - org.apache.camel.camel-core -
> 2.13.2
> | Could not unregister error handler:
> org.apache.camel.management.mbean.ManagedErrorHandler@1008da34 as
> ErrorHandler MBean.
> org.apache.camel.NoSuchBeanException: No bean could be found in the
> registry
> for: deadLetterErrorHandler of type:
> org.apache.camel.builder.ErrorHandlerBuilder
> at
>
> org.apache.camel.util.CamelContextHelper.mandatoryLookup(CamelContextHelper.java:151)
> at
>
> org.apache.camel.impl.DefaultRouteContext.mandatoryLookup(DefaultRouteContext.java:144)
> at
>
> org.apache.camel.builder.ErrorHandlerBuilderRef.lookupErrorHandlerBuilder(ErrorHandlerBuilderRef.java:125)
> at
>
> org.apache.camel.management.DefaultManagementNamingStrategy.getObjectNameForErrorHandler(DefaultManagementNamingStrategy.java:154)
> at
>
> org.apache.camel.management.ManagedManagementStrategy.getManagedObjectName(ManagedManagementStrategy.java:104)
> at
>
> org.apache.camel.management.ManagedManagementStrategy.unmanageObject(ManagedManagementStrategy.java:143)
> at
>
> org.apache.camel.management.DefaultManagementLifecycleStrategy.unmanageObject(DefaultManagementLifecycleStrategy.java:827)
> at
>
> org.apache.camel.management.DefaultManagementLifecycleStrategy.onErrorHandlerRemove(DefaultManagementLifecycleStrategy.java:626)
> at
> org.apache.camel.impl.RouteService.stopChildService(RouteService.java:345)
> at org.apache.camel.impl.RouteService.doStop(RouteService.java:222)
> at
>
> org.apache.camel.support.ChildServiceSupport.stop(ChildServiceSupport.java:74)
> at
>
> org.apache.camel.support.ChildServiceSupport.stop(ChildServiceSupport.java:98)
> at org.apache.camel.util.ServiceHelper.stopService(ServiceHelper.java:141)
> at
>
> org.apache.camel.util.ServiceHelper.stopAndShutdownService(ServiceHelper.java:204)
> at
>
> org.apache.camel.impl.DefaultCamelContext.shutdownServices(DefaultCamelContext.java:2005)
> at
>
> org.apache.camel.impl.DefaultCamelContext.shutdownServices(DefaultCamelContext.java:2030)
> at
>
> org.apache.camel.impl.DefaultCamelContext.shutdownServices(DefaultCamelContext.java:2018)
> at
>
> org.apache.camel.impl.DefaultCamelContext.doStop(DefaultCamelContext.java:1870)
> at org.apache.camel.support.ServiceSupport.stop(ServiceSupport.java:102)
> at
>
> org.apache.camel.blueprint.BlueprintCamelContext.destroy(BlueprintCamelContext.java:119)
> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)[:1.7.0_60]
> at
>
> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)[:1.7.0_60]
> at
>
> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)[:1.7.0_60]
> at java.lang.reflect.Method.invoke(Method.java:606)[:1.7.0_60]
> at
>
> org.apache.aries.blueprint.utils.ReflectionUtils.invoke(ReflectionUtils.java:297)
> at
> org.apache.aries.blueprint.container.BeanRecipe.invoke(BeanRecipe.java:958)
> at
>
> org.apache.aries.blueprint.container.BeanRecipe.destroy(BeanRecipe.java:863)
> at
>
> org.apache.aries.blueprint.container.BlueprintRepository.destroy(BlueprintRepository.java:320)
> at
>
> org.apache.aries.blueprint.container.BlueprintContainerImpl.destroyComponents(BlueprintContainerImpl.java:722)
> at
>
> org.apache.aries.blueprint.container.BlueprintContainerImpl.tidyupComponents(BlueprintContainerImpl.java:916)
> at
>
> org.apache.aries.blueprint.container.BlueprintContainerImpl.destroy(BlueprintContainerImpl.java:866)
> at
>
> org.apache.aries.blueprint.container.BlueprintExtender$3.run(BlueprintExtender.java:301)
> at
>
> java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:471)[:1.7.0_60]
> at java.util.concurrent.FutureTask.run(FutureTask.java:262)[:1.7.0_60]
> at
>
> org.apache.aries.blueprint.container.BlueprintExtender.destroyContainer(BlueprintExtender.java:322)
> at
>
> org.apache.aries.blueprint.container.BlueprintExtender.modifiedBundle(BlueprintExtender.java:218)
> at
>
> org.apache.aries.util.tracker.hook.BundleHookBundleTracker$Tracked.customizerModified(BundleHookBundleTracker.java:500)
> at
>
> org.apache.aries.util.tracker.hook.BundleHookBundleTracker$Tracked.customizerModified(BundleHookBundleTracker.java:433)
> at
>
> org.apache.aries.util.tracker.hook.BundleHookBundleTracker$AbstractTracked.track(BundleHookBundleTracker.java:725)
> at
>
> org.apache.aries.util.tracker.hook.BundleHookBundleTracker$Tracked.bundleChanged(BundleHookBundleTracker.java:463)
> at
>
> org.apache.aries.util.tracker.hook.BundleHookBundleTracker$BundleEventHook.event(BundleHookBundleTracker.java:422)
> at
>
> org.apache.felix.framework.util.SecureAction.invokeBundleEventHook(SecureAction.java:1103)
> at
>
> org.apache.felix.framework.util.EventDispatcher.createWhitelistFromHooks(EventDispatcher.java:695)
> at
>
> org.apache.felix.framework.util.EventDispatcher.fireBundleEvent(EventDispatcher.java:483)
> at org.apache.felix.framework.Felix.fireBundleEvent(Felix.java:4403)
> at org.apache.felix.framework.Felix.stopBundle(Felix.java:2520)
> at org.apache.felix.framework.BundleImpl.stop(BundleImpl.java:991)
> at org.apache.felix.framework.BundleImpl.stop(BundleImpl.java:978)
> at org.apache.karaf.bundle.command.Stop.executeOnBundle(Stop.java:38)
> at
>
> org.apache.karaf.bundle.command.BundlesCommandWithConfirmation.doExecute(BundlesCommandWithConfirmation.java:53)
> at
>
> org.apache.karaf.bundle.command.BundlesCommand.doExecute(BundlesCommand.java:50)
> at
>
> org.apache.karaf.bundle.command.BundlesCommandWithConfirmation.doExecute(BundlesCommandWithConfirmation.java:41)
> at
>
> org.apache.karaf.shell.console.AbstractAction.execute(AbstractAction.java:33)
> at
>
> org.apache.karaf.shell.console.OsgiCommandSupport.execute(OsgiCommandSupport.java:39)
> at
>
> org.apache.karaf.shell.commands.basic.AbstractCommand.execute(AbstractCommand.java:33)
> at sun.reflect.GeneratedMethodAccessor30.invoke(Unknown Source)
> at
>
> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)[:1.7.0_60]
> at java.lang.reflect.Method.invoke(Method.java:606)[:1.7.0_60]
> at org.apache.aries.proxy.impl.ProxyHandler$1.invoke(ProxyHandler.java:54)
> at org.apache.aries.proxy.impl.ProxyHandler.invoke(ProxyHandler.java:119)
> at
>
> org.apache.karaf.shell.console.commands.$BlueprintCommand627362708.execute(Unknown
> Source)[37:org.apache.karaf.shell.console:3.0.1]
> at sun.reflect.GeneratedMethodAccessor30.invoke(Unknown Source)
> at
>
> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)[:1.7.0_60]
> at java.lang.reflect.Method.invoke(Method.java:606)[:1.7.0_60]
> at org.apache.aries.proxy.impl.ProxyHandler$1.invoke(ProxyHandler.java:54)
> at org.apache.aries.proxy.impl.ProxyHandler.invoke(ProxyHandler.java:119)
> at
>
> org.apache.karaf.shell.console.commands.$BlueprintCommand627362708.execute(Unknown
> Source)[37:org.apache.karaf.shell.console:3.0.1]
> at
>
> org.apache.felix.gogo.runtime.CommandProxy.execute(CommandProxy.java:78)[37:org.apache.karaf.shell.console:3.0.1]
> at
>
> org.apache.felix.gogo.runtime.Closure.executeCmd(Closure.java:477)[37:org.apache.karaf.shell.console:3.0.1]
> at
>
> org.apache.felix.gogo.runtime.Closure.executeStatement(Closure.java:403)[37:org.apache.karaf.shell.console:3.0.1]
> at
>
> org.apache.felix.gogo.runtime.Pipe.run(Pipe.java:108)[37:org.apache.karaf.shell.console:3.0.1]
> at
>
> org.apache.felix.gogo.runtime.Closure.execute(Closure.java:183)[37:org.apache.karaf.shell.console:3.0.1]
> at
>
> org.apache.felix.gogo.runtime.Closure.execute(Closure.java:120)[37:org.apache.karaf.shell.console:3.0.1]
> at
>
> org.apache.felix.gogo.runtime.CommandSessionImpl.execute(CommandSessionImpl.java:89)
> at
>
> org.apache.karaf.shell.console.impl.jline.ConsoleImpl$DelegateSession.execute(ConsoleImpl.java:521)
> at
>
> org.apache.karaf.shell.console.impl.jline.ConsoleImpl.run(ConsoleImpl.java:212)
> at java.lang.Thread.run(Thread.java:745)[:1.7.0_60]
> at
>
> org.apache.karaf.shell.console.impl.jline.ConsoleFactoryService$3.doRun(ConsoleFactoryService.java:126)[37:org.apache.karaf.shell.console:3.0.1]
> at
>
> org.apache.karaf.shell.console.impl.jline.ConsoleFactoryService$3$1.run(ConsoleFactoryService.java:117)
> at java.security.AccessController.doPrivileged(Native Method)[:1.7.0_60]
> at
>
> org.apache.karaf.jaas.modules.JaasHelper.doAs(JaasHelper.java:47)[38:org.apache.karaf.jaas.modules:3.0.1]
> at
>
> org.apache.karaf.shell.console.impl.jline.ConsoleFactoryService$3.run(ConsoleFactoryService.java:115)[37:org.apache.karaf.shell.console:3.0.1]
>
>
> To reproduce this issue I created a simple blueprint based on the
> camel-archetype-blueprint and added the error handler:
>
> <?xml version="1.0" encoding="UTF-8"?>
> <blueprint xmlns="http://www.osgi.org/xmlns/blueprint/v1.0.0"
>        xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
>        xmlns:camel="http://camel.apache.org/schema/blueprint"
>        xsi:schemaLocation="
>        http://www.osgi.org/xmlns/blueprint/v1.0.0
> http://www.osgi.org/xmlns/blueprint/v1.0.0/blueprint.xsd
>        http://camel.apache.org/schema/blueprint
> http://camel.apache.org/schema/blueprint/camel-blueprint.xsd">
>   <bean id="helloBean" class="cat.champel.tests.HelloBean">
>       <property name="say" value="Hi from Camel"/>
>   </bean>
>   <camelContext id="blueprintContext" trace="false"
> xmlns="http://camel.apache.org/schema/blueprint">
> *    <errorHandler id="deadLetterErrorHandler" type="DeadLetterChannel"
> deadLetterUri="mock:error">
>       <camel:redeliveryPolicy logHandled="true" logStackTrace="true"/>
>     </errorHandler>
>     <route id="timerToLog" errorHandlerRef="deadLetterErrorHandler">
> *      <from uri="timer:foo?period=5000"/>
>       <setBody>
>           <method ref="helloBean" method="hello"/>
>       </setBody>
>       <log message="The message contains ${body}"/>
>       <to uri="mock:result"/>
>     </route>
>   </camelContext>
> </blueprint>
>
> Is there any solution to avoid this exception?
>
> Thanks,
> Ch.
>
>
>
> --
> View this message in context:
> http://camel.465427.n5.nabble.com/Could-not-unregister-error-handler-warning-destroying-a-BlueprintCamelContext-tp5755881.html
> Sent from the Camel - Users mailing list archive at Nabble.com.
>



-- 
Charles Moulliard
Apache Committer / Architect @RedHat
Twitter : @cmoulliard | Blog :  http://cmoulliard.github.io