• Post Reply Bookmark Topic Watch Topic
  • New Topic

Link Exception for Entity bean Lookup  RSS feed

 
John Vergis
Ranch Hand
Posts: 59
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,
I have deployed an entity bean called TestBean with JNDI name as "ejb.TestBeanHome" and ejb-name as "TestBeanJDBC" in WLS81, When i am trying to look up for this bean from my client code, i get the following exception:-
Exception ...javax.naming.LinkException: [Root exception is javax.naming.LinkException: [Root exception is javax.namin
g.NameNotFoundException: remaining name: /app/ejb/EntityProj.jar#TestBeanJDBC/local-home]; Link Remaining Name: 'null'];
Link Remaining Name: 'java:app/ejb/EntityProj.jar#TestBeanJDBC/local-home'

could ne1 help me out in figuring what is amiss over here...

thanks
Johnny
 
Seetesh Hindlekar
Ranch Hand
Posts: 244
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,
There is a problem with ur deployment descriptor. Post all ur xml files to locate the problem.
Seetesh
 
Seetesh Hindlekar
Ranch Hand
Posts: 244
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,
Pls refer to my thread
http://forum.java.sun.com/thread.jsp?forum=13&thread=472298. The problem lied while defining my jndi-name for that bean.
In order to use remote invocation with EJBs, you must have the Home/Remote interfaces.
If your "client" of EjbB was not an EJB, you can use reflection carefully, such as from a stand-alone application. But within the container, you cannot use reflection, ergo you must use the interfaces.
And just because the two JAR files are on the same machine, even "running" in the same JVM, doesn't mean a durn thing. Typically, they're in different ClassLoaders, which means that they cannot "see" each other - and you have to rely on the container's remote invocation to access them.
Seetesh
 
It is sorta covered in the JavaRanch Style Guide.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!