Qorus Integration Engine® Enterprise Edition 6.1.0_prod
Loading...
Searching...
No Matches
Service API Reference

Table of Contents

Introduction to the Qorus Service API

Each service's Program container is set up with the following imported objects:

In addition to the above, all public constants in the OMQ namespace are available.

See also

Service Class API

The service class APIs are documented here:

For class-based services, the service's implementation class must inherit Service::QorusService (Qore) or qore.OMQ.UserApi.Service.QorusService (Java) directly. This means that Qore code can call the static methods defined in the base class directly.

For library classes and other service code, calls must be prefixed with the class name (also for all Java code as well).

Service Program Container

Each Qorus service has a single Qore Program object containing all its code for service methods, as well as any library objects imported into the Program object (classes, constants, and functions listed as attributes of the service when the service is defined). Service Program objects are restricted from using elements of the Qore Language related to process and thread control; the use of these functions is either dangerous or could violate the integrity of the Qorus server process and therefore is restricted.

To enforce these restrictions, service Program objects are created with the following sandbox flags:

Directive Constant Description
%allow-weak-references Qore::PO_ALLOW_WEAK_REFERENCES the := operator may be used
%no-process-control Qore::PO_NO_PROCESS_CONTROL Functionality that affects the entire process is unavailable
%no-thread-control Qore::PO_NO_THREAD_CONTROL Thread management functionality is unavailable
%no-top-level Qore::PO_NO_TOP_LEVEL_STATEMENTS No code is allowed in the top-level statement (outside a function or class)
%require-our Qore::PO_REQUIRE_OUR All variables must be declared before use

Please note that despite these restrictions, service program objects have most of the Qore language API and class library available for use.

Furthermore, the following parse defines are defined:

Define Availability Description
Qorus W, S, J Identifies code in Qorus
QorusEE W, S, J Identifies the Enterprise Edition of Qorus (QorusCE is defined in the Community Edition)
QorusHasAlerts W, S, J Marks the availability of the alert API (Qorus 3.0+)
QorusHasHttpUserIndex S Marks the availability of OMQ::AbstractServiceHttpHandler::setUserIndexInfo() (Qorus 3.0+)
QorusHasTableCache W, S, J Marks the availability of the table cache API (Qorus 3.1+)
QorusHasUserConnections W, S, J Marks the availability of the connection API (Qorus 3.0+)
QorusServer W, S, J Identifies code used in Qorus server interfaces
QorusService S Identifies code used in a service Program container
Note
All defines set in qorus.defines (common to workflows, services, and jobs) are also set in service Program containers

Global Variables

Services may declare global variables, but because the %no-top-level parse restriction is set for the Program object; they may not be initialized at the top level of the program.

Initialize them in the init() method instead; global variables may also be declared here if desired. Global variables may be declared anywhere in the Program object; they do not have to be declared at the top level of the service program.

Service API

The following APIs are imported into service program logic containers (see also OMQ::UserApi::Service):

