@@ -24,7 +24,7 @@ class WorkflowProcApi(ProcRestApi):
...
@@ -24,7 +24,7 @@ class WorkflowProcApi(ProcRestApi):
:param username: DM username (it may be omitted if environment variable DM_LOGIN_FILE points to a file containing the "<username>|<password>" pair)
:param username: DM username (it may be omitted if environment variable DM_LOGIN_FILE points to a file containing the "<username>|<password>" pair)
:type username: str
:type username: str
:param password: DM password (it may be omitted if environment variable DM_LOGIN_FILE points to a file containing the "<username>|<password>" pair)
:param password: DM password (it may be omitted if environment variable DM_LOGIN_FILE points to a file containing the "<username>|<password>" pair)
:type password: str
:type password: str
...
@@ -41,7 +41,7 @@ class WorkflowProcApi(ProcRestApi):
...
@@ -41,7 +41,7 @@ class WorkflowProcApi(ProcRestApi):
Add workflow to the DM workflow database. Workflows are defined
Add workflow to the DM workflow database. Workflows are defined
using dictionaries, and they serve as templates for running
using dictionaries, and they serve as templates for running
processing jobs.
processing jobs.
Workflow keys:
Workflow keys:
- name (required)
- name (required)
- owner (required)
- owner (required)
...
@@ -52,7 +52,7 @@ class WorkflowProcApi(ProcRestApi):
...
@@ -52,7 +52,7 @@ class WorkflowProcApi(ProcRestApi):
Stage dictionary keys can be anything; they will get sorted,
Stage dictionary keys can be anything; they will get sorted,
and stages will get executed in the sorted order
and stages will get executed in the sorted order
Stage keys:
Stage keys:
- command (required; may use $variable strings that would get
- command (required; may use $variable strings that would get
their values at runtime, via <key>:<value> arguments)
their values at runtime, via <key>:<value> arguments)
...
@@ -64,6 +64,7 @@ class WorkflowProcApi(ProcRestApi):
...
@@ -64,6 +64,7 @@ class WorkflowProcApi(ProcRestApi):
subsequent workflow stages)
subsequent workflow stages)
- repeatPeriod, repeatUntil, maxRepeats (optional; must be
- repeatPeriod, repeatUntil, maxRepeats (optional; must be
used together):
used together):
- repeatPeriod:
- repeatPeriod:
- defines period in seconds after which the stage command
- defines period in seconds after which the stage command
will be repeated
will be repeated
...
@@ -78,12 +79,11 @@ class WorkflowProcApi(ProcRestApi):
...
@@ -78,12 +79,11 @@ class WorkflowProcApi(ProcRestApi):
- maxRepeats:
- maxRepeats:
- defines maximum number of repeats; if this
- defines maximum number of repeats; if this
number is reached, stage will fail
number is reached, stage will fail
Reserved keys that cannot be used in a stage definition:
Reserved keys that cannot be used in a stage definition:
- workflow: processing job workflow specification
- workflow: processing job workflow specification
Reserved keys that may be used in a stage definition as command input
Reserved keys that may be used in a stage definition as command input variables:
variables:
- id: processing job id
- id: processing job id
- stage: processing job workflow stage
- stage: processing job workflow stage
- status: processing job status
- status: processing job status
...
@@ -101,59 +101,53 @@ class WorkflowProcApi(ProcRestApi):
...
@@ -101,59 +101,53 @@ class WorkflowProcApi(ProcRestApi):
- nFailedFiles: number of failed files
- nFailedFiles: number of failed files
- nSkippedFiles: number of skipped files
- nSkippedFiles: number of skipped files
- nAbortedFiles: number of aborted files
- nAbortedFiles: number of aborted files
- nCompletedFiles: number of completed input files
- nCompletedFiles: number of completed input files (sum of processed, failed, skipped and aborted files)
- sum of processed, failed, skipped and aborted files
- processedFiles: list of processed files
- processedFiles: list of processed files
- failedFiles: list of failed files
- failedFiles: list of failed files
- skippedFiles: list of skipped files
- skippedFiles: list of skipped files
- abortedFiles: list of aborted files
- abortedFiles: list of aborted files
Reserved keys designated for specifying processing job input
Reserved keys designated for specifying processing job input files that may be used in a stage definition as command input variables:
files that may be used in a stage definition as command input
- filePath: input file path (if filePath is specified as one of the stage command input variables, the workflow stage will iterate over all job input files)
variables:
- filePath: input file path
- if filePath is specified as one of the stage command
input variables, the workflow stage will iterate over
all job input files
- filePathList: list of all input file paths
- filePathList: list of all input file paths
- filePathPattern: glob pattern for input file paths
- filePathPattern: glob pattern for input file paths