I should note that by turning the com.sun.jersey.spi.spring.container.servlet.SpringServlet into a servlet instead of a filter, I can start up Tomcat without error. However, when I try to access a page I get this error:
java.lang.IllegalStateException: No WebApplicationContext found: no ContextLoaderListener registered? Is there any way to pass the WebApplicationContext created by the camel servlet component to jersey's SpringServlet? jfaath wrote: > > That seems to finally work...providing I remove the "Jersey Filter" that > is used by the web console. This effectively breaks the Camel web > console, so as of now it appears the two are incompatible. > > > > willem.jiang wrote: >> >> Oh, you should not use the ContextLoaderLister to load the camel route. >> There is a contextConfigLocation parameter that you can pass to the >> CamelHttpTransportServlet to load the camel route. >> You can find the example here >> https://svn.apache.org/repos/asf/camel/trunk/components/camel-servlet/src/test/resources/org/apache/camel/component/servlet/web-spring.xml >> >> Willem >> >> jfaath wrote: >>> I played around with this by removing everything below the >>> ContextLoaderListener listener. I still get the same error. As a rule, >>> it >>> seems that Tomcat always loads listeners before servlets. >>> >>> What exactly is the expected behavior of the bootstrap process in the >>> servlet container? What is the contextConfigLocation parameter supposed >>> to >>> do? >>> >>> Is there a sample of using this component in an actual servlet >>> container? >>> >>> >>> willem.jiang wrote: >>>> Hi, >>>> >>>> Can you remove the web console part and try again? >>>> Maybe there are some side effect of the web console configure. >>>> >>>> Willem >>>> >>>> jfaath wrote: >>>>> So should I post a JIRA on this? The servlet component doesn't seem >>>>> to >>>>> work >>>>> in v2.2 when used in the web console. >>>> >>>> >>> >> >> >> > > -- View this message in context: http://old.nabble.com/Deploying-as-web-app-with-jetty-endpoint-tp28171746p28248126.html Sent from the Camel - Users mailing list archive at Nabble.com.