API Method Domain Availability Description
UserApi::auditCheckEventString() Audit W, S, J checks if the given audit event (given as a string) is enabled
UserApi::auditCheckEvent() Audit W, S, J checks if the given audit event (given as an integer code) is enabled
UserApi::auditGetMask() Audit W, S, J returns the audit event mask
UserApi::auditUserEvent() Audit W, S, J creates a user audit event (with audit event code OMQ::AE_USER_EVENT) against the workflow, service, or job instance
UserApi::callNetworkApi() Utility W, S, J calls a system RPC API with system permissions
UserApi::callNetworkApiArgs() Utility W, S, J calls a system RPC API with system permissions with an explicit argument list argument
UserApi::callNetworkApiArgsWithAuthentication() Utility W, S, J calls a system RPC API with authentication information (username and password)
UserApi::callRestApi() Utility W, S, J calls a system REST API with system permissions
UserApi::callRestApiWithAuthentication() Utility W, S, J calls a system REST API with authentication information (username and password)
UserApi::clearSqlTableCache() SQL Cache W, S, J clears a cached table from the SQL cache
UserApi::createOrder() Utility W, S, J creates a workflow order data instance in the database and returns the workflow_instanceid of the order created
UserApi::createRemoteOrder() Utility W, S, J creates a workflow order data instance in a remote Qorus instance and returns the workflow_instanceid of the order created
UserApi::deserializeQorusData() Utility W, S, J deserializes strings to Qore data structures
UserApi::execSynchronousWorkflow() Utility W, S, J executes a workflow order synchronously and returns the result of execution
UserApi::flushSlaEvents() SLA W, S, J flushes all pending SLA events to the DB
UserApi::getActiveJobs() System Info W, S, J returns information about active jobs
ServiceApi::getConfigItemHash() n/a S retrieves a hash of all service configuration items
ServiceApi::getConfigItemValue() n/a S retrieves the value of a service configuration item
UserApi::getDatasourceDedicated() Connections W, S, J returns a dedicated Qore::SQL::Datasource object
UserApi::getDatasourcePool() Connections W, S, J returns a shared Qore::SQL::DatasourcePool object
UserApi::getGlobalConfigItemValue() Qorus System Information API W, S, J returns the value of the global configuration item on global level
ServiceApi::getOption() Options W, S, J returns the value of one or more system or interface options
UserApi::getQorusOptions() Options W, S, J returns the value of system options
UserApi::getQorusOptionsArgs() Options W, S, J returns the value of system options
UserApi::getQorusOptionInfo() Options W, S, J returns information about system options
UserApi::getQorusOptionInfoArgs() Options W, S, J returns information about system options
UserApi::getRemoteRestConnection() Connections W, S, J returns a QorusSystemRestHelper to a remote Qorus instance
UserApi::getRemoteRpcConnection() Connections W, S, J returns a QorusSystemAPIHelper to a remote Qorus instance
UserApi::getRunningWorkflowInfo() System Info W, S, J returns information about a running workflow execution instance
UserApi::getRunningWorkflowList() System Info W, S, J returns information about running workflow execution instances
UserApi::getServiceInfo() System Info W, S, J returns information about a service
UserApi::getSessionId() System Info W, S, J returns the current application session ID
UserApi::getSqlTable() SQL Cache W, S, J retrieves an AbstractTable object from the SQL cache for DML operations
UserApi::getSqlCacheInfo() SQL Cache W, S, J returns information about the SQL cache
UserApi::getSystemInfo() System Info W, S, J returns information about the system
UserApi::getSystemServiceInfo() System Info W, S, J returns information about a system service
UserApi::getUserConnection() Connections W, S, J returns the given user connection object
UserApi::getUserServiceInfo() System Info W, S, J returns information about a user service
UserApi::getValueMap() Value Maps W, S, J retrieves a value mapping from a value map
UserApi::getValueMaps() Value Maps W, S, J retrieves a list of all known value sets
UserApi::logInfo() logging W, S, J outputs a log message in the workflow's log file
UserApi::getNextSequenceValue() Utility W, S, J returns the next value from the given datasource and database sequence
UserApi::postSlaEventError() SLA W, S, J posts an unsuccessful event for SLA and performance tracking
UserApi::postSlaEventSuccess() SLA W, S, J posts a successful event for SLA and performance tracking
UserApi::postSyncEvent() Utility W, S, J posts a workflow synchronization event given the event type name and event key
UserApi::postUserEvent() Utility W, S, J posts an application event of class OMQ::QE_CLASS_USER
UserApi::propGet() System Props W, S, J returns the value of the given system property key in the given domain or NOTHING if the system property does not exist
UserApi::propUpdate() System Props W, S, J changes (inserts, updates, or deletes) the value of one or more system properties
UserApi::qorusGetLocalUrl() System Info W, S, J returns a URL for the current system
UserApi::raiseTransientAlert() Alerts W, S, J raises a transient alert
UserApi::restartTransaction() Utility W, S, J enables recovery from restartable DB communication errors
UserApi::runtimeProperties() System Info W, S, J returns information about runtime system defines defined
UserApi::serializeQorusData() Utility W, S, J serializes Qore data structures to strings
ServiceApi::setOption() Options W, S, J sets option values on a workflow, service, or job
ServiceApi::bindFtp() Service FTP S Binds an FTP handler to the service and starts FTP listeners
ServiceApi::bindHandler() Service HTTP S Binds a new HTTP handler to a dedicated HTTP service listener
ServiceApi::bindHttp() Service HTTP S Binds an HTTP handler to the service
ServiceApi::callApiAsCurrentUser() Service System S Calls a system RPC API as the current external user (if any) and returns the result
ServiceApi::checkAuthorization() Service RBAC S checks the current user for all given permissions and throws an exception if not
ServiceApi::checkAuthorizationOr() Service RBAC S checks the current user for any of the given permissions and throws an exception if not
ServiceApi::checkJobAccess() Service RBAC S Checks if the current user can access all the given jobs and throws an exception if not
ServiceApi::checkJobInstanceAccess() Service RBAC S Checks if the current user can access the given job instance and throws an exception if not
ServiceApi::checkMapperAccess() Service RBAC S Checks if the current user can access all the given mappers and throws an exception if not
ServiceApi::checkQueueAccess() Service RBAC S Checks if the current user can access all the given asynchronous queues and throws an exception if not
ServiceApi::checkServiceAccess() Service RBAC S Checks if the current user can access all the given services and throws an exception if not
ServiceApi::checkVmapAccess() Service RBAC S Checks if the current user can access all the given value maps and throws an exception if not
ServiceApi::checkWorkflowAccess() Service RBAC S Checks if the current user can access all the given workflows and throws an exception if not
ServiceApi::checkWorkflowInstanceAccess() Service RBAC S Checks if the current user can access the given workflow order instance and throws an exception if not
UserApi::executeFsm() Utility W, S, J executes a finite state machine registered with the interface and returns the result
ServiceApi::getActiveJobsAsCurrentUser() Service Info S Returns a hash of all active jobs visible to the current external user (if any)
ServiceApi::getCallContext() Service Info S Returns a hash of contextual information about the current service call
ServiceApi::getCallContextString() Service Info S Returns a string describing the context of the current call
ServiceApi::getHttpCallContext() Service HTTP S Returns a hash with info about the external HTTP call, if any
ServiceApi::getJobAccessHash() Service RBAC S Returns a hash of all job IDs accessible by the user, NOTHING if there are no restrictions, or an empty hash if the user can access no jobs
ServiceApi::getJobAccessList() Service RBAC S Returns a list of all job IDs accessible by the user, NOTHING if there are no restrictions, or an empty list if the user can access no jobs
ServiceApi::getLastEvents() Service Events S Returns the last system events corresponding to the arguments
ServiceApi::getLastEventsAnd() Service Events S Returns the last system events that meet all the criteria given
ServiceApi::getLastEventsOr() Service Events S Returns the last system events that meet any of the criteria given
ServiceApi::getMapperAccessHash() Service RBAC S Returns a hash of all mapper IDs accessible by the user, NOTHING if there are no restrictions, or an empty hash if the user can access no mappers
ServiceApi::getMapperAccessList() Service RBAC S Returns a list of all mapper IDs accessible by the user, NOTHING if there are no restrictions, or an empty list if the user can access no mappers
ServiceApi::getResource() Service Resources S returns the requested resource as a hash with HTTP headers and an HTTP response code to be used as the response for an HTTP request handler
ServiceApi::getResourceData() Service Resources S returns the requested resource as its native type
ServiceApi::getResourceHash() Service Resources S returns a hash describing all resources for the service
ServiceApi::getResourceList() Service Resources S returns a list of all resources for the service
ServiceApi::getResourceWsdl() Service Resources S returns the given resource as a WebService object
ServiceApi::getRunningWorkflowListAsCurrentUser() Service Info S Returns a list of running workflows visible to the current external user, if any
ServiceApi::getServiceAccessHash() Service RBAC S Returns a hash of all services IDs accessible by the user, NOTHING if there are no restrictions, or an empty hash if the user can access no services
ServiceApi::getServiceAccessList() Service RBAC S Returns a list of all services IDs accessible by the user, NOTHING if there are no restrictions, or an empty list if the user can access no services
ServiceApi::getServiceInfo() Service Info S Returns a hash of information about the current service
ServiceApi::getServiceInfoAsCurrentUser() Service Info S Returns information about the given service if the current external user, if any, can access it
ServiceApi::getTemplateHash() Service Resources S returns a hash describing all template resources for the service
ServiceApi::getTemplateList() Service Resources S returns a list of all template resources for the service
ServiceApi::getVmapAccessHash() Service RBAC S Returns a hash of all value map IDs accessible by the user, NOTHING if there are no restrictions, or an empty hash if the user can access no value maps
ServiceApi::getVmapAccessList() Service RBAC S Returns a list of all value map IDs accessible by the user, NOTHING if there are no restrictions, or an empty list if the user can access no value maps
ServiceApi::getWorkflowAccessHash() Service RBAC S Returns a hash of all workflow IDs accessible by the user, NOTHING if there are no restrictions, or an empty hash if the user can access no workflows
ServiceApi::getWorkflowAccessList() Service RBAC S Returns a list of all workflow IDs accessible by the user, NOTHING if there are no restrictions, or an empty list if the user can access no workflows
ServiceApi::hasResource() Service Resources S returns True if the given resource exists
ServiceApi::hasTemplate() Service Resources S returns True if the given resource is a template
UserApi::registerFsmAsObserver() Utility W, S, J registers a finite state machine as an event observer
ServiceApi::registerSoapHandler() Service SOAP S Registers the current service as a SOAP server
ServiceApi::renderTemplate() Service Resources S explcitly renders the given template resource and returns the rendered data
ServiceApi::startThread() Service Threads S Starts a service thread
ServiceApi::startThreadArgs() Service Threads S Starts a service thread with the given arguments as a list argument
ServiceApi::testAuthorization() Service RBAC S Returns True if the current user has all given permissions
ServiceApi::testAuthorizationOr() Service RBAC S Returns True if the current user has any of the given permissions
ServiceApi::testJobAccess() Service RBAC S Returns True if the current user can access all the given jobs
ServiceApi::testMapperAccess() Service RBAC S Returns True if the current user can access all the given mappers
ServiceApi::testServiceAccess() Service RBAC S Returns True if the current user can access all the given services
ServiceApi::testVmapAccess() Service RBAC S Returns True if the current user can access all the given value maps
ServiceApi::testWorkflowAccess() Service RBAC S Returns True if the current user can access all the given workflows
ServiceApi::tryRenderTemplate() Service Resources S if the given template resource exists then it is rendered and the rendered data is returned
ServiceApi::tryGetResource() Service Resources S returns the given resource if it exists as a hash with HTTP headers and an HTTP response code to be used as the response for an HTTP request handler
ServiceApi::tryGetResourceData() Service Resources S returns the given resource if it exists as its native type
ServiceApi::uiExtensionRegister() Service HTTP S Registers the current service as a UI extension handler
ServiceApi::waitForEvents() Service Events S Waits for system events corresponding to the arguments
ServiceApi::waitForEventsAnd() Service Events S Waits for system events that meet all the criteria given
ServiceApi::waitForEventsOr() Service Events S Waits for system events that meet any of the criteria given

