aspose file tools*
The moose likes Distributed Java and the fly likes Design Issue in my RMI Application Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Spring in Action this week in the Spring forum!
JavaRanch » Java Forums » Java » Distributed Java
Bookmark "Design Issue in my RMI Application" Watch "Design Issue in my RMI Application" New topic
Author

Design Issue in my RMI Application

Rakesh Chaudhary
Ranch Hand

Joined: Feb 19, 2008
Posts: 120
I have a requirement to built a RMI-Application.

Requirement is:

A Client/Administrator will execute/start a particular executable on a Remote Machine.

Initially I thought RMI can help and started working on the same,

I thought that I need multiple RMI-Server side files on Remote Machine to open the service.

But doing this will reduced or rather completely Omit the Multiple client One Server Design.

Can somebody guide me how to start working on the same,if they have come across same task
or something like that.

Also is it feasible to use RMI in doing so.

Or do I have to use a simple core java application to start a exe and set it as a service on the Remote Machine.

Also,
I have to use a Browser so that the Client can request the start of the exe's to the Remote machine.

Waiting for your valuable Suggestion's


Acquire the unexpected.......
Preparing for SCJP 6
Jimmy Clark
Ranch Hand

Joined: Apr 16, 2008
Posts: 2187
You only need one RMI-based server application running on the same machine that has the EXE to run.

The machine that has the web server needs to be connected (via network) to the machine that has the RMI server and the EXE to run.

The code in the RMI-server should receive the remote call from a POJO and make a call on another POJO that does the execution of the executable.
Rakesh Chaudhary
Ranch Hand

Joined: Feb 19, 2008
Posts: 120
Hi James,

Thanks for the reply,

I think I am doing the same thing as you suggested!

I have kept the RMI-Server Specific files in the Remote machine/'s which are going to open the exe's on Client request.

In my App-Server I have kept my Client Specific files and Server_stub files and some view related stuff(html,jsp).

I have created a windows service for the RMI-Server Specific files on remote machine/'s using Java Wrapper.

I am using POJO as you mentioned

I will like to extend the scope of this message.Can you guide me in providing security policy for this RMI App.

Thanks...
Rakesh Chaudhary
Ranch Hand

Joined: Feb 19, 2008
Posts: 120
Hi James,

Thanks for the solution I think I have made it clear.About the kind of design I am using.

But I hunch that I have a problem with the design.

For Every Remote machine I have to copy the RMI -Server specific files to the Remote machine as well as the Java Wrapper files.

Can't we do it with some kind of a Flexible design.

Or with my kind of a requirement is it mandatory to use the Design discussed earlier.

Thanks
Rakesh

Rakesh Chaudhary
Ranch Hand

Joined: Feb 19, 2008
Posts: 120

Hi Ranchers,

Any Suggestions !!!

Thanks
K. Tsang
Bartender

Joined: Sep 13, 2007
Posts: 2505
    
    8

Not sure if the java.rmi.activation.Activatable class be any help. I haven't used it before but the idea is to dynamically open a session/connection to the RMI server. And this will require a SecurityManager.

Talking about java wrapper files, are these files for the client or server. If client yes you will have a problem deploying. If server, then there shouldn't be a problem. Remember Java 5 don't have to physically generate stubs/skeleton.


K. Tsang JavaRanch SCJP5 SCJD/OCM-JD OCPJP7 OCPWCD5 OCPBCD5
Rakesh Chaudhary
Ranch Hand

Joined: Feb 19, 2008
Posts: 120

Ok Pal !


I will try this !!!


Thanks!!!

Will be back
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
 
subject: Design Issue in my RMI Application