Win a copy of Murach's Python Programming this week in the Jython/Python forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

Client Access with JNDI: NoSuchMethodException  RSS feed

 
Nico Haller
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello.

I have an EJB project deployed to WebLogic 10.3. The beans are registered in the JNDI (remote). I access the JNDI with a test client and I also get the proxy back from JNDI without any errors. But when I try to call a method over the proxy, I get this error:

Caused by: java.lang.NoSuchMethodException: bestellungsverwaltung.WarenkorbBean_4kew2o_WarenkorbRemoteImpl_1030_WLStub.flush()

I connect to the JNDI with this jndi.properties:

java.naming.provider.url=t3://localhost:7001
java.naming.factory.initial=weblogic.jndi.WLInitialContextFactory

This is how I access the proxy:

final Context ctx = new InitialContext();
bvProxy = (BenutzerverwaltungRemote) ctx.lookup("BenutzerverwaltungBean#benutzerverwaltung/BenutzerverwaltungRemote");
 
Jaikiran Pai
Sheriff
Posts: 10447
227
IntelliJ IDE Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Are you sure your client classpath has the correct version of the jar containing bestellungsverwaltung.WarenkorbBean_4kew2o_WarenkorbRemoteImpl_1030_WLStub
 
Nico Haller
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I have set a dependency to the EJB project! It should be working, right? And when I try to access the EJB with a managed bean in the same EAR, it doesn't work either.
 
Reza Rahman
author
Ranch Hand
Posts: 580
5
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Nico,

Without looking at your code in detail, it looks like WLS is having trouble generating the EJB stubs properly.

I would look into issues like proper access modifiers (EJB methods must be public, non-final, non-static), specifying an interface correctly (through the OO inheritance hierarchy), byte-code generation issues (are you using third-party byte-code generation engines on top of WLS?), class-path issues (something in the classpath does not agree with the WLS EJB 3 container?), deployment issues (are you using auto-deploy - not always smooth?, waiting for the deployment to finish?) etc.

Hope this helps,
Reza
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!