Skip to content
v2.277.0

BatchRestrictionsProperty Struct ​

Specifies restrictions for the batch build.

Example ​

ts
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import { aws_codebuild as codebuild } from 'aws-cdk-lib';
const batchRestrictionsProperty: codebuild.CfnProject.BatchRestrictionsProperty = {
  computeTypesAllowed: ['computeTypesAllowed'],
  fleetsAllowed: ['fleetsAllowed'],
  maximumBuildsAllowed: 123,
};
python
# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk import aws_codebuild as codebuild

batch_restrictions_property = codebuild.CfnProject.BatchRestrictionsProperty(
    compute_types_allowed=["computeTypesAllowed"],
    fleets_allowed=["fleetsAllowed"],
    maximum_builds_allowed=123
)
java
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import software.amazon.awscdk.services.codebuild.*;

BatchRestrictionsProperty batchRestrictionsProperty = BatchRestrictionsProperty.builder()
        .computeTypesAllowed(List.of("computeTypesAllowed"))
        .fleetsAllowed(List.of("fleetsAllowed"))
        .maximumBuildsAllowed(123)
        .build();
csharp
// Install: dotnet add package Amazon.CDK.Lib
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
using Amazon.CDK.AWS.CodeBuild;

var batchRestrictionsProperty = new BatchRestrictionsProperty {
    ComputeTypesAllowed = new [] { "computeTypesAllowed" },
    FleetsAllowed = new [] { "fleetsAllowed" },
    MaximumBuildsAllowed = 123
};
go
// Install: go get github.com/aws/aws-cdk-go/awscdk/v2
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import "github.com/aws/aws-cdk-go/awscdk"

batchRestrictionsProperty := &BatchRestrictionsProperty{
	ComputeTypesAllowed: []*string{
		jsii.String("computeTypesAllowed"),
	},
	FleetsAllowed: []*string{
		jsii.String("fleetsAllowed"),
	},
	MaximumBuildsAllowed: jsii.Number(123),
}

Properties ​

computeTypesAllowedoptionalstring[]compute_types_allowedoptionaltyping.List[str]computeTypesAllowedoptionalList<String>ComputeTypesAllowedoptionalstring[]ComputeTypesAllowedoptional*[]*string #
An array of strings that specify the compute types that are allowed for the batch build.

See Build environment compute types in the AWS CodeBuild User Guide for these values.

fleetsAllowedoptionalstring[]fleets_allowedoptionaltyping.List[str]fleetsAllowedoptionalList<String>FleetsAllowedoptionalstring[]FleetsAllowedoptional*[]*string #
maximumBuildsAllowedoptionalnumbermaximum_builds_allowedoptionalint | floatmaximumBuildsAllowedoptionalNumberMaximumBuildsAllowedoptionaldoubleMaximumBuildsAllowedoptional*float64 #
Specifies the maximum number of builds allowed.