In ParaWeb, we are designing, building and experimenting with mechanisms for parallel computation within the Java framework. This framework, consisting of the Java programming system and the Java runtime system, may be extended in a variety of ways to achieve parallelism. The obvious approach is to extend both the Java programming system and the runtime system to provide a complete parallel programming and computing environment. However, it is possible to achieve parallelism in Java by extending the programming system (through a set of parallel classes) without modifying the Java runtime system. Further, since Java already provides some basic mechanisms for concurrency, including threads and synchronization, it is also possible to modify the Java runtime system to achieve parallelism without extending or modifying the Java programming environment.
The suitability of each of these approaches to parallelism in the Java framework depends on the nature of the target parallel computing environment. In ParaWeb, we are building two distinct sets of mechanisms based on the latter two approaches, the first called the Java Parallel Runtime System (JPRS), and the second called the Java Parallel Class Library (JPCL). Our decision to support these as two separate mechanisms for parallel computing is based upon the observation that parallel computing on the web will likely take two predominant forms:
A secondary distinction in the current implementation of these two approaches is that the former (the JPRS) supports a distributed shared memory framework while the latter (the JPCL) supports message passing (this distinction may disappear as the classes in the JPCL and those provided in future Java distributions both continue to evolve). Because Java provides a threads abstraction, executing standard thread-based programs across multiple platforms on the JPRS requires presenting these threads with the illusion of shared memory, so that from the perspective of the program, the underlying system is no different from the standard system in which all threads execute on the same machine. On the other hand, providing communication mechanisms between remote threads supported only by the JPCL class library (executing on the standard Java runtime system) is easiest to do using a message passing framework. In the following subsections, we first describe the implementation of the Java parallel class library, and the mechanisms for uploading applications or threads to remote servers for execution within this approach. We then describe the parallel runtime system approach.