aspose file tools*
The moose likes Distributed Java and the fly likes RMI - how the server knows what the client invoked? 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 » Java » Distributed Java
Bookmark "RMI - how the server knows what the client invoked?" Watch "RMI - how the server knows what the client invoked?" New topic
Author

RMI - how the server knows what the client invoked?

mahdi sa
Greenhorn

Joined: Jan 03, 2013
Posts: 1
I have a program in which there are these classes:
RMIServer,
RMIClient,
RMIImplementation,
RMIInterface

which are as follows:

RMIServer:


RMIClient:



RMIInterface:



RMIImplementation:


(This program is for a test purpose. The test is done in one machine.)

Well, the client makes calls to the remote object, sending some parameters.

I want the RMIServer to print out the summary of the calls made from the client to the remote object. What should I do to have access to such information?

I want the output to look like this:

RMI Server started
RMIImplementation instance created and ready to serve
RMI service called for :
tonny (30)
john (26)
Edward Harned
Ranch Hand

Joined: Sep 19, 2005
Posts: 291

How about just keeping a list of callers yourself.


Ed's latest article: A Java Parallel Calamity http://coopsoft.com/ar/Calamity2Article.html
Vijitha Kumara
Bartender

Joined: Mar 24, 2008
Posts: 3775

Your implementation just returns the values instead printing them?


SCJP 5 | SCWCD 5
[How to ask questions] [Twitter]
 
It is sorta covered in the JavaRanch Style Guide.
 
subject: RMI - how the server knows what the client invoked?
 
Similar Threads
RMI client server don't work on ipv6 machines
can't solve the problem on RMI client code
RMI pass by value or by reference ?
Exception: Connection refused to host
Deploying an RMI application