Configuring Job Prioritization
Batch uses resource tags to calculate the priority value of each job.
Priority tags let you assign numerical values to tag values that are associated with a specific tag key. These values determine the job's priority score and therefore its scheduling order. Higher numerical values place jobs and their tasks higher in the queue when resources are limited.
Batch doesn't provide default tags for job prioritization. Before using the priority system, you must define your own tagging infrastructure and priority configuration.
- Create Tag Namespace: At the tenancy level, create a tag namespace to group all priority-related tags together (for example,
BatchPriority). - Define Tag keys and Values: Within the tag namespace, define tag keys with their possible values (for example, key:
deptwith values:lgt, lay, mdl, cfx, fx, cmp). - Assign Job Priority Configuration: In your batch context, add a job priority configuration. This references your tag namespace and keys and specifies how job priorities are weighted and calculated. For more information, see Job Priority Configuration.
- Assign Priority Tags to Jobs or Job Pools: When creating or editing a job or job pool, assign the relevant tag (for example,
BatchPriority:deptwith valuelgt). Batch references these tags, along with your job priority configuration, to determine job order in the scheduling queue.
When configuring job prioritization, assign numerical weights to each tag value (for example, HIGH = 10, LOW = 1, or Yes = 5, No = 0) in the tag management settings. You can update a job's priority by modifying the tags on the job or job pool. This approach lets you fine-tune job scheduling as priorities change.
To configure tag namespace and tag key definitions for Batch job prioritization, see Tag Namespaces and Tag Key Definitions.
After a job is submitted, Batch calculates its priority based on the configured tag values.
| Tag Namespace | Tag Key | Tag Values |
|---|---|---|
| Prioritization Tags | StudioPriority | LOW, MED, HIGH |
| Prioritization Tags | PriorityBoost | (Yes), (No) Note: Weight must be 100 percent. |
When configuring job prioritization, each tag key is assigned a weight (as a percentage) to control its influence on job priority calculation. Assign numerical values to each tag value within the key in the tag management settings (for example, for StudioPriority: LOW = 0, MED = 2, HIGH = 5).
The following table shows example tag keys and values used for job prioritization:
| Tag Namespace | Tag Key | Weight | Priorities |
|---|---|---|---|
| Prioritization Tags | StudioPriority | 100% | [(LOW, 0), (MED, 2), (HIGH, 5)] |
| Prioritization Tags | PriorityBoost | 100% | [(Yes, 10), (No, 0)] |