Win a copy of The Business Blockchain this week in the Cloud forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

NoClassDef in Weblogic 8.1 client

 
John Lindwall
Ranch Hand
Posts: 31
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
We're testing our JNLP client application which talks to a session bean running in a Weblogic 8.1 server. This application works fine against a WebLogic 6.1 server. We're getting a ClassDefNotFoundException when getting the initial context even though the class it complains about IS in the application jar file.
Any ideas?
Thanks!
Authentication failed: java.lang.NoClassDefFoundError: weblogic/rmi/extensions/server/Stub
at java.lang.ClassLoader.defineClass0(Native Method)
at java.lang.ClassLoader.defineClass(Unknown Source)
at java.security.SecureClassLoader.defineClass(Unknown Source)
at weblogic.utils.classloaders.GenericClassLoader.findLocalClass(GenericClassLoader.java:431)
at weblogic.utils.classloaders.GenericClassLoader.findClass(GenericClassLoader.java:169)
at java.lang.ClassLoader.loadClass(Unknown Source)
at java.lang.ClassLoader.loadClass(Unknown Source)
at java.lang.ClassLoader.loadClassInternal(Unknown Source)
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(Unknown Source)
at weblogic.utils.classfile.utils.CodeGenerator.generateClass(CodeGenerator.java:71)
at weblogic.rmi.internal.StubGenerator.getStubClass(StubGenerator.java:672)
at weblogic.rmi.internal.StubGenerator.generateStub(StubGenerator.java:712)
at weblogic.rmi.internal.StubGenerator.generateStub(StubGenerator.java:699)
at weblogic.rmi.extensions.StubFactory.getStub(StubFactory.java:76)
at weblogic.jndi.WLInitialContextFactoryDelegate.newRootNamingNodeStub(WLInitialContextFactoryDelegate.java:486)
at weblogic.jndi.WLInitialContextFactoryDelegate.newRemoteContext(WLInitialContextFactoryDelegate.java:449)
at weblogic.jndi.WLInitialContextFactoryDelegate.newContext(WLInitialContextFactoryDelegate.java:345)
at weblogic.jndi.WLInitialContextFactoryDelegate.getInitialContext(WLInitialContextFactoryDelegate.java:308)
at weblogic.jndi.WLInitialContextFactoryDelegate.getInitialContext(WLInitialContextFactoryDelegate.java:234)
at weblogic.jndi.WLInitialContextFactory.getInitialContext(WLInitialContextFactory.java:135)
at javax.naming.spi.NamingManager.getInitialContext(Unknown Source)
at javax.naming.InitialContext.getDefaultInitCtx(Unknown Source)
at javax.naming.InitialContext.init(Unknown Source)
at javax.naming.InitialContext.<init>(Unknown Source)
at com.xifin.lor.oe.action.login.RemoteLoginModule.authenticate(RemoteLoginModule.java:116)
at com.xifin.lor.oe.action.login.RemoteLoginModule.login(RemoteLoginModule.java:81)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at javax.security.auth.login.LoginContext.invoke(Unknown Source)
at javax.security.auth.login.LoginContext.access$000(Unknown Source)
at javax.security.auth.login.LoginContext$4.run(Unknown Source)
at java.security.AccessController.doPrivileged(Native Method)
at javax.security.auth.login.LoginContext.invokeModule(Unknown Source)
at javax.security.auth.login.LoginContext.login(Unknown Source)
at com.xifin.lor.oe.action.login.Login.perform(Login.java:55)
at com.xifin.mvc.swing.ActionAdapter.perform(ActionAdapter.java:62)
at com.xifin.mvc.framework.Controller.performAction(Controller.java:245)
at com.xifin.mvc.framework.Controller.performAction(Controller.java:240)
at com.xifin.mvc.framework.Controller.performAction(Controller.java:232)
at com.xifin.mvc.framework.Controller.run(Controller.java:55)
at com.xifin.lor.oe.Application.main(Application.java:32)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at com.sun.javaws.Launcher.executeApplication(Unknown Source)
at com.sun.javaws.Launcher.executeMainClass(Unknown Source)
at com.sun.javaws.Launcher.continueLaunch(Unknown Source)
at com.sun.javaws.Launcher.handleApplicationDesc(Unknown Source)
at com.sun.javaws.Launcher.handleLaunchFile(Unknown Source)
at com.sun.javaws.Launcher.run(Unknown Source)
at java.lang.Thread.run(Unknown Source)
 
John Lindwall
Ranch Hand
Posts: 31
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
BTW We've testied this using several version of Java Web Start ranging from 1.4.1_01, 1.4.1_02 and 1.4.2 beta.
 
Murali Nanchala
Ranch Hand
Posts: 74
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
This was an issue and was resolved in WebLogic 6.1 (SP 5, I think); It wouldn't hurt if you reported this to BEA. The bug may be back.
 
John Lindwall
Ranch Hand
Posts: 31
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks for your reply. We did file a case w/BEA and the response did not help us (see below). We tried the suggestions at that Sun forum and the thin client is not what we want.
BEA Support said:
The problem you pointed out seems to be associated with implementation with Java Web Start and WebLogic Server. Java Web Start has the classloading problem. WebLogic Server has complex classloader hierarchy. Changing WebLogic Server code in order to work with Java Web Start is not a simple thing that can be done very soon.
I did some research. I found a post at http://forum.java.sun.com/thread.jsp?forum=38&thread=301640 which suggests to use Thread.currentThread().setContextClassLoader( someClass.class.getClassLoader() ) in application code. I know it's not pretty. Are you willing to try that?
There is another possibility is to try something other than Java Web Start. WebLogic 8.1 provides Thin Client functionality. You may find documentation at http://e-docs.bea.com/wls/docs81/rmi_iiop/rmiiiop2.html#1071450. Does thin-client meets your requirement?
 
John Lindwall
Ranch Hand
Posts: 31
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
We recieved an unsolicited email from BEA support indicating that this is indeed a bug in WL 8.1 and it will be fixed in SP1 due in mid June 2003.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic