5 Replies Latest reply on Jun 19, 2012 7:55 AM by Fabrizio Benedetti

    connecting remote ejb2.1 on weblogic 1.0 from AS 7.1.2

    Newbie

      HI

      I am trying to connect to ejb2.1 on weblogic10.0. My application is a Axis2( 1.6.0) application

      I placed wlclient.jar in web application lib folder. Still getting following error. Is there any conflict with system class. I tried placing wlclient.jar in /standalone/lib but it did not work.

       

      13:23:29,351 WARN  [org.jboss.modules] (http-/127.0.0.1:8080-1) Failed to define class weblogic.corba.client.cluster.ORB

      SocketFactory in Module "deployment.CurianServices.war:main" from Service Module Loader: java.lang.LinkageError: Failed

      to link weblogic/corba/client/cluster/ORBSocketFactory (Module "deployment.CurianServices.war:main" from Service Module

      Loader)

              at org.jboss.modules.ModuleClassLoader.defineClass(ModuleClassLoader.java:396)

              at org.jboss.modules.ModuleClassLoader.loadClassLocal(ModuleClassLoader.java:243)

              at org.jboss.modules.ModuleClassLoader$1.loadClassLocal(ModuleClassLoader.java:73)

              at org.jboss.modules.Module.loadModuleClass(Module.java:527)

              at org.jboss.modules.ModuleClassLoader.findClass(ModuleClassLoader.java:182)

              at org.jboss.modules.ConcurrentClassLoader.performLoadClassUnchecked(ConcurrentClassLoader.java:468)

              at org.jboss.modules.ConcurrentClassLoader.performLoadClassChecked(ConcurrentClassLoader.java:456)

              at org.jboss.modules.ConcurrentClassLoader.performLoadClassChecked(ConcurrentClassLoader.java:423)

              at org.jboss.modules.ConcurrentClassLoader.performLoadClass(ConcurrentClassLoader.java:398)

              at org.jboss.modules.ConcurrentClassLoader.loadClass(ConcurrentClassLoader.java:120)

              at java.lang.Class.forName0(Native Method) [rt.jar:1.6.0_32]

              at java.lang.Class.forName(Class.java:169) [rt.jar:1.6.0_32]

              at weblogic.corba.j2ee.naming.ORBHelper.<clinit>(ORBHelper.java:148) [wlclient.jar:10.0.1.0]

              at weblogic.corba.client.ClientORBInitializer.initialize(ClientORBInitializer.java:91) [wlclient.jar:10.0.1.0]

              at weblogic.jndi.WLInitialContextFactory.<init>(WLInitialContextFactory.java:29) [wlclient.jar:10.0.1.0]

              at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) [rt.jar:1.6.0_32]

              at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39) [rt.jar:1.6.0_32

      ]

              at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27) [rt.jar:

      1.6.0_32]

              at java.lang.reflect.Constructor.newInstance(Constructor.java:513) [rt.jar:1.6.0_32]

              at java.lang.Class.newInstance0(Class.java:355) [rt.jar:1.6.0_32]

              at java.lang.Class.newInstance(Class.java:308) [rt.jar:1.6.0_32]

              at org.jboss.as.naming.InitialContextFactoryBuilder.createInitialContextFactory(InitialContextFactoryBuilder.jav

      a:62)

              at javax.naming.spi.NamingManager.getInitialContext(NamingManager.java:664) [rt.jar:1.6.0_32]

              at javax.naming.InitialContext.getDefaultInitCtx(InitialContext.java:288) [rt.jar:1.6.0_32]

              at javax.naming.InitialContext.init(InitialContext.java:223) [rt.jar:1.6.0_32]

              at javax.naming.InitialContext.<init>(InitialContext.java:197) [rt.jar:1.6.0_32]

              at com.curian.services.quote.wrapper.BSSecurityHandler.getEjbContext(BSSecurityHandler.java:143)

              at com.curian.services.quote.wrapper.QuoteBusinessService.initializeBean(QuoteBusinessService.java:55)

              at com.curian.services.quote.wrapper.QuoteBusinessService.getQuotes(QuoteBusinessService.java:116)

              at com.curian.services.quote.wrapper.QuoteService.getQuotes(QuoteService.java:73)

              at com.curian.services.quote.QuoteServiceMessageReceiverInOut.invokeBusinessLogic(QuoteServiceMessageReceiverInO

      ut.java:49)

              at org.apache.axis2.receivers.AbstractInOutMessageReceiver.invokeBusinessLogic(AbstractInOutMessageReceiver.java

      :40) [axis2-kernel-1.6.0.jar:1.6.0]

              at org.apache.axis2.receivers.AbstractMessageReceiver.receive(AbstractMessageReceiver.java:110) [axis2-kernel-1.

      6.0.jar:1.6.0]

              at org.apache.axis2.engine.AxisEngine.receive(AxisEngine.java:181) [axis2-kernel-1.6.0.jar:1.6.0]

              at org.apache.axis2.transport.http.HTTPTransportUtils.processHTTPPostRequest(HTTPTransportUtils.java:172) [axis2

      -transport-http-1.6.0.jar:]

              at org.apache.axis2.transport.http.AxisServlet.doPost(AxisServlet.java:146) [axis2-transport-http-1.6.0.jar:]

              at javax.servlet.http.HttpServlet.service(HttpServlet.java:754) [jboss-servlet-api_3.0_spec-1.0.1.Final.jar:1.0.

      1.Final]

              at javax.servlet.http.HttpServlet.service(HttpServlet.java:847) [jboss-servlet-api_3.0_spec-1.0.1.Final.jar:1.0.

      1.Final]

              at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:329) [jbossweb-7

      .0.16.Final.jar:]

              at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:248) [jbossweb-7.0.16.Fi

      nal.jar:]

              at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:275) [jbossweb-7.0.16.Final.ja

      r:]

              at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:161) [jbossweb-7.0.16.Final.ja

      r:]

              at org.jboss.as.web.security.SecurityContextAssociationValve.invoke(SecurityContextAssociationValve.java:153) [j

      boss-as-web-7.1.2.Final.jar:7.1.2.Final]

              at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:155) [jbossweb-7.0.16.Final.jar:]

              at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102) [jbossweb-7.0.16.Final.jar:]

              at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109) [jbossweb-7.0.16.Final.jar:

      ]

              at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:368) [jbossweb-7.0.16.Final.jar:]

              at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:877) [jbossweb-7.0.16.Final.jar:]

              at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:679) [jbossweb-7.

      0.16.Final.jar:]

              at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:931) [jbossweb-7.0.16.Final.jar:]

              at java.lang.Thread.run(Thread.java:662) [rt.jar:1.6.0_32]

      Caused by: java.lang.NoClassDefFoundError: com/sun/corba/se/spi/legacy/connection/ORBSocketFactory

              at java.lang.ClassLoader.defineClass1(Native Method) [rt.jar:1.6.0_32]

              at java.lang.ClassLoader.defineClassCond(ClassLoader.java:631) [rt.jar:1.6.0_32]

              at java.lang.ClassLoader.defineClass(ClassLoader.java:615) [rt.jar:1.6.0_32]

              at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:141) [rt.jar:1.6.0_32]

              at org.jboss.modules.ModuleClassLoader.doDefineOrLoadClass(ModuleClassLoader.java:327)

              at org.jboss.modules.ModuleClassLoader.defineClass(ModuleClassLoader.java:391)

              ... 50 more

      Caused by: java.lang.ClassNotFoundException: com.sun.corba.se.spi.legacy.connection.ORBSocketFactory from [Module "deplo

      yment.CurianServices.war:main" from Service Module Loader]

              at org.jboss.modules.ModuleClassLoader.findClass(ModuleClassLoader.java:190)

              at org.jboss.modules.ConcurrentClassLoader.performLoadClassUnchecked(ConcurrentClassLoader.java:468)

              at org.jboss.modules.ConcurrentClassLoader.performLoadClassChecked(ConcurrentClassLoader.java:456)

              at org.jboss.modules.ConcurrentClassLoader.performLoadClassChecked(ConcurrentClassLoader.java:423)

              at org.jboss.modules.ConcurrentClassLoader.performLoadClassChecked(ConcurrentClassLoader.java:423)

              at org.jboss.modules.ConcurrentClassLoader.performLoadClass(ConcurrentClassLoader.java:398)

              at org.jboss.modules.ConcurrentClassLoader.loadClass(ConcurrentClassLoader.java:120)

              ... 56 more

       

      Is there any way i can rectify these errors

       

      Ramineni

        • 1. Re: connecting remote ejb2.1 on weblogic 1.0 from AS 7.1.2
          Wolf-Dieter Fink Master

          You have to add the client.jar as a module in AS7 ./module/weblogic/client/main for example and also create a module.xml here.

          An example you will find here, see how you add a database driver as module.

          And you have to add the dependency to your application/META-INF/MANIFEST see AS7 classloading.

          • 2. Re: connecting remote ejb2.1 on weblogic 1.0 from AS 7.1.2
            Newbie

            Thanks for Quick reponse

            I added wlclient in /modules/weblogic/wlclient and created a module file and deployment structure files as below.

             

            <module xmlns="urn:jboss:module:1.1" name="weblogic.wlclient">

                <resources>

                    <resource-root path="wlclient.jar"/>

                </resources>

            </module>

             

             

            <?xml version="1.0" encoding="UTF-8"?>

            <jboss-deployment-structure>

              <deployment>

                <dependencies>

                  <module name="weblogic.wlclient" />

                </dependencies>

              </deployment>

            </jboss-deployment-structure>

             

             

            Now I am getting exception. This is same exception i got when i did not add wlclient to web-inf/lib.

             

            15:24:25,211 ERROR [stderr] (http-/127.0.0.1:8080-1) javax.naming.NamingException: JBAS011843: Failed instantiate In

            lContextFactory weblogic.jndi.WLInitialContextFactory from classloader ModuleClassLoader for Module "deployment.Curi

             

             

            With regards

            Ramineni

            • 3. Re: connecting remote ejb2.1 on weblogic 1.0 from AS 7.1.2
              Wolf-Dieter Fink Master

              I think there are dependencies by the wlclient.jar, you have to declare it in the module.xml.

              i.e.

               

              {code}

              <dependencies>

                <module name="javax.api"/>

                <module name="???"/>

              </dependencies>

              {code}

              1 of 1 people found this helpful
              • 4. Re: connecting remote ejb2.1 on weblogic 1.0 from AS 7.1.2
                Newbie

                I habve loded couple of dependencies. jacorb also as Jacorb is implementer for CORBA related interfaces. 

                 

                <dependencies>

                                    <module name="javax.api"/>

                                    <module name="org.jboss.as.jacorb"/>

                <!--<module name="org.jacorb"/> --> tried this also

                          </dependencies>

                 

                 

                I am getting following errors

                14:36:58,207 WARN  [org.jboss.modules] (http-/127.0.0.1:8080-1) Failed to define class weblogic.corba.client.ClientORBIn

                itializer in Module "weblogic.wlclient:main" from local module loader @193a66f (roots: D:\Program Files\jboss-as-7.1.2.F

                inal\modules): java.lang.LinkageError: Failed to link weblogic/corba/client/ClientORBInitializer (Module "weblogic.wlcli

                ent:main" from local module loader @193a66f (roots: D:\Program Files\jboss-as-7.1.2.Final\modules))

                        at org.jboss.modules.ModuleClassLoader.defineClass(ModuleClassLoader.java:396)

                        at org.jboss.modules.ModuleClassLoader.loadClassLocal(ModuleClassLoader.java:243)

                        at org.jboss.modules.ModuleClassLoader$1.loadClassLocal(ModuleClassLoader.java:73)

                        at org.jboss.modules.Module.loadModuleClass(Module.java:527)

                        at org.jboss.modules.ModuleClassLoader.findClass(ModuleClassLoader.java:182)

                        at org.jboss.modules.ConcurrentClassLoader.performLoadClassUnchecked(ConcurrentClassLoader.java:468)

                        at org.jboss.modules.ConcurrentClassLoader.performLoadClassChecked(ConcurrentClassLoader.java:456)

                        at org.jboss.modules.ConcurrentClassLoader.performLoadClassChecked(ConcurrentClassLoader.java:423)

                        at org.jboss.modules.ConcurrentClassLoader.performLoadClass(ConcurrentClassLoader.java:398)

                        at org.jboss.modules.ConcurrentClassLoader.loadClass(ConcurrentClassLoader.java:120)

                        at weblogic.jndi.WLInitialContextFactory.<init>(WLInitialContextFactory.java:29) [wlclient.jar:10.3.0.0]

                        at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) [rt.jar:1.6.0_32]

                        at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39) [rt.jar:1.6.0_32

                ]

                        at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27) [rt.jar:

                1.6.0_32]

                        at java.lang.reflect.Constructor.newInstance(Constructor.java:513) [rt.jar:1.6.0_32]

                        at java.lang.Class.newInstance0(Class.java:355) [rt.jar:1.6.0_32]

                        at java.lang.Class.newInstance(Class.java:308) [rt.jar:1.6.0_32]

                        at org.jboss.as.naming.InitialContextFactoryBuilder.createInitialContextFactory(InitialContextFactoryBuilder.jav

                a:62)

                        at javax.naming.spi.NamingManager.getInitialContext(NamingManager.java:664) [rt.jar:1.6.0_32]

                        at javax.naming.InitialContext.getDefaultInitCtx(InitialContext.java:288) [rt.jar:1.6.0_32]

                        at javax.naming.InitialContext.init(InitialContext.java:223) [rt.jar:1.6.0_32]

                        at javax.naming.InitialContext.<init>(InitialContext.java:197) [rt.jar:1.6.0_32]

                        at com.curian.services.quote.wrapper.BSSecurityHandler.getEjbContext(BSSecurityHandler.java:143)

                        at com.curian.services.quote.wrapper.QuoteBusinessService.initializeBean(QuoteBusinessService.java:55)

                        at com.curian.services.quote.wrapper.QuoteBusinessService.getQuotes(QuoteBusinessService.java:116)

                        at com.curian.services.quote.wrapper.QuoteService.getQuotes(QuoteService.java:73)

                        at com.curian.services.quote.QuoteServiceMessageReceiverInOut.invokeBusinessLogic(QuoteServiceMessageReceiverInO

                ut.java:49)

                        at org.apache.axis2.receivers.AbstractInOutMessageReceiver.invokeBusinessLogic(AbstractInOutMessageReceiver.java

                :40) [axis2-kernel-1.6.0.jar:1.6.0]

                        at org.apache.axis2.receivers.AbstractMessageReceiver.receive(AbstractMessageReceiver.java:110) [axis2-kernel-1.

                6.0.jar:1.6.0]

                        at org.apache.axis2.engine.AxisEngine.receive(AxisEngine.java:181) [axis2-kernel-1.6.0.jar:1.6.0]

                        at org.apache.axis2.transport.http.HTTPTransportUtils.processHTTPPostRequest(HTTPTransportUtils.java:172) [axis2

                -transport-http-1.6.0.jar:]

                        at org.apache.axis2.transport.http.AxisServlet.doPost(AxisServlet.java:146) [axis2-transport-http-1.6.0.jar:]

                        at javax.servlet.http.HttpServlet.service(HttpServlet.java:754) [jboss-servlet-api_3.0_spec-1.0.1.Final.jar:1.0.

                1.Final]

                        at javax.servlet.http.HttpServlet.service(HttpServlet.java:847) [jboss-servlet-api_3.0_spec-1.0.1.Final.jar:1.0.

                1.Final]

                        at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:329) [jbossweb-7

                .0.16.Final.jar:]

                        at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:248) [jbossweb-7.0.16.Fi

                nal.jar:]

                        at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:275) [jbossweb-7.0.16.Final.ja

                r:]

                        at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:161) [jbossweb-7.0.16.Final.ja

                r:]

                        at org.jboss.as.web.security.SecurityContextAssociationValve.invoke(SecurityContextAssociationValve.java:153) [j

                boss-as-web-7.1.2.Final.jar:7.1.2.Final]

                        at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:155) [jbossweb-7.0.16.Final.jar:]

                        at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102) [jbossweb-7.0.16.Final.jar:]

                        at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109) [jbossweb-7.0.16.Final.jar:

                ]

                        at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:368) [jbossweb-7.0.16.Final.jar:]

                        at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:877) [jbossweb-7.0.16.Final.jar:]

                        at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:679) [jbossweb-7.

                0.16.Final.jar:]

                        at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:931) [jbossweb-7.0.16.Final.jar:]

                        at java.lang.Thread.run(Thread.java:662) [rt.jar:1.6.0_32]

                Caused by: java.lang.NoClassDefFoundError: org/omg/PortableInterceptor/ORBInitializer

                        at java.lang.ClassLoader.defineClass1(Native Method) [rt.jar:1.6.0_32]

                        at java.lang.ClassLoader.defineClassCond(ClassLoader.java:631) [rt.jar:1.6.0_32]

                        at java.lang.ClassLoader.defineClass(ClassLoader.java:615) [rt.jar:1.6.0_32]

                        at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:141) [rt.jar:1.6.0_32]

                        at org.jboss.modules.ModuleClassLoader.doDefineOrLoadClass(ModuleClassLoader.java:327)

                        at org.jboss.modules.ModuleClassLoader.defineClass(ModuleClassLoader.java:391)

                        ... 46 more

                Caused by: java.lang.ClassNotFoundException: org.omg.PortableInterceptor.ORBInitializer from [Module "weblogic.wlclient:

                main" from local module loader @193a66f (roots: D:\Program Files\jboss-as-7.1.2.Final\modules)]

                        at org.jboss.modules.ModuleClassLoader.findClass(ModuleClassLoader.java:190)

                        at org.jboss.modules.ConcurrentClassLoader.performLoadClassUnchecked(ConcurrentClassLoader.java:468)

                        at org.jboss.modules.ConcurrentClassLoader.performLoadClassChecked(ConcurrentClassLoader.java:456)

                        at org.jboss.modules.ConcurrentClassLoader.performLoadClassChecked(ConcurrentClassLoader.java:423)

                        at org.jboss.modules.ConcurrentClassLoader.performLoadClassChecked(ConcurrentClassLoader.java:423)

                        at org.jboss.modules.ConcurrentClassLoader.performLoadClass(ConcurrentClassLoader.java:398)

                        at org.jboss.modules.ConcurrentClassLoader.loadClass(ConcurrentClassLoader.java:120)

                        ... 52 more

                 

                My client is conflicting with jacorb implementation. Any thoughts on this will be appeciated.

                 

                 

                With regards

                Raja Ramineni

                • 5. Re: connecting remote ejb2.1 on weblogic 1.0 from AS 7.1.2
                  Fabrizio Benedetti Novice

                  wlclient.jar lacks some dependencies, try to use weblogic.jar instead.