Closed cschneider closed 8 years ago
This results in a warning of "JettyServerWrapper": failed to parse and instantiate of javax.servlet.ServletContainerInitializer in classpath
2015-09-24 20:29:41,402 | INFO | pool-58-thread-1 | JettyFactoryImpl | 84 - org.ops4j.pax.web.pax-web-jetty - 4.2.0 | SPDY not available, creating standard ServerConnector for Http 2015-09-24 20:29:41,403 | INFO | pool-58-thread-1 | JettyServerImpl | 84 - org.ops4j.pax.web.pax-web-jetty - 4.2.0 | Pax Web available at [0.0.0.0]:[8181] 2015-09-24 20:29:41,406 | INFO | pool-58-thread-1 | HttpServiceFactoryImpl | 85 - org.ops4j.pax.web.pax-web-runtime - 4.2.0 | Binding bundle: [com.eclipsesource.jaxrs.publisher [89]] to http service 2015-09-24 20:29:41,413 | INFO | pool-58-thread-1 | JettyServerWrapper | 84 - org.ops4j.pax.web.pax-web-jetty - 4.2.0 | will add org.eclipse.jetty.websocket.jsr356.server.deploy.WebSocketServerContainerInitializer to ServletContainerInitializers 2015-09-24 20:29:41,518 | INFO | pool-58-thread-1 | JettyServerWrapper | 84 - org.ops4j.pax.web.pax-web-jetty - 4.2.0 | added ServletContainerInitializer: org.eclipse.jetty.websocket.jsr356.server.deploy.WebSocketServerContainerInitializer 2015-09-24 20:29:41,518 | INFO | pool-58-thread-1 | JettyServerWrapper | 84 - org.ops4j.pax.web.pax-web-jetty - 4.2.0 | will add org.glassfish.jersey.servlet.init.JerseyServletContainerInitializer to ServletContainerInitializers 2015-09-24 20:29:41,518 | WARN | pool-58-thread-1 | JettyServerWrapper | 84 - org.ops4j.pax.web.pax-web-jetty - 4.2.0 | failed to parse and instantiate of javax.servlet.ServletContainerInitializer in classpath 2015-09-24 20:29:41,519 | INFO | pool-58-thread-1 | HttpServiceContext | 84 - org.ops4j.pax.web.pax-web-jetty - 4.2.0 | registering context DefaultHttpContext [bundle=com.eclipsesource.jaxrs.publisher [89], contextID=default], with context-name: 2015-09-24 20:29:41,520 | INFO | pool-58-thread-1 | ContextHandler | 72 - org.eclipse.jetty.util - 9.2.10.v20150310 | Started HttpServiceContext{httpContext=DefaultHttpContext [bundle=com.eclipsesource.jaxrs.publisher [89], contextID=default]} 2015-09-24 20:29:41,520 | INFO | pool-58-thread-1 | Server | 72 - org.eclipse.jetty.util - 9.2.10.v20150310 | jetty-9.2.10.v20150310 2015-09-24 20:29:41,526 | INFO | pool-58-thread-1 | ServerConnector | 72 - org.eclipse.jetty.util - 9.2.10.v20150310 | Started default@657d45f5{HTTP/1.1}{0.0.0.0:8181} 2015-09-24 20:29:41,526 | INFO | pool-58-thread-1 | Server | 72 - org.eclipse.jetty.util - 9.2.10.v20150310 | Started @415384ms
Could that warning be ignored?
@cschneider yo mean adding a bundle to the feature? Can you open a pull request for this?
closing this issue. Thanks for the pull request!
I just tried to install the feature file you provide into a plain apache karaf 4.0.1.
karaf@root()> feature:install jax-rs-connector Error executing command: Unable to resolve root: missing requirement [root] osgi.identity; osgi.identity=jax-rs-connector; type=karaf.feature; version="[5.0.0,5.0.0]"; filter:="(&(osgi.identity=jax-rs-connector)(type=karaf.feature)(version>=5.0.0)(version<=5.0.0))" [caused by: Unable to resolve jax-rs-connector/5.0.0: missing requirement [jax-rs-connector/5.0.0] osgi.identity; osgi.identity=com.eclipsesource.jaxrs.publisher; type=osgi.bundle; version="[5.0.0.201506221200,5.0.0.201506221200]"; resolution:=mandatory [caused by: Unable to resolve com.eclipsesource.jaxrs.publisher/5.0.0.201506221200: missing requirement [com.eclipsesource.jaxrs.publisher/5.0.0.201506221200] osgi.wiring.package; filter:="(&(osgi.wiring.package=javax.servlet)(version>=2.3.0)(!(version>=4.0.0)))"]]
So the servlet API is missing. I think you should add a bundle with dependency=true that contains the servlet API.
A workaround is to install the http feature before jaxrs-connector.
Btw I many thanks for the karaf support you provide. I just added your feature file uri to the repos.cfg file in karaf: https://issues.apache.org/jira/browse/KARAF-4010
So from karaf 4.0.2 on people can install your repo using: feature:install eclipsesource-jaxrs 5.0
I chose the name from the groupId. Please say if you prefer another alias.