• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Paul Clapham
  • Ron McLeod
  • Jeanne Boyarsky
  • Tim Cooke
Sheriffs:
  • Liutauras Vilda
  • paul wheaton
  • Henry Wong
Saloon Keepers:
  • Tim Moores
  • Tim Holloway
  • Stephan van Hulst
  • Carey Brown
  • Frits Walraven
Bartenders:
  • Piet Souris
  • Himai Minh

JNDI Bindings for Remote Objects?

 
Ranch Hand
Posts: 74
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi,

I am studying RMI-IIOP and JNDI as a prerequisite foundation for EJB.

I am trying to figure out how to bind a Remote Object (not an EJB)to the JNDI tree of the J2EE application server. I would then like to call this remote object from the client running on another machine. Client can be desktop or servlet etc..How do I bind a Remote Object to the J2EE Application Server JNDI tree and what java:comp/env/ would I use? Is this possible? Maybe this makes no sense, but I am not sure. Can this be done in the deployment descriptor? Most of my consufusion comes from my EJB's being binded to JNDI automatically by my IDE(Netbeans) build and deploy tools so I have no idea where to do this manually for EJB or any object i may wish to bind.

Thanks...
 
author & internet detective
Posts: 41086
848
Eclipse IDE VI Editor Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Stu,
Many objects, such as EJBs and datasources, are bound automatically by the app server. For other objects, you can bind them programmatically using initialContext.bind().

You get the initial context the same way you do when finding an EJB.
 
Stu Higgs
Ranch Hand
Posts: 74
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi Jeanne,

Thanks! I was just playing around with various methods from Context Interface last night...sometimes it is tough to see the tree in the forest.

So I am supposing now that once binded, the Remote Object will be accessible via use of client stub and JNDI lookup just like an EJB would be accessible etc...? This is all very new territory for me, sorry if it is a dumb question. Will post back with results...

Thanks again...
 
It's just like a fortune cookie, but instead of a cookie, it's pie. And we'll call it ... tiny ad:
Free, earth friendly heat - from the CodeRanch trailboss
https://www.kickstarter.com/projects/paulwheaton/free-heat
reply
    Bookmark Topic Watch Topic
  • New Topic