Monitoring the status of jobs that load data into the agreements internal knowledge base is possible using the ERM Agreement Jobs widget. While mostly we would expect (or at least hope!) that jobs will complete successfully without errors, we can use a widget to look out for jobs that have created errors and investigate their cause.
Checking for jobs with errors
Jobs that complete without errors are given a result of "success". Jobs with errors can receive the result of "partial_success" (if they ran to completion but generated errors) or "failure" or "interrupted" if they did not manage to run to completion.
- Navigate to the Dashboard app, and click the Actions button (top right) and select "New"
- In the "Widget name" enter "Jobs with errors"
- In the "Widget definition" dropdown select "ERM Agreement Jobs"
- Click "Add filter" and from the "Filter by" dropdown select "Job result"
- In Filter 1, Rule 1:
- change the "Comparator" to "is not"
- change the "Value" to "success"
- Click "Add filter" again and from the "Filter by" dropdown select "Job status"
- In Filter 2, Rule 1
- change the "Comparator" to "is"
- change the "Value" to "ended"
- The result should be two filters as follows:
- Scroll to the bottom of the widget configuration form and click the "Add column" button twice. This will add two additional columns to the display, all initially set to "Job name"
- Leave the first as "Job name", change the second one to "Number of errors" and third to "End time" by selecting the values from the dropdown menu
- You could decide to add other or different columns to your display depending on your requirements. You can also change the label used for each column if you do not want to use the default value which is added when you select the Column from the dropdown
- Set the "Sort by" option to "End time" and set the "Sort direction" to "asc" (ascending)
- Click "Save and close" to save the widget configuration and display the widget on the dashboard
- This widget has no filter on when the job ran, so any jobs with errors will remain in the widget (until they are knocked off the list depending on the number of rows you have selected to display). Therefore it is important to check the details of this carefully to know if there is a new entry on the list. The end time and job name can help you know if a new job has been added to the list since you last checked as they both include the date and time