Universal Messaging 9.12 | Developer Guide | Enterprise APIs | Enterprise Developer's Guide for Python | Enterprise Client Development | Environment Configuration
 
Environment Configuration
The Universal Messaging Python API uses a C++ wrapper library to expose functionality from Universal Messaging C++ in python. Therefore the Python API has the same dependencies as the C++ API, some of which do not ship with the product.
OpenSSL
The Universal Messaging C++ Client uses OpenSSL for secure connections. This product does not ship with Universal Messaging because some of the encryption used is restricted in certain countries.
OpenSSL comes pre-installed on most unix based systems. On Windows you can either download and build the source from www.openssl.org. Or you can download pre-compiled binaries. The required binaries for Windows are "Win32 OpenSSL v0.9.8r".
Microsoft Visual C++ 2008 Runtime Libraries
These libraries are requires to run any C++ application. Because the Universal Messaging Python Client uses Universal Messaging C++, these libraries are required. They are available to download from the Microsoft website.
Running the Sample Applications
Once you have installed Universal Messaging, the sample applications can be found in [Universal Messaging Install]/python/examples. To run the applications you first need to setup the required paths by running the Python Examples Command Prompt.
On Windows this can be found in: Start -> All Programs -> Universal Messaging_6.0.XXXXX -> Client -> [RealmName] -> Python Examples Command Prompt.
On Linux this can be found in: [Universal Messaging Install] / links / Client / [RealmName] / Python Examples Command Prompt.
Running this script will set up the environment and change to the directory containing the python samples so now to run the DataStreamListener sample you can simply enter:
c:\Python26\python.exe DataStreamListener.py
Running with a Different Python Version
The C++ wrapper which the Python API uses has to be compiled against a specific python version. In the Universal Messaging installer we currently release the wrapper compiled against Python 2.6 and 2.7. By default the sample applications will reference the library built against 2.6. To change this you can alter the file named NirvanaModule.py which is found in the same directory as the sample applications.
ImportError: DLL load failed
If any libraries cannot be found then you will get an error like this. Please ensure you have installed OpenSSL, Visual C++ 2008 runtime libraries and have run the Python Examples Command Prompt.

Copyright © 2013-2019 | Software AG, Darmstadt, Germany and/or Software AG USA, Inc., Reston, VA, USA, and/or its subsidiaries and/or its affiliates and/or their licensors.