Service API Classes

The following classes are imported into service program logic containers:

Class Availability Description
AbstractAuthenticator S Allows the service to define custom authentication handlers for external HTTP and FTP requests
AbstractFsRemoteReceive W, S, J provides an API for streaming data from a remote filesystem through a remote Qorus instance
AbstractFtpHandler S Allows the service to implement an FTP server and handle FTP requests from clients
AbstractHttpRequestHandler S Allows the service to refer to AbstractHttpRequestHandler methods directly
AbstractParallelStream W, S, J provides an abstract base class for streaming data to or from a remote database through a remote Qorus instance and also provides static helper methods
AbstractPersistentDataHelper S Used when defining persistent HTTP connection support in services
AbstractServiceStream S Used when defining custom stream handlers in a service
AbstractServiceDataStreamResponseHandler S Used when defining custom stream handlers in a service
AbstractServiceHttpHandler S Allows the Qorus HTTP server to redirect HTTP requests to a service
AbstractServiceRestHandler S Allows the service to implement a REST handler and serve external REST requests
AbstractServiceWebSocketHandler S Allows the service to implement a Web Socket service handler
DbRemote W, S, J provides an API wrapper for all system.sqlutil service methods
DbRemoteReceive W, S, J provides an API for streaming data from a remote database through a remote Qorus instance
DbRemoteSend W, S, J provides an API for streaming data to a remote database through a remote Qorus instance
DefaultQorusRBACAuthenticator S the standard Qorus RBAC authentication class
DefaultQorusRBACBasicAuthenticator S the standard Qorus RBAC authentication class that requests basic authentication with 401 Unauthorized responses
FsRemote W, S, J provides an API wrapper for all system.fs service methods
FsRemoteSend W, S, J provides an API for streaming data to a remote filesystem through a remote Qorus instance
PermissiveAuthenticator S Used to indiscriminately authenticate all requests in HTTP and FTP request handlers
QorusExtensionHandler S Allows the service to extend the Qorus web UI
QorusInboundTableMapper W, S, J provides an API for mapping data to a DB table
QorusInboundTableMapperIterator W, S, J provides an iterator-based API for mapping data to a DB table
QorusRawSqlStatementOutboundMapper W, S, J provides an API for mapping from SQL statement using direct SQL statements passed in
QorusRemoteServiceHelper W, S, J provides an API for calling service methods in remote Qorus instances
QorusSqlStatementOutboundMapper W, S, J provides an API for mapping from SQL statement using SqlUtil
QorusSystemAPIHelper W, S, J provides an API for calling RPC API methods in remote Qorus instances
OMQ::QorusSystemRestHelper W, S, J provides an API for using the REST API in remote Qorus instances
QorusWebSocketConnection S Used when defining web socket service handlers
ServiceApi S the primary service Qorus API class
ServiceFileHandler S Allows services to implement HTTP file-based request handlers
UserApi W, S, J the primary shared Qorus API class

Service API Modules

The following modules are imported by default into service program logic containers:

!Name|!Availability|!Description

json W, S, J provides APIs for JSON data serialization and deserialization support
HttpServerUtil S provides definitions for HTTP services
Mime W, S, J provides MIME definitions and functionality
Mapper W, S, J provides a data-mapping API
RestHandler S provides definitions for REST server services
SoapClient W, S, J provides a SOAP client API
SqlUtil W, S, J provides high-level APIs for programmatic DML (SQL data manipulation), DDL (creating, querying, manipulating database definitions), and DBA operations
TableMapper W, S, J provides high-level APIs for mapping data to and from database tables
Util W, S, J provides utility APIs
uuid W, S, J provides an API for generating UUIDs
xml W, S, J provides APIs for parsing, validating, and generating XML documents
yaml W, S, J provides APIs for Qore's YAML-based data serialization and deserialization support
Note
other modules can be imported using the %requires directive, and it's always safe to %require a module that's already imported into the current Program container

Service API Overview

This section lists all of the API methods specific to services; the main service API classes are:

Note
See also
  • Qorus Common Server API for APIs and API concepts common to all Qorus server code (workflows, services, and jobs).
  • Qorus Common API for a definition of API definitions common to all Qorus user code (workflows, services, and jobs) as well as the client library.

Logging APIs:

Service Resource APIs

API Method Desc
ServiceApi::getResource() returns the requested resource as a hash with HTTP headers and an HTTP response code to be used as the response for an HTTP request handler
ServiceApi::getResourceData() returns the requested resource as its native type
ServiceApi::getResourceHash() returns a hash describing all resources for the service
ServiceApi::getResourceList() returns a list of all resources for the service
ServiceApi::getResourceWsdl() returns the given resource as a WebService object
ServiceApi::getTemplateHash() returns a hash describing all template resources for the service
ServiceApi::getTemplateList() returns a list of all template resources for the service
ServiceApi::hasResource() returns True if the given resource exists
ServiceApi::hasTemplate() returns True if the given resource is a template
ServiceApi::renderTemplate() explcitly renders the given template resource and returns the rendered data
ServiceApi::tryRenderTemplate() if the given template resource exists then it is rendered and the rendered data is returned
ServiceApi::tryGetResource() returns the given resource if it exists as a hash with HTTP headers and an HTTP response code to be used as the response for an HTTP request handler
ServiceApi::tryGetResourceData() returns the given resource if it exists as its native type

Service RBAC Functions

API Method Desc
ServiceApi::checkAuthorization() checks the current user for all given permissions and throws an exception if not
ServiceApi::checkAuthorizationOr() checks the current user for any of the given permissions and throws an exception if not
ServiceApi::checkJobAccess() Checks if the current user can access all the given jobs and throws an exception if not
ServiceApi::checkJobInstanceAccess() Checks if the current user can access the given job instance and throws an exception if not
ServiceApi::checkMapperAccess() Checks if the current user can access all the given mappers and throws an exception if not
ServiceApi::checkQueueAccess() Checks if the current user can access all the given asynchronous queues and throws an exception if not
ServiceApi::checkServiceAccess() Checks if the current user can access all the given services and throws an exception if not
ServiceApi::checkVmapAccess() Checks if the current user can access all the given value maps and throws an exception if not
ServiceApi::checkWorkflowAccess() Checks if the current user can access all the given workflows and throws an exception if not
ServiceApi::checkWorkflowInstanceAccess() Checks if the current user can access the given workflow order instance and throws an exception if not
ServiceApi::getJobAccessHash() Returns a hash of all job IDs accessible by the user, NOTHING if there are no restrictions, or an empty hash if the user can access no jobs
ServiceApi::getJobAccessList() Returns a list of all job IDs accessible by the user, NOTHING if there are no restrictions, or an empty list if the user can access no jobs
ServiceApi::getMapperAccessHash() Returns a hash of all mapper IDs accessible by the user, NOTHING if there are no restrictions, or an empty hash if the user can access no mappers
ServiceApi::getMapperAccessList() Returns a list of all mapper IDs accessible by the user, NOTHING if there are no restrictions, or an empty list if the user can access no mappers
ServiceApi::getServiceAccessHash() Returns a hash of all services IDs accessible by the user, NOTHING if there are no restrictions, or an empty hash if the user can access no services
ServiceApi::getServiceAccessList() Returns a list of all services IDs accessible by the user, NOTHING if there are no restrictions, or an empty list if the user can access no services
ServiceApi::getVmapAccessHash() Returns a hash of all value map IDs accessible by the user, NOTHING if there are no restrictions, or an empty hash if the user can access no value maps
ServiceApi::getVmapAccessList() Returns a list of all value map IDs accessible by the user, NOTHING if there are no restrictions, or an empty list if the user can access no value maps
ServiceApi::getWorkflowAccessHash() Returns a hash of all workflow IDs accessible by the user, NOTHING if there are no restrictions, or an empty hash if the user can access no workflows
ServiceApi::getWorkflowAccessList() Returns a list of all workflow IDs accessible by the user, NOTHING if there are no restrictions, or an empty list if the user can access no workflows
ServiceApi::testAuthorization() Returns True if the current user has all given permissions
ServiceApi::testAuthorizationOr() Returns True if the current user has any of the given permissions
ServiceApi::testJobAccess() Returns True if the current user can access all the given jobs
ServiceApi::testMapperAccess() Returns True if the current user can access all the given mappers
ServiceApi::testServiceAccess() Returns True if the current user can access all the given services
ServiceApi::testVmapAccess() Returns True if the current user can access all the given value maps
ServiceApi::testWorkflowAccess() Returns True if the current user can access all the given workflows

