Is the camel jbi component available in your classpath ?
It seems camel can not resolve the jbi: protocol which would mean the
needed jar is not available.

On Fri, May 30, 2008 at 10:35 AM, Sebastian Gomez <[EMAIL PROTECTED]> wrote:
> You're probably right. It seems like it's looking for the endpoints
> when building the route. Have you got any idea of how I could bypass
> this problem? Maybe by using the Java RouteBuilder it won't be looking
> for endpoints until runtime. I'll try it out to see if it works.
>
> Here is the stack trace:
>
> [org.springframework.web.context.ContextLoader] - Context
> initialization failed
> org.apache.camel.NoSuchEndpointException: No endpoint could be found
> for: jbi:service:http://my.namespace.com/tracker
>       at 
> org.apache.camel.util.CamelContextHelper.getMandatoryEndpoint(CamelContextHelper.java:54)
>       at org.apache.camel.model.RouteType.resolveEndpoint(RouteType.java:92)
>       at 
> org.apache.camel.impl.RouteContext.resolveEndpoint(RouteContext.java:95)
>       at 
> org.apache.camel.impl.RouteContext.resolveEndpoint(RouteContext.java:104)
>       at org.apache.camel.model.ToType.resolveEndpoint(ToType.java:78)
>       at org.apache.camel.model.ToType.createProcessor(ToType.java:72)
>       at 
> org.apache.camel.model.ProcessorType.makeProcessor(ProcessorType.java:1387)
>       at org.apache.camel.model.ProcessorType.addRoutes(ProcessorType.java:95)
>       at org.apache.camel.model.RouteType.addRoutes(RouteType.java:189)
>       at org.apache.camel.model.RouteType.addRoutes(RouteType.java:83)
>       at 
> org.apache.camel.impl.DefaultCamelContext.startRouteDefinitions(DefaultCamelContext.java:438)
>       at 
> org.apache.camel.impl.DefaultCamelContext.doStart(DefaultCamelContext.java:430)
>       at 
> org.apache.camel.spring.SpringCamelContext.doStart(SpringCamelContext.java:148)
>       at org.apache.camel.impl.ServiceSupport.start(ServiceSupport.java:47)
>       at 
> org.apache.camel.spring.SpringCamelContext.onApplicationEvent(SpringCamelContext.java:102)
>       at 
> org.springframework.context.event.SimpleApplicationEventMulticaster$1.run(SimpleApplicationEventMulticaster.java:77)
>       at 
> org.springframework.core.task.SyncTaskExecutor.execute(SyncTaskExecutor.java:49)
>       at 
> org.springframework.context.event.SimpleApplicationEventMulticaster.multicastEvent(SimpleApplicationEventMulticaster.java:75)
>       at 
> org.springframework.context.support.AbstractApplicationContext.publishEvent(AbstractApplicationContext.java:246)
>       at 
> org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:355)
>       at 
> org.springframework.web.context.ContextLoader.createWebApplicationContext(ContextLoader.java:244)
>       at 
> org.springframework.web.context.ContextLoader.initWebApplicationContext(ContextLoader.java:187)
>       at 
> org.springframework.web.context.ContextLoaderListener.contextInitialized(ContextLoaderListener.java:49)
>       at 
> org.apache.catalina.core.StandardContext.listenerStart(StandardContext.java:3843)
>       at 
> org.apache.catalina.core.StandardContext.start(StandardContext.java:4350)
>       at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1045)
>       at org.apache.catalina.core.StandardHost.start(StandardHost.java:719)
>       at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1045)
>       at 
> org.apache.catalina.core.StandardEngine.start(StandardEngine.java:443)
>       at 
> org.apache.catalina.core.StandardService.start(StandardService.java:516)
>       at 
> org.apache.catalina.core.StandardServer.start(StandardServer.java:710)
>       at org.apache.catalina.startup.Catalina.start(Catalina.java:578)
>       at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>       at 
> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
>       at 
> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
>       at java.lang.reflect.Method.invoke(Method.java:585)
>       at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:288)
>       at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:413)
>
> On Fri, May 30, 2008 at 10:22 AM, Guillaume Nodet <[EMAIL PROTECTED]> wrote:
>> The problem may be that Camel looks for the JBI endpoint when the route is 
>> built
>> rather than looking for the endpoint at runtime.  Could you post the
>> whole stack trace
>> please ?  Or maybe raise a JIRA and attach the needed files to
>> reproduce the problem.
>>
>> On Fri, May 30, 2008 at 9:57 AM, Sebastian Gomez <[EMAIL PROTECTED]> wrote:
>>> Hi.
>>>
>>> I'm in the same place as you are: I tried to use camel before and
>>> ended up using eip. Now I'm trying to use camel again and I'm still
>>> finding some problems.
>>>
>>> My configuration for camel is simply:
>>>
>>>          <camelContext autowireRouteBuilders="false" useJmx="true"
>>> xmlns="http://activemq.apache.org/camel/schema/spring";>
>>>             <route>
>>>                <from uri="timer:myTimerEvent?fixedRate=true" />
>>>                <to uri="jbi:service:http://my.namespace.com/tracker"/>
>>>        </route>
>>>          </camelContext>
>>>
>>> The reason for the autowireRouteBuilder is explained in this post. The
>>> rest speaks for itself. I must mention that right now I'm trying to
>>> find out why during startup the CamelContext doesn´t find my jbi
>>> endpoints (I get a NoSuchEndpointException). If you change the
>>> jbi:service uri for
>>> "log:org.apache.servicemix.samples.camel.ExampleCamelRoute" it will
>>> start sending exchanges like in the camel example that comes with the
>>> distribution (but without body, because it's not specified).
>>>
>>> If I find a solution to my problem I'll update you with the news.
>>>
>>>
>>>
>>> On Thu, May 29, 2008 at 10:17 PM, Björn Bength <[EMAIL PROTECTED]> wrote:
>>>> Hi,
>>>>
>>>> Could you post the relevant parts of your configuration regarding
>>>> servicemix-camel.
>>>> I had trouble using servicemix-camel a while ago in my embedded
>>>> servicemix deployment and went for servicemix-eip instead. But would
>>>> like to use camel. or at least test it.
>>>>
>>>> /Björn
>>>>
>>>> On Thu, 2008-05-29 at 16:07 +0200, Sebastian Gomez wrote:
>>>>> You are right. I had a Jencks connectionFactory declared in the
>>>>> servicemix.xml file and it was being autowired when creating the camel
>>>>> context. I've now declared the camel context with the attribute
>>>>> autowireRouteBuilders="false" and it works correctly. Thanks a lot for
>>>>> the pointing out.
>>>>>
>>>>> Best regards.
>>>>>
>>>>> Sebastian Gomez.
>>>>>
>>>>>
>>>>>
>>>>> On Thu, May 29, 2008 at 12:05 PM, Guillaume Nodet <[EMAIL PROTECTED]> 
>>>>> wrote:
>>>>> > It seems that you misconfigured the jencks / jms layer somehow.  I
>>>>> > don't think this is
>>>>> > anything to do with camel per se.
>>>>> > What's your exact xml config ?
>>>>> >
>>>>> > On Wed, May 28, 2008 at 6:41 PM, Sebastian Gomez <[EMAIL PROTECTED]> 
>>>>> > wrote:
>>>>> >> Hi.
>>>>> >>
>>>>> >> I'm trying to use servicemix-camel in a static configuration (i.e
>>>>> >> using servicemix.xml). I try to create a Camel Context but I keep
>>>>> >> getting a NullPointerException saying the managedConnectionFactory is
>>>>> >> null. A few months ago I used the standard jbi configuration and it
>>>>> >> went OK, so I'm worried Camel cannot be used in the static
>>>>> >> configuration. Is this true? I'd appreciate an example of camel in the
>>>>> >> static configuration, I've been looking all over the internet and I
>>>>> >> can only find jbi configurations :( .
>>>>> >>
>>>>> >> Thanks in advance.
>>>>> >>
>>>>> >> BTW, here's the exception trace in case it's of any use:
>>>>> >>
>>>>> >> java.lang.NullPointerException: managedConnectionFactory is null
>>>>> >>        at 
>>>>> >> org.jencks.factory.ConnectionFactoryFactoryBean.getConnectionFactory(ConnectionFactoryFactoryBean.java:73)
>>>>> >>        at 
>>>>> >> org.jencks.factory.ConnectionFactoryFactoryBean.getObjectType(ConnectionFactoryFactoryBean.java:54)
>>>>> >>        at 
>>>>> >> org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.getTypeForFactoryBean(AbstractAutowireCapableBeanFactory.java:555)
>>>>> >>        at 
>>>>> >> org.springframework.beans.factory.support.AbstractBeanFactory.isTypeMatch(AbstractBeanFactory.java:441)
>>>>> >>        at 
>>>>> >> org.springframework.beans.factory.support.DefaultListableBeanFactory.getBeanNamesForType(DefaultListableBeanFactory.java:173)
>>>>> >>        at 
>>>>> >> org.springframework.beans.factory.support.DefaultListableBeanFactory.getBeansOfType(DefaultListableBeanFactory.java:242)
>>>>> >>        at 
>>>>> >> org.springframework.context.support.AbstractApplicationContext.getBeansOfType(AbstractApplicationContext.java:796)
>>>>> >>        at 
>>>>> >> org.apache.camel.spring.CamelContextFactoryBean.installRoutes(CamelContextFactoryBean.java:287)
>>>>> >>        at 
>>>>> >> org.apache.camel.spring.CamelContextFactoryBean.afterPropertiesSet(CamelContextFactoryBean.java:137)
>>>>> >>        at 
>>>>> >> org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.invokeInitMethods(AbstractAutowireCapableBeanFactory.java:1201)
>>>>> >>        at 
>>>>> >> org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1171)
>>>>> >>        at 
>>>>> >> org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:425)
>>>>> >>        at 
>>>>> >> org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:251)
>>>>> >>        at 
>>>>> >> org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:156)
>>>>> >>        at 
>>>>> >> org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:248)
>>>>> >>        at 
>>>>> >> org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:160)
>>>>> >>        at 
>>>>> >> org.springframework.beans.factory.support.BeanDefinitionValueResolver.resolveReference(BeanDefinitionValueResolver.java:261)
>>>>> >>        at 
>>>>> >> org.springframework.beans.factory.support.BeanDefinitionValueResolver.resolveValueIfNecessary(BeanDefinitionValueResolver.java:109)
>>>>> >>        at 
>>>>> >> org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.applyPropertyValues(AbstractAutowireCapableBeanFactory.java:1099)
>>>>> >>        at 
>>>>> >> org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.populateBean(AbstractAutowireCapableBeanFactory.java:861)
>>>>> >>        at 
>>>>> >> org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:421)
>>>>> >>        at 
>>>>> >> org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:251)
>>>>> >>        at 
>>>>> >> org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:156)
>>>>> >>        at 
>>>>> >> org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:248)
>>>>> >>        at 
>>>>> >> org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:160)
>>>>> >>        at 
>>>>> >> org.springframework.context.support.AbstractApplicationContext.getBean(AbstractApplicationContext.java:733)
>>>>> >>        at 
>>>>> >> org.springframework.context.support.AbstractApplicationContext.registerBeanPostProcessors(AbstractApplicationContext.java:511)
>>>>> >>        at 
>>>>> >> org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:337)
>>>>> >>        at 
>>>>> >> org.springframework.web.context.ContextLoader.createWebApplicationContext(ContextLoader.java:244)
>>>>> >>        at 
>>>>> >> org.springframework.web.context.ContextLoader.initWebApplicationContext(ContextLoader.java:187)
>>>>> >>        at 
>>>>> >> org.springframework.web.context.ContextLoaderListener.contextInitialized(ContextLoaderListener.java:49)
>>>>> >>        at 
>>>>> >> org.apache.catalina.core.StandardContext.listenerStart(StandardContext.java:3843)
>>>>> >>        at 
>>>>> >> org.apache.catalina.core.StandardContext.start(StandardContext.java:4350)
>>>>> >>        at 
>>>>> >> org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1045)
>>>>> >>        at 
>>>>> >> org.apache.catalina.core.StandardHost.start(StandardHost.java:719)
>>>>> >>        at 
>>>>> >> org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1045)
>>>>> >>        at 
>>>>> >> org.apache.catalina.core.StandardEngine.start(StandardEngine.java:443)
>>>>> >>        at 
>>>>> >> org.apache.catalina.core.StandardService.start(StandardService.java:516)
>>>>> >>        at 
>>>>> >> org.apache.catalina.core.StandardServer.start(StandardServer.java:710)
>>>>> >>        at org.apache.catalina.startup.Catalina.start(Catalina.java:578)
>>>>> >>        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>>>>> >>        at 
>>>>> >> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
>>>>> >>        at 
>>>>> >> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
>>>>> >>        at java.lang.reflect.Method.invoke(Method.java:585)
>>>>> >>        at 
>>>>> >> org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:288)
>>>>> >>        at 
>>>>> >> org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:413)
>>>>> >>
>>>>> >> Best regards,
>>>>> >>
>>>>> >> Sebastian Gomez.
>>>>> >>
>>>>> >
>>>>> >
>>>>> >
>>>>> > --
>>>>> > Cheers,
>>>>> > Guillaume Nodet
>>>>> > ------------------------
>>>>> > Blog: http://gnodet.blogspot.com/
>>>>> >
>>>>
>>>>
>>>
>>
>>
>>
>> --
>> Cheers,
>> Guillaume Nodet
>> ------------------------
>> Blog: http://gnodet.blogspot.com/
>>
>



-- 
Cheers,
Guillaume Nodet
------------------------
Blog: http://gnodet.blogspot.com/

Reply via email to