File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Websphere and the fly likes JNDI for local and remote interfaces: which works? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of EJB 3 in Action this week in the EJB and other Java EE Technologies forum!
JavaRanch » Java Forums » Products » Websphere
Bookmark "JNDI for local and remote interfaces: which works?" Watch "JNDI for local and remote interfaces: which works?" New topic
Author

JNDI for local and remote interfaces: which works?

Leonard Solomyak
Greenhorn

Joined: Feb 12, 2003
Posts: 8
HI,
I was trying to use Local interfaces with WebSphere 5, specifically with WADS where
I do all development.
To generate entity beans I use bottom-up approach. WASD generated Local interfaces
by default, with the associated JNDI names.
I can use Universal Client to access beans' methods via the Local interfaces but the
problem occures when I put the LOOKUP implementation code into the bean.
In my case a session bean creates an entity bean inside one container. Apparently
JNDI refused to work: NamingException was thrown, saying that the specified in the lookup
JNDI name not found.
I tryed different values for the JNDI name, which I can see in the descriptors but all unsuccessfully.
The JNDI name got resolved only when I added remote interfaces to the entity bean. WSAD by default
readdressed JNDI name in from local to the remote home interface.
I am asking
1. How can I use local interfaces via JNDI service in WSAD and WAS 5 ?
2. How can I use JNDI service for remote and local interfaces for the same bean ?
Regards
Leonard
Liz Lee
Greenhorn

Joined: Feb 23, 2003
Posts: 6
I have the same problem. Have you had any solution?
David O'Meara
Rancher

Joined: Mar 06, 2001
Posts: 13459

Dagnabit, I know the solution to this, but I don't have access to a WSAD or WAS environment to test it. I beleive you have to create a reference to the second bean in the descriptor for the first and then you will be able to reference it. Have a look at the reference tab in the deployment descriptor in WSAD and search around there.
Not a great solution, but I hope it helps.
Dave.
Andre Mermegas
Ranch Hand

Joined: Jun 20, 2001
Posts: 158
Here are two good links that will help:
http://www.webagesolutions.com/knowledgebase/waskb/waskb002/index.html
and this one has the rest of his howto's
http://www.webagesolutions.com/knowledgebase/waskb/


--=( Andre Mermegas )=--
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: JNDI for local and remote interfaces: which works?
 
Similar Threads
Remote EJB deployment needs a Local Home Interface too?
How to represent Local JNDI name in J2EE RI ?
Incomplete Deployment
Web Services for EJB Session Beans
Doubt in SessionBean contract(ejb 3.0 core)