Forums Register Login

@EJB usage for remote EJB

+Pie Number of slices to send: Send
I have a question regarding the @EJB Usage

Is it possible to call inject an EJB using @EJB annotation , which is residing on different App Server than where Caller EJB is residing.

For example AppServer server1 has an EJB A
AppServer server2 has an EJB B

I want to inject B into EJB A using @EJB annotation (without using any look up logic) , where will I give the host name information for AppServer 2 ? I dont see any attribute in EJB which I can use to provide that.

is the only workaround to have Jndi.properties in class path of EJB A ?
+Pie Number of slices to send: Send
+Pie Number of slices to send: Send
Thanks Paul.

Based on your answer , I have posted some further queries on the same topic . Can you please have a look at it ?
No one can make you feel inferior without your consent - Eleanor Roosevelt. tiny ad:
a bit of art, as a gift, the permaculture playing cards
https://gardener-gift.com


reply
reply
This thread has been viewed 834 times.
Similar Threads
EJB 3 DI
@EJB giving NullPointerException
Access to entity manager in Session Bean
@EJB annotation Injection
EJBs in WebSphere
Building a Better World in your Backyard by Paul Wheaton and Shawn Klassen-Koop
More...

All times above are in ranch (not your local) time.
The current ranch time is
Mar 29, 2024 02:01:44.