• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Paul Clapham
  • Bear Bibeault
  • Liutauras Vilda
  • Devaka Cooray
Sheriffs:
  • Knute Snortum
  • Junilu Lacar
  • Henry Wong
Saloon Keepers:
  • Ron McLeod
  • Stephan van Hulst
  • Tim Moores
  • Carey Brown
  • Tim Holloway
Bartenders:
  • salvin francis
  • Frits Walraven
  • Piet Souris

Problem with JNDI Name in CMP

 
Ranch Hand
Posts: 452
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello Friends,

I am trying to access a CMP through a SessionBean.



The jndi name of the CMP ("EMPLOYEE_DATA") is "saddy/EMPLOYEE_DATALocalHome".

Now my problem is when i try to access my CMp through the Session Bean using jndi name "java:comp/env/ejb/EMPLOYEE_DATALocalHome" or "java:comp/env/ejb/saddy/EMPLOYEE_DATALocalHome" i get exception where as the same code works if i use jndi name as "local:/ejb/saddy/EMPLOYEE_DATALocalHome".

I am unable to understand what is wrong in my code, why i am not able to access my CMP in a normal way.

Sorry for the way i have displayed the content of ejb-jar.xml, as i was unable to put it in better format using UBB code.

Please help.
[ May 26, 2004: Message edited by: Prakash Dwivedi ]
 
author & internet detective
Posts: 39840
797
Eclipse IDE VI Editor Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Prakash,
WSAD uses / for remote interfaces and local:ejb/ for local interfaces. Since you only have the local interfaces in your xml file, that is all the JNDI can find.
 
this llama doesn't want your drama, he just wants this tiny ad for his mama
Java file APIs (DOC, XLS, PDF, and many more)
https://products.aspose.com/total/java
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!