• Post Reply Bookmark Topic Watch Topic
  • New Topic

RMI bypassing Naming.lookup()  RSS feed

 
Pieter Laeremans
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,
Is it possible to bypass Naming.lookup(...)
For example when I create a UnicastRemoteObject a can bind it to a chosen Port.
Is it possible to write a client that fetches a reference to that object without using Naming.lookup() when that client knows there will be an object listening add a given port on a given host.
thanks in advance,
Pieter
 
Cindy Glass
"The Hood"
Sheriff
Posts: 8521
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Moving to the RMI forum (Distributed Computing).
 
Michael Ernest
High Plains Drifter
Sheriff
Posts: 7292
Netbeans IDE VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I don't believe there's a facility for downloading a stub directly from the RMI service, and I believe (translation: too busy to look it up myself) there's a reason behind it. But you can certainly contact the service without using the registry directly if you have the stub you need.
 
Pieter Laeremans
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Originally posted by Michael Ernest:
But you can certainly contact the service without using the registry directly if you have the stub you need.

Nice, that 's exactly what I need. Do you also now how that can be done ?
Thanks in advance,
Pieter
 
William Zhou
Greenhorn
Posts: 4
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Do you have the Impl class?
if yes, just
Interface myStaff=new Impl();
myStaft.business();
just like this..
with stub, I have no idea how to use it, I think it's for RMI only,
 
Michael Ernest
High Plains Drifter
Sheriff
Posts: 7292
Netbeans IDE VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I was poking around Esmond Pitt's book a bit last night and found some stuff on point.
Either he is claiming that your service must be activatable (as opposed to merely unicast) or I am reading him wrong. But he walks through an activatable solution in chapter 10.
It's not trivial, and I won't attempt to reproduce here -- as if I could. I've got a head cold and I'm knee-deep in a Solaris kernel class right now, and can't quite think RMI at the moment.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!