This week's book giveaway is in the OCAJP 8 forum.
We're giving away four copies of OCA Java SE 8 Programmer I Study Guide and have Edward Finegan & Robert Liguori on-line!
See this thread for details.
The moose likes EJB and other Java EE Technologies and the fly likes ClassCastException Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of OCA Java SE 8 Programmer I Study Guide this week in the OCAJP 8 forum!
JavaRanch » Java Forums » Java » EJB and other Java EE Technologies
Bookmark "ClassCastException" Watch "ClassCastException" New topic


Mathias Andrae

Joined: Feb 04, 2002
Posts: 23
My AppServer is WebSphere 4.0, my IDE is JBuilder 6 Enterprise.
Now my problem:
I have got problems to connect to my ejb.
the ejb runs correctly on websphere.
the lookup() in the works also correctly.
but when I cast the HomeInterface I got following exception:
java.lang.ClassCastException: Unable to load class: org.omg.stub.ejb._SessionHome_Stub
at javax.rmi.PortableRemoteObject.narrow(
at ejb.SessionTestClient1.<init>(
at ejb.SessionTestClient1.main(
Is there anything I have to do on the client???
classpath??? imports???
I used the standard-test-client of JBuilder.
I only changed the URL of my AppServer.
thanks for help!!!
Malli Raman
Ranch Hand

Joined: Nov 07, 2001
Posts: 312
Check whether javax.rmi.* package is available in the classpath.
I agree. Here's the link:
subject: ClassCastException
jQuery in Action, 3rd edition