OS4X client-side plugin philosophy

From OS4X
Jump to navigation Jump to search

Abstract

With the local processing ability of OS4X Webaccess, you can do the following:

  • dynamically retrieve locally available environments
  • list a structured hierarchy of directory with aliases within a selected environment, sourcing them locally in the context of the logged in user in the client machine
  • list content of the selected directory, offerung filtering and file type selection
  • export selected (single or multiple) files with a configured program or script
  • grab the created files, upload it to an outgoing send job, keeping the log output for every file for possibly later processing

From end-user's view, the selection works as follows:

  1. Select environment (last selected environment is saved and pre-selected in future calls)
  2. Search and select DLName
  3. Search and select file(s) for export
  4. Start export process

In case of success, the output file(s) will be added to the send job, in case of error an error message shows the output of the process.

All scripts/programs for every situation can be located on a defined web position (http(s) URL) or available at a local or remote path.

Requirements

For this functionality, you need:

  • OS4X Webaccess Webbrowser plugin version 1.4.0 and up
  • Configured environemnt for local processing
    • All commands must be configured for the used environment in the used operating system

Supported operating systems:

  • Windows
  • Linux
  • Mac OS X
  • generic "other" operating systems, addressed via "unsupported operating system"

Executability of the configured programs/scripts must be given.

Configuration

Enable the configuration option "Enable local client process execution" in "Configuration" -> "OS4X Enterprise", section "OS4X Webaccess":

Enable local client process execution.png

When enabled, a tabbed panel offers the configuration of the script/program location for every platform. In case that the platform cannot be selected correctly, the fallback "Other" will be used.

Supported script locations

There are two modes for script locations:

  • web locations: starting with "http", these locations will trigger a special logic by downloading them to the client in case of execution.
  • local location: all configurations which don't start with "http" will start the configured script at the configured position. These must be locally available paths.

In case of a web location, the client checks if the location is approved by the user. For non-approved locations, the user will be prompted for the first time of access to the URL if he allows to download and execute the program/script from the given position.

Special files

In Windows, script types with the file extension ".vbs" will lead to an invocation of the Visual Basic interpreter in command line mode, which suppresses the opening of command shell windows ("cmd.exe") during execution.

Script / Programs

There exist three configuration options for the following cases:

  • Environment listing script: tool to resolve environments usable by the client
  • DLName listing script: tool to deliver a list of directories, given in a special format also known as "DLName"
  • Export script: tool to export selected files in the used environment

Environment listing script

The environment list script will be executed dynamically on the client to list all available enviromment:

StreamingSmoke envList.png

Parameters:

  • none

Expected returncode:

  • 0: in case of success
  • non 0: in case of errors

Output (written to standard output ["stdout"]) must have the following line syntax:

<internal ID>|<Descriptor for GUI>

Lines may be seperated by linefeed or carriage-return/linefeed. The internal ID will be re-used later.

Example output:

dc_r19|Daimler AG
pag|Porsche AG
bmw|BMW AG

Logging

Local process execution and file handling will be logged in the plugin's logger, which writes its information to a defined location:

  • Windows:
%USERPROFILE%\AppData\LocalLow\OS4X\logs\StreamingSmokePlugin.log
  • Mac OS X:
$HOME/Library/Application Support/OS4X/logs/StreamingSmokePlugin.log