April 28, 2001
I am pleased to announce the first beta release of JPE, the Java-Python Extension.
JPE is at once:
- A Python module (named 'java') providing access to all Java
services from Python
- A Java package (named 'python') providing access to all Python
services from Java
JPE relies on the following computing paradigm: One Python VM (PyInterp pointer) an one Java VM (JavaVM pointer) are in the same process. The virtual machines act as common process resources, shared by the threads.
Each virtual machine has its own thread-specific execution environment (PyThreadState pointer in Python, JNIEnv pointer in Java). Each thread is attached to zero or one thread environment from each virtual machine; each thread environment is attached to one thread.
The paradigm is generic. I have not done much research in the literature in this regard, but I am not aware of a similar pattern. I'll baptize it the "symmetrical virtual machine" pattern :))
This is different from Jython, for instance, in the sense that Jython is an emulation of the Python VM, written in Java, and entirely running within the Java VM.
The advantage of the symmetrical virtual machine approach over the emulation is that we get to work with the actual, full-featured Python VM, rather than with an emulation on top of another virtual machine, emulation which necesseraly suffers from limitations inherited from the emulating environment.
Object semantics are the same in both environments.
Frederic Giacometti email@example.com