Java Remote Job Execution System
By Shanliang Jiang on Sep 19, 2008
We have published our paper in the Second Workshop on Engineering of Complex Distributed Systems (ECDS-2008) in March 2008, Barcelona, Spain
This paper describes a Remote Job Execution (RJE) System, developed on the JavaTM platform. The system is designed for developing distributed applications that are more efficient and more reliable than applications developed using the existing Remote Method Invocation (RMI) APIs.
The main functions of the RJE system are as follows:
Multiple remote method invocations can be grouped into a single job. This reduces the communication time and the risk of communication failure.
Even before a job has been executed in the server, the calls grouped in this job can take results from previous calls grouped in the same job and use them as their method input parameters. Each call is given a virtual result before the job is executed. These virtual results are then replaced on the client side by the real results after the job has been executed.
Remote Exception Handling
A client can specify code to catch and handle execution exceptions remotely on the server side.
Determination of Communication Failures
A client is notified explicitly if a direct communication failure between the client and the server occurs. This helps to avoid re-executing the job, as described in the next section.
Automatic Recovery from a Direct Communication Failure
When a client is informed of a communication failure, as presented in the previous section, the client can re-send a job after the communication is re-established, and the RJE server will simply send back the previous result if the job has already been executed and the communication failure occurred while the result was being sent. Otherwise, the server will execute the job if it had not already received the job before the failure.
Automatic Remote Calls
Before a remote job is sent to its server for waiting more remote calls, if the RJS detects that a local call needs to access one of the virtual results specified in the job, the RJS can automatically send the job. Users should set up a callback to handle exceptions if the remote execution of the job encounters a problem.
Asynchronous Remote Calls
The RJE system also allows a user to execute a job manually, rather than automatically.
Benefits of the RJE System
Increased flexibility and extensibility: Flexible and extensible distributed systems are developed by providing basic services on the server side and allowing a client to select and combine these basic services to perform a specific job. The RMI API requires each service to be called in a separate remote call. The RJE system's virtual result solution solves this problem. By only providing basic services, the RJE system makes distributed applications simpler and easier to develop and maintain.
Increased scalability: Instead of connecting to the server as soon as the first request is sent, the RJE system allows users wait until the last request is ready before connecting to the server. This reduces communication times, and leaves the server free to serve other clients.
More reliable remote transactions: Avoids problems caused by communication failures during remote transactions.
Increased efficiency: The RJE system makes one communication instead of many.
Increased reliability: Fewer communications mean a lower chance of failure.
A prototype has been implemented to validate this Remote Job Execution System.