Server-side Python mode
Enterprise only
Last updated
Enterprise only
Last updated
In this case the Pyhon Interpreter environment is installed on the server side where the Xplain Object Analytics Engine is running. This setup enables user to run python code to access Xplain API without installing Python environment and python packages locally.
Python environment and installed packages can be managed by system admin
OS level processing possible, like file /DB access on server
faster than Web Assembly
Python is a very powerful language, it can cause serious impact by malicious or bad implementation.
the right version of python and installed python packages must fit tog, an unintentional upgrade might cause compatibility problems which could prohibit the code running .
Python 3.8+ and pip
is installed on the server where Xplain Object Analytics Backend is running
required packages like xplain is installed on server via pip .
Xplain Object Analytics engine ist started with application property xplain.serverside.python=true
To start Object Analytics Engin with server side python enablement, you could
add the following entry into the external application.properties file
another option is start the application with addtional JVW parameter
Only users with admin role can implement the python code and specify if the code should be performed on server side. Without the explicit serverside checkbox setting, the python code will performed by default in the secure Web Assembly environment
open Python IDE as admin user
add source code or chose the existing python source code,
select the checkbox "serverside", this checkbox is only visible if user has admin role and backend is started with application property xplain.serverside.python=true (see Prerequisites above)
python file list : list of the python files
code area: the python code can be edited and viewed there
The admins can write comments inside python comment block such as '''description in the comment block'''
will be displayed to the users, who do not have the admin right to read the code in the code area.
output area: the output is there
run icon: run the python code
pip install area: install area are automatically filled for the user. Install the packages by entering the package names divided using a "," for example: xplain, panda, streamlit
options: options are set automatically for the user. Multiple options can be set in the input field "Options", separated by spaces. Options syntax: --<option_name>=option_value
collapse icon: collapse the IDE
If your code requires additional python packages, they can be installed on server side on demand, just add the name of packages in the input field "pip install" , multiple package names can be separated with commas.
The required package information will be persisted together with source code.
Python code can be run with multiple additional options, the option values can be consumed in the python code. Options can be specified in the Options field of Python IDE. Source code can be saved with option values.
We could provide multiple options in the input field "Options", separated by spaces.
Options Syntax: --<option_name>=option_value