1. Packages
  2. AWS Cloud Control
  3. API Docs
  4. batch
  5. SchedulingPolicy

We recommend new projects start with resources from the AWS provider.

AWS Cloud Control v1.27.0 published on Monday, Apr 14, 2025 by Pulumi

aws-native.batch.SchedulingPolicy

Explore with Pulumi AI

We recommend new projects start with resources from the AWS provider.

AWS Cloud Control v1.27.0 published on Monday, Apr 14, 2025 by Pulumi

Resource Type definition for AWS::Batch::SchedulingPolicy

Create SchedulingPolicy Resource

Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.

Constructor syntax

new SchedulingPolicy(name: string, args?: SchedulingPolicyArgs, opts?: CustomResourceOptions);
@overload
def SchedulingPolicy(resource_name: str,
                     args: Optional[SchedulingPolicyArgs] = None,
                     opts: Optional[ResourceOptions] = None)

@overload
def SchedulingPolicy(resource_name: str,
                     opts: Optional[ResourceOptions] = None,
                     fairshare_policy: Optional[SchedulingPolicyFairsharePolicyArgs] = None,
                     name: Optional[str] = None,
                     tags: Optional[Mapping[str, str]] = None)
func NewSchedulingPolicy(ctx *Context, name string, args *SchedulingPolicyArgs, opts ...ResourceOption) (*SchedulingPolicy, error)
public SchedulingPolicy(string name, SchedulingPolicyArgs? args = null, CustomResourceOptions? opts = null)
public SchedulingPolicy(String name, SchedulingPolicyArgs args)
public SchedulingPolicy(String name, SchedulingPolicyArgs args, CustomResourceOptions options)
type: aws-native:batch:SchedulingPolicy
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.

Parameters

name This property is required. string
The unique name of the resource.
args SchedulingPolicyArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.
resource_name This property is required. str
The unique name of the resource.
args SchedulingPolicyArgs
The arguments to resource properties.
opts ResourceOptions
Bag of options to control resource's behavior.
ctx Context
Context object for the current deployment.
name This property is required. string
The unique name of the resource.
args SchedulingPolicyArgs
The arguments to resource properties.
opts ResourceOption
Bag of options to control resource's behavior.
name This property is required. string
The unique name of the resource.
args SchedulingPolicyArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.
name This property is required. String
The unique name of the resource.
args This property is required. SchedulingPolicyArgs
The arguments to resource properties.
options CustomResourceOptions
Bag of options to control resource's behavior.

SchedulingPolicy Resource Properties

To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.

Inputs

In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.

The SchedulingPolicy resource accepts the following input properties:

FairsharePolicy Pulumi.AwsNative.Batch.Inputs.SchedulingPolicyFairsharePolicy
The fair-share scheduling policy details.
Name string
Name of Scheduling Policy.
Tags Dictionary<string, string>
A key-value pair to associate with a resource.
FairsharePolicy SchedulingPolicyFairsharePolicyArgs
The fair-share scheduling policy details.
Name string
Name of Scheduling Policy.
Tags map[string]string
A key-value pair to associate with a resource.
fairsharePolicy SchedulingPolicyFairsharePolicy
The fair-share scheduling policy details.
name String
Name of Scheduling Policy.
tags Map<String,String>
A key-value pair to associate with a resource.
fairsharePolicy SchedulingPolicyFairsharePolicy
The fair-share scheduling policy details.
name string
Name of Scheduling Policy.
tags {[key: string]: string}
A key-value pair to associate with a resource.
fairshare_policy SchedulingPolicyFairsharePolicyArgs
The fair-share scheduling policy details.
name str
Name of Scheduling Policy.
tags Mapping[str, str]
A key-value pair to associate with a resource.
fairsharePolicy Property Map
The fair-share scheduling policy details.
name String
Name of Scheduling Policy.
tags Map<String>
A key-value pair to associate with a resource.

Outputs

All input properties are implicitly available as output properties. Additionally, the SchedulingPolicy resource produces the following output properties:

Arn string
Returns the scheduling policy ARN, such as batch: *us-east-1* : *111122223333* :scheduling-policy/ *HighPriority* .
Id string
The provider-assigned unique ID for this managed resource.
Arn string
Returns the scheduling policy ARN, such as batch: *us-east-1* : *111122223333* :scheduling-policy/ *HighPriority* .
Id string
The provider-assigned unique ID for this managed resource.
arn String
Returns the scheduling policy ARN, such as batch: *us-east-1* : *111122223333* :scheduling-policy/ *HighPriority* .
id String
The provider-assigned unique ID for this managed resource.
arn string
Returns the scheduling policy ARN, such as batch: *us-east-1* : *111122223333* :scheduling-policy/ *HighPriority* .
id string
The provider-assigned unique ID for this managed resource.
arn str
Returns the scheduling policy ARN, such as batch: *us-east-1* : *111122223333* :scheduling-policy/ *HighPriority* .
id str
The provider-assigned unique ID for this managed resource.
arn String
Returns the scheduling policy ARN, such as batch: *us-east-1* : *111122223333* :scheduling-policy/ *HighPriority* .
id String
The provider-assigned unique ID for this managed resource.

Supporting Types

SchedulingPolicyFairsharePolicy
, SchedulingPolicyFairsharePolicyArgs

ComputeReservation double

A value used to reserve some of the available maximum vCPU for share identifiers that aren't already used.

The reserved ratio is ( *computeReservation* /100)^ *ActiveFairShares* where *ActiveFairShares* is the number of active share identifiers.

For example, a computeReservation value of 50 indicates that AWS Batch reserves 50% of the maximum available vCPU if there's only one share identifier. It reserves 25% if there are two share identifiers. It reserves 12.5% if there are three share identifiers. A computeReservation value of 25 indicates that AWS Batch should reserve 25% of the maximum available vCPU if there's only one share identifier, 6.25% if there are two fair share identifiers, and 1.56% if there are three share identifiers.

The minimum value is 0 and the maximum value is 99.

ShareDecaySeconds double

The amount of time (in seconds) to use to calculate a fair-share percentage for each share identifier in use. A value of zero (0) indicates the default minimum time window (600 seconds). The maximum supported value is 604800 (1 week).

The decay allows for more recently run jobs to have more weight than jobs that ran earlier. Consider adjusting this number if you have jobs that (on average) run longer than ten minutes, or a large difference in job count or job run times between share identifiers, and the allocation of resources doesn’t meet your needs.

ShareDistribution List<Pulumi.AwsNative.Batch.Inputs.SchedulingPolicyShareAttributes>
List of Share Attributes
ComputeReservation float64

A value used to reserve some of the available maximum vCPU for share identifiers that aren't already used.

The reserved ratio is ( *computeReservation* /100)^ *ActiveFairShares* where *ActiveFairShares* is the number of active share identifiers.

For example, a computeReservation value of 50 indicates that AWS Batch reserves 50% of the maximum available vCPU if there's only one share identifier. It reserves 25% if there are two share identifiers. It reserves 12.5% if there are three share identifiers. A computeReservation value of 25 indicates that AWS Batch should reserve 25% of the maximum available vCPU if there's only one share identifier, 6.25% if there are two fair share identifiers, and 1.56% if there are three share identifiers.

The minimum value is 0 and the maximum value is 99.

ShareDecaySeconds float64

The amount of time (in seconds) to use to calculate a fair-share percentage for each share identifier in use. A value of zero (0) indicates the default minimum time window (600 seconds). The maximum supported value is 604800 (1 week).

The decay allows for more recently run jobs to have more weight than jobs that ran earlier. Consider adjusting this number if you have jobs that (on average) run longer than ten minutes, or a large difference in job count or job run times between share identifiers, and the allocation of resources doesn’t meet your needs.

ShareDistribution []SchedulingPolicyShareAttributes
List of Share Attributes
computeReservation Double

A value used to reserve some of the available maximum vCPU for share identifiers that aren't already used.

The reserved ratio is ( *computeReservation* /100)^ *ActiveFairShares* where *ActiveFairShares* is the number of active share identifiers.

For example, a computeReservation value of 50 indicates that AWS Batch reserves 50% of the maximum available vCPU if there's only one share identifier. It reserves 25% if there are two share identifiers. It reserves 12.5% if there are three share identifiers. A computeReservation value of 25 indicates that AWS Batch should reserve 25% of the maximum available vCPU if there's only one share identifier, 6.25% if there are two fair share identifiers, and 1.56% if there are three share identifiers.

The minimum value is 0 and the maximum value is 99.

shareDecaySeconds Double

The amount of time (in seconds) to use to calculate a fair-share percentage for each share identifier in use. A value of zero (0) indicates the default minimum time window (600 seconds). The maximum supported value is 604800 (1 week).

The decay allows for more recently run jobs to have more weight than jobs that ran earlier. Consider adjusting this number if you have jobs that (on average) run longer than ten minutes, or a large difference in job count or job run times between share identifiers, and the allocation of resources doesn’t meet your needs.

shareDistribution List<SchedulingPolicyShareAttributes>
List of Share Attributes
computeReservation number

A value used to reserve some of the available maximum vCPU for share identifiers that aren't already used.

The reserved ratio is ( *computeReservation* /100)^ *ActiveFairShares* where *ActiveFairShares* is the number of active share identifiers.

For example, a computeReservation value of 50 indicates that AWS Batch reserves 50% of the maximum available vCPU if there's only one share identifier. It reserves 25% if there are two share identifiers. It reserves 12.5% if there are three share identifiers. A computeReservation value of 25 indicates that AWS Batch should reserve 25% of the maximum available vCPU if there's only one share identifier, 6.25% if there are two fair share identifiers, and 1.56% if there are three share identifiers.

The minimum value is 0 and the maximum value is 99.

shareDecaySeconds number

The amount of time (in seconds) to use to calculate a fair-share percentage for each share identifier in use. A value of zero (0) indicates the default minimum time window (600 seconds). The maximum supported value is 604800 (1 week).

The decay allows for more recently run jobs to have more weight than jobs that ran earlier. Consider adjusting this number if you have jobs that (on average) run longer than ten minutes, or a large difference in job count or job run times between share identifiers, and the allocation of resources doesn’t meet your needs.

shareDistribution SchedulingPolicyShareAttributes[]
List of Share Attributes
compute_reservation float

A value used to reserve some of the available maximum vCPU for share identifiers that aren't already used.

The reserved ratio is ( *computeReservation* /100)^ *ActiveFairShares* where *ActiveFairShares* is the number of active share identifiers.

For example, a computeReservation value of 50 indicates that AWS Batch reserves 50% of the maximum available vCPU if there's only one share identifier. It reserves 25% if there are two share identifiers. It reserves 12.5% if there are three share identifiers. A computeReservation value of 25 indicates that AWS Batch should reserve 25% of the maximum available vCPU if there's only one share identifier, 6.25% if there are two fair share identifiers, and 1.56% if there are three share identifiers.

The minimum value is 0 and the maximum value is 99.

share_decay_seconds float

The amount of time (in seconds) to use to calculate a fair-share percentage for each share identifier in use. A value of zero (0) indicates the default minimum time window (600 seconds). The maximum supported value is 604800 (1 week).

The decay allows for more recently run jobs to have more weight than jobs that ran earlier. Consider adjusting this number if you have jobs that (on average) run longer than ten minutes, or a large difference in job count or job run times between share identifiers, and the allocation of resources doesn’t meet your needs.

share_distribution Sequence[SchedulingPolicyShareAttributes]
List of Share Attributes
computeReservation Number

A value used to reserve some of the available maximum vCPU for share identifiers that aren't already used.

The reserved ratio is ( *computeReservation* /100)^ *ActiveFairShares* where *ActiveFairShares* is the number of active share identifiers.

For example, a computeReservation value of 50 indicates that AWS Batch reserves 50% of the maximum available vCPU if there's only one share identifier. It reserves 25% if there are two share identifiers. It reserves 12.5% if there are three share identifiers. A computeReservation value of 25 indicates that AWS Batch should reserve 25% of the maximum available vCPU if there's only one share identifier, 6.25% if there are two fair share identifiers, and 1.56% if there are three share identifiers.

The minimum value is 0 and the maximum value is 99.

shareDecaySeconds Number

The amount of time (in seconds) to use to calculate a fair-share percentage for each share identifier in use. A value of zero (0) indicates the default minimum time window (600 seconds). The maximum supported value is 604800 (1 week).

The decay allows for more recently run jobs to have more weight than jobs that ran earlier. Consider adjusting this number if you have jobs that (on average) run longer than ten minutes, or a large difference in job count or job run times between share identifiers, and the allocation of resources doesn’t meet your needs.

shareDistribution List<Property Map>
List of Share Attributes

SchedulingPolicyShareAttributes
, SchedulingPolicyShareAttributesArgs

ShareIdentifier string

A share identifier or share identifier prefix. If the string ends with an asterisk (*), this entry specifies the weight factor to use for share identifiers that start with that prefix. The list of share identifiers in a fair-share policy can't overlap. For example, you can't have one that specifies a shareIdentifier of UserA* and another that specifies a shareIdentifier of UserA-1 .

There can be no more than 500 share identifiers active in a job queue.

The string is limited to 255 alphanumeric characters, and can be followed by an asterisk (*).

WeightFactor double