Service SOAP Methods

Class Description
ServiceApi::registerSoapHandler() Registers the current service as a SOAP server

Service HTTP and UI Methods

Class Description
ServiceApi::bindHandler() Binds a new HTTP handler to a dedicated HTTP service listener
ServiceApi::bindHttp() Binds an HTTP handler to the service
ServiceApi::uiExtensionRegister() Registers the current service as a UI extension handler
ServiceApi::getHttpCallContext() Returns a hash with info about the external HTTP call, if any

Service FTP Methods

Class Description
ServiceApi::bindFtp() Binds an FTP handler to the service and starts FTP listeners

Service Event Handling Methods

Class Description
ServiceApi::getLastEvents() Returns the last system events corresponding to the arguments
ServiceApi::getLastEventsAnd() Returns the last system events that meet all the criteria given
ServiceApi::getLastEventsOr() Returns the last system events that meet any of the criteria given
ServiceApi::waitForEvents() Waits for system events corresponding to the arguments
ServiceApi::waitForEventsAnd() Waits for system events that meet all the criteria given
ServiceApi::waitForEventsOr() Waits for system events that meet any of the criteria given

Service System Methods

Class Description
ServiceApi::callApiAsCurrentUser() Calls a system RPC API as the current external user (if any) and returns the result
UserApi::sleep() safely pause execution for a defined period of time
UserApi::usleep() safely pause execution for a defined period of time

Service Info Methods

Class Description
ServiceApi::getActiveJobsAsCurrentUser() Returns a hash of all active jobs visible to the current external user (if any)
ServiceApi::getCallContext() Returns a hash of contextual information about the current service call
ServiceApi::getCallContextString() Returns a string describing the context of the current call
ServiceApi::getRunningWorkflowListAsCurrentUser() Returns a list of running workflows visible to the current external user, if any
ServiceApi::getServiceInfo() Returns a hash of information about the current service
ServiceApi::getServiceInfoAsCurrentUser() Returns information about the given service if the current external user, if any, can access it

Service Threading Methods

Class Description
ServiceApi::startThread() Starts a service thread
ServiceApi::startThreadArgs() Starts a service thread with the given arguments as a list argument

System Event Processing

Each event hash has the the following keys:

  • id (int): the unique event ID for the application session; the first event starts with 1 and increases serially with each event
  • time (date): the date and time the event was submitted with a resolution to the microsecond
  • timeus (int): the microsecond value of the event (i.e. 0-999); this value is included separately because when the date and time are serialized through some protocols (such as XML-RPC), then microsecond value is lost
  • class (int): the event class code of the event
  • classstr (string): the string designation corresponding to the event class code (see the keys of the OMQ::QE_RMAP_CLASS Constant Hash for possible values)
  • event (int): the event code for the event
  • eventstr (string): the string designation corresponding to the event code (see the keys of the OMQ::QE_RMAP_EVENT Constant Hash for possible values)
  • severity (int): the severity level of the event; please note that all user events will have severity code 0 (OMQ::ES_Info). Values may be integers from -1 to 4 corresponding to the keys in the OMQ::ErrorSeverityMap hash.
  • severitystr (string): the string corresponding to the severity level; see the keys of the OMQ::ErrorSeverityOrder hash for possible values of this field.
  • caller (hash): a hash of caller information in case the event was trigger by or can be traced directly to an external call
  • compositeseverity (int) the maximum of the system and user severity levels; in case there is no user severity level; then this field is always equal to the system severity level. Values may be integers from -1 to 4 corresponding to the keys in the OMQ::ErrorSeverityMap hash.
  • compositeseveritystr (string): the string corresponding to the composite severity level; see the keys of the OMQ::ErrorSeverityOrder hash for possible values of this field
  • userseverity (integer, optional): in case the event is a user event and a user severity level was supplied; this field contains the severity level of the user event
  • userseveritystr (string, optional): in case the event is a user event and a user severity level was supplied; this field contains the string corresponding to the user severity level; see the keys of the OMQ::ErrorSeverityOrder hash for possible values of this field
  • info (hash, optional): additional event-specific information; See Event Information Descriptions for details on each message; note that user events have user-defined information in this field

Event Information Descriptions

This section contains the definitions of the info hash of event types

SYSTEM_ERROR Event Information Description

Event constant: OMQ::QEC_SYSTEM_ERROR

  • err: (string) the error code
  • desc: (string) the error description
  • info: (string) additional information about the error

SYSTEM_HEALTH_CHANGED Event Information Description

Event constant: OMQ::QEC_SYSTEM_HEALTH_CHANGED

  • health: (string) one of "GREEN", "YELLOW", or "RED"
  • old-health: (string) the old health value before the change
  • ongoing: (int) the number of ongoing alerts
  • transient: (int) the number of transient alerts in the cache
  • cutoff: (absolute date) the date time of the cutoff for transient alerts

SYSTEM_REMOTE_HEALTH_CHANGED Event Information Description

Event constant: OMQ::QEC_SYSTEM_REMOTE_HEALTH_CHANGED

  • name: (string) the name of the remote Qorus connection
  • health: (string) one of "GREEN", "YELLOW", or "RED"
  • old-health: (string) the old health value before the change
  • url: (string) the URL to the remote system
  • error: (string) an error string

SYSTEM_SCALED Event Information Description

Event constant: OMQ::QEC_SYSTEM_SCALED

  • scaling-min-replicas: (int) minimum replicas
  • scaling-max-replicas: (int) maximum repliacas
  • scaling-cpu: (int) average CPU utliization target
  • scaling-memory: (string) average memory usage target

SYSTEM_SHUTDOWN Event Information Description

Event constant: OMQ::QEC_SYSTEM_SHUTDOWN

SYSTEM_STARTUP Event Information Description

Event constant: OMQ::QEC_SYSTEM_STARTUP

  • name: (string) the product string for Qorus Integrtion Engine
  • version: (string) the version string
  • build: (string) the build string
Note
This event has no info hash.

WORKFLOW_START Event Information Description

Event constant: OMQ::QEC_WORKFLOW_START

  • name: The name of the workflow
  • version: The version of the workflow
  • workflowid: The workflow ID (metadata ID, i.e. workflows.workflowid in the database)
  • execid: The workflow execution ID
  • mode: The mode of the workflow (OMQ::WM_Normal or OMQ::WM_Recovery)
  • synchronous: True for synchronous workflows, False if not
  • options: A hash of workflow options

WORKFLOW_STOP Event Information Description

