9
Python Modules
OSE includes a number of Python modules. The main module is a wrapper around functionality pro-
vided in the OSE C++ class library. Those parts of the OSE C++ class library for which a Python wrap-
per are provided are the logging system, the real time events system, the service agent framework for
creating distributed applications and the HTTP servlet framework.
Additional modules provide access to the OSE service agent framework using an RPC over HTTP pro-
tocol called NET-RPC as well as the XML-RPC and SOAP protocol. Note that the XML-RPC and
SOAP protocols come with restrictions deriving from problems in the respective protocols and the
NET-RPC protocol provides the best integration.
Because interfaces are provided for the OSE service agent framework in both C++ and Python, an ap-
plication may be spread across multiple processes and consist of processes written using either C++ or
Python code. Using shared libraries and dynamic loading, C or C++ code could also be loaded into
Python to perform some functions if desired.
Overall, the Python wrappers provide an interface to the functionality of the OSE C++ class library
which is easier to use than if the C++ class library were used directly. This makes the Python wrappers
ideal for building up the overall structure of a distributed system, with C++ code being used only when
necessary.