AWS Batch quota sharing separates two decisions that AI infrastructure teams often have to make together: how much training capacity a project normally receives, and what happens to that allocation while the project is idle. The service's published API models document options to reserve the allocation, lend it to other shares, or both lend and borrow. They also expose separate controls for borrowing limits and job preemption.[1][2]
The distinction matters when several teams submit SageMaker Training jobs through a shared queue. A project may need predictable access for urgent work while another has experiments that can wait. Quota shares encode those allocation rules, but they are scheduler limits rather than a promise of new physical instances. The service environment still constrains the resources available to its jobs.[1][2]
Three sharing strategies
What each quota-share strategy permits
| Strategy | Idle allocation | Borrowing from another share |
|---|---|---|
| RESERVE | Held for the share | Not enabled by this strategySource 1Source 2 |
| LEND | Available to another share | Not enabled by this strategySource 1Source 2 |
| LEND_AND_BORROW | Available to another share | Permitted, subject to configured limitsSource 1Source 2 |
A share's maxCapacity is the quantity it can allocate without borrowing. Its capacityUnit identifies the resource type. For a quota-enabled SageMaker Training environment, the documentation uses an instance type as that unit, rather than treating all machines as interchangeable. A limit for one instance type does not create a matching limit for another. This is especially relevant when a team discusses a GPU budget but its jobs request instances with different hardware configurations.[1][2]
For LEND_AND_BORROW, borrowLimit is an additional allowance expressed as a percentage of the share's configured capacity. In a hypothetical share with a ten-instance allocation, a borrowLimit of 200 would permit borrowing up to twenty more matching instances, for thirty in total if sufficient resources were available. It does not mean a total limit of twenty. The documented default of −1 means the share has no borrowing cap at that setting; it does not remove the environment's capacity constraints.[1][2]
Priority and interruption are separate settings
The quota-share policy currently documents FIFO assignment of idle resources to borrowing shares. Within a share, administrators can separately enable inSharePreemption so that a higher-priority job can preempt another job in the same share. Borrowing policy and within-share preemption therefore answer different questions: which allocation a job may use, and whether another job can interrupt it.[1][2]
The service-job configuration also provides preemptionRetriesBeforeTermination, which limits how often a preempted job can be retried. If it is unset, the API documentation says preempted jobs can be requeued without a retry-count limit. That retry policy is not itself a checkpoint. Recovering training progress depends on whether the workload saved usable state and can restore it when it runs again.[1][2]
That creates a practical cost trade-off. Sharing spare allocation can reduce waiting while resources would otherwise be idle, but repeated interruptions may consume time reloading data or repeating work after the last checkpoint. A team evaluating the setup needs completion time and useful training progress, not just a high percentage of occupied instances. The API definitions do not establish a measured cost saving for any particular customer.[1][2]
Configuration choices that matter before a rollout
The scheduling policy accepts either quotaSharePolicy or fairsharePolicy, not both. The documented policy type cannot subsequently be converted into the other type. A quota share belongs to a job queue, and service jobs submitted to a queue using quota-share scheduling must identify their quotaShareName. Those are configuration dependencies worth checking before migrating an existing queue.[1][2]
This is a documentation-based explanation, not a test deployment. The useful capability is explicit control over allocation, spare-capacity sharing and interruption behaviour. Whether it improves a team's GPU economics depends on the actual workload mix, available instance types, queue delays and the cost of recovering from preemption.[1][2]
Sources & further reading
- AWS Batch API service model: quota shares, scheduling policies and service-job preemption AWS SDK for Python / Botocore · Accessed 30 Oct 2026
- AWS SDK for Go v2: Batch quota-share and service-job types Amazon Web Services · Accessed 30 Oct 2026