Skip to end of metadata
Go to start of metadata

Introduction

JS7 offers a number of strategies for error handling which are explained with the articles in this section.

Job warnings do not require error handling: 

  • Job return codes that signal warnings are considered successful execution of the job.
  • In addition, a JS7 - Notification is created in case of job warnings.

Warnings for Job Errors

See JS7 - How to detect job errors and warnings, chapter: Detect Job Warnings

Warnings for Jobs running longer than expected

If a job runs longer than expected a warning will be raised and a notification will be created. Find details from the JS7 - Job Instruction.

  • Warnings on longer job runs do not affect execution of jobs and are not subject to error handling.
  • Delimitation: Timeouts for job execution will terminate and will finally kill a running job exceeding the given limit. The job will be considered to have failed and error handling will apply.

Download example (upload .json): pdWarnIfLongerThan.workflow.json

Assume a job to be configured to consume 30s execution time like this:


The respective setting is available from the "Job Options" tab like this:

  • The Warn on longer execution setting is assumed to be 3s.
    • As an alternative to specifying seconds, the duration can be specified using the format hh:mm:ss, for example 01:30:00 for one and a half hours.
    • As an alternative to specifying absolute values, a percentage can be specified which is calculated from successful past job executions. A value 30% indicates that a warning is raised if the execution time exceeds the average by this ratio.
  • The job will raise a notification when exceeding this limit.


Warnings for Jobs running shorter than expected

If a job runs shorter than expected, a warning will be raised and a notification will be created. Find details from the JS7 - Job Instruction.

  • Warnings on shorter job runs do not affect execution of the job and are not subject to error handling.
  • A shorter job run can indicate a problem with the job, for example, in the event of a job processing less input data than expected.

Download example (upload .json): pdWarnIfShorterThan.workflow.json

Assume a job to be configured to consume 3s execution time like this:


The respective setting is available from the "Job Options" tab like this:

  • The Warn on shorter execution setting is assumed to be 30s.
    • As an alternative to specifying seconds the duration can be specified using the format hh:mm:ss, for example 01:30:00 for one and a half hours.
    • As an alternative to specifying absolute values a percentage can be specified that is calculated from successful past job executions. A value 30% indicates that a warning is raised if the execution time falls below the average by this ratio.
  • The job will cause a notification when falling below the threshold.

Notification

For any above warnings a JS7 - Notification is created.

  • Notifications are visible from the JOC Cockpit user interface with the Monitor->Notifications view.
  • Notifications can be configured to be forwarded:
    • by e-mail,
    • by writing to a log file,
    • by integration with a System Monitor or Message Queue (JMS).

The Monitor->Notifications view displays errors and warnings like this:

  • The  icon indicates warnings.
    • The message indicates respectively "Job runs longer than ..." or "Job runs shorter than ...". 
    • For job return codes that are configured as warnings the message indicates "Job return code 1 matches the configured warning ...".
  • The icon indicates errors.