...
Behavior up to and including Version 1.9
Display feature availability | ||
---|---|---|
|
When a shell script is executed within a job and when this script writes messages to the standard output and error channels (stdout and stderr) then the JobScheduler treats these as info messages.
- Logging:
- the JobScheduler writes these messages to the task's log with severity "info", e.g.
2015-03-18 07:57:38.991+0100 [info] This message goes to stdout
2015-03-18 07:57:38.993+0100 [info] This message goes to stderr
- The user cannot decide from the log if output from the shell script has been written to stdout or to stderr.
- the JobScheduler writes these messages to the task's log with severity "info", e.g.
...
- Error Handling:
- the JobScheduler handles the script execution as being successful if the exit code returned by the script is 0.
...
Behavior with Version 1.10 and newer
...
Job error handling can optionally be extended to include detect errors arising from output that is created by shell scripts.
Jira | ||||||||
---|---|---|---|---|---|---|---|---|
|
...
- Logging:
- Messages received via the standard error channel are added with error severity, e.g.
2015-03-18 07:57:38.993+0100 [error] This message goes to stderr
This behavior has precedence overJS-1393, i.e.
no specifics to identify the error channel as with [stderr] are added.
- Messages received via the standard error channel are added with error severity, e.g.
- Error Handling:
- The JobScheduler raises an error for any output to stderr from the shell script. This behavior extents JS-1393 that identfies the output channel that has been used.
- Depending on the job settings and the job node settings the usual behavior for failed execution would apply, e.g. the job could be stopped, the order could be suspended, setback, etc.
...
- This option applies to shell jobs, not to API jobs.
- It applies to jobs executed by JobScheduler instances, including clustered instances, and to JobScheduler Agents. An Agent forwards errors to the relevant JobScheduler Master.
Configuration
- Error handling for shell jobs is configured with the
<job stderr_log_level="error|info">
job attribute.- A value
error
causes shell job errors output to stderr to be considered by JobScheduler as errors. - The default value is
info
and causes the JobScheduler to stick to the behavior described for version 1.9 abovenot to raise an error.
- A value
Change Management References
...