You can check the status of jobs that have been submitted to Job Queue Manager by querying the database directly.
You can also use direct database access to remove failed jobs from the queue, change the job priority, and restart failed jobs. Follow these guidelines when directly accessing the database:
- Do not update a job that is in the RUNNING state.
- Do not update or otherwise modify the "queuedjob" "VERSIONNUM” as it is a reserved field.
- Do not update or otherwise modify the "queuedjob" "RESULT" as it is a binary data field.
Job Queue Statuses
To see all jobs and their current status, view the QueuedJob table and check the Status column:
The possible Status values are as follows:
The system has saved the job in the database but has not yet set its priority.
The system has calculated the priority of the job and scheduled it for processing.
The system is currently processing this job.
The system has processed the job and the result is ready for download.
The user who created the job has downloaded the result at least once.
An error occurred while processing the job but the job may succeed when the problem is resolved. For example, the Space-Time Research data server was down at the time the system tried to process the job.
An error occurred while processing the job and the job is unlikely to succeed if the system tries to run it again. For example, a job that needs a database that is not present on the system will not succeed until someone installs the missing database.
As an administrator, you should regularly check for the job queue for errors and for jobs that are stuck in the SUBMITTED state (a job should not be in this status for more than a few seconds).
A job in the ERROR state requires manual intervention by the administrator. Otherwise, it will remain in the ERROR state forever. Check the StatusDetails column and the ErrorDetails table for information about the cause of the error. See the troubleshooting section for help resolving errors.
Job Queue Priorities
Job Queue Manager automatically calculates a priority for each job when it is added to the database.
The priority is a numeric value between - 10^8 and + 10^8 that is used to determine which jobs get executed first: jobs with a higher priority number are executed first, and negative priority values are executed before positive priority values.
For example, if you have jobs in the queue with the following priority values: 100, 200, -1, 5, 4, 500, 400, -40
The jobs will be executed in this order:
You can review the priority for existing jobs by checking the Priority column.
Restart a Failed Job
If you have resolved the issue that caused a job to fail, you can restart the job by changing the job status in the database to SCHEDULED, for example using a SQL statement similar to the following:
<priority> with the job priority and
<job_id> with the ID of the job being rescheduled.
Restart All Failed Jobs
To restart all jobs in the ERROR state without changing their priorities, you could use the following SQL statement:
Delete Failed Jobs
To remove all jobs in the ERROR state, you could use the following SQL statements: