G'day,

I'm trying to run a EJB test client via RMI-IIOP, i followed the instructions 
found on this site to override the standard invoker in the Jboss.xml file of 
the session bean I want to approach.

The lookup of the home reference is fine, e.g.
    Object o = ctx.lookup("ejb/EmployeeManagerSession");

but when I try to 'narrow '
the object to the home interface I get a ClassCastException.

EmployeeManagerSessionHome intf = (EmployeeManagerSessionHome) 
PortableRemoteObject.narrow( o, EmployeeManagerSessionHome.class);


I looked a bit further and noticed that the 
  result = Utility.loadStub(narrowObj,narrowTo); function is returning 'null', 
apparently there is no stub available for my home interface. I was under the 
impresion that the server is taking care of the stub generation at deploytime, 
do I have to configure something on the server first to enable this?

I aslo ran the iiop-test from the 'testsuite', they are working fine. i tried 
to figure out what is being done differently here (comparing classpath, 
propertie files etc. ), but since this test configuration is quite complex I 
didnt manage yet, does anybody have a clue what  I am missing?

Btw, I get the foolwing excpetion each time I run my test client

java.lang.ClassCastException
        at 
com.sun.corba.se.internal.javax.rmi.PortableRemoteObject.narrow(PortableRemoteObject.java:293)
        at javax.rmi.PortableRemoteObject.narrow(PortableRemoteObject.java:134)
        at 
nl.technolution.tpts.testapp.TestEmployeeManager.getHome(TestEmployeeManager.java:82)
        at 
nl.technolution.tpts.testapp.TestEmployeeManager.setUp(TestEmployeeManager.java:92)
        at junit.framework.TestCase.runBare(TestCase.java:125)
        at junit.framework.TestResult$1.protect(TestResult.java:106)
        at junit.framework.TestResult.runProtected(TestResult.java:124)
        at junit.framework.TestResult.run(TestResult.java:109)
        at junit.framework.TestCase.run(TestCase.java:118)
        at junit.framework.TestSuite.runTest(TestSuite.java:208)
        at junit.framework.TestSuite.run(TestSuite.java:203)
        at 
org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:421)
        at 
org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:305)
        at 
org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main(RemoteTestRunner.java:186)

thx in advance, Joeri Klekamp


View the original post : 
http://www.jboss.org/index.html?module=bb&op=viewtopic&p=3855218#3855218

Reply to the post : 
http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=3855218


-------------------------------------------------------
This SF.Net email is sponsored by: InterSystems CACHE
FREE OODBMS DOWNLOAD - A multidimensional database that combines
robust object and relational technologies, making it a perfect match
for Java, C++,COM, XML, ODBC and JDBC. www.intersystems.com/match8
_______________________________________________
JBoss-Development mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-development

Reply via email to