0

我正在开发一个应用程序,它使用消息驱动 bean 接收消息并将数据持久保存到数据库中。尝试在 glassfish 上部署它时,我收到以下错误:

java.lang.RuntimeException: IIOP Protocol Manager initialization failed.  Possible cause is that ORB is not available in this container
        at com.sun.ejb.containers.BaseContainer.initializeProtocolManager(BaseContainer.java:827)
        at com.sun.ejb.containers.BaseContainer.<init>(BaseContainer.java:508)
        at com.sun.ejb.containers.MessageBeanContainer.<init>(MessageBeanContainer.java:142)
        at com.sun.ejb.containers.ContainerFactoryImpl.createContainer(ContainerFactoryImpl.java:121)
        at org.glassfish.ejb.startup.EjbApplication.loadContainers(EjbApplication.java:230)
        at org.glassfish.ejb.startup.EjbDeployer.load(EjbDeployer.java:305)
        at org.glassfish.ejb.startup.EjbDeployer.load(EjbDeployer.java:108)
        at org.glassfish.internal.data.ModuleInfo.load(ModuleInfo.java:186)
        at org.glassfish.internal.data.ApplicationInfo.load(ApplicationInfo.java:264)
        at com.sun.enterprise.v3.server.ApplicationLifecycle.deploy(ApplicationLifecycle.java:460)
        at com.sun.enterprise.v3.server.ApplicationLifecycle.deploy(ApplicationLifecycle.java:240)
        at org.glassfish.deployment.admin.DeployCommand.execute(DeployCommand.java:389)
        at com.sun.enterprise.v3.admin.CommandRunnerImpl$1.execute(CommandRunnerImpl.java:348)
        at com.sun.enterprise.v3.admin.CommandRunnerImpl.doCommand(CommandRunnerImpl.java:363)
        at com.sun.enterprise.v3.admin.CommandRunnerImpl.doCommand(CommandRunnerImpl.java:1085)
        at com.sun.enterprise.v3.admin.CommandRunnerImpl.access$1200(CommandRunnerImpl.java:95)
        at com.sun.enterprise.v3.admin.CommandRunnerImpl$ExecutionContext.execute(CommandRunnerImpl.java:1291)
        at com.sun.enterprise.v3.admin.CommandRunnerImpl$ExecutionContext.execute(CommandRunnerImpl.java:1259)
        at org.glassfish.admin.rest.ResourceUtil.runCommand(ResourceUtil.java:214)
        at org.glassfish.admin.rest.ResourceUtil.runCommand(ResourceUtil.java:207)
        at org.glassfish.admin.rest.resources.TemplateListOfResource.createResource(TemplateListOfResource.java:148)
        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:597)
        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.server.impl.container.grizzly.GrizzlyContainer._service(GrizzlyContainer.java:182)
        at com.sun.jersey.server.impl.container.grizzly.GrizzlyContainer.service(GrizzlyContainer.java:147)
        at org.glassfish.admin.rest.adapter.RestAdapter.service(RestAdapter.java:148)
        at com.sun.grizzly.tcp.http11.GrizzlyAdapter.service(GrizzlyAdapter.java:179)
        at com.sun.enterprise.v3.server.HK2Dispatcher.dispath(HK2Dispatcher.java:117)
        at com.sun.enterprise.v3.services.impl.ContainerMapper$Hk2DispatcherCallable.call(ContainerMapper.java:354)
        at com.sun.enterprise.v3.services.impl.ContainerMapper.service(ContainerMapper.java:195)
        at com.sun.grizzly.http.ProcessorTask.invokeAdapter(ProcessorTask.java:860)
        at com.sun.grizzly.http.ProcessorTask.doProcess(ProcessorTask.java:757)
        at com.sun.grizzly.http.ProcessorTask.process(ProcessorTask.java:1056)
        at com.sun.grizzly.http.DefaultProtocolFilter.execute(DefaultProtocolFilter.java:229)
        at com.sun.grizzly.DefaultProtocolChain.executeProtocolFilter(DefaultProtocolChain.java:137)
        at com.sun.grizzly.DefaultProtocolChain.execute(DefaultProtocolChain.java:104)
        at com.sun.grizzly.DefaultProtocolChain.execute(DefaultProtocolChain.java:90)
        at com.sun.grizzly.http.HttpProtocolChain.execute(HttpProtocolChain.java:79)
        at com.sun.grizzly.ProtocolChainContextTask.doCall(ProtocolChainContextTask.java:54)
        at com.sun.grizzly.SelectionKeyContextTask.call(SelectionKeyContextTask.java:59)
        at com.sun.grizzly.ContextTask.run(ContextTask.java:71)
        at com.sun.grizzly.util.AbstractThreadPool$Worker.doWork(AbstractThreadPool.java:532)
        at com.sun.grizzly.util.AbstractThreadPool$Worker.run(AbstractThreadPool.java:513)
        at java.lang.Thread.run(Thread.java:662)
Caused by: java.lang.RuntimeException: Orb initialization erorr
        at org.glassfish.enterprise.iiop.api.GlassFishORBHelper.getORB(GlassFishORBHelper.java:180)
        at org.glassfish.enterprise.iiop.api.GlassFishORBHelper.getProtocolManager(GlassFishORBHelper.java:219)
        at com.sun.ejb.containers.BaseContainer.initializeProtocolManager(BaseContainer.java:824)
        ... 60 more
