Table of Contents |
---|
...
|
Executing Jobs On Demand:
The purpose of scheduled jobs is to perform a task at predetermined schedule like once in a week, every night at 11 pm or every minute. However, at times, you would like to trigger the scheduled job execution on demand especially when using the jobs to retrieve the data for integration with the other external systems.
...
Parameter | Description |
---|---|
jobId | ID of the scheduled job to run / queue for execution. Scheduled Job ID is a unique identifier assigned to every scheduled job in OpenSpecimen. This ID can be obtained from Jobs view UI. |
args | Space separated list of input arguments to the job. This can be empty if the job has no run time arguments as the input |
...
Job Runs
Whenever a scheduled job is executed, it creates scheduled job run. The idea of a run record is to capture the details of execution like when the job was executed, who executed it, and output of the execution, if any.
...
Parameter | Description |
---|---|
jobId | Scheduled Job ID whose run records are required. This is a required parameter. |
fromDate | Specifies the date/time after which the scheduled job run was created. This is an optional parameter. When not specified, it defaults to the earliest date/time known to the mankind. Example: a) b) |
toDate | Specifies the date/time before which the scheduled job run was created. This is an optional parameter. When not specified, it defaults to the current date/time. Follows the same format as fromDate. |
status | One of the 3 values given below. This is an optional parameter. When not specified, it is assumed job runs of all statuses are required.
|
Download the
...
Job Run Output
Some scheduled jobs like the saved query jobs created an output CSV file. The resultant CSV file can be downloaded using the API given below:
...