Event constant: OMQ::QEC_WORKFLOW_STOP

  • name: The name of the workflow
  • version: The version of the workflow
  • workflowid: The workflow ID (metadata ID, i.e. workflows.workflowid in the database)
  • execid: The workflow execution ID
  • mode: The mode of the workflow (OMQ::WM_Normal or OMQ::WM_Recovery))
  • synchronous: True for synchronous workflows, False if not

WORKFLOW_CACHE_RESET Event Information Description

Event constant: OMQ::QEC_WORKFLOW_CACHE_RESET

  • name: The name of the workflow
  • version: The version of the workflow
  • workflowid: The workflow ID (metadata ID, i.e. workflows.workflowid in the database)

Event Information Description

Event constant: OMQ::QEC_WORKFLOW_DATA_SUBMITTED

  • name: The name of the workflow
  • version: The version of the workflow
  • workflowid: The workflow ID (metadata ID, i.e. workflows.workflowid in the database)
  • workflow_instanceid: The workflow instance ID (i.e. workflow_instance.workflow_instanceid in the database)
  • status: The new workflow order instance's initial status (see Workflow, Segment, and Step Status Descriptions for possible status values)

WORKFLOW_INFO_CHANGED Event Information Description

Event constant: OMQ::QEC_WORKFLOW_INFO_CHANGED

  • name: The name of the workflow
  • version: The version of the workflow
  • workflowid: The workflow ID (metadata ID, i.e. workflows.workflowid in the database)
  • workflow_instanceid: The workflow instance ID (i.e. workflow_instance.workflow_instanceid in the database)
  • info: The info hash for the change

WORKFLOW_STATUS_CHANGED Event Information Description

Event constant: OMQ::QEC_WORKFLOW_STATUS_CHANGED

  • name: The name of the workflow
  • version: The version of the workflow
  • workflowid: The workflow ID (metadata ID, i.e. workflows.workflowid in the database)
  • workflow_instanceid: The workflow instance ID (i.e. workflow_instance.workflow_instanceid in the database)
  • info: A hash with old and new keys giving the old and new status values (see Workflow, Segment, and Step Status Descriptions for possible status values)

WORKFLOW_DATA_ERROR Event Information Description

Event constant: OMQ::QEC_WORKFLOW_DATA_ERROR

  • name: The name of the workflow
  • version: The version of the workflow
  • workflowid: The workflow ID (metadata ID, i.e. workflows.workflowid in the database)
  • workflow_instanceid: The workflow instance ID (i.e. workflow_instance.workflow_instanceid in the database)
  • execid: The workflow execution ID
  • error: A hash of error information containing the following keys:
    • err: the error string (ex: exception name)
    • desc: the error description (ex: exception description)
    • info: any additional error information provided
    • business_error: True for business errors, False if not
    • stepid: the stepid of the error, if any
    • ind: the ind code of the step (array index), if any
    • retry: retry number for error
    • errorid: the error_instanceid in the database

WORKFLOW_DATA_RELEASED Event Information Description

Event constant: OMQ::QEC_WORKFLOW_DATA_RELEASED

  • name: The name of the workflow
  • version: The version of the workflow
  • workflowid: The workflow ID (metadata ID, i.e. workflows.workflowid in the database)
  • workflow_instanceid: The workflow instance ID (i.e. workflow_instance.workflow_instanceid in the database)
  • status: The status of the workflow as it is released
  • business_error: The business error status of the workflow (True only if the status is OMQ::StatError due to a business error)

WORKFLOW_DATA_CACHED Event Information Description

Event constant: OMQ::QEC_WORKFLOW_DATA_CACHED

  • name: The name of the workflow
  • version: The version of the workflow
  • workflowid: The workflow ID (metadata ID, i.e. workflows.workflowid in the database)
  • workflow_instanceid: The workflow instance ID (i.e. workflow_instance.workflow_instanceid in the database)
  • status: The status of the workflow as it is released
  • business_error: The business error status of the workflow (True only if the status is OMQ::StatError due to a business error)
  • external_order_instanceid: The external order instance ID of the workflow, if any
  • keys: A hash of workflow order keys, if any

WORKFLOW_DATA_UPDATED Event Information Description

Event constant: OMQ::QEC_WORKFLOW_DATA_UPDATED

  • name: The name of the workflow
  • version: The version of the workflow
  • workflowid: The workflow ID (metadata ID, i.e. workflows.workflowid in the database)
  • workflow_instanceid: The workflow instance ID (i.e. workflow_instance.workflow_instanceid in the database)
  • datatype: Type of data updated: staticdata or dynamicdata

WORKFLOW_DATA_LOCKED Event Information Description

Event constant: OMQ::QEC_WORKFLOW_DATA_LOCKED

  • name: (string) The name of the workflow
  • version: (string) The version of the workflow
  • workflowid: (int) The workflow ID (metadata ID, i.e. workflows.workflowid in the database)
  • workflow_instanceid: (int) The workflow instance ID (i.e. workflow_instance.workflow_instanceid in the database)
  • note: (string) the note stored against the workflow order when locking it

WORKFLOW_DATA_UNLOCKED Event Information Description

Event constant: OMQ::QEC_WORKFLOW_DATA_UNLOCKED

  • name: (string) The name of the workflow
  • version: (string) The version of the workflow
  • workflowid: (int) The workflow ID (metadata ID, i.e. workflows.workflowid in the database)
  • workflow_instanceid: (int) The workflow instance ID (i.e. workflow_instance.workflow_instanceid in the database)
  • note: (string) the note stored against the workflow order when unlocking it

WORKFLOW_PERFORMANCE Event Information Description

Event constant: OMQ::QEC_WORKFLOW_PERFORMANCE

  • name: (string) The name of the workflow
  • version: (string) The version of the workflow
  • workflowid: (int) The workflow ID (metadata ID, i.e. workflows.workflowid in the database)
  • workflow_instanceid: (int) The workflow instance ID (i.e. workflow_instance.workflow_instanceid in the database)
  • status: (string) the workflow order's status
  • disposition: (string) a code giving the disposition of the workflow; see Workflow Order Complete Disposition Constants for possible values and their meanings
  • start: (date) the start timestamp for workflow order execution
  • end: (date) the end timestamp for the workflow order execution (i.e. when the final status is reached)
Note
These events are only emitted if system option qorus.workflow-perf-events is enabled and when workflow orders get a final status (final statuses are COMPLETE and CANCELED)

WORKFLOW_RECOVERED Event Information Description

Event constant: OMQ::QEC_WORKFLOW_RECOVERED

  • name: (string) The name of the workflow
  • version: (string) The version of the workflow
  • workflowid: (int) The workflow ID (metadata ID, i.e. workflows.workflowid in the database)
  • old_statuses: (list<string>) a list of status values for orders that have been recovered and now have the status given by new_status
  • new_status: (string) a status value for recovered orders

WORKFLOW_STATS_UPDATED Event Information Description

Event constant: OMQ::QEC_WORKFLOW_STATS_UPDATED

  • tag: the tag or label identifying the bands; either "global" for summarized global info or <id> where <id> is the workflow ID
  • bands: list of OrderSummaryOutputInfo hashes

WORKFLOW_STEP_DATA_UPDATED Event Information Description

Event constant: OMQ::QEC_WORKFLOW_STEP_DATA_UPDATED

  • name: The name of the workflow
  • version: The version of the workflow
  • workflowid: The workflow ID (metadata ID, i.e. workflows.workflowid in the database)
  • workflow_instanceid: The workflow instance ID (i.e. workflow_instance.workflow_instanceid in the database)
  • stepid: The stepid for the data that was updated
  • ind: the step instance index for the data that was updated
