Hello, I have a scenario where I am using camel-main with XML Route and a Java Class as a Processor.
It gives me following error: Exception in thread "main" org.apache.camel.FailedToCreateRouteException: Failed to create route route1 at: >>> process[ref:#class:org.myorg.camel.MyProcessor] <<< in route: Route(route1)[From[timer://foo?fixedRate=true&period=60000] ... because of No bean could be found in the registry for: #class:org.myorg.camel.MyProcessor of type: org.apache.camel.Processor at org.apache.camel.reifier.RouteReifier.doCreateRoute(RouteReifier.java:240) at org.apache.camel.reifier.RouteReifier.createRoute(RouteReifier.java:74) at org.apache.camel.impl.DefaultModelReifierFactory.createRoute(DefaultModelReifierFactory.java:49) at org.apache.camel.impl.DefaultCamelContext.startRouteDefinitions(DefaultCamelContext.java:868) at org.apache.camel.impl.DefaultCamelContext.startRouteDefinitions(DefaultCamelContext.java:758) at org.apache.camel.impl.engine.AbstractCamelContext.doInit(AbstractCamelContext.java:2861) at org.apache.camel.support.service.BaseService.init(BaseService.java:83) at org.apache.camel.impl.engine.AbstractCamelContext.init(AbstractCamelContext.java:2567) at org.apache.camel.support.service.BaseService.start(BaseService.java:111) at org.apache.camel.impl.engine.AbstractCamelContext.start(AbstractCamelContext.java:2586) at org.apache.camel.impl.DefaultCamelContext.start(DefaultCamelContext.java:247) at org.apache.camel.main.Main.doStart(Main.java:116) at org.apache.camel.support.service.BaseService.start(BaseService.java:119) at org.apache.camel.main.MainSupport.run(MainSupport.java:69) at org.apache.camel.main.MainCommandLineSupport.run(MainCommandLineSupport.java:174) at org.myorg.camel.MyMainApp.main(MyMainApp.java:21) Caused by: org.apache.camel.NoSuchBeanException: No bean could be found in the registry for: #class:org.myorg.camel.MyProcessor of type: org.apache.camel.Processor at org.apache.camel.support.CamelContextHelper.mandatoryLookup(CamelContextHelper.java:241) at org.apache.camel.reifier.AbstractReifier.mandatoryLookup(AbstractReifier.java:145) at org.apache.camel.reifier.ProcessReifier.createProcessor(ProcessReifier.java:40) at org.apache.camel.reifier.ProcessorReifier.makeProcessor(ProcessorReifier.java:838) at org.apache.camel.reifier.ProcessorReifier.addRoutes(ProcessorReifier.java:579) at org.apache.camel.reifier.RouteReifier.doCreateRoute(RouteReifier.java:236) ... 15 more Example Code is described: https://github.com/chiragsanghavi/camel-experiments/tree/main/processor Basically referring to processor using <process ref="#class:org.myorg.camel.MyProcessor"/> in route directly as described in https://camel.apache.org/manual/processor.html#_referring_to_beans_using_class_syntax . But it doesn't seem to work. Are there any other conditions to using #class ? ચિરાગ/चिराग/Chirag ------------------------------------------ Sent from My Gmail Account