This week's book giveaways are in the Java EE and JavaScript forums.
We're giving away four copies each of The Java EE 7 Tutorial Volume 1 or Volume 2(winners choice) and jQuery UI in Action and have the authors on-line!
See this thread and this one for details.
The moose likes EJB and other Java EE Technologies and the fly likes HF EJB AdviceClient example - error- java.lang.ClassNotFoundException: com.sun.corba.se.internal.uti Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of The Java EE 7 Tutorial Volume 1 or Volume 2 this week in the Java EE forum
or jQuery UI in Action in the JavaScript forum!
JavaRanch » Java Forums » Java » EJB and other Java EE Technologies
Bookmark "HF EJB AdviceClient example - error- java.lang.ClassNotFoundException: com.sun.corba.se.internal.uti" Watch "HF EJB AdviceClient example - error- java.lang.ClassNotFoundException: com.sun.corba.se.internal.uti" New topic
Author

HF EJB AdviceClient example - error- java.lang.ClassNotFoundException: com.sun.corba.se.internal.uti

Ravendra Singh
Greenhorn

Joined: May 09, 2014
Posts: 2

Hi,

I'm trying to run Head First EJB - Advice example. I've created and deployed the bean using RI but when when I tried to run AdviceClient class, I'm getting the below error.

Please find below my client java code and the error message

Please help.

AdviceClient.java




Error message :


C:\javaEJB\projects\advice>java -cp .;C:\j2sdkee1.3.1\lib\j2ee.jar;AdviceAppClient.jar AdviceClient
Exception in thread "main" java.lang.NoClassDefFoundError: com/sun/corba/se/internal/util/JDKBridge
at com.sun.corba.ee.internal.core.IOR$LocalCodeBaseSingletonHolder.<clinit>(IOR.java:90)
at com.sun.corba.ee.internal.core.IOR.<init>(IOR.java:238)
at com.sun.corba.ee.internal.iiop.messages.LocateReplyMessage_1_2.read(LocateReplyMessage_1_2.java:137)
at com.sun.corba.ee.internal.iiop.IIOPInputStream.unmarshalHeader(IIOPInputStream.java:126)
at com.sun.corba.ee.internal.iiop.IIOPConnection.getResponse(IIOPConnection.java:671)
at com.sun.corba.ee.internal.iiop.IIOPConnection.send(IIOPConnection.java:778)
at com.sun.corba.ee.internal.corba.InitialNamingClient.locateObject(InitialNamingClient.java:786)
at com.sun.corba.ee.internal.corba.InitialNamingClient.getIORUsingHostInfo(InitialNamingClient.java:597)
at com.sun.corba.ee.internal.corba.InitialNamingClient.resolveCorbaloc(InitialNamingClient.java:573)
at com.sun.corba.ee.internal.corba.InitialNamingClient.resolveUsingORBInitRef(InitialNamingClient.java:544)
at com.sun.corba.ee.internal.corba.InitialNamingClient.cachedInitialReferences(InitialNamingClient.java:1080)
at com.sun.corba.ee.internal.corba.InitialNamingClient.resolve_initial_references(InitialNamingClient.java:981)
at com.sun.corba.ee.internal.corba.ORB.resolve_initial_references(ORB.java:2425)
at com.sun.enterprise.naming.SerialContext.getProvider(SerialContext.java:52)
at com.sun.enterprise.naming.SerialContext.lookup(SerialContext.java:120)
at javax.naming.InitialContext.lookup(Unknown Source)
at AdviceClient.go(AdviceClient.java:17)
at AdviceClient.main(AdviceClient.java:11)
Caused by: java.lang.ClassNotFoundException: com.sun.corba.se.internal.util.JDKBridge
at java.net.URLClassLoader$1.run(Unknown Source)
at java.net.URLClassLoader$1.run(Unknown Source)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(Unknown Source)
at java.lang.ClassLoader.loadClass(Unknown Source)
at sun.misc.Launcher$AppClassLoader.loadClass(Unknown Source)
at java.lang.ClassLoader.loadClass(Unknown Source)
... 18 more


How to resolve this error?

Regards,
Ravendra
Ravendra Singh
Greenhorn

Joined: May 09, 2014
Posts: 2
The class (JDKBridge) that wasn't being found can be found in:

C:\j2sdk1.4.2_08\jre\lib\rt.jar

After adding that to my classpath, the program worked fine.

http://www.coderanch.com/t/316336/EJB-JEE/java/Head-EJB-Chapter-Application
Rob Spoor
Sheriff

Joined: Oct 27, 2005
Posts: 19679
    
  18

Why are you using such ancient Java versions? JEE 1.3 and JSE 1.4 (from your directory names) have been replaced ages ago. JEE 6 and 7 are now mainstream, as well as JSE 7 (with 8 already released).


SCJP 1.4 - SCJP 6 - SCWCD 5 - OCEEJBD 6
How To Ask Questions How To Answer Questions
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: HF EJB AdviceClient example - error- java.lang.ClassNotFoundException: com.sun.corba.se.internal.uti