tp_peng
2018-04-02 13:21
采纳率: 0%
浏览 2.4k
已结题

springboot2.0增加eureka-server后jersey报NoInitialContextException

2018-04-01 23:40:20.813 INFO 21366 --- [ost-startStop-1] c.sun.jersey.spi.service.ServiceFinder : Running in a non-OSGi environment
2018-04-01 23:40:58.646 INFO 21366 --- [ost-startStop-1] .e.EJBComponentProviderFactoryInitilizer : The EJB interceptor binding API is not available. JAX-RS EJB support is disabled.

javax.naming.NoInitialContextException: Need to specify class name in environment or system property, or as an applet parameter, or in an application resource file: java.naming.factory.initial
at javax.naming.spi.NamingManager.getInitialContext(NamingManager.java:662)
at javax.naming.InitialContext.getDefaultInitCtx(InitialContext.java:313)
at javax.naming.InitialContext.getURLOrDefaultInitCtx(InitialContext.java:350)
at javax.naming.InitialContext.lookup(InitialContext.java:417)
at com.sun.jersey.server.impl.ejb.EJBComponentProviderFactoryInitilizer.initialize(EJBComponentProviderFactoryInitilizer.java:64)
at com.sun.jersey.spi.container.servlet.WebComponent.configure(WebComponent.java:570)
at com.sun.jersey.spi.container.servlet.ServletContainer$InternalWebComponent.configure(ServletContainer.java:332)
at com.sun.jersey.spi.container.servlet.WebComponent.load(WebComponent.java:604)
at com.sun.jersey.spi.container.servlet.WebComponent.init(WebComponent.java:207)
at com.sun.jersey.spi.container.servlet.ServletContainer.init(ServletContainer.java:394)
at com.sun.jersey.spi.container.servlet.ServletContainer.init(ServletContainer.java:744)
at org.apache.catalina.core.ApplicationFilterConfig.initFilter(ApplicationFilterConfig.java:285)
at org.apache.catalina.core.ApplicationFilterConfig.(ApplicationFilterConfig.java:112)
at org.apache.catalina.core.StandardContext.filterStart(StandardContext.java:4599)
at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5241)
at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1419)
at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1409)
at java.util.concurrent.FutureTask.run(FutureTask.java:266)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
at java.lang.Thread.run(Thread.java:748)

2018-04-01 23:40:58.648 INFO 21366 --- [ost-startStop-1] c.CDIComponentProviderFactoryInitializer : The CDI BeanManager is not available at java:comp/BeanManager

javax.naming.NoInitialContextException: Need to specify class name in environment or system property, or as an applet parameter, or in an application resource file: java.naming.factory.initial
at javax.naming.spi.NamingManager.getInitialContext(NamingManager.java:662)
at javax.naming.InitialContext.getDefaultInitCtx(InitialContext.java:313)
at javax.naming.InitialContext.getURLOrDefaultInitCtx(InitialContext.java:350)
at javax.naming.InitialContext.lookup(InitialContext.java:417)
at com.sun.jersey.server.impl.cdi.CDIComponentProviderFactoryInitializer.lookupInJndi(CDIComponentProviderFactoryInitializer.java:110)
at com.sun.jersey.server.impl.cdi.CDIComponentProviderFactoryInitializer.lookup(CDIComponentProviderFactoryInitializer.java:83)
at com.sun.jersey.server.impl.cdi.CDIComponentProviderFactoryInitializer.initialize(CDIComponentProviderFactoryInitializer.java:70)
at com.sun.jersey.spi.container.servlet.WebComponent.configure(WebComponent.java:572)
at com.sun.jersey.spi.container.servlet.ServletContainer$InternalWebComponent.configure(ServletContainer.java:332)
at com.sun.jersey.spi.container.servlet.WebComponent.load(WebComponent.java:604)
at com.sun.jersey.spi.container.servlet.WebComponent.init(WebComponent.java:207)
at com.sun.jersey.spi.container.servlet.ServletContainer.init(ServletContainer.java:394)
at com.sun.jersey.spi.container.servlet.ServletContainer.init(ServletContainer.java:744)
at org.apache.catalina.core.ApplicationFilterConfig.initFilter(ApplicationFilterConfig.java:285)
at org.apache.catalina.core.ApplicationFilterConfig.(ApplicationFilterConfig.java:112)
at org.apache.catalina.core.StandardContext.filterStart(StandardContext.java:4599)
at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5241)
at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1419)
at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1409)
at java.util.concurrent.FutureTask.run(FutureTask.java:266)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
at java.lang.Thread.run(Thread.java:748)

