Qorus Integration Engine® Enterprise Edition 7.0.0_prod
|
defines the Qorus System API methods More...
Functions | |
hash | omq.system.help () |
gives a hash of API information, where each key is a Qorus system API method | |
hash | omq.system.get-option-info () |
returns a hash of all global Qorus system options and their current values | |
hash | omq.system.get-status () |
returns a hash giving information about system status | |
string | omq.system.set-option (hash params) |
sets one or more system options | |
string | omq.system.flush-options (*hash params) |
write the server's options to the option file on the server's filesystem | |
string | omq.system.shutdown () |
initiates the system shutdown process | |
string | omq.system.shutdown-wait () |
shuts down the system; returns when the system shutdown process is complete | |
hash | omq.system.submit-data.[workflow].[version] (hash params, string status=OMQ::StatReady) |
create workflow order (workflow order data instance) | |
hash | omq.system.create-order (hash params) |
create workflow order method (workflow order data instance) | |
any | omq.system.get-workflow-info (*softstring id) |
returns workflow information for the execution id passed, or for all workflows if no execution id is passed | |
list | omq.system.show-workflow-cache () |
returns a list of the workflows currently cached | |
hash | omq.system.start-workflow (hash params) |
Starts a workflow execution instance with the designated name and version. | |
hash | omq.system.start-workflows (hash params) |
Starts one or more workflow execution instances with the designated name and version. | |
hash | omq.system.exec-synchronous-workflow (hash params) |
Executes a workflow in synchronous mode and returns the final status of the order after processing. | |
hash | omq.system.exec-synchronous-existing (hash params) |
Executes a workflow in synchronous mode against an already-existing order in the database with status OMQ::StatReady. | |
string | omq.system.stop-all-workflows () |
stops all running workflows | |
string | omq.system.stop-workflow-instance (softint id) |
stops the given workflow execution instance given its ID | |
string | omq.system.stop-workflow (string name, *string version) |
stops all instances of the given workflow | |
string | omq.system.set-workflow-option (softint id, hash hash) |
Sets the options given in the hash on the running workflow identified by the execution ID passed. | |
any | omq.system.get-workflow-option (softint id) |
Returns options set on the running workflow identified by the execution ID passed. | |
hash | omq.system.get-workflow-options (softint id) |
Returns all options set on the running workflow identified by the execution ID passed. | |
string | omq.system.reset-workflow (string name, *string version) |
Deletes the configuration for the specified workflow from the cache. | |
string | omq.system.reset-all-workflows () |
Deletes the configuration for all workflows from the workflow configuration cache. | |
string | omq.system.replace-dynamic-data (softstring wfiid, *hash data) |
Replaces the dynamic data for the given workflow order data instance. | |
string | omq.system.replace-static-data (softstring wfiid, *hash data) |
Replaces the static data for the given workflow order data instance. | |
hash | omq.system.retry-workflow-instance (softstring wfiid) |
retries the given workflow order instance | |
hash | omq.system.retry-workflow-instances (softlist l) |
retries the given workflow order instances | |
hash | omq.system.cancel-workflow-instance (softint wfiid, any cancel) |
cancels the given workflow order data instance or resets a canceled order to the original status | |
hash | omq.system.cancel-workflow-instances (hash ih) |
cancels the given workflow order data instance or resets a canceled order to the original status | |
string | omq.system.reschedule-order (softint wfiid, *softdate scheduled) |
sets or removes the scheduled date for a workflow order data instance | |
hash | omq.system.reschedule-orders (hash ih) |
sets or removes the scheduled date for a list of workflow order data instances | |
string | omq.system.reprioritize-order (softint wfiid, softint priority) |
changes the priority for an existing workflow order data instance | |
hash | omq.system.reprioritize-orders (hash ih) |
changes the priority for a list of workflow order data instances | |
hash | omq.system.block-workflow-instance (softint wfiid, any block) |
block the given workflow order data instance or resets a blocked order to the original status | |
hash | omq.system.block-workflow-instances (hash ih) |
block or restore the list of workflow order data instances | |
hash | omq.system.set-workflow-instance-error (softint wfiid) |
Changes a workflow order data instance's status to OMQ::StatError, as long as the starting status is OMQ::StatRetry, OMQ::StatCanceled, OMQ::StatBlocked, or OMQ::StatAsyncWaiting. | |
hash | omq.system.set-workflow-instances-error (softlist l) |
Changes a list of workflow order data instances' statuses to OMQ::StatError, as long as the starting status is OMQ::StatRetry, OMQ::StatCanceled, OMQ::StatBlocked, or OMQ::StatAsyncWaiting. | |
nothing | omq.system.skip-step (softstring wfiid, softstring stepid, softint ind=0) |
Skips execution of a step in a workflow. | |
nothing | omq.system.skip-step-without-retry (softint wfiid, softint stepid, softint ind=0) |
Skips execution of a step in a workflow without initiating an immediate retry. | |
nothing | omq.system.set-order-info (softstring wfiid, hash h) |
Sets or clears additional info for the given workflow order data instance. | |
hash | omq.system.get-order-info (softstring wfiid) |
Gets additional info for the given workflow order data instance. | |
nothing | omq.system.set-order-note (softstring wfiid, string notestr) |
Add new Order Instance Notes. | |
list | omq.system.order-notes (softstring wfiid, *softint count) |
Gets Order Instance Notes. | |
nothing | omq.system.post-event (softstring eventtype, softstring eventkey) |
Posts a workflow synchronization event with the event type name and key value. | |
hash | omq.system.runtime-properties () |
Returns a hash with runtime properties specified with -D in the Qorus system startup command-line. | |
any | omq.system.list-all-services (*date date) |
returns a list of all services currently loaded or a constant string if the services have not been updated since the optional date argument | |
list | omq.system.list-services () |
returns a list of all system services currently loaded | |
list | omq.system.reset-all-services () |
unloads all services currently loaded in memory and reloads them from the database | |
list | omq.system.reset-services () |
unloads all system services currently loaded in memory and reloads them from the database | |
bool | omq.system.reset-service (string name, bool load=False) |
unloads a single system service and reloads it from the database | |
any | omq.system.service.[servicename].[method] () |
calls a system service method and returns the result | |
string | omq.system.delete-service (string name, *string version) |
Unloads the named system service from the system. | |
string | omq.system.set-service-autostart (string name, softstring stat) |
Sets the autostart status of the given system service. | |
bool | omq.system.get-service-autostart (string name) |
returns the autostart status of the given system service | |
string | omq.system.set-service-options (hash< auto > c, string name, hash hash) |
Sets the options given in the hash on the given service. | |
any | omq.system.get-service-options (string name) |
Returns options set on the given system service; the service must be already loaded or an exception is raised. | |
list | omq.user.list-services () |
returns a list of all user services currently loaded | |
list | omq.user.reset-services () |
unloads all user services currently loaded in memory and reloads those services from the database | |
bool | omq.user.reset-service (string name, bool load=False) |
unloads a single user service and reloads it from the database | |
any | omq.user.service.[servicename].[method] () |
calls a user service method and returns the result | |
string | omq.user.delete-service (string name, *string version) |
Unloads the named user service from the system. | |
string | omq.user.set-service-autostart (string name, softstring stat) |
Sets the autostart status of the given user service. | |
bool | omq.user.get-service-autostart (string name) |
returns the autostart status of the given user service | |
string | omq.user.set-service-options (string name, hash hash) |
Sets the options given in the hash on the given service. | |
any | omq.user.get-service-options (string name) |
Returns options set on the given unsert service; the service must be already loaded or an exception is raised. | |
string | omq.system.reload-rbac () |
Reloads the all RBAC information (users, permissions, roles, groups) from the system schema. | |
string | omq.system.add-user (string user, string pass, string name, *softlist roles) |
Adds a user to the system; also creates the user in the database. | |
string | omq.system.update-user (string user, hash hash) |
Modifies an existing user in the database and in the RBAC cache. | |
string | omq.system.passwd (softstring oldpwd, softstring newpwd) |
Changes the password for the current user. | |
string | omq.system.delete-user (string user) |
Deletes an existing user from the database and the RBAC cache. | |
string | omq.system.add-role (string name, string desc, *softlist permissions, softlist groups=list("DEFAULT")) |
Permanently add a role to the system. | |
string | omq.system.clone-role (string source_role, string new_role, string desc) |
Permanently add a role to the system by cloning an existing role's permissions and groups. | |
string | omq.system.update-role (string name, hash h) |
Modifies an existing role in the database and in the RBAC cache. | |
string | omq.system.delete-role (string role) |
Deletes an existing role from the database and the RBAC cache. | |
string | omq.system.add-permission (string permission, string desc) |
Permanently add a user permission to the system. | |
string | omq.system.update-permission (string permission, string desc) |
Modifies the description for an existing user permission in the database and in the RBAC cache. | |
string | omq.system.delete-permission (string permission) |
Deletes an existing user permission from the database and the RBAC cache. | |
hash | omq.system.get-all-users () |
Returns a hash with all information (except passwords) on all Qorus users in the RBAC cache. | |
hash | omq.system.get-all-roles () |
Returns a hash with information on all roles in the RBAC cache. | |
hash | omq.system.get-all-permissions () |
returns a hash of information about all permissions in the RBAC cache | |
string | omq.system.update-current-user (hash hash) |
Modifies the current user in the database and in the RBAC cache. | |
hash | omq.system.get-current-user-info () |
Returns a hash with all information (except passwords) on for the current user from the RBAC cache. | |
hash | omq.system.get-user-info (*string user) |
Returns a hash with all information (except passwords) on for the given or current user from the RBAC cache. | |
hash | omq.system.get-role-info (string role) |
Returns a hash with information on all roles in the RBAC cache. | |
string | omq.system.rotate-log-files () |
Rotates all system log files. | |
string | omq.system.ping () |
Returns a constant "OK" string. | |
string | omq.system.authenticate () |
returns a constant string "admin" | |
hash< auto > | omq.system.wait-for-events (hash< auto > cx, softint min_id, *timeout timeout_ms) |
Returns a hash giving the list of the new events and the last event ID generated by the system. | |
int | omq.system.wait-for-events-or () |
returns the last system event ID generated | |
hash< auto > | omq.system.get-last-events (hash< auto > cx, softint count) |
returns the last system events | |
hash | omq.system.get-last-events-or () |
returns a hash of listener information for the HTTP server | |
nothing | omq.system.stop-listener (softstring name) |
stops the listener from the bind address | |
nothing | omq.system.stop-listener-id (softint id) |
stops the listener from listener ID | |
list | omq.system.start-listeners (softstring bind, *string cert_file, *string key_file) |
starts a new HTTP listener; listeners will be started on all possible bind addresses in case more than one interface is resolved from the bind address given | |
nothing | omq.system.group.set-status (string name, softstring enabled) |
Enables or disables an interface group. | |
int | omq.system.group.create (string name, string desc, softlist svcids, softlist wfids, softstring enabled=True, softlist jobids=(), softlist mapperids=(), softlist vmapids=()) |
Creates an interface group. | |
string | omq.system.group.update (string group, hash hash) |
Modifies an existing interface group in the database and in the RBAC cache. | |
nothing | omq.system.group.delete (string name) |
Permanently deletes a workflow/service/job group. | |
nothing | omq.system.group.add-workflow (string name, string wname, *string ver) |
Adds a workflow to a workflow/service/job group from the workflow's name and optional version. | |
nothing | omq.system.group.add-service (string name, string sname, *string ver) |
Adds a service to a workflow/service/job group from the service's name and optional version. | |
nothing | omq.system.group.add-job (string name, string jname) |
Adds a job to a workflow/service/job group from the job's name. | |
nothing | omq.system.group.add-workflow-id (string name, softlist ids) |
Adds one or more workflows to a workflow/service/job group from the workflowids. | |
nothing | omq.system.group.add-service-id (string name, softlist ids) |
Adds one or more services to a workflow/service/job group from the serviceids. | |
nothing | omq.system.group.add-job-id (string name, softlist ids) |
Adds one or more jobs to a workflow/service/job group from the jobids. | |
nothing | omq.system.group.delete-workflow (string name, string wname, *string ver) |
Permanently deletes a workflow from a workflow/service/job group using the workflow's name and optional version. | |
nothing | omq.system.group.delete-service (string name, string sname, *string ver) |
Permanently deletes a service from a workflow/service/job group using the service's name and optional version. | |
nothing | omq.system.group.delete-job (string name, string jname) |
Permanently deletes a job from an interface group using the job's name. | |
nothing | omq.system.group.delete-workflow-id (string name, softlist ids) |
Permanently deletes one or more workflows from a workflow/service/job group using workflow ids. | |
nothing | omq.system.group.delete-service-id (string name, softlist ids) |
Permanently deletes one or more services to a workflow/service/job group from the service ids. | |
nothing | omq.system.group.delete-job-id (string name, softlist ids) |
Permanently deletes one or more jobs from an interface group using job ids. | |
hash | omq.system.group.info (*string name) |
Returns information for a group or all groups if no group name argument is passed. | |
hash | omq.system.job.info (*string name) |
Returns information on all jobs visible to the calling user or a specific job depending on the argument (or lack thereof) | |
hash | omq.system.job.info-id (softint id) |
Returns information on a specific job by the jobid. | |
hash | omq.system.job.list-active () |
Returns information on all active jobs visible to the calling user. | |
hash | omq.system.job.run (string name) |
Runs the given job immediately (regardless of the trigger time) from the job name even if the job is expired, inactive, or dedicated to another instance. | |
hash | omq.system.job.run-id (softint id) |
Runs the given job immediately (regardless of the trigger time) from the jobid even if the job is expired, inactive, or dedicated to another instance. | |
string | omq.system.job.set-active (string name, *softstring active) |
Updates the "active" status of a job from the job name; if any errors occur an exception is thrown. | |
string | omq.system.job.set-active-id (softint id, *softstring active) |
Updates the "active" status of a job from the job id; if any errors occur an exception is thrown. | |
string | omq.system.job.set-expiry (string name, *date expiry) |
Updates the expiry date of a job from the job name; if any errors occur an exception is thrown. | |
string | omq.system.job.set-expiry-id (softint id, *date expiry) |
Updates the expiry date of a job from the job id; if any errors occur an exception is thrown. | |
string | omq.system.job.schedule (string name, *string schedule, *softint recurring) |
Updates a job's schedule from the job name; if any errors occur an exception is thrown. | |
string | omq.system.job.schedule-id (softint id, *string schedule, *softint recurring) |
Updates a job's schedule from the jobid; if any errors occur an exception is thrown. | |
string | omq.system.job.reset (string name) |
Reloads a job from the database from its name; if it's currently running it is stopped and reloaded. | |
string | omq.system.job.reset-id (softint id) |
Reloads a job from the database from its id; if it's currently running it is stopped and reloaded. | |
string | omq.system.job.reset-all () |
Reloads all jobs from the database; all currently-running jobs are stopped and reloaded. | |
string | omq.system.job.set-options (string name, hash hash) |
Sets the options given in the hash on the given job; the job must be active or an exception is raised. | |
any | omq.system.job.get-options (string name) |
Returns options set on the given job; the job must be active or an exception is raised. | |
string | omq.system.job.set-options-id (softint id, hash hash) |
Sets the options given in the hash on the given job; the job must be active or an exception is raised. | |
any | omq.system.job.get-options-id (softint id) |
Returns options set on the given job; the job must be active or an exception is raised. | |
hash | omq.system.schema.refresh-snapshots () |
Refresh helper database snapshots. | |
*hash | omq.system.get-global-errors (*softlist l) |
returns global error definition information | |
*hash | omq.system.get-workflow-errors (softint wfid, *softlist l) |
returns workflow-specific error definition information | |
hash | omq.system.get-all-errors () |
returns all global and workflow-specific error definitions | |
*hash | omq.system.search-errors (softlist l) |
searches for error definitions at all levels for the given error(s) | |
string | omq.system.update-global-error (hash eh) |
creates or updates a global error | |
string | omq.system.update-workflow-error (softint wfid, hash eh, *bool forceworkflow) |
creates or updates a workflow-specific error definition | |
bool | omq.system.delete-workflow-error (softint wfid, string err) |
deletes a workflow-specific error so that the global error definition will be used instead | |
int | omq.system.delete-error (string err) |
deletes all definitions of an error from all workflows and at the global level | |
hash | omq.system.reload-errors () |
reloads all error definitions from the DB | |
any | omq.system.debug.echo () |
echos any argument passed | |
hash | omq.system.debug.get-thread-stacks () |
returns information about the status of running threads | |
string | omq.system.debug.get-data-cache () |
returns detailed technical data about the workflow order data cache for debugging purposes | |
string | omq.system.debug.get-data-cache-summary () |
returns summarized technical data about the workflow order data cache for debugging purposes | |
string | omq.system.debug.get-segment-cache () |
returns detailed technical data about the segment event cache for debugging purposes | |
string | omq.system.debug.get-segment-summary () |
returns summarized technical data about the segment event cache for debugging purposes | |
string | omq.system.debug.get-workflow-queue-status () |
returns a description of the workflow queue thread pool | |
hash | omq.system.debug.get-mon () |
returns a description of internal monitoring data structures | |
string | omq.system.debug.dump-caches () |
returns technical data about the segment cache for debugging purposes | |
string | omq.system.debug.dump-system-pool () |
returns a description of the status of the system DatasourcePool | |
string | omq.system.debug.dump-exec-cache () |
returns technical data about the execution cache for debugging purposes | |
string | omq.system.debug.get-workflow-entry (softint wfiid) |
returns technical cache data about an internal workflow entry for debugging purposes | |
nothing | omq.system.debug.workflow-entry (softint wfiid, *string flag) |
sets the debug flag on a cached workflow entry for debugging purposes | |
nothing | omq.system.debug.system (softstring flag) |
turns system debugging on or off | |
defines the Qorus System API methods
string omq.system.add-permission | ( | string | permission, |
string | desc | ||
) |
Permanently add a user permission to the system.
Also creates the user permission in the database
permission | the name of the permission to add |
desc | the description of the permission |
RBAC-ADD-PERMISSION-ERROR | invalid permission (permission already exists) |
AUTHORIZATION-ERROR | this exception is thrown when Role Based Access Control is enabled and the user does not have sufficient privileges for the operation |
string omq.system.add-role | ( | string | name, |
string | desc, | ||
*softlist | permissions, | ||
softlist | groups = list("DEFAULT") |
||
) |
Permanently add a role to the system.
Also creates the role in the database
name | the name of the role to add |
desc | the description of the role |
permissions | a single permission or a list of permissions to add to the role; note that users must have at least the OMQ::QR_LOGIN permission to connect to the server |
groups | a single group or a list of groups to add to the role |
RBAC-ADD-ROLE-ERROR | invalid role (already exists), invalid permission, invalid group |
AUTHORIZATION-ERROR | this exception is thrown when Role Based Access Control is enabled and the user does not have sufficient privileges for the operation |
string omq.system.add-user | ( | string | user, |
string | pass, | ||
string | name, | ||
*softlist | roles | ||
) |
Adds a user to the system; also creates the user in the database.
user | the username to add |
pass | the password for the user |
name | the name of the user |
roles | a single role or a list of roles to add to the user; note that the user must have at least the OMQ::QR_LOGIN permission to connect to the server |
RBAC-ADD-USER-ERROR | invalid user, invalid role, invalid group |
AUTHORIZATION-ERROR | this exception is thrown when Role Based Access Control is enabled and the user does not have sufficient privileges for the operation |
string omq.system.authenticate | ( | ) |
returns a constant string "admin"
hash omq.system.block-workflow-instance | ( | softint | wfiid, |
any | block | ||
) |
block the given workflow order data instance or resets a blocked order to the original status
If the block argument set to True (or missing) it changes a workflow order data instance's status to OMQ::StatBlocked. An exception will be thrown if the status is OMQ::StatInProgress. No further processing can be done on workflow order data instances with a OMQ::StatBlocked status (unless the workflow instance is recovered back from OMQ::StatBlocked or the status is first updated to OMQ::StatError and then to OMQ::StatRetry). If the blocked argument is set to False the workflow instance is recovered back to its original status and it is processed.
wfiid | the workflow order data instance ID |
block | if missing or evaluates to True, then the order is blocked, if False then the order is unblocked |
workflow_status:
the status of the workflow orderBLOCK-WORKFLOW-ERROR | invalid status, foreign session id, missing original status, unblock operation already in progress |
AUTHORIZATION-ERROR | this exception is thrown when Role Based Access Control is enabled and the user does not have sufficient privileges for the operation |
WORKFLOW-ACCESS-ERROR | this is exception is thrown when Role Based Access Control is enabled and the user does not have the right to access the given workflow (for more information, see Interface Groups) |
hash omq.system.block-workflow-instances | ( | hash | ih | ) |
block or restore the list of workflow order data instances
If the block argument is set to True it changes a workflow order data instance's status to OMQ::StatBlocked, otherwise orders with a OMQ::StatBlocked status are restored to their original status. An exception will be thrown if the status is OMQ::StatInProgress. No further processing can be done on workflow order data instances with a OMQ::StatBlocked status (unless the workflow instance is recovered back from OMQ::StatBlocked or the status is first updated to OMQ::StatError and then to OMQ::StatRetry). If the blocked argument is set to False the workflow instance is recovered back to its original status and it is processed.
ih | a hash where each key is the workflow_instanceid to block or unblock, and the value is the block status (boolean True means block or False means unblock) |
workflow_status:
the status of the workflow orderAUTHORIZATION-ERROR | this exception is thrown when Role Based Access Control is enabled and the user does not have sufficient privileges for the operation |
hash omq.system.cancel-workflow-instance | ( | softint | wfiid, |
any | cancel | ||
) |
cancels the given workflow order data instance or resets a canceled order to the original status
If the cancel argument is True (or missing) it changes a workflow order data instance's status to OMQ::StatCanceled. An exception will be thrown if the status is OMQ::StatInProgress. No further processing can be done on workflow order data instances with a OMQ::StatCanceled status (unless the workflow instance is recovered back from OMQ::StatCanceled or the status is first updated to OMQ::StatError and then to OMQ::StatRetry).
wfiid | the workflow_instanceid of the order to process |
cancel | if set to False the workflow instance is recovered back to its original status and it is processed, otherwise if True or missing then the order is canceled |
workflow_status:
the status of the workflow orderCANCEL-WORKFLOW-ERROR | invalid status, foreign session id, missing original status, uncancel operation already in progress |
AUTHORIZATION-ERROR | this exception is thrown when Role Based Access Control is enabled and the user does not have sufficient privileges for the operation |
WORKFLOW-ACCESS-ERROR | this is exception is thrown when Role Based Access Control is enabled and the user does not have the right to access the given workflow (for more information, see Interface Groups) |
hash omq.system.cancel-workflow-instances | ( | hash | ih | ) |
cancels the given workflow order data instance or resets a canceled order to the original status
If the cancel argument is set to True (or missing) it changes a workflow order data instance's status to OMQ::StatCanceled. An exception will be thrown if the status is OMQ::StatInProgress. No further processing can be done on workflow order data instances with a OMQ::StatCanceled status (unless the workflow instance is recovered back from OMQ::StatCanceled or the status is first updated to OMQ::StatError and then to OMQ::StatRetry). If the cancel argument is set to False the workflow instance is recovered back to its original status and it is processed.
ih | a hash where each key is the workflow_instanceid to cancel or uncancel, and the value is the cancel status (boolean True means cancel or False means uncancel) |
workflow_status:
the status of the workflow orderCANCEL-WORKFLOW-ERROR | invalid status, foreign session id, missing original status, uncancel operation already in progress |
AUTHORIZATION-ERROR | this exception is thrown when Role Based Access Control is enabled and the user does not have sufficient privileges for the operation |
WORKFLOW-ACCESS-ERROR | this is exception is thrown when Role Based Access Control is enabled and the user does not have the right to access the given workflow (for more information, see Interface Groups) |
string omq.system.clone-role | ( | string | source_role, |
string | new_role, | ||
string | desc | ||
) |
Permanently add a role to the system by cloning an existing role's permissions and groups.
Also creates the role in the database
source_role | the name of the source role |
new_role | the name of the role to add |
desc | the description of the role |
RBAC-ADD-ROLE-ERROR | invalid role (already exists), invalid permission, invalid group |
AUTHORIZATION-ERROR | this exception is thrown when Role Based Access Control is enabled and the user does not have sufficient privileges for the operation |
hash omq.system.create-order | ( | hash | params | ) |
create workflow order method (workflow order data instance)
Creates a workflow order data instance of the specified type with the data passed as the static order data
params | The hash passed must have at either a staticdata key or an external_order_instanceid key, valid keys:
|
workflow_instanceid
the workflow instance ID of the workflow order instance ID createdSUBMIT-ORDER-ERROR | unknown workflow, invalid status |
AUTHORIZATION-ERROR | this exception is thrown when Role Based Access Control is enabled and the user does not have sufficient privileges for the operation |
WORKFLOW-ACCESS-ERROR | this is exception is thrown when Role Based Access Control is enabled and the user does not have the right to access the given workflow (for more information, see Interface Groups) |
string omq.system.debug.dump-caches | ( | ) |
string omq.system.debug.dump-exec-cache | ( | ) |
string omq.system.debug.dump-system-pool | ( | ) |
string omq.system.debug.get-data-cache | ( | ) |
string omq.system.debug.get-data-cache-summary | ( | ) |
hash omq.system.debug.get-mon | ( | ) |
string omq.system.debug.get-segment-cache | ( | ) |
string omq.system.debug.get-segment-summary | ( | ) |
hash omq.system.debug.get-thread-stacks | ( | ) |
string omq.system.debug.get-workflow-entry | ( | softint | wfiid | ) |
string omq.system.debug.get-workflow-queue-status | ( | ) |
nothing omq.system.debug.system | ( | softstring | flag | ) |
nothing omq.system.debug.workflow-entry | ( | softint | wfiid, |
*string | flag | ||
) |
int omq.system.delete-error | ( | string | err | ) |
deletes all definitions of an error from all workflows and at the global level
Changes are committed internally and also to the database in this method (i.e. all changes are persistent)
err | the name of the error to delete |
AUTHORIZATION-ERROR | this exception is thrown when Role Based Access Control is enabled and the user does not have sufficient privileges for the operation |
WORKFLOW-ACCESS-ERROR | this is exception is thrown when Role Based Access Control is enabled and the user does not have the right to access at least one of the affected workflows (for more information, see Interface Groups) |
string omq.system.delete-permission | ( | string | permission | ) |
Deletes an existing user permission from the database and the RBAC cache.
System permissions may not be deleted; only user permissions may be deleted.
This operation will fail if the permission is currently associated to any roles. To remove a permission that is associated with one or more roles, first remove the permission from all roles and then remove the permission, or use the user-tool program to perform a cascading delete of the permission and synchronize the RBAC cache with the database by calling Qorus API function omq.system.reload-rbac().
permission | the permission to delete |
RBAC-DELETE-PERMISSION-ERROR | invalid permission |
AUTHORIZATION-ERROR | this exception is thrown when Role Based Access Control is enabled and the user does not have sufficient privileges for the operation |
string omq.system.delete-role | ( | string | role | ) |
Deletes an existing role from the database and the RBAC cache.
role | the role to delete |
RBAC-DELETE-ROLE-ERROR | invalid role |
AUTHORIZATION-ERROR | this exception is thrown when Role Based Access Control is enabled and the user does not have sufficient privileges for the operation |
string omq.system.delete-service | ( | string | name, |
*string | version | ||
) |
Unloads the named system service from the system.
If the service is running, it is first stopped. Additionally, any outstanding method calls must return before the service can be unloaded.
name | the name of the system service to unload |
version | the version of the service to unload; normally this parameter should not be given; only one version of a service can be loaded at a time and giving the wrong version string will cause an exception to be thrown |
AUTHORIZATION-ERROR | this exception is thrown when Role Based Access Control is enabled and the user does not have sufficient privileges for the operation |
SERVICE-NOT-LOADED | this exception is thrown when the service is not loaded |
string omq.system.delete-user | ( | string | user | ) |
Deletes an existing user from the database and the RBAC cache.
user | the user to delete |
RBAC-DELETE-USER-ERROR | invalid user |
AUTHORIZATION-ERROR | this exception is thrown when Role Based Access Control is enabled and the user does not have sufficient privileges for the operation |
bool omq.system.delete-workflow-error | ( | softint | wfid, |
string | err | ||
) |
deletes a workflow-specific error so that the global error definition will be used instead
Changes are committed internally and also to the database in this method (i.e. all changes are persistent)
wfid | the workflow ID of the workflow-specific error to delete |
err | the name of the error to delete |
AUTHORIZATION-ERROR | this exception is thrown when Role Based Access Control is enabled and the user does not have sufficient privileges for the operation |
WORKFLOW-ACCESS-ERROR | this is exception is thrown when Role Based Access Control is enabled and the user does not have the right to access the given workflow (for more information, see Interface Groups) |
hash omq.system.exec-synchronous-existing | ( | hash | params | ) |
Executes a workflow in synchronous mode against an already-existing order in the database with status OMQ::StatReady.
Starts a workflow execution instance in synchronous mode against the already existing workflow order data instance identified in the hash argument (must correspond to the WORKFLOW_INSTANCE.WORKFLOW_INSTANCE_ID
value for the data to be processed). Note that the workflow must have a OMQ::StatReady or OMQ::StatScheduled (WORKFLOW_INSTANCE.WORKFLOW_STATUS
= "Y" or "S") status in the database in order to be processed in a synchronous workflow instance; it's not possible to process workflow data with other statuses synchronously. The call will normally return only after the workflow reaches a OMQ::StatComplete or OMQ::StatError state, unless the system or the workflow order data instance are manually stopped while the workflow order data instance is being processed, in which case other statuses can be returned.
params | a hash with the following keys:
|
workflow_instanceid:
the workflow instance ID of the orderstatus:
the status of the workflowdynamicdata:
the dynamic data of the workflow order instancePARAMETER-ERROR | workflow_instanceid key missing from argument hash |
SHUTDOWN-IN-PROGRESS | cannot start new workflows because the system is shutting down |
AUTHORIZATION-ERROR | this exception is thrown when Role Based Access Control is enabled and the user does not have sufficient privileges for the operation |
WORKFLOW-ACCESS-ERROR | this is exception is thrown when Role Based Access Control is enabled and the user does not have the right to access the given workflow (for more information, see Interface Groups) |
hash omq.system.exec-synchronous-workflow | ( | hash | params | ) |
Executes a workflow in synchronous mode and returns the final status of the order after processing.
Starts a workflow execution instance with the designated name and version in synchronous mode against the order data given in the call. The call will normally return only after the workflow reaches a OMQ::StatComplete or OMQ::StatError state, unless the system or the workflow order data instance are manually stopped while the workflow order data instance is being processed, in which case other statuses can be returned.
params | a hash with the following keys:
|
workflow_instanceid:
the workflow instance ID for the order createdstatus:
the status of the workflowdynamicdata:
the dynamic data of the workflow order instanceversion:
(string) the version of the workflow executed (useful if no version key supplied in the call)PARAMETER-ERROR | invalid workflow, mode, options key in incorrect format (not a hash), or orderdata key missing from argument hash |
SHUTDOWN-IN-PROGRESS | cannot start new workflows because the system is shutting down |
AUTHORIZATION-ERROR | this exception is thrown when Role Based Access Control is enabled and the user does not have sufficient privileges for the operation |
WORKFLOW-ACCESS-ERROR | this is exception is thrown when Role Based Access Control is enabled and the user does not have the right to access the given workflow (for more information, see Interface Groups) |
string omq.system.flush-options | ( | *hash | params | ) |
write the server's options to the option file on the server's filesystem
If any option hash if passed, then such options will be saved in the file but not applied to the running process. If any errors occur, an exception will be thrown.
params | options to set in the options file |
OPTION-ERROR | an error occurred in creating or writing to the output file |
AUTHORIZATION-ERROR | this exception is thrown when Role Based Access Control is enabled and the user does not have sufficient privileges for the operation |
hash omq.system.get-all-errors | ( | ) |
returns all global and workflow-specific error definitions
"global"
and "workflow"
; the "global"
key is assigned a hash of global error definitions, where each key is the error name and the value of each key is a hash representing the error definition. The "workflow"
key is assigned a hash of workflow IDs, each of which is then assigned a hash of error definitions, representing the workflow-specific error definitions. Each error hash has the following keys:error:
the name of the error repeateddescription:
the description of the errorseverity:
the severity of the error (see Error Severity Codes for possible values)business_flag:
indicates if the error is a business error or a technical errorstatus:
the status the order should fall in when the error occursretry_delay_secs:
indicates the retry delay in seconds for this error; if not set then the error gets the standard retry periodhash omq.system.get-all-permissions | ( | ) |
returns a hash of information about all permissions in the RBAC cache
permission_type:
either "SYSTEM"
or "USER"
desc:
the desciption for the permissionprovider:
the RBAC provider for the role information hash omq.system.get-all-roles | ( | ) |
Returns a hash with information on all roles in the RBAC cache.
role:
the role nameprovider:
the RBAC provider for the roledesc:
the description of the rolepermissions:
a list of permissions attached to the rolegroups:
a list of groups attached to the rolehas_default:
True if the has group DEFAULT, in this case workflows
, services
, and jobs
keys will be assigned to empty lists and the role has the right to access all workflows, services, and jobsworkflows:
a list of hashes of workflow information that the role may access (empty if has_default
is True); each hash has the following keys:workflowid:
the ID of the workflowname:
the name of the workflowversion:
the version of the workflowservices:
a list of hashes of user service information the role may access (empty if has_default
is True); each hash has the following keys:serviceid:
the ID of the servicetype:
always "user"
; it's not possible to restrict access to system services through interface groupsname:
the name of the serviceversion:
the version of the serviceautostart:
the autostart flag for the servicejobs:
a list of hashes of job information the role may access (empty if has_default
is True); each hash has the following keys:jobid:
the ID of the jobname:
the name of the jobversion:
the version of the jobhash omq.system.get-all-users | ( | ) |
Returns a hash with all information (except passwords) on all Qorus users in the RBAC cache.
username:
the username of the user (same as the higher-level hash key)name:
the descriptive (or real) name for the userprovider:
the RBAC provider for the userpermissions:
a list of all permissions that the user has inherited through all rolesgroups:
a list of groups that the user has inherited through all roleshas_default:
True if the user has any roles that have group DEFAULT, in this case the workflows
, services
, and jobs
keys will be assigned to empty lists and the user has the right to access all workflows, services, and jobsworkflows:
a list of hashes of workflow information that the user may access (empty if has_default
is True); each hash has the following keys:workflowid:
the ID of the workflowname:
the name of the workflowversion:
the version of the workflowservices:
a list of hashes of user service information the user may access (empty if has_default
is True); each hash has the following keys:serviceid:
the ID of the servicetype:
always "user"
; it's not possible to restrict access to system services through interface groupsname:
the name of the serviceversion:
the version of the serviceautostart:
the autostart flag for the servicejobs:
a list of hashes of job information the user may access (empty if has_default
is True); each hash has the following keys:jobid:
the ID of the jobname:
the name of the jobversion:
the version of the jobAUTHORIZATION-ERROR | this exception is thrown when Role Based Access Control is enabled and the user does not have sufficient privileges for the operation |
hash omq.system.get-current-user-info | ( | ) |
Returns a hash with all information (except passwords) on for the current user from the RBAC cache.
username:
the username of the username:
the descriptive (or real) name for the userprovider:
the RBAC provider for the userroles:
a list of roles assigned to the userpermissions:
a list of all permissions that the user has inherited through all rolesgroups:
a list of groups that the user has inherited through all roleshas_default:
True if the user has any roles that have group DEFAULT, in this case the workflows
, services
, and jobs
keys will be assigned to empty lists and the user has the right to access all workflows, services, and jobsworkflows:
a list of hashes of workflow information that the user may access (empty if has_default
is True); each hash has the following keys:workflowid:
the ID of the workflowname:
the name of the workflowversion:
the version of the workflowservices:
a list of hashes of user service information the user may access (empty if has_default
is True); each hash has the following keys:serviceid:
the ID of the servicetype:
always "user"
; it's not possible to restrict access to system services through interface groupsname:
the name of the serviceversion:
the version of the serviceautostart:
the autostart flag for the servicejobs:
a list of hashes of job information the user may access (empty if has_default
is True); each hash has the following keys:jobid:
the ID of the jobname:
the name of the jobversion:
the version of the jobstorage:
a hash of key-value pairs associated with the user *hash omq.system.get-global-errors | ( | *softlist | l | ) |
returns global error definition information
l | NOTHING (meaning return all errors) or a single string (meaning return the global definition for that error string) or a list of strings (meaning return a hash of the requested errors) |
error:
the name of the error repeateddescription:
the description of the errorseverity:
the severity of the error (see Error Severity Codes for possible values)business_flag:
indicates if the error is a business error or a technical errorretry_flag:
indicates if the error should cause the order to get a "RETRY"
statusretry_delay_secs:
indicates the retry delay in seconds for this error; if not set then the error gets the standard retry periodtype:
"global"
, meaning that the error definition is globalhash< auto > omq.system.get-last-events | ( | hash< auto > | cx, |
softint | count | ||
) |
returns the last system events
count | the maximum number of events to return |
lastid:
the last event ID at the time the function returnsevents:
a list of event hashes (see eventhash for a detailed description); note that this key will be missing if no events are returnedshutdown:
if this key is returned, it means the system is shutting downinfo
hash value in the event hashhash omq.system.get-last-events-or | ( | ) |
hash omq.system.get-option-info | ( | ) |
returns a hash of all global Qorus system options and their current values
value:
(any) the value of the optionexpects:
(string) the data type the option expectsdesc:
(string) description of the optiondefault:
(any) the default value of the option (if any)startup-only
: (boolean) if the option can only be set when the system is startedstatus:
(string) either locked
or unlocked
hash omq.system.get-order-info | ( | softstring | wfiid | ) |
Gets additional info for the given workflow order data instance.
wfiid | the workflow instance id |
op_username:
the username of the operator working on the orderop_comment:
notes about processing the orderWORKFLOW-ACCESS-ERROR | this is exception is thrown when Role Based Access Control is enabled and the user does not have the right to access the given workflow (for more information, see Interface Groups) |
hash omq.system.get-role-info | ( | string | role | ) |
Returns a hash with information on all roles in the RBAC cache.
role:
the role nameprovider:
the RBAC provider for the roledesc:
the description of the rolepermissions:
a list of permissions attached to the rolegroups:
a list of groups attached to the rolehas_default:
True if the role has group DEFAULT, in this case workflows
, services
, and jobs
keys will be assigned to empty lists and the role has the right to access all workflows, services, and jobsworkflows:
a list of hashes of workflow information that the role may access (empty if has_default
is True); each hash has the following keys:workflowid:
the ID of the workflowname:
the name of the workflowversion:
the version of the workflowservices:
a list of hashes of user service information the role may access (empty if has_default
is True); each hash has the following keys:serviceid:
the ID of the servicetype:
always "user"
; it's not possible to restrict access to system services through interface groupsname:
the name of the serviceversion:
the version of the serviceautostart:
the autostart flag for the servicejobs:
a list of hashes of job information the role may access (empty if has_default
is True); each hash has the following keys:jobid:
the ID of the jobname:
the name of the jobversion:
the version of the jobGET-ROLE-ERROR | role does not exist |
bool omq.system.get-service-autostart | ( | string | name | ) |
any omq.system.get-service-options | ( | string | name | ) |
Returns options set on the given system service; the service must be already loaded or an exception is raised.
If no arguments are passed, then all service-level options are returned, otherwise only the values for the given options are returned. If the given option is not overridden on the service level, then the value of the system option is returned. If the service is not already loaded is not valid, then an exception is raised.
name | the service name |
SERVICE-ERROR | the given service is not loaded |
SERVICE-ACCESS-ERROR | this is exception is thrown when Role Based Access Control is enabled and the user does not have the right to access the given workflow (for more information, see Interface Groups) |
hash omq.system.get-status | ( | ) |
returns a hash giving information about system status
instance-key
: (string) the system instance keysession-id
: (int) the application session idomq-version
: (string) the version of the serverqore-version
: (string) the version of the underlying qore library usedmodules:
(hash) a hash of module info as returned by Qore::get_module_hash()datamodel-version
: (string) the version of the datamodel expected by the serveromq-schema
: (string) "user%@dbname"
string for the system "omq"
datasourceomq-driver
: (string) driver name for the system "omq"
datasourceomq-db-version
: (string) database server version for the system "omq"
datasourceomquser-schema
: (string) "user%@dbname"
string for the "omquser"
datasourceomquser-driver
: (string) driver name for the "omquser"
datasourceomquser-db-version
: (string) database server version for the "omquser"
datasourcestarttime:
(date) date and time the server was startedhostname:
(string) hostname where the server is runningpid:
(int) PID of the server processthreads:
(int) count of currently active threadsschema-properties
: (hash) hash of actual schema properties (identical to system property domain "omq"
)omq_dir:
(string) the application directory or "LSB"
for Linux Standard Base filesystem integrationlogfile:
(string) path to system log filehttp_logfile:
(string) path to system HTTP server log filemonitoring_logfile:
(string) path to system monitoring log filealert_logfile:
(string) path to system alert log filecache_size:
(int) the current size of the workflow order data cacheshutting_down:
(bool) a flag if the system is shutting downbuild-type
: (string) the type of build of the server ("Production"
or "Debug"
)runtime-properties
: (hash) a hash of runtime propertiesalert-summary
: (hash) a hash with the following keys:transient:
(int) number of transient alertsongoing:
(int) number of ongoing alertsdebug:
system debugging flag (when True then more information is provided with exceptions)health:
a string color code for the health of the system with the following values:"GREEN"
: good health"YELLOW"
: warning"RED"
: problemssystem_log_url:
a URL to the websocket source for the main system logaudit_log_url:
a URL to the websocket source for the audit loghttp_log_url:
a URL to the websocket source for the HTTP server logmon_log_url:
a URL to the websocket source for the monitoring logalert_log_url:
a URL to the websocket source for the alert log hash omq.system.get-user-info | ( | *string | user | ) |
Returns a hash with all information (except passwords) on for the given or current user from the RBAC cache.
user | if present, the username to query, if not present, returns information about the current user |
username:
the username of the username:
the descriptive (or real) name for the userprovider:
the RBAC provider for the userroles:
a list of roles assigned to the userpermissions:
a list of all permissions that the user has inherited through all rolesgroups:
a list of groups that the user has inherited through all roleshas_default:
True if the user has any roles that have group DEFAULT, in this case workflows
, services
, and jobs
keys will be assigned to empty lists and the user has the right to access all workflows, services, and jobsworkflows:
a list of hashes of workflow information that the user may access (empty if has_default
is True); each hash has the following keys:workflowid:
the ID of the workflowname:
the name of the workflowversion:
the version of the workflowservices:
a list of hashes of user service information the user may access (empty if has_default
is True); each hash has the following keys:serviceid:
the ID of the servicetype:
always "user"
; it's not possible to restrict access to system services through interface groupsname:
the name of the serviceversion:
the version of the serviceautostart:
the autostart flag for the servicejobs:
a list of hashes of job information the user may access (empty if has_default
is True); each hash has the following keys:jobid:
the ID of the jobname:
the name of the jobversion:
the version of the jobstorage:
a hash of key-value pairs associated with the userGET-USER-ERROR | no username supplied in call and no authentication information supplied, username does not exist |
AUTHORIZATION-ERROR | this exception is thrown when Role Based Access Control is enabled and the user does not have sufficient privileges for the operation |
*hash omq.system.get-workflow-errors | ( | softint | wfid, |
*softlist | l | ||
) |
returns workflow-specific error definition information
wfid | the workflowid of the workflow to query |
l | nothing (meaning return all workflow-specific errors for this workflow) or a single string (meaning return the definition for that error string that will be used for the given workflow) or a list of strings (meaning return a hash of the requested errors used for the given workflow) |
error:
the name of the error repeateddescription:
the description of the errorseverity:
the severity of the error (see Error Severity Codes for possible values)business_flag:
indicates if the error is a business error or a technical errorretry_flag:
indicates if the error should cause the order to get a "RETRY"
statusretry_delay_secs:
indicates the retry delay in seconds for this error; if not set then the error gets the standard retry periodtype:
either "workflow"
, meaning that the error definition is workflow-specific, or "global"
, meaning that the error definition is globalWORKFLOW-ACCESS-ERROR | this is exception is thrown when Role Based Access Control is enabled and the user does not have the right to access the given workflow (for more information, see Interface Groups) |
any omq.system.get-workflow-info | ( | *softstring | id | ) |
returns workflow information for the execution id passed, or for all workflows if no execution id is passed
id | the optional workflow execution id |
executionID:
(string) the execution ID of the workflowname:
(string) the name of the workflowversion:
(string) the version of the workflowworkflowid:
(string) the ID of the workflowmode:
(string) the mode of the workflowstatus:
(string) the status of the workflowiterations:
(int) number of iterations of all segmentstotalSegments:
(int) number of segments in the workflowerrors:
(int) number of errors encounteredwarnings:
(int) number of warnings encounteredstarttime:
(date) date and time workflow execution instance startedoptions:
(hash) workflow optionslogfile:
(string) the workflow log fileINVALID-WORKFLOW-EXECUTION-ID | invlaid workflow execution ID |
WORKFLOW-ACCESS-ERROR | this is exception is thrown when Role Based Access Control is enabled and the user does not have the right to access the given workflow (for more information, see Interface Groups) |
any omq.system.get-workflow-option | ( | softint | id | ) |
Returns options set on the running workflow identified by the execution ID passed.
Additional optional string arguments giving option names are accepted after the execution ID. If no additional arguments are passed, then all options set on the workflow are returned, otherwise only the values for the given options are returned.
When returning individual option values, any option that is not set at the workflow level will be returned with the value system level if the option is a valid system option.
If the execution instance ID is not valid, then an exception is raised
id | the workflow execution ID |
INVALID-WORKFLOW-EXECUTION-ID | invalid workflow execution ID |
WORKFLOW-ACCESS-ERROR | this is exception is thrown when Role Based Access Control is enabled and the user does not have the right to access the given workflow (for more information, see Interface Groups) |
hash omq.system.get-workflow-options | ( | softint | id | ) |
Returns all options set on the running workflow identified by the execution ID passed.
If the execution instance ID is not valid, then an exception is raised
id | the workflow execution ID |
INVALID-WORKFLOW-EXECUTION-ID | invalid workflow execution ID |
WORKFLOW-ACCESS-ERROR | this is exception is thrown when Role Based Access Control is enabled and the user does not have the right to access the given workflow (for more information, see Interface Groups) |
nothing omq.system.group.add-job | ( | string | name, |
string | jname | ||
) |
Adds a job to a workflow/service/job group from the job's name.
If a job is added to a disabled group and the job is active, then the job is immediately stopped
name | the name of the group |
jname | the name of the job to add |
GROUP-ERROR | group or job does not exist |
AUTHORIZATION-ERROR | this exception is thrown when Role Based Access Control is enabled and the user does not have sufficient privileges for the operation |
nothing omq.system.group.add-job-id | ( | string | name, |
softlist | ids | ||
) |
Adds one or more jobs to a workflow/service/job group from the jobids.
If jobs are added to a disabled group, the jobs are immediately stopped
name | the name of the group |
ids | a list of job ids or a single job id |
GROUP-ERROR | group or job does not exist |
AUTHORIZATION-ERROR | this exception is thrown when Role Based Access Control is enabled and the user does not have sufficient privileges for the operation |
nothing omq.system.group.add-service | ( | string | name, |
string | sname, | ||
*string | ver | ||
) |
Adds a service to a workflow/service/job group from the service's name and optional version.
If a service is added to a disabled group, the any instances of the service are immediately stopped
name | the name of the group |
sname | the name of the service to add |
ver | the optional version of the service to add; if no version string is passed, then all existing versions of the service are added |
GROUP-ERROR | group or service does not exist |
AUTHORIZATION-ERROR | this exception is thrown when Role Based Access Control is enabled and the user does not have sufficient privileges for the operation |
nothing omq.system.group.add-service-id | ( | string | name, |
softlist | ids | ||
) |
Adds one or more services to a workflow/service/job group from the serviceids.
If services are added to a disabled group, the services are immediately stopped and unloaded
name | the name of the group |
ids | a list of service ids or a single service id |
GROUP-ERROR | group or service does not exist |
AUTHORIZATION-ERROR | this exception is thrown when Role Based Access Control is enabled and the user does not have sufficient privileges for the operation |
nothing omq.system.group.add-workflow | ( | string | name, |
string | wname, | ||
*string | ver | ||
) |
Adds a workflow to a workflow/service/job group from the workflow's name and optional version.
If a workflow is added to a disabled group, the any instances of the workflow are immediately stopped
name | the name of the group |
wname | the name of the workflow to add |
ver | the optional version of the workflow to add; if no version string is passed, then all existing versions of the workflow are added |
GROUP-ERROR | group or workflow does not exist |
AUTHORIZATION-ERROR | this exception is thrown when Role Based Access Control is enabled and the user does not have sufficient privileges for the operation |
nothing omq.system.group.add-workflow-id | ( | string | name, |
softlist | ids | ||
) |
Adds one or more workflows to a workflow/service/job group from the workflowids.
If a workflow is added to a disabled group, the any instances of the workflow are immediately stopped
name | the name of the group |
ids | a list of workflow ids or a single workflow id |
GROUP-ERROR | group or workflow does not exist |
AUTHORIZATION-ERROR | this exception is thrown when Role Based Access Control is enabled and the user does not have sufficient privileges for the operation |
int omq.system.group.create | ( | string | name, |
string | desc, | ||
softlist | svcids, | ||
softlist | wfids, | ||
softstring | enabled = True , |
||
softlist | jobids = () , |
||
softlist | mapperids = () , |
||
softlist | vmapids = () |
||
) |
Creates an interface group.
Workflows, services, and jobs in disabled groups are stopped immediately if loaded/running. When a group is enabled, then any services with the autostart flag set and any jobs with the active flag set are immediately started if the group was previously disabled and the service/job is not a member of any other disabled group.
name | the name of the group |
desc | the description of the group |
svcids | a list of integer service IDs |
wfids | a list of integer workflow IDs |
enabled | the new status of the group (to be parsed with parse_boolean()) |
jobids | a list of integer job IDs |
mapperids | a list of integer mapper IDs |
vmapids | a list of integer value map IDs |
GROUP-ERROR | group already exists, invalid service, workflow, or job ID |
AUTHORIZATION-ERROR | this exception is thrown when Role Based Access Control is enabled and the user does not have sufficient privileges for the operation |
nothing omq.system.group.delete | ( | string | name | ) |
Permanently deletes a workflow/service/job group.
When a disabled group is deleted, then any services with the autostart flag set and any active jobs are immediately started if the group was previously disabled and the service/job is not a member of any other disabled group
name | the name of the group |
GROUP-ERROR | group does not exist |
AUTHORIZATION-ERROR | this exception is thrown when Role Based Access Control is enabled and the user does not have sufficient privileges for the operation |
nothing omq.system.group.delete-job | ( | string | name, |
string | jname | ||
) |
Permanently deletes a job from an interface group using the job's name.
No error is raised if an attempt is made to remove jobs from a group that are not in the group
name | the name of the group |
jname | the name of the job to delete |
GROUP-ERROR | group or job does not exist |
AUTHORIZATION-ERROR | this exception is thrown when Role Based Access Control is enabled and the user does not have sufficient privileges for the operation |
nothing omq.system.group.delete-job-id | ( | string | name, |
softlist | ids | ||
) |
Permanently deletes one or more jobs from an interface group using job ids.
name | the name of the group |
ids | a list of job ids or a single job id |
GROUP-ERROR | group or job does not exist |
AUTHORIZATION-ERROR | this exception is thrown when Role Based Access Control is enabled and the user does not have sufficient privileges for the operation |
nothing omq.system.group.delete-service | ( | string | name, |
string | sname, | ||
*string | ver | ||
) |
Permanently deletes a service from a workflow/service/job group using the service's name and optional version.
No error is raised if an attempt is made to remove service from a group that are not in the group. When services are removed from disabled groups, any services with the autostart flag are immediately started if the group was previously disabled and the service is not a member of any other disabled group.
name | the name of the group |
sname | the name of the service to delete |
ver | the optional version of the service to delete; if no version string is passed, then all existing versions of the service are deleted |
GROUP-ERROR | group or service does not exist |
AUTHORIZATION-ERROR | this exception is thrown when Role Based Access Control is enabled and the user does not have sufficient privileges for the operation |
nothing omq.system.group.delete-service-id | ( | string | name, |
softlist | ids | ||
) |
Permanently deletes one or more services to a workflow/service/job group from the service ids.
When services are removed from disabled groups, any services with the autostart flag are immediately started if the group was previously disabled and the service is not a member of any other disabled group.
name | the name of the group |
ids | a list of service ids or a single service id |
GROUP-ERROR | group or service does not exist |
AUTHORIZATION-ERROR | this exception is thrown when Role Based Access Control is enabled and the user does not have sufficient privileges for the operation |
nothing omq.system.group.delete-workflow | ( | string | name, |
string | wname, | ||
*string | ver | ||
) |
Permanently deletes a workflow from a workflow/service/job group using the workflow's name and optional version.
No error is raised if an attempt is made to remove workflows from a group that are not in the group
name | the name of the group |
wname | the name of the workflow to delete |
ver | the optional version of the workflow to delete; if no version string is passed, then all existing versions of the workflow are deleted |
GROUP-ERROR | group or workflow does not exist |
AUTHORIZATION-ERROR | this exception is thrown when Role Based Access Control is enabled and the user does not have sufficient privileges for the operation |
nothing omq.system.group.delete-workflow-id | ( | string | name, |
softlist | ids | ||
) |
Permanently deletes one or more workflows from a workflow/service/job group using workflow ids.
name | the name of the group |
ids | a list of workflow ids or a single workflow id |
GROUP-ERROR | group or workflow does not exist |
AUTHORIZATION-ERROR | this exception is thrown when Role Based Access Control is enabled and the user does not have sufficient privileges for the operation |
hash omq.system.group.info | ( | *string | name | ) |
Returns information for a group or all groups if no group name argument is passed.
name | the optional name of the group to query; if no group name is passed, then information for all groups is returned |
name:
the name of the groupdescription:
the description of the groupenabled:
True if enabled or False if disabledis_default:
True if the group is the DEFAULT group, in this case the workflows
, services
, and jobs
keys will be assigned to empty lists and the group authorizes access all workflows, services, and jobsid:
the id of the grouproles:
a list of roles that have the groupworkflows:
a list of hashes of workflow information that the group authorizes access to (empty if is_default
is True, otherwise if is_default
is False and this list is empty, it means that the group does not authorize access to any workflows); each hash has the following keys:workflowid:
the ID of the workflowname:
the name of the workflowversion:
the version of the workflowservices:
a list of hashes of user service information the group authorizes access to (empty if is_default
is True, otherwise if is_default
is False and this list is empty, it means that the group does not authorize access to any services); each hash has the following keys:serviceid:
the ID of the servicetype:
always "user"
; it's not possible to restrict access to system services through interface groupsname:
the name of the serviceversion:
the version of the serviceautostart:
the autostart flag for the servicejobs:
a list of hashes of job information the group authorizes access to (empty if is_default
is True, otherwise if is_default
is False and this list is empty, it means that the group does not authorize access to any jobs); each hash has the following keys:jobid:
the ID of the jobname:
the name of the jobversion:
the version of the job nothing omq.system.group.set-status | ( | string | name, |
softstring | enabled | ||
) |
Enables or disables an interface group.
Workflows, services, and jobs in disabled groups are stopped immediately if loaded/running/active. When a group is enabled, then any services with the autostart flag are immediately started if the group was previously disabled and the service is not a member of any other disabled group.
name | the name of the group |
enabled | the new status of the group |
GROUP-ERROR | group does not exist |
AUTHORIZATION-ERROR | this exception is thrown when Role Based Access Control is enabled and the user does not have sufficient privileges for the operation |
string omq.system.group.update | ( | string | group, |
hash | hash | ||
) |
Modifies an existing interface group in the database and in the RBAC cache.
Changes to groups are effected immediately; for example, if a workflow, service, or job is added to a disabled group, the any corresponding running objects are immediately stopped; or if a job is removed from a disabled group, then it is immediately started, etc
group | the group to update |
hash | a hash giving the information to update, valid keys are as follows; at least one of the following keys must be present:
|
AUTHORIZATION-ERROR | this exception is thrown when Role Based Access Control is enabled and the user does not have sufficient privileges for the operation |
hash omq.system.help | ( | ) |
gives a hash of API information, where each key is a Qorus system API method
This method accepts optional string arguments will select the methods to provide help for; if the method name has no '.' in it, then "omq.system."
will be prepended. For example:
This will produce the following response:
params:
a description of the parameterscategory:
a string giving the method categorydescription:
a description of the method any omq.system.job.get-options | ( | string | name | ) |
Returns options set on the given job; the job must be active or an exception is raised.
If no arguments are passed, then all service-level options are returned, otherwise only the values for the given options are returned. If the given option is not overridden on the job level, then the value of the system option is returned. If the job is not active, then an exception is raised.
name | the job name |
JOB-ERROR | no job with the given name is active |
JOB-ACCESS-ERROR | the user does not have the right to access the given job (for more information, see Interface Groups) |
any omq.system.job.get-options-id | ( | softint | id | ) |
Returns options set on the given job; the job must be active or an exception is raised.
If no arguments are passed, then all service-level options are returned, otherwise only the values for the given options are returned. If the given option is not overridden on the job level, then the value of the system option is returned. If the job is not active, then an exception is raised.
id | the job ID |
JOB-ERROR | no job with the given name is active |
JOB-ACCESS-ERROR | the user does not have the right to access the given job (for more information, see Interface Groups) |
hash omq.system.job.info | ( | *string | name | ) |
Returns information on all jobs visible to the calling user or a specific job depending on the argument (or lack thereof)
name | the optional name of the job to query; if no job name is passed, then information for all jobs is returned (note that the hash is filtered for jobs not visible to the calling user if the calling user has no role with the DEFAULT interface group), however, if this argument is passed and no job with this name exists, then a JOB-ERROR exception is raised |
jobid:
the metadata jobid of the job typename:
the job nameversion:
the job versiondescription:
the job descriptiontrigger:
a string describing the timer/trigger for the jobjob_instanceid
]: the id of the job instance (will only have a value if the job is currently executing)last_executed
]: the last executed date/time of the job (NOTHING if not yet executed)last_executed_job_instanceid
]: the last executed instance id of the jobexpiry_date
]: the expiry date of the job, if any; if this date is present, then the job will not run automatically after this datenext
]: the next trigger date/time; this key is only included if the job is activeactive:
this value will only be True if the job is actually loaded; note that the job can be active in the database but not actually loaded if the job is a member of a disabled Interface Group, in which case the value of this key will be Falsegroups:
a list of zero or more strings giving group names the job is a member ofJOB-ERROR | no job with the given name exists |
JOB-ACCESS-ERROR | the user does not have the right to access the given job (for more information, see Interface Groups) |
hash omq.system.job.info-id | ( | softint | id | ) |
Returns information on a specific job by the jobid.
id | the jobid of the job to query |
jobid:
the metadata jobid of the job typename:
the job nameversion:
the job versiondescription:
the job descriptiontrigger:
a string describing the timer/trigger for the jobjob_instanceid
]: the id of the job instance (will only have a value if the job is currently executing)last_executed
]: the last executed date/time of the job (NOTHING if not yet executed)last_executed_job_instanceid
]: the last executed instance id of the jobexpiry_date
]: the expiry date of the job, if any; if this date is present, then the job will not run automatically after this datenext
]: the next trigger date/timeactive:
this value will only be True if the job is actually loaded; note that the job can be active in the database but not actually loaded if the job is a member of a disabled Interface Group, in which case the value of this key will be FalseJOB-ERROR | no job with the given id exists |
JOB-ACCESS-ERROR | the user does not have the right to access the given job (for more information, see Interface Groups) |
hash omq.system.job.list-active | ( | ) |
Returns information on all active jobs visible to the calling user.
If any active jobs are not accessible to the calling user, then they are filtered from the hash returned.
jobid:
the metadata jobid of the job typename:
the job nameversion:
the job versiondescription:
the job descriptiontrigger:
a string describing the timer/trigger for the jobjob_instanceid
]: the id of the job instance (will only have a value if the job is currently executing)last_executed
]: the last executed date/time of the job (NOTHING if not yet executed)last_executed_job_instanceid
]: the last executed instance id of the jobexpiry_date
]: the expiry date of the job, if any; if this date is present, then the job will not run automatically after this datenext
]: the next trigger date/time; this key is only included if the job is activeactive:
this value is always True because this API only returns information about active jobsstring omq.system.job.reset | ( | string | name | ) |
Reloads a job from the database from its name; if it's currently running it is stopped and reloaded.
This API works on all jobs regardless of state; the job does not have to be running or active to be reset.
name | the name of the job to reset |
JOB-ERROR | no job with the given name exists |
AUTHORIZATION-ERROR | this exception is thrown when Role Based Access Control is enabled and the user does not have sufficient privileges for the operation |
JOB-ACCESS-ERROR | the user does not have the right to access the given job (for more information, see Interface Groups) |
API-CALL-ERROR | cannot reset a disabled job |
string omq.system.job.reset-all | ( | ) |
Reloads all jobs from the database; all currently-running jobs are stopped and reloaded.
AUTHORIZATION-ERROR | this exception is thrown when Role Based Access Control is enabled and the user does not have sufficient privileges for the operation |
string omq.system.job.reset-id | ( | softint | id | ) |
Reloads a job from the database from its id; if it's currently running it is stopped and reloaded.
This API works on all jobs regardless of state; the job does not have to be running or active to be reset.
id | the jobid to reset |
JOB-ERROR | no job with the given name exists |
AUTHORIZATION-ERROR | this exception is thrown when Role Based Access Control is enabled and the user does not have sufficient privileges for the operation |
JOB-ACCESS-ERROR | the user does not have the right to access the given job (for more information, see Interface Groups) |
hash omq.system.job.run | ( | string | name | ) |
Runs the given job immediately (regardless of the trigger time) from the job name even if the job is expired, inactive, or dedicated to another instance.
name | the name of the job to run |
job_instanceid:
the job_instanceidstatus:
the status of the execution of the jobJOB-ERROR | no job with the given name exists |
AUTHORIZATION-ERROR | this exception is thrown when Role Based Access Control is enabled and the user does not have sufficient privileges for the operation |
JOB-ACCESS-ERROR | the user does not have the right to access the given job (for more information, see Interface Groups) |
hash omq.system.job.run-id | ( | softint | id | ) |
Runs the given job immediately (regardless of the trigger time) from the jobid even if the job is expired, inactive, or dedicated to another instance.
id | the jobid to run |
job_instanceid:
the job_instanceidstatus:
the status of the execution of the jobJOB-ERROR | no job with the given jobid exists |
AUTHORIZATION-ERROR | this exception is thrown when Role Based Access Control is enabled and the user does not have sufficient privileges for the operation |
JOB-ACCESS-ERROR | the user does not have the right to access the given job (for more information, see Interface Groups) |
string omq.system.job.schedule | ( | string | name, |
*string | schedule, | ||
*softint | recurring | ||
) |
Updates a job's schedule from the job name; if any errors occur an exception is thrown.
This API works on all jobs regardless of state; the job does not have to be running or active to be updated.
name | the name of the job to update |
schedule | a cron-like string giving the job schedule, see Job Schedule for information about the format; either this parameter or recurring must be present, but not both |
recurring | a duration in sections for triggering the job; either this parameter or schedule must be present, but not both |
JOB-SCHEDULE-ERROR | both schedule and duration parameters given or neither given |
CRON-ERROR | cron schedule cannot be parsed or 0 second duration given |
JOB-ERROR | no job with the given name exists |
AUTHORIZATION-ERROR | this exception is thrown when Role Based Access Control is enabled and the user does not have sufficient privileges for the operation |
JOB-ACCESS-ERROR | the user does not have the right to access the given job (for more information, see Interface Groups) |
string omq.system.job.schedule-id | ( | softint | id, |
*string | schedule, | ||
*softint | recurring | ||
) |
Updates a job's schedule from the jobid; if any errors occur an exception is thrown.
This API works on all jobs regardless of state; the job does not have to be running or active to be updated.
id | the jobid to update |
schedule | a cron-like string giving the job schedule, see Job Schedule for information about the format; either this parameter or recurring must be present, but not both |
recurring | a duration in sections for triggering the job; either this parameter or recurring must be present, but not both |
JOB-SCHEDULE-ERROR | both schedule and duration parameters given or neither given |
CRON-ERROR | cron schedule cannot be parsed or 0 second duration given |
JOB-ERROR | no job with the given ID exists |
AUTHORIZATION-ERROR | this exception is thrown when Role Based Access Control is enabled and the user does not have sufficient privileges for the operation |
JOB-ACCESS-ERROR | the user does not have the right to access the given job (for more information, see Interface Groups) |
string omq.system.job.set-active | ( | string | name, |
*softstring | active | ||
) |
Updates the "active" status of a job from the job name; if any errors occur an exception is thrown.
This API works on all jobs regardless of state; the job does not have to be running or active to be updated. Updating a job to active will start the job immediately unless the expiry date is past or the job is a member of a disabled group. Changing a currently-active job to inactive will stop the job immediately.
name | the name of the job to update |
active | the new status of the job; if not present, then True is assumed; note that this parameter is parsed with parse_boolean() so it's safe to pass a boolean, or a string like "true" or an integer that will be converted to a boolean value, see parse_boolean() for more information |
JOB-ERROR | no job with the given name exist |
AUTHORIZATION-ERROR | this exception is thrown when Role Based Access Control is enabled and the user does not have sufficient privileges for the operation |
JOB-ACCESS-ERROR | the user does not have the right to access the given job (for more information, see Interface Groups) |
string omq.system.job.set-active-id | ( | softint | id, |
*softstring | active | ||
) |
Updates the "active" status of a job from the job id; if any errors occur an exception is thrown.
This API works on all jobs regardless of state; the job does not have to be running or active to be updated. Updating a job to active will start the job immediately unless the expiry date is past or the job is a member of a disabled group. Changing a currently-active job to inactive will stop the job immediately.
id | the jobid of the job to update |
active | the new status of the job; if not present, then True is assumed; note that this parameter is parsed with parse_boolean() so it's safe to pass a boolean, or a string like "true" or an integer that will be converted to a boolean value, see parse_boolean() for more information |
JOB-ERROR | no job with the given id exists |
AUTHORIZATION-ERROR | this exception is thrown when Role Based Access Control is enabled and the user does not have sufficient privileges for the operation |
JOB-ACCESS-ERROR | the user does not have the right to access the given job (for more information, see Interface Groups) |
string omq.system.job.set-expiry | ( | string | name, |
*date | expiry | ||
) |
Updates the expiry date of a job from the job name; if any errors occur an exception is thrown.
This API works on all jobs regardless of state; the job does not have to be running or active to be updated. Removing the expiry date or setting a future expiry date from a job that is not started because it has expired will result in the job starting immediately (unless the job is inactive or a member of a disabled group. Setting a past expiry date on a currently-active job will stop the job immediately.
name | the name of the job to update |
expiry | the new expiration date for the job; if this parameter is not present or NOTHING then any expiration date for the job will be removed |
JOB-ERROR | no job with the given name exists |
AUTHORIZATION-ERROR | this exception is thrown when Role Based Access Control is enabled and the user does not have sufficient privileges for the operation |
JOB-ACCESS-ERROR | the user does not have the right to access the given job (for more information, see Interface Groups) |
string omq.system.job.set-expiry-id | ( | softint | id, |
*date | expiry | ||
) |
Updates the expiry date of a job from the job id; if any errors occur an exception is thrown.
This API works on all jobs regardless of state; the job does not have to be running or active to be updated. Removing the expiry date or setting a future expiry date from a job that is not started because it has expired will result in the job starting immediately (unless the job is inactive or a member of a disabled group. Setting a past expiry date on a currently-active job will stop the job immediately.
id | the jobid to update |
expiry | the new expiration date for the job; if this parameter is not present or NOTHING then any expiration date for the job will be removed |
JOB-ERROR | no job with the given id exists |
AUTHORIZATION-ERROR | this exception is thrown when Role Based Access Control is enabled and the user does not have sufficient privileges for the operation |
JOB-ACCESS-ERROR | the user does not have the right to access the given job (for more information, see Interface Groups) |
string omq.system.job.set-options | ( | string | name, |
hash | hash | ||
) |
Sets the options given in the hash on the given job; the job must be active or an exception is raised.
Options set override the system options of the same name; only system options valid for jobs may be set. If an exception is thrown due to an option error, all other options will still be set.
name | the name of the job to set options on |
hash | option-value pairs |
JOB-ERROR | no job with the given name is active |
JOB-OPTION-ERROR | invalid option |
AUTHORIZATION-ERROR | this exception is thrown when Role Based Access Control is enabled and the user does not have sufficient privileges for the operation |
JOB-ACCESS-ERROR | the user does not have the right to access the given job (for more information, see Interface Groups) |
string omq.system.job.set-options-id | ( | softint | id, |
hash | hash | ||
) |
Sets the options given in the hash on the given job; the job must be active or an exception is raised.
Options set override the system options of the same name; only system options valid for jobs may be set. If an exception is thrown due to an option error, all other options will still be set.
id | the ID of the job to set options on |
hash | option-value pairs |
JOB-ERROR | no job with the given name is active |
JOB-OPTION-ERROR | invalid option |
AUTHORIZATION-ERROR | this exception is thrown when Role Based Access Control is enabled and the user does not have sufficient privileges for the operation |
JOB-ACCESS-ERROR | the user does not have the right to access the given job (for more information, see Interface Groups) |
any omq.system.list-all-services | ( | *date | date | ) |
returns a list of all services currently loaded or a constant string if the services have not been updated since the optional date argument
date | an optional date argument; if given and the service cache has not been updated since the date, a constant string is returned instead of a list of services |
type:
"user"
or "system"
name:
the name of the serviceversion:
version of the servicedesc:
description of the servicelog:
log file pathserviceid:
service IDstatus:
OMQ::SSRunning or OMQ::SSLoadedthreads:
number of running threads in the serviceautostart:
True of False if the autostart flag is setloaded:
date/time the service was loadedmethods:
list of hashes for each method with name
and desc
keys for each methodresources:
a hash of resources attached to the service (may be NOTHING); each hash key is the unique resource name, and the value of each key is a hash with the following keys:type:
a string giving the resource type name (ie "HttpGlobalHandler"
, "HttpListener"
, "FtpListener"
, etc)desc:
a hashdecl description of the resourceinfo:
a hash with additional, free-form information about the resourcegroups:
a list of zero or more strings giving interface group names the service is a member of"log"
key to the return hash list omq.system.list-services | ( | ) |
returns a list of all system services currently loaded
type:
"system"
name:
the name of the serviceversion:
version of the servicedesc:
description of the servicelog:
log file pathserviceid:
service IDstatus:
OMQ::SSRunning or OMQ::SSLoadedthreads:
number of running threads in the serviceautostart:
True of False if the autostart flag is setloaded:
date/time the service was loadedmethods:
list of hashes for each method with name
and desc
keysresources:
a hash of resources attached to the service (may be NOTHING); each hash key is the unique resource name, and the value of each key is a hash with the following keys:type:
a string giving the resource type name (ie "HttpGlobalHandler"
, "HttpListener"
, "FtpListener"
, etc)desc:
a hashdecl description of the resourceinfo:
a hash with additional, free-form information about the resource"log"
key to the return hash list omq.system.order-notes | ( | softstring | wfiid, |
*softint | count | ||
) |
Gets Order Instance Notes.
wfiid | the workflow instance id |
count | an optional limit-count of returned notes |
WORKFLOW-ACCESS-ERROR | this is exception is thrown when Role Based Access Control is enabled and the user does not have the right to access the given workflow (for more information, see Interface Groups) |
string omq.system.passwd | ( | softstring | oldpwd, |
softstring | newpwd | ||
) |
string omq.system.ping | ( | ) |
nothing omq.system.post-event | ( | softstring | eventtype, |
softstring | eventkey | ||
) |
Posts a workflow synchronization event with the event type name and key value.
Note that this API is not checked against the Interface Groups membership of the caller, because a synchronization event could be accessed by multiple workflows.
eventtype | the event type name |
eventkey | the event key in the event type queue to post |
UNKNOWN-EVENT | unknown event type name |
AUTHORIZATION-ERROR | this exception is thrown when Role Based Access Control is enabled and the user does not have sufficient privileges for the operation |
hash omq.system.reload-errors | ( | ) |
reloads all error definitions from the DB
global:
gives the number of global error definitions loadedworkflow:
gives the number of all workflow-specific error definitions loadedAUTHORIZATION-ERROR | this exception is thrown when Role Based Access Control is enabled and the user does not have sufficient privileges for the operation |
string omq.system.reload-rbac | ( | ) |
Reloads the all RBAC information (users, permissions, roles, groups) from the system schema.
Useful for updating Qorus after updating RBAC information with the offline user-tool program
AUTHORIZATION-ERROR | this exception is thrown when Role Based Access Control is enabled and the user does not have sufficient privileges for the operation |
string omq.system.replace-dynamic-data | ( | softstring | wfiid, |
*hash | data | ||
) |
Replaces the dynamic data for the given workflow order data instance.
This API call should be used with care as erroneous changes to workflow order data instances can render further workflow processing impossible. If the workflow order data instance ID is not valid then an exception is thrown.
wfiid | the workflow order data instance id |
data | the dynamic data to replace |
AUTHORIZATION-ERROR | this exception is thrown when Role Based Access Control is enabled and the user does not have sufficient privileges for the operation |
WORKFLOW-ACCESS-ERROR | this is exception is thrown when Role Based Access Control is enabled and the user does not have the right to access the given workflow (for more information, see Interface Groups) |
string omq.system.replace-static-data | ( | softstring | wfiid, |
*hash | data | ||
) |
Replaces the static data for the given workflow order data instance.
This API call should be used with care as erroneous changes to workflow order data instances can render further workflow processing impossible. If the workflow order data instance ID is not valid then an exception is thrown
wfiid | the workflow order data instance id |
data | the static data to replace |
AUTHORIZATION-ERROR | this exception is thrown when Role Based Access Control is enabled and the user does not have sufficient privileges for the operation |
WORKFLOW-ACCESS-ERROR | this is exception is thrown when Role Based Access Control is enabled and the user does not have the right to access the given workflow (for more information, see Interface Groups) |
string omq.system.reprioritize-order | ( | softint | wfiid, |
softint | priority | ||
) |
changes the priority for an existing workflow order data instance
The workflow order data must not have status OMQ::StatComplete
wfiid | the workflow order instance ID |
priority | the new order priority from 0 - 999; priority 0 is the highest; 999 is the lowest |
"OK"
INVALID-WORKFLOW-INSTANCE | invalid workflow instance ID |
SESSION-ERROR | cannot reschedule workflow data owned by a foreign session |
WORKFLOW-STATUS-ERROR | workflows with status OMQ::StatComplete cannot have their priority changed |
AUTHORIZATION-ERROR | this exception is thrown when Role Based Access Control is enabled and the user does not have sufficient privileges for the operation |
WORKFLOW-ACCESS-ERROR | this is exception is thrown when Role Based Access Control is enabled and the user does not have the right to access the given workflow (for more information, see Interface Groups) |
hash omq.system.reprioritize-orders | ( | hash | ih | ) |
changes the priority for a list of workflow order data instances
The workflow order data must not have status OMQ::StatComplete
ih | a hash where the keys are workflow_instanceids to process and the value is an integer giving the new order priority from 0 - 999; priority 0 is the highest; 999 is the lowest |
"OK"
AUTHORIZATION-ERROR | this exception is thrown when Role Based Access Control is enabled and the user does not have sufficient privileges for the operation |
string omq.system.reschedule-order | ( | softint | wfiid, |
*softdate | scheduled | ||
) |
sets or removes the scheduled date for a workflow order data instance
Sets or removes the scheduled date for a workflow order data instance, which means that the workflow order data will not be processed before the scheduled date and time.
The workflow order data must normally have status OMQ::StatReady or OMQ::StatScheduled to be rescheduled, however also workflows with OMQ::StatCanceled and OMQ::StatBlocked statuses can be rescheduled if their original status is OMQ::StatReady or OMQ::StatScheduled.
wfiid | the workflow order instance ID |
scheduled | the scheduled date or NOTHING to clear the scheduled date |
"OK"
INVALID-WORKFLOW-INSTANCE | invalid workflow instance ID |
SESSION-ERROR | cannot reschedule workflow data owned by a foreign session |
WORKFLOW-STATUS-ERROR | only workflows with status OMQ::StatReady or OMQ::StatScheduled or blocked or canceled workflows with original status OMQ::StatReady or OMQ::StatScheduled can be rescheduled |
RESCHEDULE-ERROR | reschedule failed because workflow order data started processing while the request was being processed |
AUTHORIZATION-ERROR | this exception is thrown when Role Based Access Control is enabled and the user does not have sufficient privileges for the operation |
WORKFLOW-ACCESS-ERROR | this is exception is thrown when Role Based Access Control is enabled and the user does not have the right to access the given workflow (for more information, see Interface Groups) |
hash omq.system.reschedule-orders | ( | hash | ih | ) |
sets or removes the scheduled date for a list of workflow order data instances
Sets or removes the scheduled date for a list of workflow order data instance, which means that the workflow order data will not be processed before the scheduled date and time if the scheduled date is set. If the scheduled date is cleared, it means that the order can be processed at any time.
The workflow order data must normally have status OMQ::StatReady or OMQ::StatScheduled to be rescheduled, however also workflows with OMQ::StatCanceled and OMQ::StatBlocked statuses can be rescheduled if their original status is OMQ::StatReady or OMQ::StatScheduled.
ih | a hash where the keys are workflow_instanceids to process and the value is either a scheduled date or NOTHING , indicating that the scheduled date should be cleared from the order |
"OK"
AUTHORIZATION-ERROR | this exception is thrown when Role Based Access Control is enabled and the user does not have sufficient privileges for the operation |
list omq.system.reset-all-services | ( | ) |
unloads all services currently loaded in memory and reloads them from the database
If the calling user has restricted access to user services, only services visible by the current user are reset.
type:
either "system"
or "user"
name:
name of the servicestring omq.system.reset-all-workflows | ( | ) |
Deletes the configuration for all workflows from the workflow configuration cache.
If there are any running workflow execution instances then the reset will cause the workflow to be reloaded from the database on their next iteration.
If RBAC is enabled and the calling user does not have access to all workflows, then only the workflows that the user has access to will have their configurations removed from the workflow cache.
AUTHORIZATION-ERROR | this exception is thrown when Role Based Access Control is enabled and the user does not have sufficient privileges for the operation |
bool omq.system.reset-service | ( | string | name, |
bool | load = False |
||
) |
unloads a single system service and reloads it from the database
name | the name of the system service to reset |
load | if True then the service will be loaded and initialized if it was not already loaded |
list omq.system.reset-services | ( | ) |
unloads all system services currently loaded in memory and reloads them from the database
type:
always "system"
with this callname:
name of the servicestring omq.system.reset-workflow | ( | string | name, |
*string | version | ||
) |
Deletes the configuration for the specified workflow from the cache.
If there are any running instances of the affected workflow(s) then the reset will cause the workflow to be reloaded from the database on their next iteration.
name | the name of the workflow to reset |
version | the version of the workflow to reset; if no version string is passed, then all versions of the specified workflow are purged from the workflow cache. |
AUTHORIZATION-ERROR | this exception is thrown when Role Based Access Control is enabled and the user does not have sufficient privileges for the operation |
WORKFLOW-ACCESS-ERROR | this is exception is thrown when Role Based Access Control is enabled and the user does not have the right to access the given workflow (for more information, see Interface Groups) |
hash omq.system.retry-workflow-instance | ( | softstring | wfiid | ) |
retries the given workflow order instance
In order to make a retry; the workflow order status must be OMQ::StatError, OMQ::StatAsyncWaiting, or OMQ::StatRetry
wfiid | the workflow_instanceid to retry |
steps_updated:
(deprecated) always 0 in this version of Qorussegments_updated:
the number of segments updatedworkflow_updated:
always True in this version of Qorusworkflow_status:
always OMQ::StatRetry in this version of Qoruscached:
True if the workflow data is currently cachedSTATUS-ERROR | workflow data does not have OMQ::StatError, OMQ::StatAsyncWaiting, or OMQ::StatRetry status |
SESSION-ERROR | cannot change status for workflow data managed by another Qorus instance (foreign session ID) |
RETRY-ERROR | invalid workflow instance ID |
AUTHORIZATION-ERROR | this exception is thrown when Role Based Access Control is enabled and the user does not have sufficient privileges for the operation |
WORKFLOW-ACCESS-ERROR | this is exception is thrown when Role Based Access Control is enabled and the user does not have the right to access the given workflow (for more information, see Interface Groups) |
hash omq.system.retry-workflow-instances | ( | softlist | l | ) |
retries the given workflow order instances
In order to make a retry; the workflow order status must be OMQ::StatError, OMQ::StatAsyncWaiting, or OMQ::StatRetry
l | a list of workflow_instanceids to retry |
steps_updated:
(deprecated) always 0 in this version of Qorussegments_updated:
the number of segments updatedworkflow_updated:
always True in this version of Qorusworkflow_status:
always OMQ::StatRetry in this version of Qoruscached:
True if the workflow data is currently cachedAUTHORIZATION-ERROR | this exception is thrown when Role Based Access Control is enabled and the user does not have sufficient privileges for the operation |
WORKFLOW-ACCESS-ERROR | this is exception is thrown when Role Based Access Control is enabled and the user does not have the right to access the given workflow (for more information, see Interface Groups) |
string omq.system.rotate-log-files | ( | ) |
Rotates all system log files.
The number of old log files kept is controlled by system option qorus.max-log-files
AUTHORIZATION-ERROR | this exception is thrown when Role Based Access Control is enabled and the user does not have sufficient privileges for the operation |
hash omq.system.runtime-properties | ( | ) |
hash omq.system.schema.refresh-snapshots | ( | ) |
Refresh helper database snapshots.
AUTHORIZATION-ERROR | this exception is thrown when Role Based Access Control is enabled and the user does not have sufficient privileges for the operation |
*hash omq.system.search-errors | ( | softlist | l | ) |
searches for error definitions at all levels for the given error(s)
l | one or more error strings to search for |
global:
an optional hash giving the global error definition (if any)workflow:
an optional hash of workflow IDs where each value is an error definitionany omq.system.service.[servicename].[method] | ( | ) |
calls a system service method and returns the result
The service is loaded and started if necessary
SERVICE-ERROR | invalid method call; missing method name |
AUTHORIZATION-ERROR | this exception is thrown when Role Based Access Control is enabled and the user does not have sufficient privileges for the operation |
string omq.system.set-option | ( | hash | params | ) |
sets one or more system options
if any errors occur, an exception is thrown with error information, but all other options will be processed and set
params | key-value pairs where the key names are system option names |
OPTION-ERROR | invalid or locked option |
AUTHORIZATION-ERROR | this exception is thrown when Role Based Access Control is enabled and the user does not have sufficient privileges for the operation |
nothing omq.system.set-order-info | ( | softstring | wfiid, |
hash | h | ||
) |
Sets or clears additional info for the given workflow order data instance.
If a key is present in the hash, but has no value, then the associated value is cleared; no change is made for keys not present in the hash
wfiid | the workflow instance id |
h | a hash with the following keys:
|
AUTHORIZATION-ERROR | this exception is thrown when Role Based Access Control is enabled and the user does not have sufficient privileges for the operation |
WORKFLOW-ACCESS-ERROR | this is exception is thrown when Role Based Access Control is enabled and the user does not have the right to access the given workflow (for more information, see Interface Groups) |
nothing omq.system.set-order-note | ( | softstring | wfiid, |
string | notestr | ||
) |
Add new Order Instance Notes.
Some additional information are attached automatically - username, date of creation etc.
wfiid | the workflow_instanceid of the workflow order to update |
notestr | string, a text note |
AUTHORIZATION-ERROR | this exception is thrown when Role Based Access Control is enabled and the user does not have sufficient privileges for the operation |
WORKFLOW-ACCESS-ERROR | this is exception is thrown when Role Based Access Control is enabled and the user does not have the right to access the given workflow (for more information, see Interface Groups) |
string omq.system.set-service-autostart | ( | string | name, |
softstring | stat | ||
) |
Sets the autostart status of the given system service.
name | the name of the system service |
stat | the autostart status for the service (parsed with parse_boolean()) |
AUTHORIZATION-ERROR | this exception is thrown when Role Based Access Control is enabled and the user does not have sufficient privileges for the operation |
string omq.system.set-service-options | ( | hash< auto > | c, |
string | name, | ||
hash | hash | ||
) |
Sets the options given in the hash on the given service.
Options set override the system options of the same name. Only system options valid for services may be set. The service is loaded and initialized if not already loaded. If an exception is thrown due to an option error, all other options will still be set.
name | the name of the system service to set options on |
hash | option-value pairs |
SERVICE-ERROR | the given service cannot be loaded (unknown or error initializing the service) |
SERVICE-OPTION-ERROR | invalid option |
AUTHORIZATION-ERROR | this exception is thrown when Role Based Access Control is enabled and the user does not have sufficient privileges for the operation |
SERVICE-ACCESS-ERROR | this is exception is thrown when Role Based Access Control is enabled and the user does not have the right to access the given service (for more information, see Interface Groups) |
hash omq.system.set-workflow-instance-error | ( | softint | wfiid | ) |
Changes a workflow order data instance's status to OMQ::StatError, as long as the starting status is OMQ::StatRetry, OMQ::StatCanceled, OMQ::StatBlocked, or OMQ::StatAsyncWaiting.
If the status is any other status, an exception will be thrown. To set a workflow order data instance with a OMQ::StatWaiting status to OMQ::StatError, set the child workflows to OMQ::StatError first and the parent workflow's status will be updated automatically. When setting a workflow order from OMQ::StatCanceled to OMQ::StatError, outstanding events will be queued and the associated queued event keys will be present in the return value.
wfiid | the workflow order data instance ID |
steps_updated:
number of steps updatedsegments_updated:
number of segments updatedworkflow_status:
always OMQ::StatErrorold_status:
the old workflow data statusqueued_detached_segments:
number of detached segment events queuedqueued_subworkflows:
number of subworkflow events queuedqueued_async_messages:
number of async events queuedqueued_sync_events:
number of workflow synchronization events queuedqueued_async_retries:
number of async events queuedqueued_retries:
number of retry events queuedqueued_fixed_retries:
number of retry events with a fixed retry time queuedAUTHORIZATION-ERROR | this exception is thrown when Role Based Access Control is enabled and the user does not have sufficient privileges for the operation |
WORKFLOW-ACCESS-ERROR | this is exception is thrown when Role Based Access Control is enabled and the user does not have the right to access the given workflow (for more information, see Interface Groups) |
hash omq.system.set-workflow-instances-error | ( | softlist | l | ) |
Changes a list of workflow order data instances' statuses to OMQ::StatError, as long as the starting status is OMQ::StatRetry, OMQ::StatCanceled, OMQ::StatBlocked, or OMQ::StatAsyncWaiting.
If the status is any other status, an exception will be thrown. To set a workflow order data instance with a OMQ::StatWaiting status to OMQ::StatError, set the child workflows to OMQ::StatError first and the parent workflow's status will be updated automatically. When setting a workflow order from OMQ::StatCanceled to OMQ::StatError, outstanding events will be queued and the associated queued event keys will be present in the return value.
l | a list of workflow order data instance IDs to set to OMQ::StatError |
steps_updated:
number of steps updatedsegments_updated:
number of segments updatedworkflow_status:
always OMQ::StatErrorold_status:
the old workflow data statusqueued_detached_segments:
number of detached segment events queuedqueued_subworkflows:
number of subworkflow events queuedqueued_async_messages:
number of async events queuedqueued_sync_events:
number of workflow synchronization events queuedqueued_async_retries:
number of async events queuedqueued_retries:
number of retry events queuedqueued_fixed_retries:
number of retry events with a fixed retry time queued AUTHORIZATION-ERROR | this exception is thrown when Role Based Access Control is enabled and the user does not have sufficient privileges for the operation |
WORKFLOW-ACCESS-ERROR | this is exception is thrown when Role Based Access Control is enabled and the user does not have the right to access the given workflow (for more information, see Interface Groups) |
string omq.system.set-workflow-option | ( | softint | id, |
hash | hash | ||
) |
Sets the options given in the hash on the running workflow identified by the execution ID passed.
If the workflow has an option list and any of the options are not valid for that workflow, an exception will be thrown, however, even if an exception is thrown due to an option error, all other options will still be set.
id | the workflow execution ID to set options on |
hash | option-value pairs |
INVALID-WORKFLOW-EXECUTION-ID | invalid workflow execution ID |
WORKFLOW-OPTION-ERROR | invalid option for workflow or option cannot be overridden at the workflow level |
AUTHORIZATION-ERROR | this exception is thrown when Role Based Access Control is enabled and the user does not have sufficient privileges for the operation |
WORKFLOW-ACCESS-ERROR | this is exception is thrown when Role Based Access Control is enabled and the user does not have the right to access the given workflow (for more information, see Interface Groups) |
list omq.system.show-workflow-cache | ( | ) |
returns a list of the workflows currently cached
name:
(string) the name of the workflowversion:
(string) the version of the workflowworkflowid:
(int) the workflow ID of the workflowcached:
(date) the date and time the workflow was cachedstring omq.system.shutdown | ( | ) |
initiates the system shutdown process
This API will start the asynchronous shutdown process in the Qorus system. The response indicates only that the shutdown process has begun, and not that the system has been fully shut down. Check the log file or the process list (‘ps –ef') to verify that the system has completely stopped.
SHUTDOWN-ALREADY-IN-PROGRESS | system shutdown is already in progress |
AUTHORIZATION-ERROR | this exception is thrown when Role Based Access Control is enabled and the user does not have sufficient privileges for the operation |
string omq.system.shutdown-wait | ( | ) |
shuts down the system; returns when the system shutdown process is complete
AUTHORIZATION-ERROR | this exception is thrown when Role Based Access Control is enabled and the user does not have sufficient privileges for the operation |
nothing omq.system.skip-step | ( | softstring | wfiid, |
softstring | stepid, | ||
softint | ind = 0 |
||
) |
Skips execution of a step in a workflow.
Sometimes, for reasons outside of a workflow's control, execution for a given step must be skipped, but the rest of the workflow's logic should be executed. This call allows Qorus to continue executing a workflow order data instance after skipping the given step. Only steps with OMQ::StatError, OMQ::StatRetry, OMQ::StatEventWaiting, or OMQ::StatAsyncWaiting can be skipped. Subworkflow steps with any status cannot be skipped; the child workflow must be corrected instead.
Note that this method will also queue internal events for asynchronous steps, and will trigger a retry of the workflow for all other steps to ensure that the workflow is immediately reprocessed.
If several steps should be retried, use omq.system.skip-step-without-retry() on every step except the last one to be retried, as this function will trigger a retry of the entire workflow order data instance.
wfiid | the workflow order data instance ID |
stepid | the step ID |
ind | the step index for array steps |
SKIP-STEP-ERROR | step is a subworkflow step; step has not been executed in the given workflow order instance; the given workflow instance ID does not exist |
STEP-STATUS-ERROR | step status does not allow it to be skipped (ex: IN-PROGRESS, COMPLETE) |
SESSION-ERROR | workflow order instance belongs to another Qorus session |
AUTHORIZATION-ERROR | this exception is thrown when Role Based Access Control is enabled and the user does not have sufficient privileges for the operation |
WORKFLOW-ACCESS-ERROR | this is exception is thrown when Role Based Access Control is enabled and the user does not have the right to access the given workflow (for more information, see Interface Groups) |
nothing omq.system.skip-step-without-retry | ( | softint | wfiid, |
softint | stepid, | ||
softint | ind = 0 |
||
) |
Skips execution of a step in a workflow without initiating an immediate retry.
Sometimes, for reasons outside of a workflow's control, execution for a given step must be skipped, but the rest of the workflow's logic should be executed. This call allows Qorus to continue executing a workflow order data instance after skipping the given step. Only steps with OMQ::StatError, OMQ::StatRetry, OMQ::StatEventWaiting, or OMQ::StatAsyncWaiting can be skipped. Subworkflow steps with any status cannot be skipped; the child workflow must be corrected instead.
Note that this method will also queue internal events for asynchronous steps.
If several steps should be retried, execute this method on every step except the last one to be retried, as this function will trigger a retry of the entire workflow order data instance. Execute omq.system.skip-step() on the final step to also trigger a retry of the workflow order data after the skipo is marked to be skipped.
wfiid | the workflow order data instance ID |
stepid | the step ID |
ind | the step index for array steps |
SKIP-STEP-ERROR | step is a subworkflow step; step has not been executed in the given workflow order instance; the given workflow instance ID does not exist |
STEP-STATUS-ERROR | step status does not allow it to be skipped (ex: IN-PROGRESS, COMPLETE) |
SESSION-ERROR | workflow order instance belongs to another Qorus session |
AUTHORIZATION-ERROR | this exception is thrown when Role Based Access Control is enabled and the user does not have sufficient privileges for the operation |
WORKFLOW-ACCESS-ERROR | this is exception is thrown when Role Based Access Control is enabled and the user does not have the right to access the given workflow (for more information, see Interface Groups) |
list omq.system.start-listeners | ( | softstring | bind, |
*string | cert_file, | ||
*string | key_file | ||
) |
starts a new HTTP listener; listeners will be started on all possible bind addresses in case more than one interface is resolved from the bind address given
bind | the bind address of the new listener; listeners will be started on all possible bind addresses in case more than one interface is resolved from the bind address given |
cert_file | the file name of the X.509 certificate in PEM format (only for HTTPS listeners) |
key_file | the file name of the private key for the X.509 certificate in PEM format (only for HTTPS listeners) |
hostname
, hostname_desc
, and port
keys will not be present):hostname:
the hostname of the interfacehostname_desc:
a descriptive string for the hostname including the address family (ex: "ipv6[localhost]"
)address:
the address of the listener (i.e. "192.168.30.4"
, etc)address_desc:
a descriptive string for the hostname including the address family (ex: "ipv6[::1]"
)port:
the port numberfamily:
an integer giving the address family (AF_INET
, AF_INET6
, AF_UNIX
, etc)familystr:
a string describing the address family (ex: "ipv6"
)proto:
either "http"
or "https"
id:
the Qorus ID of the listenerbind:
a string giving the bind address used (ex: "127.0.0.1:8001"
)hash omq.system.start-workflow | ( | hash | params | ) |
Starts a workflow execution instance with the designated name and version.
If any errors occur, an exception is thrown.
params | a hash with the following keys:
|
id:
(int) the execution ID of the workflow execution instanceversion:
(string) the version of the workflow started (useful if no version key supplied in the call)PARAMETER-ERROR | invalid workflow, mode, or options key in incorrect format (not a hash) |
SHUTDOWN-IN-PROGRESS | cannot start new workflows because the system is shutting down |
AUTHORIZATION-ERROR | this exception is thrown when Role Based Access Control is enabled and the user does not have sufficient privileges for the operation |
WORKFLOW-ACCESS-ERROR | this is exception is thrown when Role Based Access Control is enabled and the user does not have the right to access the given workflow (for more information, see Interface Groups) |
hash omq.system.start-workflows | ( | hash | params | ) |
Starts one or more workflow execution instances with the designated name and version.
If any errors occur, an exception is thrown
params | a hash with the following keys:
|
id:
(list of int) the execution IDs of the workflow execution instances startedversion:
(string) the version of the workflows started (useful if no version key supplied in the call)PARAMETER-ERROR | invalid workflow, mode, options key in incorrect format (not a hash), or invalid number of instances |
SHUTDOWN-IN-PROGRESS | cannot start new workflows because the system is shutting down |
AUTHORIZATION-ERROR | this exception is thrown when Role Based Access Control is enabled and the user does not have sufficient privileges for the operation |
WORKFLOW-ACCESS-ERROR | this is exception is thrown when Role Based Access Control is enabled and the user does not have the right to access the given workflow (for more information, see Interface Groups) |
string omq.system.stop-all-workflows | ( | ) |
stops all running workflows
On errors, an exception is thrown
AUTHORIZATION-ERROR | this exception is thrown when Role Based Access Control is enabled and the user does not have sufficient privileges for the operation |
"ostop -a"
command (ostop) provides a user-friendly command-line interface to this method nothing omq.system.stop-listener | ( | softstring | name | ) |
stops the listener from the bind address
name | the name or bind address of the listener to stop |
INVALID-LISTENER-ERROR | invalid name or bind address, cannot stop last listener |
nothing omq.system.stop-listener-id | ( | softint | id | ) |
stops the listener from listener ID
id | the ID listener to stop |
INVALID-LISTENER-ERROR | invalid listener ID, cannot stop last listener |
string omq.system.stop-workflow | ( | string | name, |
*string | version | ||
) |
stops all instances of the given workflow
On errors, an exception is thrown
name | the name of the workflow to stop |
version | the optional version of the workflow to stop; if this parameter is not passed, then all versions of the given workflow are stopped |
PARAMETER-ERROR | no instances of the given workflow are running |
AUTHORIZATION-ERROR | this exception is thrown when Role Based Access Control is enabled and the user does not have sufficient privileges for the operation |
WORKFLOW-ACCESS-ERROR | this is exception is thrown when Role Based Access Control is enabled and the user does not have the right to access the given workflow (for more information, see Interface Groups) |
string omq.system.stop-workflow-instance | ( | softint | id | ) |
stops the given workflow execution instance given its ID
On errors, an exception is thrown
id | the execution instance ID of the workflow execution instance to stop |
INVALID-WORKFLOW-EXECUTION-ID | invalid workflow execution ID |
AUTHORIZATION-ERROR | this exception is thrown when Role Based Access Control is enabled and the user does not have sufficient privileges for the operation |
WORKFLOW-ACCESS-ERROR | this is exception is thrown when Role Based Access Control is enabled and the user does not have the right to access the given workflow (for more information, see Interface Groups) |
STOP-ERROR | workflow is already stopping; cannot stop workflow if called from within the workflow to be stopped |
hash omq.system.submit-data.[workflow].[version] | ( | hash | params, |
string | status = OMQ::StatReady |
||
) |
create workflow order (workflow order data instance)
Creates a workflow order data instance of the specified type with the data passed as the static order data.
params | The hash passed must have at either a staticdata key or an external_order_instanceid key, valid keys:
|
status | create the workflow order data instance with this status; may be either:
|
workflow_instanceid
the workflow instance ID of the workflow order instance ID createdSUBMIT-ORDER-ERROR | unknown workflow, invalid status |
AUTHORIZATION-ERROR | this exception is thrown when Role Based Access Control is enabled and the user does not have sufficient privileges for the operation |
WORKFLOW-ACCESS-ERROR | this is exception is thrown when Role Based Access Control is enabled and the user does not have the right to access the given workflow (for more information, see Interface Groups) |
string omq.system.update-current-user | ( | hash | hash | ) |
Modifies the current user in the database and in the RBAC cache.
hash | a hash giving the information to update, valid keys are as follows:
|
hash
UPDATE-USER-ERROR | no authentication information supplied in call |
RBAC-UPDATE-USER-ERROR | no valid keys in hash, invalid permission, invalid group |
AUTHORIZATION-ERROR | this exception is thrown when Role Based Access Control is enabled and the user does not have sufficient privileges for the operation |
string omq.system.update-global-error | ( | hash | eh | ) |
creates or updates a global error
Error definitions are committed internally and also to the database in this method (i.e. all changes are persistent)
eh | an error hash with the following keys:
|
"UPDATED-GLOBAL"
: the existing global error was updated"CREATED-GLOBAL"
: a new global error was created"UNCHANGED-GLOBAL"
: the new definition is identical to the old definitionAUTHORIZATION-ERROR | this exception is thrown when Role Based Access Control is enabled and the user does not have sufficient privileges for the operation |
ERROR-UPDATE-ERROR | when the arguments are invalid |
string omq.system.update-permission | ( | string | permission, |
string | desc | ||
) |
Modifies the description for an existing user permission in the database and in the RBAC cache.
System permissions may not be updated; only user permissions may be updated.
permission | the permission to update |
desc | the new description of the permission |
RBAC-UPDATE-PERMISSION-ERROR | invalid permission |
AUTHORIZATION-ERROR | this exception is thrown when Role Based Access Control is enabled and the user does not have sufficient privileges for the operation |
string omq.system.update-role | ( | string | name, |
hash | h | ||
) |
Modifies an existing role in the database and in the RBAC cache.
name | the role to update |
h | a hash giving the information to update, valid keys are as follows:
|
RBAC-UPDATE-ROLE-ERROR | invalid role, no valid keys in hash, invalid permission, invalid group |
AUTHORIZATION-ERROR | this exception is thrown when Role Based Access Control is enabled and the user does not have sufficient privileges for the operation |
string omq.system.update-user | ( | string | user, |
hash | hash | ||
) |
Modifies an existing user in the database and in the RBAC cache.
user | the username to update |
hash | a hash giving the information to update, valid keys are as follows:
|
RBAC-UPDATE-USER-ERROR | invalid user, no valid keys in hash, invalid role |
AUTHORIZATION-ERROR | this exception is thrown when Role Based Access Control is enabled and the user does not have sufficient privileges for the operation |
string omq.system.update-workflow-error | ( | softint | wfid, |
hash | eh, | ||
*bool | forceworkflow | ||
) |
creates or updates a workflow-specific error definition
Error definitions are committed internally and also to the database in this method (i.e. all changes are persistent)
wfid | the workflow ID of the workflow to update |
eh | an error hash with the following keys:
|
forceworkflow | if True then error processing will only be made on the workflow level regardless of any global error of the same name |
"UPDATED-WORKFLOW"
: the existing workflow-specific error was updated"CREATED-WORKFLOW"
: a new workflow-specific error definition was created"UNCHANGED-WORKFLOW"
: the new workflow-specific definition is identical to the old definition"CREATED-GLOBAL"
: a new global error was created"UNCHANGED-GLOBAL"
: the new global definition is identical to the old definitionAUTHORIZATION-ERROR | this exception is thrown when Role Based Access Control is enabled and the user does not have sufficient privileges for the operation |
WORKFLOW-ACCESS-ERROR | this is exception is thrown when Role Based Access Control is enabled and the user does not have the right to access the given workflow (for more information, see Interface Groups) |
ERROR-UPDATE-ERROR | when the arguments are invalid |
hash< auto > omq.system.wait-for-events | ( | hash< auto > | cx, |
softint | min_id, | ||
*timeout | timeout_ms | ||
) |
Returns a hash giving the list of the new events and the last event ID generated by the system.
A required argument must be supplied giving the minimum event ID to return; an optional argument may be passed giving a timeout in milliseconds to wait for new events. This API is suitable for unconditional event polling.
min_id | the minimum event ID to return; events will only be returned with an event ID at least as large as this value |
timeout_ms | a optional timeout in milliseconds; if this value is not present or zero then the function returns immediately |
lastid:
the highest existing event ID in the system at the time the results were returnedevents:
a list of event hashes; this key will not be present if there are no events availableshutdown:
if this key is returned, it means the system is shutting downinfo
hash value in the event hashint omq.system.wait-for-events-or | ( | ) |
string omq.user.delete-service | ( | string | name, |
*string | version | ||
) |
Unloads the named user service from the system.
If the service is running, it is first stopped. Additionally, any outstanding method calls must return before the service can be unloaded.
name | the name of the user service to unload |
version | the version of the service to unload; normally this parameter should not be given; only one version of a service can be loaded at a time and giving the wrong version string will cause an exception to be thrown |
AUTHORIZATION-ERROR | this exception is thrown when Role Based Access Control is enabled and the user does not have sufficient privileges for the operation |
SERVICE-ACCESS-ERROR | this is exception is thrown when Role Based Access Control is enabled and the user does not have the right to access the given service (for more information, see Interface Groups) |
SERVICE-NOT-LOADED | this exception is thrown when the service is not loaded |
bool omq.user.get-service-autostart | ( | string | name | ) |
returns the autostart status of the given user service
name | the name of the user service |
SERVICE-ACCESS-ERROR | this is exception is thrown when Role Based Access Control is enabled and the user does not have the right to access the given service (for more information, see Interface Groups) |
any omq.user.get-service-options | ( | string | name | ) |
Returns options set on the given unsert service; the service must be already loaded or an exception is raised.
If no arguments are passed, then all options are returned, otherwise only the values for the given options are returned. If the given option is not overridden on the service level, then the value of the system option is returned. If the service is not already loaded is not valid, then an exception is raised
name | the service name |
SERVICE-ERROR | the given service is not loaded |
SERVICE-ACCESS-ERROR | this is exception is thrown when Role Based Access Control is enabled and the user does not have the right to access the given workflow (for more information, see Interface Groups) |
list omq.user.list-services | ( | ) |
returns a list of all user services currently loaded
type:
"user"
name:
the name of the serviceversion:
version of the servicedesc:
description of the servicelog:
log file pathserviceid:
service IDstatus:
OMQ::SSRunning or OMQ::SSLoadedthreads:
number of running threads in the serviceautostart:
True of False if the autostart flag is setloaded:
date/time the service was loadedmethods:
list of hashes for each method with name
and desc
keysresources:
a hash of resources attached to the service (may be NOTHING); each hash key is the unique resource name, and the value of each key is a hash with the following keys:type:
a string giving the resource type name (ie "HttpGlobalHandler"
, "HttpListener"
, "FtpListener"
, etc)desc:
a hashdecl description of the resourceinfo:
a hash with additional, free-form information about the resourcegroups:
a list of interface group names that this service is a member of"log"
key to the return hash bool omq.user.reset-service | ( | string | name, |
bool | load = False |
||
) |
unloads a single user service and reloads it from the database
name | the name of the user service to reset |
load | if True then the service will be loaded and initialized if it was not already loaded |
list omq.user.reset-services | ( | ) |
unloads all user services currently loaded in memory and reloads those services from the database
If the calling user has restricted access to user services, only services visible by the current user are reset.
type:
always "user"
with this callname:
name of the serviceany omq.user.service.[servicename].[method] | ( | ) |
calls a user service method and returns the result
The service is loaded and started if necessary
SERVICE-ERROR | invalid method call; missing method name |
AUTHORIZATION-ERROR | this exception is thrown when Role Based Access Control is enabled and the user does not have sufficient privileges for the operation |
SERVICE-ACCESS-ERROR | this is exception is thrown when Role Based Access Control is enabled and the user does not have the right to access the given service (for more information, see Interface Groups) |
string omq.user.set-service-autostart | ( | string | name, |
softstring | stat | ||
) |
Sets the autostart status of the given user service.
name | the name of the user service |
stat | the autostart status for the service (parsed with parse_boolean()) |
AUTHORIZATION-ERROR | this exception is thrown when Role Based Access Control is enabled and the user does not have sufficient privileges for the operation |
SERVICE-ACCESS-ERROR | this is exception is thrown when Role Based Access Control is enabled and the user does not have the right to access the given service (for more information, see Interface Groups) |
string omq.user.set-service-options | ( | string | name, |
hash | hash | ||
) |
Sets the options given in the hash on the given service.
Options set override the user options of the same name. Only system options valid for services may be set. The service is loaded and initialized if not already loaded. If an exception is thrown due to an option error, all other options will still be set.
name | the name of the user service to set options on |
hash | option-value pairs |
SERVICE-ERROR | the given service cannot be loaded (unknown or error initializing the service) |
SERVICE-OPTION-ERROR | invalid option |
AUTHORIZATION-ERROR | this exception is thrown when Role Based Access Control is enabled and the user does not have sufficient privileges for the operation |
SERVICE-ACCESS-ERROR | this is exception is thrown when Role Based Access Control is enabled and the user does not have the right to access the given service (for more information, see Interface Groups) |