Caused by: java.lang.RuntimeException: org.omg.CORBA.BAD_OPERATION: FINE: IOP01210086: Could not bind initial GIS to name service  vmcid: OMG  minor code: 86  completed: No
        at org.glassfish.enterprise.iiop.impl.GlassFishORBManager.initORB(GlassFishORBManager.java:622)
        at org.glassfish.enterprise.iiop.impl.GlassFishORBManager.getORB(GlassFishORBManager.java:263)
        at org.glassfish.enterprise.iiop.impl.GlassFishORBFactoryImpl.createORB(GlassFishORBFactoryImpl.java:93)
        at org.glassfish.enterprise.iiop.api.GlassFishORBHelper.getORB(GlassFishORBHelper.java:152)
        ... 62 more
Caused by: org.omg.CORBA.BAD_OPERATION: FINE: IOP01210086: Could not bind initial GIS to name service  vmcid: OMG  minor code: 86  completed: No
        at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
        at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39)
        at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27)
        at java.lang.reflect.Constructor.newInstance(Constructor.java:513)
        at com.sun.corba.ee.spi.orbutil.logex.corba.CorbaExtension.makeException(CorbaExtension.java:248)
        at com.sun.corba.ee.spi.orbutil.logex.corba.CorbaExtension.makeException(CorbaExtension.java:95)
        at com.sun.corba.ee.spi.orbutil.logex.WrapperGenerator.handleFullLogging(WrapperGenerator.java:387)
        at com.sun.corba.ee.spi.orbutil.logex.WrapperGenerator.access$400(WrapperGenerator.java:107)
        at com.sun.corba.ee.spi.orbutil.logex.WrapperGenerator$2.invoke(WrapperGenerator.java:511)
        at com.sun.corba.ee.spi.orbutil.proxy.CompositeInvocationHandlerImpl.invoke(CompositeInvocationHandlerImpl.java:99)
        at $Proxy216.bindNameException(Unknown Source)
        at com.sun.corba.ee.impl.folb.InitialGroupInfoService.bindName(InitialGroupInfoService.java:215)
        at com.sun.corba.ee.impl.folb.InitialGroupInfoService.<init>(InitialGroupInfoService.java:177)
        at org.glassfish.enterprise.iiop.impl.GlassFishORBManager.initORB(GlassFishORBManager.java:611)
        ... 65 more
Caused by: org.omg.CORBA.INV_OBJREF: WARNING: IOP00511001: IOR must have at least one IIOP profile  vmcid: OMG  minor code: 1001  completed: No
        at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
        at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39)
        at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27)
        at java.lang.reflect.Constructor.newInstance(Constructor.java:513)
        at com.sun.corba.ee.spi.orbutil.logex.corba.CorbaExtension.makeException(CorbaExtension.java:248)
        at com.sun.corba.ee.spi.orbutil.logex.corba.CorbaExtension.makeException(CorbaExtension.java:95)
        at com.sun.corba.ee.spi.orbutil.logex.WrapperGenerator.handleFullLogging(WrapperGenerator.java:387)
        at com.sun.corba.ee.spi.orbutil.logex.WrapperGenerator.access$400(WrapperGenerator.java:107)
        at com.sun.corba.ee.spi.orbutil.logex.WrapperGenerator$2.invoke(WrapperGenerator.java:511)
        at com.sun.corba.ee.spi.orbutil.proxy.CompositeInvocationHandlerImpl.invoke(CompositeInvocationHandlerImpl.java:99)
        at $Proxy227.iorMustHaveIiopProfile(Unknown Source)
        at com.sun.corba.ee.impl.ior.IORImpl.getProfile(IORImpl.java:366)
        at com.sun.corba.ee.impl.transport.CorbaContactInfoListImpl.setLocalSubcontract(CorbaContactInfoListImpl.java:444)
        at com.sun.corba.ee.impl.transport.CorbaContactInfoListImpl.setEffectiveTargetIOR(CorbaContactInfoListImpl.java:277)
        at com.sun.corba.ee.impl.transport.CorbaContactInfoListImpl.setTargetIOR(CorbaContactInfoListImpl.java:219)
        at com.sun.corba.ee.impl.transport.CorbaContactInfoListImpl.<init>(CorbaContactInfoListImpl.java:183)
        at com.sun.corba.ee.spi.transport.TransportDefault$1.create(TransportDefault.java:70)
        at com.sun.corba.ee.impl.orbutil.ORBUtility.makeClientDelegate(ORBUtility.java:803)
        at com.sun.corba.ee.impl.orbutil.ORBUtility.makeObjectReference(ORBUtility.java:812)
        at com.sun.corba.ee.impl.ior.ObjectReferenceProducerBase.make_object(ObjectReferenceProducerBase.java:78)
        at com.sun.corba.ee.spi.oa.ObjectAdapterBase.makeObject(ObjectAdapterBase.java:126)
        at com.sun.corba.ee.impl.oa.poa.POAImpl.create_reference_with_id(POAImpl.java:1559)
        at com.sun.corba.ee.impl.folb.InitialGroupInfoService.bindName(InitialGroupInfoService.java:203)
        ... 67 more

我环顾四周,意识到这可能是 CORBA 问题,但我没有使用 CORBA,消息是通过 ActiveMQ 发送的,我使用 ojdbc 作为数据库。

对不起,长日志和简短描述。如果您需要更多信息,请告诉我。无论如何,欢迎所有的答案和建议。谢谢

4

2 回答 2

1

尝试在 glassfish 4 中部署应用程序时,我遇到了同样的问题,“IIOP 协议管理器初始化失败。可能的原因是 ORB 在此容器中不可用”。就我而言,原因是我更改了一个线程池我的 http-listeners 。我想使用“线程池”而不是“http-thread-pool”(因为它有更多线程)。我一改回来,它就又开始工作了。

于 2014-06-24T10:42:08.030 回答
0

我现在遇到了这个问题。经过一段时间尝试了解问题并重新启动 glassfish 后,我重新启动了服务器,问题现在消失了。

于 2013-05-07T07:02:01.270 回答