camel-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ShlomiJ <shlomij...@gmail.com>
Subject Camel Web Standalone does not work with ActiveMQ
Date Tue, 20 Mar 2012 11:57:08 GMT
hi,
I'm using Camel 2.9.0, and I'm checking its camel-web-standalone-2.9.0.jar.
I run it with java -jar and everything is OK. Cool.

But if I simply *put activemq-all-5.5.1.jar and camel-jms-2.9.0.jar in the
camel-web.war* (which exists inside camel-web-standalone-2.9.0.jar), I get
some errors.
(just to make it clear: I haven't add any reference to ActiveMQ, no
endpoint, nothing)

Upon load (java -jar...) we get the following SLF4J related message: /The
requested version 1.6 by your slf4j binding is not compatible with [1.5.5,
1.5.6, 1.5.7, 1.5.8, 1.5.9, 1.5.10, 1.5.11]/

And when I try to stop the single route that comes with the example, I get
the following error:

SEVERE: The RuntimeException could not be mapped to a response, re-throwing
to the HTTP container
> org.apache.camel.RuntimeCamelException: java.lang.*NoSuchMethodError:
> org.slf4j.helpers.MessageFormatter.format(Ljava/lang/String;Ljava/lang/Object;Ljava/lang/Object;)Lorg/slf4j/helpers/FormattingTuple;*
>         at
> org.apache.camel.util.ObjectHelper.wrapRuntimeCamelException(ObjectHelper.java:1196)
>         at
> org.apache.camel.impl.DefaultShutdownStrategy.doShutdown(DefaultShutdownStrategy.java:153)
>         at
> org.apache.camel.impl.DefaultShutdownStrategy.shutdown(DefaultShutdownStrategy.java:93)
>         at
> org.apache.camel.impl.DefaultShutdownStrategy.shutdown(DefaultShutdownStrategy.java:85)
>         at
> org.apache.camel.impl.DefaultCamelContext.stopRoute(DefaultCamelContext.java:767)
>         at
> org.apache.camel.web.resources.RouteStatusResource.setStatus(RouteStatusResource.java:75)
>         at
> org.apache.camel.web.resources.RouteStatusResource.setStatus(RouteStatusResource.java:95)
>         at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>         at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
>         at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
>         at java.lang.reflect.Method.invoke(Unknown Source)
>         at
> com.sun.jersey.spi.container.JavaMethodInvokerFactory$1.invoke(JavaMethodInvokerFactory.java:60)
>         at
> com.sun.jersey.server.impl.model.method.dispatch.AbstractResourceMethodDispatchProvider$ResponseOutInvoker._dispatch(AbstractResourceMethodDispatchProvider.java:205)
>         at
> com.sun.jersey.server.impl.model.method.dispatch.ResourceJavaMethodDispatcher.dispatch(ResourceJavaMethodDispatcher.java:75)
>         at
> com.sun.jersey.server.impl.uri.rules.HttpMethodRule.accept(HttpMethodRule.java:288)
>         at
> com.sun.jersey.server.impl.uri.rules.SubLocatorRule.accept(SubLocatorRule.java:134)
>         at
> com.sun.jersey.server.impl.uri.rules.RightHandPathRule.accept(RightHandPathRule.java:147)
>         at
> com.sun.jersey.server.impl.uri.rules.SubLocatorRule.accept(SubLocatorRule.java:134)
>         at
> com.sun.jersey.server.impl.uri.rules.RightHandPathRule.accept(RightHandPathRule.java:147)
>         at
> com.sun.jersey.server.impl.uri.rules.ResourceClassRule.accept(ResourceClassRule.java:108)
>         at
> com.sun.jersey.server.impl.uri.rules.RightHandPathRule.accept(RightHandPathRule.java:147)
>         at
> com.sun.jersey.server.impl.uri.rules.RootResourceClassesRule.accept(RootResourceClassesRule.java:84)
>         at
> com.sun.jersey.server.impl.application.WebApplicationImpl._handleRequest(WebApplicationImpl.java:1469)
>         at
> com.sun.jersey.server.impl.application.WebApplicationImpl._handleRequest(WebApplicationImpl.java:1400)
>         at
> com.sun.jersey.server.impl.application.WebApplicationImpl.handleRequest(WebApplicationImpl.java:1349)
>         at
> com.sun.jersey.server.impl.application.WebApplicationImpl.handleRequest(WebApplicationImpl.java:1339)
>         at
> com.sun.jersey.spi.container.servlet.WebComponent.service(WebComponent.java:416)
>         at
> com.sun.jersey.spi.container.servlet.ServletContainer.service(ServletContainer.java:537)
>         at
> com.sun.jersey.spi.container.servlet.ServletContainer.doFilter(ServletContainer.java:895)
>         at
> com.sun.jersey.spi.container.servlet.ServletContainer.doFilter(ServletContainer.java:843)
>         at
> com.sun.jersey.spi.container.servlet.ServletContainer.doFilter(ServletContainer.java:804)
>         at
> org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1329)
>         at
> org.eclipse.jetty.servlet.ServletHandler.doHandle(ServletHandler.java:478)
>         at
> org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:119)
>         at
> org.eclipse.jetty.security.SecurityHandler.handle(SecurityHandler.java:520)
>         at
> org.eclipse.jetty.server.session.SessionHandler.doHandle(SessionHandler.java:227)
>         at
> org.eclipse.jetty.server.handler.ContextHandler.doHandle(ContextHandler.java:940)
>         at
> org.eclipse.jetty.servlet.ServletHandler.doScope(ServletHandler.java:409)
>         at
> org.eclipse.jetty.server.session.SessionHandler.doScope(SessionHandler.java:186)
>         at
> org.eclipse.jetty.server.handler.ContextHandler.doScope(ContextHandler.java:874)
>         at
> org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:117)
>         at
> org.eclipse.jetty.server.handler.ContextHandlerCollection.handle(ContextHandlerCollection.java:250)
>         at
> org.eclipse.jetty.server.handler.HandlerCollection.handle(HandlerCollection.java:149)
>         at
> org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:110)
>         at org.eclipse.jetty.server.Server.handle(Server.java:345)
>         at
> org.eclipse.jetty.server.HttpConnection.handleRequest(HttpConnection.java:441)
>         at
> org.eclipse.jetty.server.HttpConnection$RequestHandler.content(HttpConnection.java:936)
>         at
> org.eclipse.jetty.http.HttpParser.parseNext(HttpParser.java:801)
>         at
> org.eclipse.jetty.http.HttpParser.parseAvailable(HttpParser.java:224)
>         at
> org.eclipse.jetty.server.AsyncHttpConnection.handle(AsyncHttpConnection.java:52)
>         at
> org.eclipse.jetty.io.nio.SelectChannelEndPoint.handle(SelectChannelEndPoint.java:586)
>         at
> org.eclipse.jetty.io.nio.SelectChannelEndPoint$1.run(SelectChannelEndPoint.java:44)
>         at
> org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPool.java:598)
>         at
> org.eclipse.jetty.util.thread.QueuedThreadPool$3.run(QueuedThreadPool.java:533)
>         at java.lang.Thread.run(Unknown Source)
> Caused by: java.lang.NoSuchMethodError:
> org.slf4j.helpers.MessageFormatter.format(Ljava/lang/String;Ljava/lang/Object;Ljava/lang/Object;)Lorg/slf4j/helpers/FormattingTuple;
>         at
> org.slf4j.impl.Log4jLoggerAdapter.info(Log4jLoggerAdapter.java:346)
>         at
> org.apache.camel.impl.DefaultShutdownStrategy$ShutdownTask.run(DefaultShutdownStrategy.java:466)
>         at java.util.concurrent.Executors$RunnableAdapter.call(Unknown
> Source)
>         at java.util.concurrent.FutureTask$Sync.innerRun(Unknown Source)
>         at java.util.concurrent.FutureTask.run(Unknown Source)
>         at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(Unknown
> Source)
>         at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown
> Source)
>         ... 1 more
> 2012-03-20 13:46:00.715:WARN:oejs.ServletHandler:/routes/route1/status
> org.apache.camel.RuntimeCamelException: java.lang.NoSuchMethodError:
> org.slf4j.helpers.MessageFormatter.format(Ljava/lang/String;Ljava/lang/Object;Ljava/lang/Object;)Lorg/slf4j/helpers/FormattingTuple;
>         at
> org.apache.camel.util.ObjectHelper.wrapRuntimeCamelException(ObjectHelper.java:1196)
>         at
> org.apache.camel.impl.DefaultShutdownStrategy.doShutdown(DefaultShutdownStrategy.java:153)
>         at
> org.apache.camel.impl.DefaultShutdownStrategy.shutdown(DefaultShutdownStrategy.java:93)
>         at
> org.apache.camel.impl.DefaultShutdownStrategy.shutdown(DefaultShutdownStrategy.java:85)
>         at
> org.apache.camel.impl.DefaultCamelContext.stopRoute(DefaultCamelContext.java:767)
>         at
> org.apache.camel.web.resources.RouteStatusResource.setStatus(RouteStatusResource.java:75)
>         at
> org.apache.camel.web.resources.RouteStatusResource.setStatus(RouteStatusResource.java:95)
>         at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>         at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
>         at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
>         at java.lang.reflect.Method.invoke(Unknown Source)
>         at
> com.sun.jersey.spi.container.JavaMethodInvokerFactory$1.invoke(JavaMethodInvokerFactory.java:60)
>         at
> com.sun.jersey.server.impl.model.method.dispatch.AbstractResourceMethodDispatchProvider$ResponseOutInvoker._dispatch(AbstractResourceMethodDispatchProvider.java:205)
>         at
> com.sun.jersey.server.impl.model.method.dispatch.ResourceJavaMethodDispatcher.dispatch(ResourceJavaMethodDispatcher.java:75)
>         at
> com.sun.jersey.server.impl.uri.rules.HttpMethodRule.accept(HttpMethodRule.java:288)
>         at
> com.sun.jersey.server.impl.uri.rules.SubLocatorRule.accept(SubLocatorRule.java:134)
>         at
> com.sun.jersey.server.impl.uri.rules.RightHandPathRule.accept(RightHandPathRule.java:147)
>         at
> com.sun.jersey.server.impl.uri.rules.SubLocatorRule.accept(SubLocatorRule.java:134)
>         at
> com.sun.jersey.server.impl.uri.rules.RightHandPathRule.accept(RightHandPathRule.java:147)
>         at
> com.sun.jersey.server.impl.uri.rules.ResourceClassRule.accept(ResourceClassRule.java:108)
>         at
> com.sun.jersey.server.impl.uri.rules.RightHandPathRule.accept(RightHandPathRule.java:147)
>         at
> com.sun.jersey.server.impl.uri.rules.RootResourceClassesRule.accept(RootResourceClassesRule.java:84)
>         at
> com.sun.jersey.server.impl.application.WebApplicationImpl._handleRequest(WebApplicationImpl.java:1469)
>         at
> com.sun.jersey.server.impl.application.WebApplicationImpl._handleRequest(WebApplicationImpl.java:1400)
>         at
> com.sun.jersey.server.impl.application.WebApplicationImpl.handleRequest(WebApplicationImpl.java:1349)
>         at
> com.sun.jersey.server.impl.application.WebApplicationImpl.handleRequest(WebApplicationImpl.java:1339)
>         at
> com.sun.jersey.spi.container.servlet.WebComponent.service(WebComponent.java:416)
>         at
> com.sun.jersey.spi.container.servlet.ServletContainer.service(ServletContainer.java:537)
>         at
> com.sun.jersey.spi.container.servlet.ServletContainer.doFilter(ServletContainer.java:895)
>         at
> com.sun.jersey.spi.container.servlet.ServletContainer.doFilter(ServletContainer.java:843)
>         at
> com.sun.jersey.spi.container.servlet.ServletContainer.doFilter(ServletContainer.java:804)
>         at
> org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1329)
>         at
> org.eclipse.jetty.servlet.ServletHandler.doHandle(ServletHandler.java:478)
>         at
> org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:119)
>         at
> org.eclipse.jetty.security.SecurityHandler.handle(SecurityHandler.java:520)
>         at
> org.eclipse.jetty.server.session.SessionHandler.doHandle(SessionHandler.java:227)
>         at
> org.eclipse.jetty.server.handler.ContextHandler.doHandle(ContextHandler.java:940)
>         at
> org.eclipse.jetty.servlet.ServletHandler.doScope(ServletHandler.java:409)
>         at
> org.eclipse.jetty.server.session.SessionHandler.doScope(SessionHandler.java:186)
>         at
> org.eclipse.jetty.server.handler.ContextHandler.doScope(ContextHandler.java:874)
>         at
> org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:117)
>         at
> org.eclipse.jetty.server.handler.ContextHandlerCollection.handle(ContextHandlerCollection.java:250)
>         at
> org.eclipse.jetty.server.handler.HandlerCollection.handle(HandlerCollection.java:149)
>         at
> org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:110)
>         at org.eclipse.jetty.server.Server.handle(Server.java:345)
>         at
> org.eclipse.jetty.server.HttpConnection.handleRequest(HttpConnection.java:441)
>         at
> org.eclipse.jetty.server.HttpConnection$RequestHandler.content(HttpConnection.java:936)
>         at
> org.eclipse.jetty.http.HttpParser.parseNext(HttpParser.java:801)
>         at
> org.eclipse.jetty.http.HttpParser.parseAvailable(HttpParser.java:224)
>         at
> org.eclipse.jetty.server.AsyncHttpConnection.handle(AsyncHttpConnection.java:52)
>         at
> org.eclipse.jetty.io.nio.SelectChannelEndPoint.handle(SelectChannelEndPoint.java:586)
>         at
> org.eclipse.jetty.io.nio.SelectChannelEndPoint$1.run(SelectChannelEndPoint.java:44)
>         at
> org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPool.java:598)
>         at
> org.eclipse.jetty.util.thread.QueuedThreadPool$3.run(QueuedThreadPool.java:533)
>         at java.lang.Thread.run(Unknown Source)
> Caused by:java.lang.NoSuchMethodError:
> org.slf4j.helpers.MessageFormatter.format(Ljava/lang/String;Ljava/lang/Object;Ljava/lang/Object;)Lorg/slf4j/helpers/FormattingTuple;
>         at
> org.slf4j.impl.Log4jLoggerAdapter.info(Log4jLoggerAdapter.java:346)
>         at
> org.apache.camel.impl.DefaultShutdownStrategy$ShutdownTask.run(DefaultShutdownStrategy.java:466)
>         at java.util.concurrent.Executors$RunnableAdapter.call(Unknown
> Source)
>         at java.util.concurrent.FutureTask$Sync.innerRun(Unknown Source)
>         at java.util.concurrent.FutureTask.run(Unknown Source)
>         at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(Unknown
> Source)
>         at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown
> Source)
>         at java.lang.Thread.run(Unknown Source)

Looking at the dependencies of ActiveMQ 5.5.1 (that's the newest) I see that
it depends on SLF4J 1.5.11, whereas Camel 2.9.0 depends on SLF4J 1.6.1.

What solution do I have, except for building the entire ActiveMQ project
with SLF4J 1.6.1 ?

thanks
ShlomiJ

--
View this message in context: http://camel.465427.n5.nabble.com/Camel-Web-Standalone-does-not-work-with-ActiveMQ-tp5579802p5579802.html
Sent from the Camel - Users mailing list archive at Nabble.com.

Mime
View raw message