• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Ron McLeod
  • Paul Clapham
  • Devaka Cooray
  • Liutauras Vilda
Sheriffs:
  • Jeanne Boyarsky
  • paul wheaton
  • Henry Wong
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Tim Moores
  • Carey Brown
  • Mikalai Zaikin
Bartenders:
  • Lou Hamers
  • Piet Souris
  • Frits Walraven

PLS help -urgent Prob with headfirst Advice

 
Greenhorn
Posts: 13
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I tried compiling the sample program in Headfirst - (Advice). I was able to generate the class file after the successful compilation, but failed in running the AdviceClient.

The command given is
java -classpath %CLASSPATH%;AdviceAppClient.jar AdviceClient

I am getting NoClassFound Exception. Below is the full error message:


C:\EJBDEMO\projects\advice>java -classpath %CLASSPATH%;AdviceAppClient.jar Advic
eClient
Exception in thread "main" java.lang.NoClassDefFoundError: com/sun/corba/se/inte
rnal/util/JDKBridge
at com.sun.corba.ee.internal.core.IOR$LocalCodeBaseSingletonHolder.<clin
it>(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(L
ocateReplyMessage_1_2.java:137)
at com.sun.corba.ee.internal.iiop.IIOPInputStream.unmarshalHeader(IIOPIn
putStream.java:126)
at com.sun.corba.ee.internal.iiop.IIOPConnection.getResponse(IIOPConnect
ion.java:671)
at com.sun.corba.ee.internal.iiop.IIOPConnection.send(IIOPConnection.jav
a:778)
at com.sun.corba.ee.internal.corba.InitialNamingClient.locateObject(Init
ialNamingClient.java:786)
at com.sun.corba.ee.internal.corba.InitialNamingClient.getIORUsingHostIn
fo(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(InitialContext.java:351)
at AdviceClient.go(adviceclient.java:18)
at AdviceClient.main(adviceclient.java:11)

I tried all the solutions given for similar problems in the following sites:

https://coderanch.com/t/158486/java-EJB-SCBCD/certification/head-first-ejb-pg-client

http://wickedlysmart.com/HeadFirst/HeadFirstEJB/HeadFirstEJBNotes.html

Still I couldn't solve the problem. My settings are
Classpath-
C:\jdk1.3.1\bin;C:\jdk1.3.1\lib;c:\j2sdkee1.3.1\lib\j2ee.jar;.;C:\j2sdkee1.3.1\lib;C:\j2sdkee1.3.1\lib\system;C:\j2sdkee1.3.1\lib\cloudscape

J2EE_HOME-
C:\j2sdkee1.3.1

Java_Home-
C:\jdk1.3.1

PATH-
C:\j2sdkee1.3.1\bin

Please help me to resolve this problem. Its killing my sleep for long days....
Thanks
Priya

[ March 09, 2007: Message edited by: priya pratheep ]
[ March 09, 2007: Message edited by: priya pratheep ]
 
Ranch Hand
Posts: 643
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
remove any other jre if installed on your machine.
this problem occurs if you have any other jre installed other than 1.3.1_19
run time should be like this

java -version
java version "1.3.1_19"
Java(TM) 2 Runtime Environment, Standard Edition (build 1.3.1_19-b03)
Java HotSpot(TM) Client VM (build 1.3.1_19-b03, mixed mode)
 
priya pratheep
Greenhorn
Posts: 13
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
HI Gowher amin naik

We have jre 1.3.1 only .
But when trying "java -version"

java version "1.5.0_09"
Java(TM) 2 Runtime Environment, Standard Edition (build 1.5.0_09-b03)
Java HotSpot(TM) Client VM (build 1.5.0_09-b03, mixed mode)

Actually no such version existing .
I don't know from where it is comming

Still i cant't run my adviceclient
thanks in advance...pls help
 
priya pratheep
Greenhorn
Posts: 13
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Anybody please help me...I send private message also to brilliant people like you
there is no response
please help urgent !!!
 
Gowher Naik
Ranch Hand
Posts: 643
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
if java -version shows jre 1.5.0_09 that means it is installed on your machine.
You have to remove jre 1.5.0_09 and your problem will be solved.
 
priya pratheep
Greenhorn
Posts: 13
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi gowher amin naik

Actually i removed all jre version from system except 1.3.1....
To make sure,I removed all Java from the system and installed jdk jsdk and jre of version 1.3.1...after restart Still java version shows 1.5
I don't know from where it is getting...
pls help
 
drifter
Posts: 1364
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
You need C:\jdk1.3.1\bin in your PATH and at the beginning of your path. After you do that try java -version again. If you still have problems then please show us your actual path and other settings.

(Don't remove C:\j2sdkee1.3.1\bin from your path, just add the jdk to the beginning.)

(This may not be hurting anything, but you do not need a bunch of bin and lib directories in your classpath. You do need the j2ee.jar and dot: c:\j2sdkee1.3.1\lib\j2ee.jar;.)


Originally posted by priya pratheep:
\
Still I couldn't solve the problem. My settings are
Classpath-
C:\jdk1.3.1\bin;C:\jdk1.3.1\lib;c:\j2sdkee1.3.1\lib\j2ee.jar;.;C:\j2sdkee1.3.1\lib;C:\j2sdkee1.3.1\lib\system;C:\j2sdkee1.3.1\lib\cloudscape

J2EE_HOME-
C:\j2sdkee1.3.1

Java_Home-
C:\jdk1.3.1

PATH-
C:\j2sdkee1.3.1\bin

 
priya pratheep
Greenhorn
Posts: 13
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi Carol Enderlin

thank you for your reply...I really fed up with this prob....

Regarding version
I uninstall jre 1.5 from my system and instal 1.3....
I am using windows XP, From control panel -- java -- i changed there to 1.3 also..
Still java -version is showing 1.5

My Setting are
Path :: C:\Sun\SDK\jdk\bin;C:\jdk1.3.1\bin;c:\j2sdkee1.3.1\bin;
Classpath :: C:\j2sdkee1.3.1\lib\j2ee.jar;.
java_home :: c:\jdk1.3.1
j2ee_home :: c:\j2sdkee1.3.1

I am getting the error
C:\EJBDEMO\projects\advice>java -classpath %classpath%;AdvAppClient.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.<clin
it>(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(L
ocateReplyMessage_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.getIORUsingHostIn
fo(InitialNamingClient.java:597)
at com.sun.corba.ee.internal.corba.InitialNamingClient.resolveCorbaloc(I
nitialNamingClient.java:573)
at com.sun.corba.ee.internal.corba.InitialNamingClient.resolveUsingORBIn
itRef(InitialNamingClient.java:544)
at com.sun.corba.ee.internal.corba.InitialNamingClient.cachedInitialRefe
rences(InitialNamingClient.java:1080)
at com.sun.corba.ee.internal.corba.InitialNamingClient.resolve_initial_r
eferences(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(InitialContext.java:351)
at AdviceClient.go(AdviceClient.java:28)
at AdviceClient.main(AdviceClient.java:15)
pls help
thank you
priya
 
priya pratheep
Greenhorn
Posts: 13
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi Carol
please reply
priya
 
Carol Enderlin
drifter
Posts: 1364
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
EaseUp!

If this is your path, it would look for java from C:\Sun\SDK\jdk\bin before it would look in C:\jdk1.3.1\bin since it comes before C:\jdk1.3.1\bin in the path :

Path :: C:\Sun\SDK\jdk\bin;C:\jdk1.3.1\bin;c:\j2sdkee1.3.1\bin;

Can you change it to this? :

C:\jdk1.3.1\bin;c:\j2sdkee1.3.1\bin;C:\Sun\SDK\jdk\bin
 
priya pratheep
Greenhorn
Posts: 13
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi Carol

I don't know how to express my happiness ....At LAST it is working...
After giving three weeks of pain.......
In System variables (environment variable) path was not correct that causes the problem..............
Once again thanks

Priya
 
Carol Enderlin
drifter
Posts: 1364
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
That's great news!
 
Hey cool! They got a blimp! But I have a tiny ad:
We need your help - Coderanch server fundraiser
https://coderanch.com/wiki/782867/Coderanch-server-fundraiser
reply
    Bookmark Topic Watch Topic
  • New Topic