Since
Qorus 4.0.1

WORKFLOW_STEP_PERFORMANCE Event Information Description

Event constant: OMQ::QEC_WORKFLOW_STEP_PERFORMANCE

  • name: (string) The name of the workflow
  • version: (string) The version of the workflow
  • workflowid: (int) The workflow ID (metadata ID, i.e. workflows.workflowid in the database)
  • workflow_instanceid: (int) The workflow instance ID (i.e. workflow_instance.workflow_instanceid in the database)
  • stepname: (string) the name of the step
  • stepid: (int) the ID of the step
  • ind: (int) the array index for the step (always 0 for non-array steps)
  • start: (date) the start timestamp for workflow step execution
  • end: (date) the end timestamp for the workflow step execution
Note
These events are only emitted if system option qorus.workflow-step-perf-events is enabled

WORKFLOW_UPDATED Event Information Description

Event constant: OMQ::QEC_WORKFLOW_UPDATED

  • name: (string) The name of the workflow
  • version: (string) The version of the workflow
  • workflowid: (int) The workflow ID (metadata ID, i.e. workflows.workflowid in the database)
  • [remote]: (bool) the new remote value
  • [autostart]: (int) the new autostart value
  • [sla_threshold]: (int) the new SLA threshold value

SERVICE_START Event Information Description

Event constant: OMQ::QEC_SERVICE_START

  • type: The type of service; either USER or SYSTEM
  • name: The name of the service
  • version: The version of the service
  • serviceid: The service ID (metadata ID, i.e. services.serviceid in the database)

SERVICE_STOP Event Information Description

Event constant: OMQ::QEC_SERVICE_STOP

  • type: The type of service; either USER or SYSTEM
  • name: The name of the service
  • version: The version of the service
  • serviceid: The service ID (metadata ID, i.e. services.serviceid in the database)

SERVICE_ERROR Event Information Description

Event constant: OMQ::QEC_SERVICE_ERROR

  • type: The type of service; either USER or SYSTEM
  • name: The name of the service
  • version: The version of the service
  • serviceid: The service ID (metadata ID, i.e. services.serviceid in the database)
  • err: The error code for the error
  • desc: The error description
  • info: Additional information for the error, if available

SERVICE_AUTOSTART_CHANGE Event Information Description

Event constant: OMQ::QEC_SERVICE_AUTOSTART_CHANGE

Deprecated:
This event it no longer raised as of Qorus 4.0

SERVICE_METHOD_PERFORMANCE Event Information Description

Event constant: OMQ::QEC_SERVICE_METHOD_PERFORMANCE

  • type: (string) the service type ("system" or "user")
  • name: (string) the name of the service
  • version: (string) the version of the service
  • serviceid: (int) the ID of the service
  • method: (string) the name of the service method called
  • start: (date) the start timestamp for the call
  • end: (date) the end timestamp for the call
  • error: (bool) an indicator if the call ended in an error or not
Note

SERVICE_UPDATED Event Information Description

Event constant: OMQ::QEC_SERVICE_CREATED

  • type: (string) the service type ("system" or "user")
  • name: (string) the name of the service
  • version: (string) the version of the service
  • serviceid: (int) the ID of the service
  • remote: (bool) the new remote value
  • autostart: (bool) the new autostart value

Event constant: OMQ::QEC_SERVICE_UPDATED

  • type: (string) the service type ("system" or "user")
  • name: (string) the name of the service
  • version: (string) the version of the service
  • serviceid: (int) the ID of the service
  • [remote]: (bool) the new remote value
  • [autostart]: (bool) the new autostart value

SERVICE_DELETED Event Information Description

Event constant: OMQ::QEC_SERVICE_DELETED

  • type: (string) the service type ("system" or "user")
  • name: (string) name
  • version: (string) version
  • serviceid: (int) service ID

JOB_START Event Information Description

Event constant: OMQ::QEC_JOB_START

  • name: The name of the job
  • version: The version of the job
  • jobid: The job ID (metadata ID, i.e. jobs.jobid in the database)
  • info: Additional information about the job; a hash with the following keys:
    • description: the job's description
    • run_skipped: boolean flag, True if the job will be run immediately if its last trigger time was missed due to the system being down
    • last_executed: date/time of last execution
    • next: next trigger date/time
    • trigger: a string describing the job's trigger

JOB_STOP Event Information Description

Event constant: OMQ::QEC_JOB_STOP

  • name: The name of the job
  • version: The version of the job
  • jobid: The job ID (metadata ID, i.e. jobs.jobid in the database)

JOB_INSTANCE_START Event Information Description

Event constant: OMQ::QEC_JOB_INSTANCE_START

  • name: The name of the job
  • version: The version of the job
  • jobid: The job ID (metadata ID, i.e. jobs.jobid in the database)
  • job_instanceid: The job instance ID (i.e. job_instance.job_instanceid in the database)

JOB_INSTANCE_STOP Event Information Description

Event constant: OMQ::QEC_JOB_INSTANCE_STOP

  • name: The name of the job
  • version: The version of the job
  • jobid: The job ID (metadata ID, i.e. jobs.jobid in the database)
  • job_instanceid: The job instance ID (i.e. job_instance.job_instanceid in the database)
  • status: the job instance's final status in the database (see Job Data Status Codes for possible values)

JOB_ERROR Event Information Description

Event constant: OMQ::QEC_JOB_ERROR

  • name: The name of the job
  • version: The version of the job
  • jobid: The job ID (metadata ID, i.e. jobs.jobid in the database)
  • job_instanceid: The job instance ID (i.e. job_instance.job_instanceid in the database)
  • error: a hash of error information with the following keys:
    • err: the error code
    • desc: the description of the error
    • info: optional info about the error
    • business_error: boolean flag, True if the error is a business error
    • errorid: the error instance id for the job (i.e. job_errors.job_errorid in the database)

JOB_RECOVERED Event Information Description

Event constant: OMQ::QEC_JOB_RECOVERED

  • name: (string) The name of the job
  • version: (string) The version of the job
  • jobid: (int) The job ID (metadata ID, i.e. jobs.jobid in the database)
  • old_statuses: (list<string>) a list of status values for orders that have been recovered and now have the status given by new_status
  • new_status: (string) a status value for recovered job instances

JOB_UPDATED Event Information Description

Event constant: OMQ::QEC_JOB_UPDATED

  • name: (string) The name of the job
  • version: (string) The version of the job
  • jobid: (int) The job ID (metadata ID, i.e. jobs.jobid in the database)
  • [remote]: (bool) the new remote value
  • [sched_txt]: (string) the new schedule value
  • [month]: (string) the new month value
  • [day]: (string) the new day value
  • [wday]: (string) the new wday value
  • [hour]: (string) the new hour value
  • [minute]: (string) the new minute value
  • [active]: (bool) the new active value
  • [expiry_date]: (*date) the new expiry date or NOTHING if the expiry date has been cleared

JOB_CREATED Event Information Description

Event constant: OMQ::QEC_JOB_CREATED

  • name: (string) name
  • version: (string) version
  • jobid: The job ID (metadata ID, i.e. jobs.jobid in the database)
  • info: (hash) new job information

JOB_DELETED Event Information Description

Event constant: OMQ::QEC_JOB_DELETED

  • name: (string) name
  • version: (string) version
  • jobid: The job ID (metadata ID, i.e. jobs.jobid in the database)

CONFIG_ITEM_CHANGED Event Information Description

