• 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
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

RMI - Client Application

 
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
do u have any idea if i would like to create a server application invoke a client method in RMI?
can anybody show me some examples bcos i jus started programming using RMI.
Tanks in advance...
 
Ranch Hand
Posts: 118
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Your application will consist of two-RMI Servers and two-RMI clients.
its simple
as you do in a simple RMI client-server application
in this case
both client & server will extend UnicastRemoteObject
i.e both will implement some Remote methods hence both will act like RMI Servers for clients.
and both will become clients for each other by invoking Remote Methods on each other.
so both are clients as well as servers.
its like C is a client , B & A are a server
C --------------------->B---------------------->A

here B is Server for C and Client for A
in your case A is C itself.
so write 2 RMI server programs.
& implement client code in both of them.
 
Ranch Hand
Posts: 388
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
hi,
how about creating an RMI server and first do some kind of login with the client. in this login procedure you pass a reference to the client to the server. then there is no need for to servers, two registrys.
would this work ?
karl
 
dk
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
tanks guy for replying me...
 
Ranch Hand
Posts: 5040
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

"dk"
your name doesn't agree with the javaranch guidelines.
please take a moment and re-register after reviewing
the guidelines at http://www.javaranch.com/name.jsp
thanks for your cooperation.
- satya
 
reply
    Bookmark Topic Watch Topic
  • New Topic