• 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 Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

question about ejb-ref and jndi .. HELP!!

 
Ranch Hand
Posts: 145
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
when deploying each EJB, we need to specify the JNDI name (for example, /ejb/HelloWorld), then EJB client can use that JNDI name to do the look up for the EJB home.
context.lookup("ejb/HelloWorld");
so why is ejb-ref necessary for war and ejb jar file? Can we just use the JNDI name to the do lookup in EJB or JSP, etc.. or we will have to use ejb-ref-name?
what would be the difference between using ejb-ref-name and using ejb jndi name for lookup?
also, i saw code that use prefix the lookup name with java:/comp/env, some don't.. why? what should be the standard?
Thanks in advance.
 
Ernest Lee
Ranch Hand
Posts: 145
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
any one can help?
 
Ranch Hand
Posts: 8945
Firefox Browser Spring Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Please download the ejb spec. It explains the meaning of various tags and how they are used.
It would be better if you post these types of queries to J2EE section. You will receive a quick response there.
 
reply
    Bookmark Topic Watch Topic
  • New Topic