Win a copy of Cross-Platform Desktop Applications: Using Node, Electron, and NW.js this week in the JavaScript forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

Accessing beans remotely  RSS feed

 
vijaya raj
Greenhorn
Posts: 7
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Dear All,
I have created and deployed a stand alone EJB module. Now i want to contact this bean from a client; say a servlet deployed in a different machine in the network. What are the necessary steps i need to do? I know the JNDI name of my EJB module (which i noted from the server log). But no idea as how to use it in the client. Can someone point me in the right direction? A proper resource in the net will also do. I know that injection or lookup is needed for this. I have performed fair bit of googling.. but no real solution i could find.

Thanks for your valuable time.
 
Kumar Raja
Ranch Hand
Posts: 548
2
Hibernate Java Spring
  • Likes 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
If you have setup the JNDI properties properly in your servlet and you have the necessary libraries (vendor specific and stubs), then getting the reference of the bean is same as what you do with a local client. Location transparency is a key feature.


In this forum, there is a similar thread, which you should look into. How to access EJB residing in a different container ?
 
vijaya raj
Greenhorn
Posts: 7
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Kumar Raja wrote:If you have setup the JNDI properties properly in your servlet and you have the necessary libraries (vendor specific and stubs), then getting the reference of the bean is same as what you do with a local client. Location transparency is a key feature.


Thanks a lot dear Kumar. I would definitely work on the lines. . Would update the results.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!