Win a copy of The Little Book of Impediments (e-book only) this week in the Agile and Other Processes forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Help required for executing EJB

 
Prateesh Pandey
Ranch Hand
Posts: 45
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi All,

I have recently started studying EJB using HFEJB. I have successfully deployed Advice Bean on J2eesdk1.3. I am facing Exception in Thread "main" java.lang.NoClassDefFoundError: while trying to run AdviceClient.

Please help me to sort out the problem.

Thanks in advance
 
Sandeep Prabhakar
Ranch Hand
Posts: 59
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hey,
Go through this link.

http://www.coderanch.com/t/161481/java-EJB-SCBCD/certification/AdviceClient-Solution

Hope this Helps

Cheers,
Sandep
 
Prateesh Pandey
Ranch Hand
Posts: 45
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi sandeep,

I have followed all the steps but still facing following exception;


javax.naming.NoInitialContextException: Need to specify class name in environment or system property, or as an applet parameter, or in an application resource file: java.naming.factory.initial

Please help!
 
Shivakanth Thyagarajan
Ranch Hand
Posts: 41
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Prateesh,
Have you set the classpath with this appserv-rt.jar which is in lib folder. This could help you. I probably feel it's simply a issue with your settings and not about the code. Try this out.

Thanks
Shivakanth
 
Prateesh Pandey
Ranch Hand
Posts: 45
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Shiva,
I couldn't locate the file appserv-rt.jar in j2eesdk1.3.1 version.
 
Prateesh Pandey
Ranch Hand
Posts: 45
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi All,
I am not able to run my first EJB.
Now facing a strange kind of Exception:

java.rmi.AccessException: CORBA NO_PERMISSION 0 No; nested exception is:
org.omg.CORBA.NO_PERMISSION: vmcid: 0x0 minor code: 0 completed: No
at com.sun.corba.ee.internal.iiop.ShutdownUtilDelegate.mapSystemExceptio
n(ShutdownUtilDelegate.java:87)
at javax.rmi.CORBA.Util.mapSystemException(Unknown Source)
at headfirst._AdviceHome_Stub.create(Unknown Source)
at AdviceClient.go(AdviceClient.java:22)
at AdviceClient.main(AdviceClient.java:11)
Caused by: org.omg.CORBA.NO_PERMISSION: vmcid: 0x0 minor code: 0 completed:
No
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)

at sun.reflect.NativeConstructorAccessorImpl.newInstance(Unknown Source)

at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(Unknown Sou
rce)
at java.lang.reflect.Constructor.newInstance(Unknown Source)
at java.lang.Class.newInstance0(Unknown Source)
at java.lang.Class.newInstance(Unknown Source)
at com.sun.corba.ee.internal.iiop.messages.ReplyMessage_1_2.getSystemExc
eption(ReplyMessage_1_2.java:93)
at com.sun.corba.ee.internal.iiop.ClientResponseImpl.getSystemException(
ClientResponseImpl.java:108)
at com.sun.corba.ee.internal.POA.GenericPOAClientSC.invoke(GenericPOACli
entSC.java:136)
at org.omg.CORBA.portable.ObjectImpl._invoke(Unknown Source)
... 3 more

I am using j2eesdk1.3.1 on WIN XP with J2sdk1.4_03.

Pls help!
 
Sandeep Prabhakar
Ranch Hand
Posts: 59
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hey,
Please try using JDK1.3.

Cheers,
Sandeep
 
Prateesh Pandey
Ranch Hand
Posts: 45
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Finally, the code is running.
Thanks to u all.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic