Win a copy of Re-engineering Legacy Software this week in the Refactoring forum
or Docker in Action in the Agile forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Specifying jndi properties for using @EJB from a servlet

 
Sandhya Narayanan
Greenhorn
Posts: 7
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I have a servlet deployed in a JBoss server and it has to look up an EJB deployed in a remote WebLogic server using the @EJB annotation. Where do I pass the jndi properties such as JNDI server url and port? I put the jndi.properties file in the classpath, but it is not working.
Thanks in advance.

-Sandhya
[ April 24, 2007: Message edited by: Sandhya Narayanan ]
 
Rahul Bhattacharjee
Ranch Hand
Posts: 2308
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Creata a hashmap with the connection properties and pass it as parameter to the InitialContext.Refer the vedor documentation for more information.
 
Sandhya Narayanan
Greenhorn
Posts: 7
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I'm not using JNDI API, so there is no InitialContext. How do I specify the JNDI information when @EJB annotation is used.
Thanks

-Sandhya
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic