Win a copy of Kotlin in Action this week in the Kotlin forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

EJB to EJB Communication on different Servers  RSS feed

 
Kanchan K Bulbule
Greenhorn
Posts: 20
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I have two application installed on two different servers . With the callerEjb on one server I want to invoke the CalleeEjb on other Server.

In the deployment descriptor of callerBean I have written these lines
--------------
<ejb-name>CallerBean</ejb-name>
<reference-descriptor>
<ejb-reference-description>
<ejb-ref-name>ejb/CalleeBeanReference</ejb-ref-name> <jndi-name>t3://172.24.99.42:7003/com.ejb.Callee.CalleeBean</jndi-name>
</ejb-reference-description>
</reference-descriptor>
-----------
My question to you is that When I do lookup and narrowdown the object I need Remote and Home interfaces of the callee bean , How I will resolve this references . Currently in development environment I have set my classpath to point to these classes as both the servers are running on same machine. But the real problem comes when caller and callee bean will deployed on different physical servers. Do I need to package the home and remote interfaces of calleebean into callerbean or there is some other approach ?

Awaiting your guidances .

Thanks In advance
Kanchan
 
Jeanne Boyarsky
author & internet detective
Sheriff
Posts: 37234
519
Eclipse IDE Java VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Originally posted by Kanchan K Bulbule:
Do I need to package the home and remote interfaces of calleebean into callerbean or there is some other approach ?

Yes. You package the EJB stubs and skeletons in a client jar.
 
Andreas Schaefer
Ranch Hand
Posts: 63
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I would suggest you are using the "corbaname" based JNDI names because they will work on every J2EE 1.3 certified app. server.

-Andy
 
Kanchan K Bulbule
Greenhorn
Posts: 20
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Jeanne & Andreas Thanks for the replies .


Andreas ,
Can you please give more illustration on "corbaname" based JNDI. If I do that , then No need to package the RI and HI in my client.

Many Thanks
Kanchan
 
Don't get me started about those stupid light bulbs.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!