Event constant: OMQ::QEC_CONFIG_ITEM_CHANGED

  • interfaceType: (string) The type of the interface (job, service, step, workflow or global)
  • [type]: (string) The type of the service if the interface type is "service"
  • name: (string) The name of the interface
  • [version]: (string) The version of the interface if is present
  • [workflowid]: (int) The workflow ID (metadata ID, i.e. workflows.workflowid in the database) if the interface type is "workflow" or "step"
  • [stepid]: (int) The step ID (metadata ID, i.e. steps.stepid in the database) if the interface type is "step"
  • [serviceid]: (int) The service ID (metadata ID, i.e. services.serviceid in the database) if the interface type is "service"
  • [jobid:] (int) The job ID (metadata ID, i.e. jobs.jobid in the database) if the interface type is "job"
  • item: (string) the name of the configuration item
  • value: (any) the new value of the configuration item

GROUP_STATUS_CHANGED Event Information Description

Event constant: OMQ::QEC_GROUP_STATUS_CHANGED

  • name: the interface group's name
  • enabled: the new status of the group

ALERT_ONGOING_RAISED Event Information Description

Event constant: OMQ::QEC_ALERT_ONGOING_RAISED

  • type: the alert type
  • id: the ID of the object causing or related to the alert
  • alert: the string "name" of the alert
  • reason: the text giving the reason for the alert
  • name: the name of the object causing or related to the alert
  • version: the version of the object causing or related to the alert

ALERT_ONGOING_CLEARED Event Information Description

Event constant: OMQ::QEC_ALERT_ONGOING_CLEARED

  • type: the alert type
  • id: the ID of the object causing or related to the alert
  • alert: the string "name" of the alert
  • reason: the text giving the reason for the alert
  • name: the name of the object causing or related to the alert
  • version: the version of the object causing or related to the alert

ALERT_TRANSIENT_RAISED Event Information Description

Event constant: OMQ::QEC_ALERT_TRANSIENT_RAISED

  • type: the alert type
  • id: the ID of the object causing or related to the alert
  • alert: the string "name" of the alert
  • reason: the text giving the reason for the alert
  • name: the name of the object causing or related to the alert
  • version: the version of the object causing or related to the alert

CONNECTION_UP Event Information description

Event constant: OMQ::QEC_CONNECTION_UP

  • conntype: (string) the connection type name (one of "DATASOURCE", "REMOTE", or "USER-CONNECTION")
  • name: (string) the unique name for the connection in its type

CONNECTION_DOWN Event Information description

Event constant: OMQ::QEC_CONNECTION_DOWN

  • conntype: (string) the connection type name (one of "DATASOURCE", "REMOTE", or "USER-CONNECTION")
  • name: (string) the unique name for the connection in its type
  • err: (string) the error string

CONNECTION_ENABLED_CHANGE Event Information description

Event constant: OMQ::QEC_CONNECTION_ENABLED_CHANGE

  • conntype: (string) the connection type name (one of "DATASOURCE", "REMOTE", or "USER-CONNECTION")
  • name: (string) the unique name for the connection in its type
  • enabled: (bool) the enabled status for the connection

CONNECTION_DEBUG_DATA_CHANGE Event Information description

Event constant: OMQ::QEC_CONNECTION_DEBUG_DATA_CHANGE

  • conntype: (string) the connection type name (one of "DATASOURCE", "REMOTE", or "USER-CONNECTION")
  • name: (string) the unique name for the connection in its type
  • debug_data: (bool) the new state of Socket data debugging for the connection
Note
socket data debugging only takes effect on connections that support it; see the documentation for the connection in question for more information

CONNECTION_CREATED Event Information description

Event constant: OMQ::QEC_CONNECTION_CREATED

  • conntype: (string) the connection type name (one of "DATASOURCE", "REMOTE", or "USER-CONNECTION")
  • name: (string) the unique name for the connection in its type
  • desc: (string) the description of the connection
  • url: (string) the URL for the connection
  • url_hash: (hash) a broken-down hash of url
  • opts: (hash) connection options
  • enabled: (bool) the enabled status of the connection
  • see the REST info response for the appropriate connection type for details about the message per connection type:

CONNECTION_UPDATED Event Information description

Event constant: OMQ::QEC_CONNECTION_UPDATED

  • conntype: (string) the connection type name (one of "DATASOURCE", "REMOTE", or "USER-CONNECTION")
  • name: (string) the unique name for the connection in its type
  • desc: (string) the description of the connection
  • url: (string) the URL for the connection
  • url_hash: (hash) a broken-down hash of url
  • opts: (hash) connection options
  • enabled: (bool) the enabled status of the connection
  • see the REST info response for the appropriate connection type for details about the message per connection type:

CONNECTION_DELETED Event Information description

Event constant: OMQ::QEC_CONNECTION_DELETED

  • conntype: (string) the connection type name (one of "DATASOURCE", "REMOTE", or "USER-CONNECTION")
  • name: (string) the unique name for the connection in its type

CONNECTIONS_RELOADED Event Information description

Event constant: OMQ::QEC_CONNECTIONS_RELOADED

  • conntype: (string) the connection type name (one of "DATASOURCE", "REMOTE", or "USER-CONNECTION")
  • connections: (list of hashes) list of connections reloaded

LOGGER_CREATED Event Information description

Event constant: OMQ::QEC_LOGGER_CREATED emitted when logger is created

  • loggerId: (string) logger id
  • interface: (string) type of related system (e.g. workflows, jobs, services, system, audit, http, ...)
  • interfaceId: (*string) interface id (not set for default loggers)
  • params: (hash) actual logger params
  • isDefault: (bool) true if created defaut logger

LOGGER_UPDATED Event Information description

Event constant: OMQ::QEC_LOGGER_UPDATED emitted when logger is updated

  • loggerId: (string) logger id
  • appenderIds: (list) list of assigned appender ids (not set if no appenders assigned)
  • interface: (string) type of related system (e.g. workflows, jobs, services, system, audit, http, ...)
  • interfaceId: (*string) interface id (not set for default loggers)
  • params: (hash) actual logger params
  • isDefault: (bool) true if edited defaut logger

LOGGER_DELETED Event Information description

Event constant: OMQ::QEC_LOGGER_DELETED emitted when logger is deleted

  • loggerId: (string) logger id
  • interface: (string) type of related system (e.g. workflows, jobs, services, system, audit, http, ...)
  • interfaceId: (*string) interface id (not set for default loggers)
  • current_logger: (hash) actual logger information
  • isDefault: (bool) true if deleted defaut logger

APPENDER_CREATED Event Information description

Event constant: OMQ::QEC_APPENDER_CREATED emitted when logger appender is created

  • loggerId: (string) logger id
  • logger_appenderid: (string) appender id
  • interface: (string) type of related system (e.g. workflows, jobs, services, system, audit, http, ...)
  • interfaceId: (*string) if exists contains interface name (e.g. workflow/jobs/services name)
  • params: (hash) actual appender params
  • isDefault: (bool) true if created appender for defaut logger

APPENDER_DELETED Event Information description

Event constant: OMQ::QEC_APPENDER_DELETED emitted when logger is created

  • logger_appenderid: (string) appender id
  • interface: (string) type of related system (e.g. workflows, jobs, services, system, audit, http, ...)
  • interfaceId: (*string) if exists contains interface name (e.g. workflow/jobs/services name)
  • isDefault: (bool) true if deleted appender from defaut logger

APPENDER_UPDATED Event Information description

Event constant: OMQ::QEC_APPENDER_UPDATED emitted when logger appender is updated

  • loggerId: (string) logger id
  • logger_appenderid: (string) appender id
  • interface: (string) type of related system (e.g. workflows, jobs, services, system, audit, http, ...)
  • interfaceId: (*string) if exists contains interface name (e.g. workflow/jobs/services name)
  • params: (hash) actual appender params
  • isDefault: (bool) true if created appender for defaut logger

