What is a Background Job?
A background task is a passive procedure that runs in the background of active processes. They function in parallel and don't interfere with interactive (foreground jobs) procedures and operations.
In Tcode SM36 you can schedule background jobs. By checking its job log, you can analyze it from SM37.
Benefits of Background Jobs
- It automates the process and minimizes manual work.
- It can be scheduled to suit the user's preferences.
- It requires little user engagement and can operate without input in the background.
- The user doesn't have to worry about value entered in the field once the variant for the background job is defined.
- Ideal for lengthy or resource-intensive programs that can be set to run at night (when system load is low).
There are three different types of background job:
- Class A (High/Critical Priority): Certain jobs must be planned with class A priority due to their urgency or importance. One or more background work procedures are reserved for class A priorities. The number of background work processes that should be assigned to a Class A priority job must be decided by the users.
- Class B (Medium Priority): Following the completion of Class A activities, Class B jobs will begin running in the background before Class C jobs.
- Class C (Low Priority): It executes following the conclusion of class A and class B jobs.
Potential background job status
- Scheduled: Although the program name and variant have been specified, the start conditions, such as the start date, end date, frequency, etc., have not. That implies that you haven't specified in the system how a job should be scheduled.
- Released: All requirements for the job definition have been met. The job must meet the start condition requirement in order to be released.
- Ready: - All prerequisites for running the job in a background work process have been satisfied. But because it is awaiting the availability of the background work process, the job scheduler has placed the job in the queue.
- Active: The background job has begun to run. Once a job is in the "Active" status, we are unable to update it.
- Finished: The task has been completed successfully. It indicates flawless completion of the targeted task.
- Cancelled: There are two possible explanations for this. The Administrator has abruptly terminated the position, or there may be a problem with the position. Job logs can be used to look into this.