AWS v6.60.0 published on Tuesday, Nov 19, 2024 by Pulumi
aws.batch.getSchedulingPolicy
Explore with Pulumi AI
The Batch Scheduling Policy data source allows access to details of a specific Scheduling Policy within AWS Batch.
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as aws from "@pulumi/aws";
const test = aws.batch.getSchedulingPolicy({
arn: "arn:aws:batch:us-east-1:012345678910:scheduling-policy/example",
});
import pulumi
import pulumi_aws as aws
test = aws.batch.get_scheduling_policy(arn="arn:aws:batch:us-east-1:012345678910:scheduling-policy/example")
package main
import (
"github.com/pulumi/pulumi-aws/sdk/v6/go/aws/batch"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := batch.LookupSchedulingPolicy(ctx, &batch.LookupSchedulingPolicyArgs{
Arn: "arn:aws:batch:us-east-1:012345678910:scheduling-policy/example",
}, nil)
if err != nil {
return err
}
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Aws = Pulumi.Aws;
return await Deployment.RunAsync(() =>
{
var test = Aws.Batch.GetSchedulingPolicy.Invoke(new()
{
Arn = "arn:aws:batch:us-east-1:012345678910:scheduling-policy/example",
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.aws.batch.BatchFunctions;
import com.pulumi.aws.batch.inputs.GetSchedulingPolicyArgs;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;
public class App {
public static void main(String[] args) {
Pulumi.run(App::stack);
}
public static void stack(Context ctx) {
final var test = BatchFunctions.getSchedulingPolicy(GetSchedulingPolicyArgs.builder()
.arn("arn:aws:batch:us-east-1:012345678910:scheduling-policy/example")
.build());
}
}
variables:
test:
fn::invoke:
Function: aws:batch:getSchedulingPolicy
Arguments:
arn: arn:aws:batch:us-east-1:012345678910:scheduling-policy/example
Using getSchedulingPolicy
Two invocation forms are available. The direct form accepts plain arguments and either blocks until the result value is available, or returns a Promise-wrapped result. The output form accepts Input-wrapped arguments and returns an Output-wrapped result.
function getSchedulingPolicy(args: GetSchedulingPolicyArgs, opts?: InvokeOptions): Promise<GetSchedulingPolicyResult>
function getSchedulingPolicyOutput(args: GetSchedulingPolicyOutputArgs, opts?: InvokeOptions): Output<GetSchedulingPolicyResult>
def get_scheduling_policy(arn: Optional[str] = None,
tags: Optional[Mapping[str, str]] = None,
opts: Optional[InvokeOptions] = None) -> GetSchedulingPolicyResult
def get_scheduling_policy_output(arn: Optional[pulumi.Input[str]] = None,
tags: Optional[pulumi.Input[Mapping[str, pulumi.Input[str]]]] = None,
opts: Optional[InvokeOptions] = None) -> Output[GetSchedulingPolicyResult]
func LookupSchedulingPolicy(ctx *Context, args *LookupSchedulingPolicyArgs, opts ...InvokeOption) (*LookupSchedulingPolicyResult, error)
func LookupSchedulingPolicyOutput(ctx *Context, args *LookupSchedulingPolicyOutputArgs, opts ...InvokeOption) LookupSchedulingPolicyResultOutput
> Note: This function is named LookupSchedulingPolicy
in the Go SDK.
public static class GetSchedulingPolicy
{
public static Task<GetSchedulingPolicyResult> InvokeAsync(GetSchedulingPolicyArgs args, InvokeOptions? opts = null)
public static Output<GetSchedulingPolicyResult> Invoke(GetSchedulingPolicyInvokeArgs args, InvokeOptions? opts = null)
}
public static CompletableFuture<GetSchedulingPolicyResult> getSchedulingPolicy(GetSchedulingPolicyArgs args, InvokeOptions options)
// Output-based functions aren't available in Java yet
fn::invoke:
function: aws:batch/getSchedulingPolicy:getSchedulingPolicy
arguments:
# arguments dictionary
The following arguments are supported:
- Arn string
- ARN of the scheduling policy.
- Dictionary<string, string>
- Key-value map of resource tags
- Arn string
- ARN of the scheduling policy.
- map[string]string
- Key-value map of resource tags
- arn String
- ARN of the scheduling policy.
- Map<String,String>
- Key-value map of resource tags
- arn string
- ARN of the scheduling policy.
- {[key: string]: string}
- Key-value map of resource tags
- arn str
- ARN of the scheduling policy.
- Mapping[str, str]
- Key-value map of resource tags
- arn String
- ARN of the scheduling policy.
- Map<String>
- Key-value map of resource tags
getSchedulingPolicy Result
The following output properties are available:
- Arn string
- List<Get
Scheduling Policy Fair Share Policy> - Id string
- The provider-assigned unique ID for this managed resource.
- Name string
- Name of the scheduling policy.
- Dictionary<string, string>
- Key-value map of resource tags
- Arn string
- []Get
Scheduling Policy Fair Share Policy - Id string
- The provider-assigned unique ID for this managed resource.
- Name string
- Name of the scheduling policy.
- map[string]string
- Key-value map of resource tags
- arn String
- List<Get
Scheduling Policy Fair Share Policy> - id String
- The provider-assigned unique ID for this managed resource.
- name String
- Name of the scheduling policy.
- Map<String,String>
- Key-value map of resource tags
- arn string
- Get
Scheduling Policy Fair Share Policy[] - id string
- The provider-assigned unique ID for this managed resource.
- name string
- Name of the scheduling policy.
- {[key: string]: string}
- Key-value map of resource tags
- arn str
- Sequence[Get
Scheduling Policy Fair Share Policy] - id str
- The provider-assigned unique ID for this managed resource.
- name str
- Name of the scheduling policy.
- Mapping[str, str]
- Key-value map of resource tags
- arn String
- List<Property Map>
- id String
- The provider-assigned unique ID for this managed resource.
- name String
- Name of the scheduling policy.
- Map<String>
- Key-value map of resource tags
Supporting Types
GetSchedulingPolicyFairSharePolicy
- Compute
Reservation int - Value used to reserve some of the available maximum vCPU for fair share identifiers that have not yet been used. For more information, see FairsharePolicy.
- int
- List<Get
Scheduling Policy Fair Share Policy Share Distribution> - One or more share distribution blocks which define the weights for the fair share identifiers for the fair share policy. For more information, see FairsharePolicy. The
share_distribution
block is documented below.
- Compute
Reservation int - Value used to reserve some of the available maximum vCPU for fair share identifiers that have not yet been used. For more information, see FairsharePolicy.
- int
- []Get
Scheduling Policy Fair Share Policy Share Distribution - One or more share distribution blocks which define the weights for the fair share identifiers for the fair share policy. For more information, see FairsharePolicy. The
share_distribution
block is documented below.
- compute
Reservation Integer - Value used to reserve some of the available maximum vCPU for fair share identifiers that have not yet been used. For more information, see FairsharePolicy.
- Integer
- List<Get
Scheduling Policy Fair Share Policy Share Distribution> - One or more share distribution blocks which define the weights for the fair share identifiers for the fair share policy. For more information, see FairsharePolicy. The
share_distribution
block is documented below.
- compute
Reservation number - Value used to reserve some of the available maximum vCPU for fair share identifiers that have not yet been used. For more information, see FairsharePolicy.
- number
- Get
Scheduling Policy Fair Share Policy Share Distribution[] - One or more share distribution blocks which define the weights for the fair share identifiers for the fair share policy. For more information, see FairsharePolicy. The
share_distribution
block is documented below.
- compute_
reservation int - Value used to reserve some of the available maximum vCPU for fair share identifiers that have not yet been used. For more information, see FairsharePolicy.
- int
- Sequence[Get
Scheduling Policy Fair Share Policy Share Distribution] - One or more share distribution blocks which define the weights for the fair share identifiers for the fair share policy. For more information, see FairsharePolicy. The
share_distribution
block is documented below.
- compute
Reservation Number - Value used to reserve some of the available maximum vCPU for fair share identifiers that have not yet been used. For more information, see FairsharePolicy.
- Number
- List<Property Map>
- One or more share distribution blocks which define the weights for the fair share identifiers for the fair share policy. For more information, see FairsharePolicy. The
share_distribution
block is documented below.
GetSchedulingPolicyFairSharePolicyShareDistribution
- string
- Fair share identifier or fair share identifier prefix. For more information, see ShareAttributes.
- Weight
Factor double - Weight factor for the fair share identifier. For more information, see ShareAttributes.
- string
- Fair share identifier or fair share identifier prefix. For more information, see ShareAttributes.
- Weight
Factor float64 - Weight factor for the fair share identifier. For more information, see ShareAttributes.
- String
- Fair share identifier or fair share identifier prefix. For more information, see ShareAttributes.
- weight
Factor Double - Weight factor for the fair share identifier. For more information, see ShareAttributes.
- string
- Fair share identifier or fair share identifier prefix. For more information, see ShareAttributes.
- weight
Factor number - Weight factor for the fair share identifier. For more information, see ShareAttributes.
- str
- Fair share identifier or fair share identifier prefix. For more information, see ShareAttributes.
- weight_
factor float - Weight factor for the fair share identifier. For more information, see ShareAttributes.
- String
- Fair share identifier or fair share identifier prefix. For more information, see ShareAttributes.
- weight
Factor Number - Weight factor for the fair share identifier. For more information, see ShareAttributes.
Package Details
- Repository
- AWS Classic pulumi/pulumi-aws
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
aws
Terraform Provider.