PROCESS_STARTED Event Information description

Event constant: OMQ::QEC_PROCESS_STARTED

  • id: (string) the unique name for the process
  • node: (string) the node where the process is running
  • status: (int) the process status code; 0 = IDLE, 1 = STARTING, 2 = RUNNING, 3 = STOPPING, 4 = ERROR
  • urls: (list<string>) a list of distributed queue URLs for the proces
  • host: (string) the hostname of the node running the process
  • pid: (int) the PID of the process on the host
  • type: (string) the type of cluster process
  • client_id: (string) the type-specific ID for the process
  • start_code: (int) the start code or start reason: 0 = manual start, 1 = manual restart, 2 = automatic restart

PROCESS_START_ERROR Event Information Description

Event constant: OMQ::QEC_PROCESS_START_ERROR

  • id: (string) the unique name for the process
  • node: (string) the node where the process is running
  • status: (int) the process status code; 0 = IDLE, 1 = STARTING, 2 = RUNNING, 3 = STOPPING, 4 = ERROR
  • urls: (list<string>) a list of distributed queue URLs for the proces
  • host: (string) the hostname of the node running the process
  • pid: (int) the PID of the process on the host
  • type: (string) the type of cluster process
  • client_id: (string) the type-specific ID for the process
  • error: (string) the error string

PROCESS_STOPPED Event Information description

Event constant: OMQ::QEC_PROCESS_STOPPED

  • id: (string) the unique name for the process
  • node: (string) the node where the process is running
  • status: (int) the process status code; 0 = IDLE, 1 = STARTING, 2 = RUNNING, 3 = STOPPING, 4 = ERROR
  • urls: (list<string>) a list of distributed queue URLs for the proces
  • host: (string) the hostname of the node running the process
  • pid: (int) the PID of the process on the host
  • type: (string) the type of cluster process
  • client_id: (string) the type-specific ID for the process

PROCESS_MEMORY_CHANGED Event Information description

Event constant: OMQ::QEC_PROCESS_MEMORY_CHANGED

  • id: (string) the unique ID for the process
  • node: (string) the node where the process is running
  • status: (int) the process status code; 0 = IDLE, 1 = STARTING, 2 = RUNNING, 3 = STOPPING, 4 = ERROR
  • urls: (list<string>) a list of distributed queue URLs for the proces
  • host: (string) the hostname of the node running the process
  • pid: (int) the PID of the process on the host
  • type: (string) the type of cluster process
  • client_id: (string) the type-specific ID for the process
  • priv: (int) the amount of private memory (stacks, heap, non-shared, non-memory-mapped virtual memory segments) for the process in bytes
  • rss: (int) the resident size of the process in bytes
  • vsz: (int) the virtual memory size of the process in bytes (includes shared and memory-mapped segments)
  • pct: (int) the percentage of main memory on the node used by private memory
  • node_priv: (int) the amount of non-shared private memory used by the cluster on the node in bytes
  • node_priv_str: (string) a descriptive string giving the amount of non-shared private memory used by the cluster on the current node
  • node_ram: (int) the total amount of physical RAM on the node in bytes
  • node_ram_str: (string) a descriptive string giving the total amount of physical RAM on the node
  • node_ram_in_use: (int) the amount of physical RAM in use on the node in bytes
  • node_ram_in_use_str: (string) a descriptive string giving the amount of physical RAM in use on the node
  • node_cpu_count: (int) the number of CPUs on the node
  • node_load_pct: (float) the average load on the machine over the last minute

NODE_INFO Event Information Description

Event constant: OMQ::QEC_NODE_INFO

  • name: (string) the name of the node
  • node_priv: (int) the amount of private memory used by Qorus processes for the instance on the node
  • node_priv_str: (string) a string corresponding to node_priv
  • node_ram_in_use: (int) the amount of physical RAM in use on the node in bytes
  • node_ram_in_use_str: (string) a descriptive string giving the amount of physical RAM in use on the node
  • node_cpu_count: (int) the number of CPUs on the node
  • node_load_pct: (float) the average load on the machine over the last minute
  • processes: (int) the number of Qorus processes for the instance on the node

NODE_REMOVED Event Information Description

Event constant: OMQ::QEC_NODE_REMOVED

  • name: (string) the name of the node that was removed

USER_EVENT Event Information Description

Event constant: OMQ::QEC_USER_EVENT

CLASS_CREATED Event Information Description

Event constant: OMQ::QEC_CLASS_CREATED

  • name: (string) name
  • version: (string) version
  • classid: (int) class ID
  • info: (hash) new class information

CLASS_DELETED Event Information Description

Event constant: OMQ::QEC_CLASS_DELETED

  • name: (string) name
  • version: (string) version
  • classid: (int) class ID

CLASS_UPDATED Event Information Description

Event constant: OMQ::QEC_CLASS_UPDATED

  • name: (string) name
  • version: (string) version
  • classid: (int) class ID
  • info: (hash) new class information

The info hash for user events is free form; any serializable information can be included in the info hash.

Event Filter Criteria

The following gives a list of the criteria that can be used for filtering events:

  • "all": The argument with this criteria is ignored; automatically matches all events; this criteria is useful with “logical or” filtering and an “and not” list to specify all events except events matching all of the criteria in any of the “and not” criteria hashes.
  • "class": The class code for the event; the event’s class code must match this class code exactly for the criteria to match
  • "classstr": The string designation corresponding to the event class code (see the keys of the OMQ::QE_RMAP_CLASS Constant Hash for possible values); the event’s class string must match this class string exactly for the criteria to match
  • "event": The event code for the event; the event’s event code must match this event code exactly for the criteria to match
  • "eventstr": The string designation corresponding to the event code (see the keys of the OMQ::QE_RMAP_EVENT Constant Hash for possible values); the event’s event string must match this event string exactly for the criteria to match
  • "mincompositeseverity": The minimum composite severity code for the event. Composite severity is the maximum of the event and user severity levels. Values may be integers from -1 to 4 corresponding to the keys in the OMQ::ErrorSeverityMap hash. If the event has an equal or higher composite severity code, then this criteria matches.
  • "mincompositeseveritystr": The string description corresponding to the minimum composite severity code for the event. Composite severity is the maximum of the event and user severity levels. See the keys of the OMQ::ErrorSeverityOrder hash for possible values of this field. When the strings are converted to severity codes, works like the mincompositeseverity criteria.
  • "minseverity": The minimum severity code for the event; values may be integers from -1 to 4 corresponding to the keys in the OMQ::ErrorSeverityMap hash. If the event has an equal or higher severity code, then this criteria matches.
  • "minseveritystr": The string description corresponding to the minimum severity code for the event; see the keys of the OMQ::ErrorSeverityOrder hash for possible values of this field. When the strings are converted to severity codes, works like the minseverity criteria.
  • "miuserseverity": The minimum user severity for the event; values may be integers from -1 to 4 corresponding to the keys in the OMQ::ErrorSeverityMap hash. If the event has an equal or higher user severity code, then this criteria matches.
  • "minuserseveritystr": The string description corresponding to the minimum user severity code for the event; see the keys of the OMQ::ErrorSeverityOrder hash for possible values of this field. When the strings are converted to severity codes, works like the minuserseverity criteria.
  • "none": The argument with this criteria is ignored; automatically matches no events; this criteria is useful with “logical and” filtering” and an “or not” list to specify all events except those not matching the criteria in the “or not” list.
Qorus Integration Engine®