Qorus Integration Engine
3.0.4.p7
|
oload
[options] [workflow|order|service|function file(s) ...]This program is used to load new code and object descriptions into the Qorus database. It can also be used to run SQL files into Qorus datasources, but, as of Qorus version 2.0.0, oload
calls schema-tool to actually execute the SQL. If functions, services, workflows, or orders are changed or inserted, then oload will attempt to refresh the Qorus server’s cache by calling the omq.system.service.omqmap.reload() method. Normally this program should be run by automated installation scripts, however during development this tool may be used to manipulate schema objects by hand.
The loader recognizes the file type based on its extension, therefore metadata files must have the appropriate extensions as documented below.
Metadata File Suffixes
Suffix | Description |
* .qfd | Function Definition File |
* .qwf | Workflow Definition File |
* .qsd | Service Definition File |
* .qjob | Job Definition Files |
* .qclass | Class Definition File |
* .qconn | Connection Definition Files |
* .qconst | Constant Definition File |
* .qrf | Loader Release File Description |
* .qsm | User Schema Module Files |
If an object already exists, it will be redefined by the oload
program.
The loader supports release files which are useful for packaging automated releases. Release files are text files with simple instructions that are executed by the loader.
Each command takes one or no arguments. The commands in the following table are supported:
Load Release File Commands
Command | Argument | Description |
load | Filename | Loads the specified file into the database |
omquser-exec-sql | Filename | Executes the file as an SQL script using schema-tool in the user schema |
check-shutdown | n/a | Checks if the Qorus server is running; if so, prints an error message and exits |
refresh-all | n/a | Will reset all affected workflows, services, and jobs |
refresh-services | n/a | Will reset all jobs directly loaded in the server |
refresh-recursive | n/a | Will reset all affected workflows, services, and jobs directly listed or used by any library code (functions, classes, constants, etc) loaded |
refresh-services | n/a | Will reset any services directly loaded to ensure that the new configuration is used on the next method call |
refresh-workflows | n/a | Will call omq.system.reset-workflow() to refresh the cached configuration on all workflow updated |
Be aware that this program is delivered as a Qore-language script, and, as such, requires either the $OMQ_DIR
or $QORE_MODULE_DIR
environment variables to be set to find the Qorus client module, if not located in the default location.
Options Supported by oload
Long Option | Short | Description |
–allow-redef | -A | Allows dangerous workflow redefinitions (for example, making recoveries of instances of the previous definition impossible) – for use in development only. |
–data-ts=ARG | Sets the data tablespace name for the given datasource for use with the –schema and –user-schema options, ARG syntax: datasource_name=tablespace_name | |
–datasource=ARG | -D | Overrides datasource parameters, ARG: dsname=spec - spec=driver:user/pass@dbname[(encoding)][hostname][:port] |
–delete=ARG | -X | delete database object, ARG: type:spec - workflow: workflow:name:version - order data: wfinstances:name:version - service: service:name:version - service method: method:servicename:version:methodname - step: step:name:version - function: function:name:version - class: class:name:version - constant: constant:name:version - queue: queue:name
|
–help | -h | Shows option help text |
–index-ts=ARG | Sets the index tablespace name for the given datasource, ARG syntax: datasource_name=tablespace_name | |
–list=ARG | -L | Lists objects in the database, ARG=workflows, services, jobs, classes, constants, functions, queues, events, groups
|
–quiet | -q | Suppress all output except error messages |
–refresh=ARG | -r | Refreshes objects loaded using the network API, ARG is w (workflows), s (services), or j (jobs) |
–schema=ARG | Run SQL file given as argument against the omq datasource (only use with system patches) | |
–show-url | -W | Displays the default Qorus system URL |
–sign-schema | Performs no action; schema signing is no longer necessary or supported | |
–url=ARG | -u | Set URL: "http://host:port" ; at least host or port must be given; ex: "http://server1:8501/RPC2" ; see UNIX Socket Support in URLs |
–proxy-url=ARG | -p | Set the proxy URL: "http://host:port" ; at least host or port must be given; ex: "http://proxy1:8080" ; see UNIX Socket Support in URLs |
–user-schema=ARG | Run SQL file given as argument against the omquser datasource | |
–verbose | -v | Sets verbosity level |
–validate | -l | Validate all workflows, services, and jobs affected by updated or inserted objects; without this option only workflows, services, and jobs that are directly loaded are validated |