2018-04-01 23:40:58.648 INFO 21366 --- [ost-startStop-1] c.CDIComponentProviderFactoryInitializer : The CDI BeanManager is not available at javax.enterprise.inject.spi.BeanManager
2018-04-01 23:40:58.648 INFO 21366 --- [ost-startStop-1] c.CDIComponentProviderFactoryInitializer : The CDI BeanManager is not available at org.jboss.weld.environment.servlet.javax.enterprise.inject.spi.BeanManager
2018-04-01 23:40:58.648 INFO 21366 --- [ost-startStop-1] c.CDIComponentProviderFactoryInitializer : The CDI BeanManager is not available. JAX-RS CDI support is disabled.
2018-04-01 23:40:58.650 INFO 21366 --- [ost-startStop-1] edBeanComponentProviderFactoryInitilizer : The managed beans injection manager API is not available. JAX-RS managed beans support is disabled.

javax.naming.NoInitialContextException: Need to specify class name in environment or system property, or as an applet parameter, or in an application resource file: java.naming.factory.initial
at javax.naming.spi.NamingManager.getInitialContext(NamingManager.java:662)
at javax.naming.InitialContext.getDefaultInitCtx(InitialContext.java:313)
at javax.naming.InitialContext.getURLOrDefaultInitCtx(InitialContext.java:350)
at javax.naming.InitialContext.lookup(InitialContext.java:417)
at com.sun.jersey.server.impl.managedbeans.ManagedBeanComponentProviderFactoryInitilizer.initialize(ManagedBeanComponentProviderFactoryInitilizer.java:65)
at com.sun.jersey.spi.container.servlet.WebComponent.configure(WebComponent.java:576)
at com.sun.jersey.spi.container.servlet.ServletContainer$InternalWebComponent.configure(ServletContainer.java:332)
at com.sun.jersey.spi.container.servlet.WebComponent.load(WebComponent.java:604)
at com.sun.jersey.spi.container.servlet.WebComponent.init(WebComponent.java:207)
at com.sun.jersey.spi.container.servlet.ServletContainer.init(ServletContainer.java:394)
at com.sun.jersey.spi.container.servlet.ServletContainer.init(ServletContainer.java:744)
at org.apache.catalina.core.ApplicationFilterConfig.initFilter(ApplicationFilterConfig.java:285)
at org.apache.catalina.core.ApplicationFilterConfig.(ApplicationFilterConfig.java:112)
at org.apache.catalina.core.StandardContext.filterStart(StandardContext.java:4599)
at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5241)
at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1419)
at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1409)
at java.util.concurrent.FutureTask.run(FutureTask.java:266)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
at java.lang.Thread.run(Thread.java:748)

2018-04-01 23:40:58.655 INFO 21366 --- [ost-startStop-1] c.s.j.s.i.a.WebApplicationImpl : Initiating Jersey application, version 'Jersey: 1.19.1 03/11/2016 02:08 PM'
2018-04-01 23:40:58.668 INFO 21366 --- [ost-startStop-1] c.s.j.c.spi.component.ProviderServices

启动异常,有人知道什么原因吗?

2条回答 默认 最新

相关推荐 更多相似问题