Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

ejb calls without using stubs

14 views
Skip to first unread message

kdeeva...@yahoo.com

unread,
Oct 12, 2007, 5:34:46 AM10/12/07
to
hello friends
the standard convention of using rmi stubs to call ejb's is pretty common.In websphere specifically I needed to use the ejb.jar in my class path to call ejb's.I have read some where that we can use dynamic proxies(which doesn't need stub generation) but don't know how to use it in context of IBM jvm.Please can anyone suggest or give me an example.

Thanks

kdeeva...@yahoo.com

unread,
Oct 12, 2007, 9:10:11 AM10/12/07
to
I installed websphere application client on my machine and added the entire folder in classpath and tried calling it without generating the stubs.
but I get the following error.

java.lang.ClassCastException: Unable to load class: com.stg.classes.ejb._BusinessHome_Stub
at com.ibm.rmi.javax.rmi.PortableRemoteObject.narrow(PortableRemoteObject.java:367)
at javax.rmi.PortableRemoteObject.narrow(PortableRemoteObject.java:156)
at TestConnection.getBusinessSession(TestEJBConnection.java:42)
at TestConnection.main(TestEJBConnection.java:21)

any ideas please

kdeeva...@yahoo.com

unread,
Oct 12, 2007, 9:39:43 AM10/12/07
to
Thanks Paul
it works fine when i generate stubs and add them onto classpath but the idea is to test without generating stubs.I read somewhere that having websphere application client in classpath would resolve the issue.Please let me know if my understanding is wrong or I need a different approach.

thanks

Paul Ilechko

unread,
Oct 12, 2007, 9:24:11 AM10/12/07
to

Generate the stubs.

Paul Ilechko

unread,
Oct 12, 2007, 11:03:26 AM10/12/07
to

It's not supported without the stubs.

Jonathan

unread,
Oct 12, 2007, 11:34:01 AM10/12/07
to
Websphere does not support dynamic proxies, you must generate the stubs.


0 new messages