Uploaded image for project: 'FUSE Mediation Router'
  1. FUSE Mediation Router
  2. MR-485

Failed to create route fromQueueToLog at: >>> Transacted[ref:null] <<< in route: Route[[From[activemq:acoss]] - ClassCastException - Camel Blueprint

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Major
    • Resolution: Out of Date
    • Affects Version/s: 2.7.1-fuse-00-27
    • Fix Version/s: None
    • Component/s: None
    • Labels:
      None

      Description

      When deploying a camel DSL route defined using camel-blueprint, then the following error is generated :

      11:50:29,317 | ERROR | rint Extender: 3 | BlueprintContainerImpl           | ?                                   ? | 10 - org.apache.aries.blueprint - 0.3.1 | Unable to start blueprint container for bundle config-camel.xml
      org.osgi.service.blueprint.container.ComponentDefinitionException: Unable to intialize bean camel-1
      	at org.apache.aries.blueprint.container.BeanRecipe.runBeanProcInit(BeanRecipe.java:638)[10:org.apache.aries.blueprint:0.3.1]
      	at org.apache.aries.blueprint.container.BeanRecipe.internalCreate(BeanRecipe.java:724)[10:org.apache.aries.blueprint:0.3.1]
      	at org.apache.aries.blueprint.di.AbstractRecipe.create(AbstractRecipe.java:64)[10:org.apache.aries.blueprint:0.3.1]
      	at org.apache.aries.blueprint.container.BlueprintRepository.createInstances(BlueprintRepository.java:219)[10:org.apache.aries.blueprint:0.3.1]
      	at org.apache.aries.blueprint.container.BlueprintRepository.createInstance(BlueprintRepository.java:198)[10:org.apache.aries.blueprint:0.3.1]
      	at org.apache.aries.blueprint.container.BlueprintRepository.create(BlueprintRepository.java:137)[10:org.apache.aries.blueprint:0.3.1]
      	at org.apache.aries.blueprint.container.BlueprintContainerImpl.getComponentInstance(BlueprintContainerImpl.java:718)[10:org.apache.aries.blueprint:0.3.1]
      	at org.apache.camel.blueprint.handler.CamelNamespaceHandler$CamelDependenciesFinder.process(CamelNamespaceHandler.java:499)[84:org.apache.camel.camel-blueprint:2.7.1.fuse-00-27]
      	at org.apache.aries.blueprint.container.BlueprintContainerImpl.processProcessors(BlueprintContainerImpl.java:495)[10:org.apache.aries.blueprint:0.3.1]
      	at org.apache.aries.blueprint.container.BlueprintContainerImpl.doRun(BlueprintContainerImpl.java:314)[10:org.apache.aries.blueprint:0.3.1]
      	at org.apache.aries.blueprint.container.BlueprintContainerImpl.run(BlueprintContainerImpl.java:227)[10:org.apache.aries.blueprint:0.3.1]
      	at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:441)[:1.6.0_24]
      	at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303)[:1.6.0_24]
      	at java.util.concurrent.FutureTask.run(FutureTask.java:138)[:1.6.0_24]
      	at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$301(ScheduledThreadPoolExecutor.java:98)[:1.6.0_24]
      	at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:206)[:1.6.0_24]
      	at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)[:1.6.0_24]
      	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)[:1.6.0_24]
      	at java.lang.Thread.run(Thread.java:680)[:1.6.0_24]
      Caused by: org.apache.camel.FailedToCreateRouteException: Failed to create route fromQueueToLog at: >>> Transacted[ref:null] <<< in route: Route[[From[activemq:acoss]] -> [Transacted[ref:null]]] because of java.lang.ClassCastException
      	at org.apache.camel.model.RouteDefinition.addRoutes(RouteDefinition.java:818)
      	at org.apache.camel.model.RouteDefinition.addRoutes(RouteDefinition.java:165)
      	at org.apache.camel.impl.DefaultCamelContext.startRoute(DefaultCamelContext.java:708)
      	at org.apache.camel.impl.DefaultCamelContext.startRouteDefinitions(DefaultCamelContext.java:1650)
      	at org.apache.camel.impl.DefaultCamelContext.doStartCamel(DefaultCamelContext.java:1439)
      	at org.apache.camel.impl.DefaultCamelContext.doStart(DefaultCamelContext.java:1338)
      	at org.apache.camel.impl.ServiceSupport.start(ServiceSupport.java:67)
      	at org.apache.camel.impl.ServiceSupport.start(ServiceSupport.java:54)
      	at org.apache.camel.impl.DefaultCamelContext.start(DefaultCamelContext.java:1316)
      	at org.apache.camel.blueprint.BlueprintCamelContext.maybeStart(BlueprintCamelContext.java:78)
      	at org.apache.camel.blueprint.BlueprintCamelContext.init(BlueprintCamelContext.java:73)
      	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)[:1.6.0_24]
      	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)[:1.6.0_24]
      	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)[:1.6.0_24]
      	at java.lang.reflect.Method.invoke(Method.java:597)[:1.6.0_24]
      	at org.apache.aries.blueprint.utils.ReflectionUtils.invoke(ReflectionUtils.java:226)[10:org.apache.aries.blueprint:0.3.1]
      	at org.apache.aries.blueprint.container.BeanRecipe.invoke(BeanRecipe.java:824)[10:org.apache.aries.blueprint:0.3.1]
      	at org.apache.aries.blueprint.container.BeanRecipe.runBeanProcInit(BeanRecipe.java:636)[10:org.apache.aries.blueprint:0.3.1]
      	... 18 more
      Caused by: org.apache.camel.RuntimeCamelException: java.lang.ClassCastException
      	at org.apache.camel.util.ObjectHelper.wrapRuntimeCamelException(ObjectHelper.java:1139)
      	at org.apache.camel.impl.PropertyPlaceholderDelegateRegistry.lookup(PropertyPlaceholderDelegateRegistry.java:56)
      	at org.apache.camel.impl.DefaultRouteContext.lookup(DefaultRouteContext.java:139)
      	at org.apache.camel.model.TransactedDefinition.doResolvePolicy(TransactedDefinition.java:191)
      	at org.apache.camel.model.TransactedDefinition.resolvePolicy(TransactedDefinition.java:162)
      	at org.apache.camel.model.TransactedDefinition.createProcessor(TransactedDefinition.java:133)
      	at org.apache.camel.model.ProcessorDefinition.makeProcessor(ProcessorDefinition.java:433)
      	at org.apache.camel.model.ProcessorDefinition.addRoutes(ProcessorDefinition.java:181)
      	at org.apache.camel.model.RouteDefinition.addRoutes(RouteDefinition.java:815)
      	... 35 more
      Caused by: java.lang.ClassCastException
      	at java.lang.Class.cast(Class.java:2990)[:1.6.0_24]
      	at org.apache.camel.blueprint.BlueprintContainerRegistry.lookup(BlueprintContainerRegistry.java:43)
      	at org.apache.camel.impl.CompositeRegistry.lookup(CompositeRegistry.java:47)
      	at org.apache.camel.impl.PropertyPlaceholderDelegateRegistry.lookup(PropertyPlaceholderDelegateRegistry.java:54)
      	... 42 more
       

      To reproduce the error :

      0) Edit the file /etc/org.apache.karaf.features.cfg

      #
      featuresBoot=karaf-framework,config,activemq,camel,camel-blueprint,camel-jms,camel-activemq

      1) Start Fuse ESB 4.4.0-fuse-00-27

      2) Drag and drop the 2 following files in deploy directory

        Gliffy Diagrams

          Attachments

            Activity

              People

              • Assignee:
                davsclaus Claus Ibsen
                Reporter:
                cmoulliard Charles Moulliard
              • Votes:
                0 Vote for this issue
                Watchers:
                1 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: