Hello, I just embarked on my journey towards SCBCD and have been getting the following runtime error when I try to run the AdviceClient code after following HeadFirstEJB. Please let me know if I am missing somethign(have the j2ee.jar etc in my classpath and the j2ee server shows no errors, says Deployment of AdviceAppClient is completed.
C:\projects\advice>java -cp %CLASSPATH%;AdviceAppClient.jar AdviceClient java.rmi.RemoteException: CORBA BAD_OPERATION 0 No; nested exception is: org.omg.CORBA.BAD_OPERATION: minor code: 0 completed: No org.omg.CORBA.BAD_OPERATION: minor code: 0 completed: No at java.lang.Class.newInstance0(Native Method) 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:132) at org.omg.CORBA.portable.ObjectImpl._invoke(Unknown Source) at headfirst._Advice_Stub.getAdvice(Unknown Source) at AdviceClient.go(AdviceClient.java:19) at AdviceClient.main(AdviceClient.java:9) Thanks Siva
Joined: Aug 20, 2004
Hello, Think I figured part of the problem. Had a copy of AdviceAppClient.jar in the projects/advice folder and when I removed the same the previous errors vanished, still getting the following, trying further. Let me know if any of you have come across this problem.
C:\projects\advice>java -cp %CLASSPATH%;AdviceAppClient.jar AdviceClient java.lang.ClassCastException at com.sun.corba.se.internal.javax.rmi.PortableRemoteObject.narrow(Unkno wn Source) at javax.rmi.PortableRemoteObject.narrow(Unknown Source) at AdviceClient.go(AdviceClient.java:17) at AdviceClient.main(AdviceClient.java:9)
See the Errata of HFE. It may help. According to this Component interface name (Advice) should not be part of bean method name (getAdvice). so change bean method name to some thing else like getMessage and try?.
Joined: Aug 20, 2004
Thanks Yamini. Looks like the version of J2EE RI that I have installed has that bug.
I was trying for the last 4 hrs without readig your posting and nothing helped, finally when I looked at your posting, and made the necessary changes, presto, it worked. Now, I will read the book with more confidence.