The weight factor for the share identifier. The default value is 1.0. A lower value has a higher priority for compute resources. For example, jobs that use a share identifier with a weight factor of 0.125 (1/8) get 8 times the compute resources of jobs that use a share identifier with a weight factor of 1.

The smallest supported value is 0.0001, and the largest supported value is 999.9999.

ShareIdentifier string

A share identifier or share identifier prefix. If the string ends with an asterisk (*), this entry specifies the weight factor to use for share identifiers that start with that prefix. The list of share identifiers in a fair-share policy can't overlap. For example, you can't have one that specifies a shareIdentifier of UserA* and another that specifies a shareIdentifier of UserA-1 .

There can be no more than 500 share identifiers active in a job queue.

The string is limited to 255 alphanumeric characters, and can be followed by an asterisk (*).

WeightFactor float64

The weight factor for the share identifier. The default value is 1.0. A lower value has a higher priority for compute resources. For example, jobs that use a share identifier with a weight factor of 0.125 (1/8) get 8 times the compute resources of jobs that use a share identifier with a weight factor of 1.

The smallest supported value is 0.0001, and the largest supported value is 999.9999.

shareIdentifier String

A share identifier or share identifier prefix. If the string ends with an asterisk (*), this entry specifies the weight factor to use for share identifiers that start with that prefix. The list of share identifiers in a fair-share policy can't overlap. For example, you can't have one that specifies a shareIdentifier of UserA* and another that specifies a shareIdentifier of UserA-1 .

There can be no more than 500 share identifiers active in a job queue.

The string is limited to 255 alphanumeric characters, and can be followed by an asterisk (*).

weightFactor Double

The weight factor for the share identifier. The default value is 1.0. A lower value has a higher priority for compute resources. For example, jobs that use a share identifier with a weight factor of 0.125 (1/8) get 8 times the compute resources of jobs that use a share identifier with a weight factor of 1.

The smallest supported value is 0.0001, and the largest supported value is 999.9999.

shareIdentifier string

A share identifier or share identifier prefix. If the string ends with an asterisk (*), this entry specifies the weight factor to use for share identifiers that start with that prefix. The list of share identifiers in a fair-share policy can't overlap. For example, you can't have one that specifies a shareIdentifier of UserA* and another that specifies a shareIdentifier of UserA-1 .

There can be no more than 500 share identifiers active in a job queue.

The string is limited to 255 alphanumeric characters, and can be followed by an asterisk (*).

weightFactor number

The weight factor for the share identifier. The default value is 1.0. A lower value has a higher priority for compute resources. For example, jobs that use a share identifier with a weight factor of 0.125 (1/8) get 8 times the compute resources of jobs that use a share identifier with a weight factor of 1.

The smallest supported value is 0.0001, and the largest supported value is 999.9999.

share_identifier str

A share identifier or share identifier prefix. If the string ends with an asterisk (*), this entry specifies the weight factor to use for share identifiers that start with that prefix. The list of share identifiers in a fair-share policy can't overlap. For example, you can't have one that specifies a shareIdentifier of UserA* and another that specifies a shareIdentifier of UserA-1 .

There can be no more than 500 share identifiers active in a job queue.

The string is limited to 255 alphanumeric characters, and can be followed by an asterisk (*).

weight_factor float

The weight factor for the share identifier. The default value is 1.0. A lower value has a higher priority for compute resources. For example, jobs that use a share identifier with a weight factor of 0.125 (1/8) get 8 times the compute resources of jobs that use a share identifier with a weight factor of 1.

The smallest supported value is 0.0001, and the largest supported value is 999.9999.

shareIdentifier String

A share identifier or share identifier prefix. If the string ends with an asterisk (*), this entry specifies the weight factor to use for share identifiers that start with that prefix. The list of share identifiers in a fair-share policy can't overlap. For example, you can't have one that specifies a shareIdentifier of UserA* and another that specifies a shareIdentifier of UserA-1 .

There can be no more than 500 share identifiers active in a job queue.

The string is limited to 255 alphanumeric characters, and can be followed by an asterisk (*).

weightFactor Number

The weight factor for the share identifier. The default value is 1.0. A lower value has a higher priority for compute resources. For example, jobs that use a share identifier with a weight factor of 0.125 (1/8) get 8 times the compute resources of jobs that use a share identifier with a weight factor of 1.

The smallest supported value is 0.0001, and the largest supported value is 999.9999.

Package Details

Repository
AWS Native pulumi/pulumi-aws-native
License
Apache-2.0

We recommend new projects start with resources from the AWS provider.

AWS Cloud Control v1.27.0 published on Monday, Apr 14, 2025 by Pulumi