Skip to content
v2.274.0

CfnFleet L1 construct ​

Creates a fleet.

Fleets gather information relating to compute, or capacity, for renders within your farms. You can choose to manage your own capacity or opt to have fleets fully managed by Deadline Cloud.

Example ​

ts
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import { aws_deadline as deadline } from 'aws-cdk-lib';
const cfnFleet = new deadline.CfnFleet(this, 'MyCfnFleet', {
  configuration: {
    customerManaged: {
      mode: 'mode',
      workerCapabilities: {
        cpuArchitectureType: 'cpuArchitectureType',
        memoryMiB: {
          min: 123,

          // the properties below are optional
          max: 123,
        },
        osFamily: 'osFamily',
        vCpuCount: {
          min: 123,

          // the properties below are optional
          max: 123,
        },

        // the properties below are optional
        acceleratorCount: {
          min: 123,

          // the properties below are optional
          max: 123,
        },
        acceleratorTotalMemoryMiB: {
          min: 123,

          // the properties below are optional
          max: 123,
        },
        acceleratorTypes: ['acceleratorTypes'],
        customAmounts: [{
          min: 123,
          name: 'name',

          // the properties below are optional
          max: 123,
        }],
        customAttributes: [{
          name: 'name',
          values: ['values'],
        }],
      },

      // the properties below are optional
      autoScalingConfiguration: {
        scaleOutWorkersPerMinute: 123,
        standbyWorkerCount: 123,
        workerIdleDurationSeconds: 123,
      },
      storageProfileId: 'storageProfileId',
      tagPropagationMode: 'tagPropagationMode',
    },
    serviceManagedEc2: {
      instanceCapabilities: {
        cpuArchitectureType: 'cpuArchitectureType',
        memoryMiB: {
          min: 123,

          // the properties below are optional
          max: 123,
        },
        osFamily: 'osFamily',
        vCpuCount: {
          min: 123,

          // the properties below are optional
          max: 123,
        },

        // the properties below are optional
        acceleratorCapabilities: {
          selections: [{
            name: 'name',

            // the properties below are optional
            runtime: 'runtime',
          }],

          // the properties below are optional
          count: {
            min: 123,

            // the properties below are optional
            max: 123,
          },
        },
        allowedInstanceTypes: ['allowedInstanceTypes'],
        customAmounts: [{
          min: 123,
          name: 'name',

          // the properties below are optional
          max: 123,
        }],
        customAttributes: [{
          name: 'name',
          values: ['values'],
        }],
        excludedInstanceTypes: ['excludedInstanceTypes'],
        rootEbsVolume: {
          iops: 123,
          sizeGiB: 123,
          throughputMiB: 123,
        },
      },
      instanceMarketOptions: {
        type: 'type',
      },

      // the properties below are optional
      autoScalingConfiguration: {
        scaleOutWorkersPerMinute: 123,
        standbyWorkerCount: 123,
        workerIdleDurationSeconds: 123,
      },
      persistentVolumeConfiguration: {
        mountPath: 'mountPath',

        // the properties below are optional
        iops: 123,
        lastUsedTtlHours: 123,
        sizeGiB: 123,
        throughputMiB: 123,
      },
      storageProfileId: 'storageProfileId',
      vpcConfiguration: {
        resourceConfigurationArns: ['resourceConfigurationArns'],
      },
    },
  },
  displayName: 'displayName',
  farmId: 'farmId',
  maxWorkerCount: 123,
  roleArn: 'roleArn',

  // the properties below are optional
  description: 'description',
  hostConfiguration: {
    scriptBody: 'scriptBody',

    // the properties below are optional
    scriptTimeoutSeconds: 123,
  },
  minWorkerCount: 123,
  tags: [{
    key: 'key',
    value: 'value',
  }],
});
python
from aws_cdk import CfnTag
# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk import aws_deadline as deadline

cfn_fleet = deadline.CfnFleet(self, "MyCfnFleet",
    configuration=deadline.CfnFleet.FleetConfigurationProperty(
        customer_managed=deadline.CfnFleet.CustomerManagedFleetConfigurationProperty(
            mode="mode",
            worker_capabilities=deadline.CfnFleet.CustomerManagedWorkerCapabilitiesProperty(
                cpu_architecture_type="cpuArchitectureType",
                memory_mi_b=deadline.CfnFleet.MemoryMiBRangeProperty(
                    min=123,

                    # the properties below are optional
                    max=123
                ),
                os_family="osFamily",
                v_cpu_count=deadline.CfnFleet.VCpuCountRangeProperty(
                    min=123,

                    # the properties below are optional
                    max=123
                ),

                # the properties below are optional
                accelerator_count=deadline.CfnFleet.AcceleratorCountRangeProperty(
                    min=123,

                    # the properties below are optional
                    max=123
                ),
                accelerator_total_memory_mi_b=deadline.CfnFleet.AcceleratorTotalMemoryMiBRangeProperty(
                    min=123,

                    # the properties below are optional
                    max=123
                ),
                accelerator_types=["acceleratorTypes"],
                custom_amounts=[deadline.CfnFleet.FleetAmountCapabilityProperty(
                    min=123,
                    name="name",

                    # the properties below are optional
                    max=123
                )],
                custom_attributes=[deadline.CfnFleet.FleetAttributeCapabilityProperty(
                    name="name",
                    values=["values"]
                )]
            ),

            # the properties below are optional
            auto_scaling_configuration=deadline.CfnFleet.CustomerManagedAutoScalingConfigurationProperty(
                scale_out_workers_per_minute=123,
                standby_worker_count=123,
                worker_idle_duration_seconds=123
            ),
            storage_profile_id="storageProfileId",
            tag_propagation_mode="tagPropagationMode"
        ),
        service_managed_ec2=deadline.CfnFleet.ServiceManagedEc2FleetConfigurationProperty(
            instance_capabilities=deadline.CfnFleet.ServiceManagedEc2InstanceCapabilitiesProperty(
                cpu_architecture_type="cpuArchitectureType",
                memory_mi_b=deadline.CfnFleet.MemoryMiBRangeProperty(
                    min=123,

                    # the properties below are optional
                    max=123
                ),
                os_family="osFamily",
                v_cpu_count=deadline.CfnFleet.VCpuCountRangeProperty(
                    min=123,

                    # the properties below are optional
                    max=123
                ),

                # the properties below are optional
                accelerator_capabilities=deadline.CfnFleet.AcceleratorCapabilitiesProperty(
                    selections=[deadline.CfnFleet.AcceleratorSelectionProperty(
                        name="name",

                        # the properties below are optional
                        runtime="runtime"
                    )],

                    # the properties below are optional
                    count=deadline.CfnFleet.AcceleratorCountRangeProperty(
                        min=123,

                        # the properties below are optional
                        max=123
                    )
                ),
                allowed_instance_types=["allowedInstanceTypes"],
                custom_amounts=[deadline.CfnFleet.FleetAmountCapabilityProperty(
                    min=123,
                    name="name",

                    # the properties below are optional
                    max=123
                )],
                custom_attributes=[deadline.CfnFleet.FleetAttributeCapabilityProperty(
                    name="name",
                    values=["values"]
                )],
                excluded_instance_types=["excludedInstanceTypes"],
                root_ebs_volume=deadline.CfnFleet.Ec2EbsVolumeProperty(
                    iops=123,
                    size_gi_b=123,
                    throughput_mi_b=123
                )
            ),
            instance_market_options=deadline.CfnFleet.ServiceManagedEc2InstanceMarketOptionsProperty(
                type="type"
            ),

            # the properties below are optional
            auto_scaling_configuration=deadline.CfnFleet.ServiceManagedEc2AutoScalingConfigurationProperty(
                scale_out_workers_per_minute=123,
                standby_worker_count=123,
                worker_idle_duration_seconds=123
            ),
            persistent_volume_configuration=deadline.CfnFleet.PersistentVolumeConfigurationProperty(
                mount_path="mountPath",

                # the properties below are optional
                iops=123,
                last_used_ttl_hours=123,
                size_gi_b=123,
                throughput_mi_b=123
            ),
            storage_profile_id="storageProfileId",
            vpc_configuration=deadline.CfnFleet.VpcConfigurationProperty(
                resource_configuration_arns=["resourceConfigurationArns"]
            )
        )
    ),
    display_name="displayName",
    farm_id="farmId",
    max_worker_count=123,
    role_arn="roleArn",

    # the properties below are optional
    description="description",
    host_configuration=deadline.CfnFleet.HostConfigurationProperty(
        script_body="scriptBody",

        # the properties below are optional
        script_timeout_seconds=123
    ),
    min_worker_count=123,
    tags=[CfnTag(
        key="key",
        value="value"
    )]
)
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.deadline.*;

CfnFleet cfnFleet = CfnFleet.Builder.create(this, "MyCfnFleet")
        .configuration(FleetConfigurationProperty.builder()
                .customerManaged(CustomerManagedFleetConfigurationProperty.builder()
                        .mode("mode")
                        .workerCapabilities(CustomerManagedWorkerCapabilitiesProperty.builder()
                                .cpuArchitectureType("cpuArchitectureType")
                                .memoryMiB(MemoryMiBRangeProperty.builder()
                                        .min(123)

                                        // the properties below are optional
                                        .max(123)
                                        .build())
                                .osFamily("osFamily")
                                .vCpuCount(VCpuCountRangeProperty.builder()
                                        .min(123)

                                        // the properties below are optional
                                        .max(123)
                                        .build())

                                // the properties below are optional
                                .acceleratorCount(AcceleratorCountRangeProperty.builder()
                                        .min(123)

                                        // the properties below are optional
                                        .max(123)
                                        .build())
                                .acceleratorTotalMemoryMiB(AcceleratorTotalMemoryMiBRangeProperty.builder()
                                        .min(123)

                                        // the properties below are optional
                                        .max(123)
                                        .build())
                                .acceleratorTypes(List.of("acceleratorTypes"))
                                .customAmounts(List.of(FleetAmountCapabilityProperty.builder()
                                        .min(123)
                                        .name("name")

                                        // the properties below are optional
                                        .max(123)
                                        .build()))
                                .customAttributes(List.of(FleetAttributeCapabilityProperty.builder()
                                        .name("name")
                                        .values(List.of("values"))
                                        .build()))
                                .build())

                        // the properties below are optional
                        .autoScalingConfiguration(CustomerManagedAutoScalingConfigurationProperty.builder()
                                .scaleOutWorkersPerMinute(123)
                                .standbyWorkerCount(123)
                                .workerIdleDurationSeconds(123)
                                .build())
                        .storageProfileId("storageProfileId")
                        .tagPropagationMode("tagPropagationMode")
                        .build())
                .serviceManagedEc2(ServiceManagedEc2FleetConfigurationProperty.builder()
                        .instanceCapabilities(ServiceManagedEc2InstanceCapabilitiesProperty.builder()
                                .cpuArchitectureType("cpuArchitectureType")
                                .memoryMiB(MemoryMiBRangeProperty.builder()
                                        .min(123)

                                        // the properties below are optional
                                        .max(123)
                                        .build())
                                .osFamily("osFamily")
                                .vCpuCount(VCpuCountRangeProperty.builder()
                                        .min(123)

                                        // the properties below are optional
                                        .max(123)
                                        .build())

                                // the properties below are optional
                                .acceleratorCapabilities(AcceleratorCapabilitiesProperty.builder()
                                        .selections(List.of(AcceleratorSelectionProperty.builder()
                                                .name("name")

                                                // the properties below are optional
                                                .runtime("runtime")
                                                .build()))

                                        // the properties below are optional
                                        .count(AcceleratorCountRangeProperty.builder()
                                                .min(123)

                                                // the properties below are optional
                                                .max(123)
                                                .build())
                                        .build())
                                .allowedInstanceTypes(List.of("allowedInstanceTypes"))
                                .customAmounts(List.of(FleetAmountCapabilityProperty.builder()
                                        .min(123)
                                        .name("name")

                                        // the properties below are optional
                                        .max(123)
                                        .build()))
                                .customAttributes(List.of(FleetAttributeCapabilityProperty.builder()
                                        .name("name")
                                        .values(List.of("values"))
                                        .build()))
                                .excludedInstanceTypes(List.of("excludedInstanceTypes"))
                                .rootEbsVolume(Ec2EbsVolumeProperty.builder()
                                        .iops(123)
                                        .sizeGiB(123)
                                        .throughputMiB(123)
                                        .build())
                                .build())
                        .instanceMarketOptions(ServiceManagedEc2InstanceMarketOptionsProperty.builder()
                                .type("type")
                                .build())

                        // the properties below are optional
                        .autoScalingConfiguration(ServiceManagedEc2AutoScalingConfigurationProperty.builder()
                                .scaleOutWorkersPerMinute(123)
                                .standbyWorkerCount(123)
                                .workerIdleDurationSeconds(123)
                                .build())
                        .persistentVolumeConfiguration(PersistentVolumeConfigurationProperty.builder()
                                .mountPath("mountPath")

                                // the properties below are optional
                                .iops(123)
                                .lastUsedTtlHours(123)
                                .sizeGiB(123)
                                .throughputMiB(123)
                                .build())
                        .storageProfileId("storageProfileId")
                        .vpcConfiguration(VpcConfigurationProperty.builder()
                                .resourceConfigurationArns(List.of("resourceConfigurationArns"))
                                .build())
                        .build())
                .build())
        .displayName("displayName")
        .farmId("farmId")
        .maxWorkerCount(123)
        .roleArn("roleArn")

        // the properties below are optional
        .description("description")
        .hostConfiguration(HostConfigurationProperty.builder()
                .scriptBody("scriptBody")

                // the properties below are optional
                .scriptTimeoutSeconds(123)
                .build())
        .minWorkerCount(123)
        .tags(List.of(CfnTag.builder()
                .key("key")
                .value("value")
                .build()))
        .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.Deadline;

var cfnFleet = new CfnFleet(this, "MyCfnFleet", new CfnFleetProps {
    Configuration = new FleetConfigurationProperty {
        CustomerManaged = new CustomerManagedFleetConfigurationProperty {
            Mode = "mode",
            WorkerCapabilities = new CustomerManagedWorkerCapabilitiesProperty {
                CpuArchitectureType = "cpuArchitectureType",
                MemoryMiB = new MemoryMiBRangeProperty {
                    Min = 123,

                    // the properties below are optional
                    Max = 123
                },
                OsFamily = "osFamily",
                VCpuCount = new VCpuCountRangeProperty {
                    Min = 123,

                    // the properties below are optional
                    Max = 123
                },

                // the properties below are optional
                AcceleratorCount = new AcceleratorCountRangeProperty {
                    Min = 123,

                    // the properties below are optional
                    Max = 123
                },
                AcceleratorTotalMemoryMiB = new AcceleratorTotalMemoryMiBRangeProperty {
                    Min = 123,

                    // the properties below are optional
                    Max = 123
                },
                AcceleratorTypes = new [] { "acceleratorTypes" },
                CustomAmounts = new [] { new FleetAmountCapabilityProperty {
                    Min = 123,
                    Name = "name",

                    // the properties below are optional
                    Max = 123
                } },
                CustomAttributes = new [] { new FleetAttributeCapabilityProperty {
                    Name = "name",
                    Values = new [] { "values" }
                } }
            },

            // the properties below are optional
            AutoScalingConfiguration = new CustomerManagedAutoScalingConfigurationProperty {
                ScaleOutWorkersPerMinute = 123,
                StandbyWorkerCount = 123,
                WorkerIdleDurationSeconds = 123
            },
            StorageProfileId = "storageProfileId",
            TagPropagationMode = "tagPropagationMode"
        },
        ServiceManagedEc2 = new ServiceManagedEc2FleetConfigurationProperty {
            InstanceCapabilities = new ServiceManagedEc2InstanceCapabilitiesProperty {
                CpuArchitectureType = "cpuArchitectureType",
                MemoryMiB = new MemoryMiBRangeProperty {
                    Min = 123,

                    // the properties below are optional
                    Max = 123
                },
                OsFamily = "osFamily",
                VCpuCount = new VCpuCountRangeProperty {
                    Min = 123,

                    // the properties below are optional
                    Max = 123
                },

                // the properties below are optional
                AcceleratorCapabilities = new AcceleratorCapabilitiesProperty {
                    Selections = new [] { new AcceleratorSelectionProperty {
                        Name = "name",

                        // the properties below are optional
                        Runtime = "runtime"
                    } },

                    // the properties below are optional
                    Count = new AcceleratorCountRangeProperty {
                        Min = 123,

                        // the properties below are optional
                        Max = 123
                    }
                },
                AllowedInstanceTypes = new [] { "allowedInstanceTypes" },
                CustomAmounts = new [] { new FleetAmountCapabilityProperty {
                    Min = 123,
                    Name = "name",

                    // the properties below are optional
                    Max = 123
                } },
                CustomAttributes = new [] { new FleetAttributeCapabilityProperty {
                    Name = "name",
                    Values = new [] { "values" }
                } },
                ExcludedInstanceTypes = new [] { "excludedInstanceTypes" },
                RootEbsVolume = new Ec2EbsVolumeProperty {
                    Iops = 123,
                    SizeGiB = 123,
                    ThroughputMiB = 123
                }
            },
            InstanceMarketOptions = new ServiceManagedEc2InstanceMarketOptionsProperty {
                Type = "type"
            },

            // the properties below are optional
            AutoScalingConfiguration = new ServiceManagedEc2AutoScalingConfigurationProperty {
                ScaleOutWorkersPerMinute = 123,
                StandbyWorkerCount = 123,
                WorkerIdleDurationSeconds = 123
            },
            PersistentVolumeConfiguration = new PersistentVolumeConfigurationProperty {
                MountPath = "mountPath",

                // the properties below are optional
                Iops = 123,
                LastUsedTtlHours = 123,
                SizeGiB = 123,
                ThroughputMiB = 123
            },
            StorageProfileId = "storageProfileId",
            VpcConfiguration = new VpcConfigurationProperty {
                ResourceConfigurationArns = new [] { "resourceConfigurationArns" }
            }
        }
    },
    DisplayName = "displayName",
    FarmId = "farmId",
    MaxWorkerCount = 123,
    RoleArn = "roleArn",

    // the properties below are optional
    Description = "description",
    HostConfiguration = new HostConfigurationProperty {
        ScriptBody = "scriptBody",

        // the properties below are optional
        ScriptTimeoutSeconds = 123
    },
    MinWorkerCount = 123,
    Tags = new [] { new CfnTag {
        Key = "key",
        Value = "value"
    } }
});
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"

cfnFleet := awscdk.Aws_deadline.NewCfnFleet(this, jsii.String("MyCfnFleet"), &CfnFleetProps{
	Configuration: &FleetConfigurationProperty{
		CustomerManaged: &CustomerManagedFleetConfigurationProperty{
			Mode: jsii.String("mode"),
			WorkerCapabilities: &CustomerManagedWorkerCapabilitiesProperty{
				CpuArchitectureType: jsii.String("cpuArchitectureType"),
				MemoryMiB: &MemoryMiBRangeProperty{
					Min: jsii.Number(123),

					// the properties below are optional
					Max: jsii.Number(123),
				},
				OsFamily: jsii.String("osFamily"),
				VCpuCount: &VCpuCountRangeProperty{
					Min: jsii.Number(123),

					// the properties below are optional
					Max: jsii.Number(123),
				},

				// the properties below are optional
				AcceleratorCount: &AcceleratorCountRangeProperty{
					Min: jsii.Number(123),

					// the properties below are optional
					Max: jsii.Number(123),
				},
				AcceleratorTotalMemoryMiB: &AcceleratorTotalMemoryMiBRangeProperty{
					Min: jsii.Number(123),

					// the properties below are optional
					Max: jsii.Number(123),
				},
				AcceleratorTypes: []*string{
					jsii.String("acceleratorTypes"),
				},
				CustomAmounts: []interface{}{
					&FleetAmountCapabilityProperty{
						Min: jsii.Number(123),
						Name: jsii.String("name"),

						// the properties below are optional
						Max: jsii.Number(123),
					},
				},
				CustomAttributes: []interface{}{
					&FleetAttributeCapabilityProperty{
						Name: jsii.String("name"),
						Values: []*string{
							jsii.String("values"),
						},
					},
				},
			},

			// the properties below are optional
			AutoScalingConfiguration: &CustomerManagedAutoScalingConfigurationProperty{
				ScaleOutWorkersPerMinute: jsii.Number(123),
				StandbyWorkerCount: jsii.Number(123),
				WorkerIdleDurationSeconds: jsii.Number(123),
			},
			StorageProfileId: jsii.String("storageProfileId"),
			TagPropagationMode: jsii.String("tagPropagationMode"),
		},
		ServiceManagedEc2: &ServiceManagedEc2FleetConfigurationProperty{
			InstanceCapabilities: &ServiceManagedEc2InstanceCapabilitiesProperty{
				CpuArchitectureType: jsii.String("cpuArchitectureType"),
				MemoryMiB: &MemoryMiBRangeProperty{
					Min: jsii.Number(123),

					// the properties below are optional
					Max: jsii.Number(123),
				},
				OsFamily: jsii.String("osFamily"),
				VCpuCount: &VCpuCountRangeProperty{
					Min: jsii.Number(123),

					// the properties below are optional
					Max: jsii.Number(123),
				},

				// the properties below are optional
				AcceleratorCapabilities: &AcceleratorCapabilitiesProperty{
					Selections: []interface{}{
						&AcceleratorSelectionProperty{
							Name: jsii.String("name"),

							// the properties below are optional
							Runtime: jsii.String("runtime"),
						},
					},

					// the properties below are optional
					Count: &AcceleratorCountRangeProperty{
						Min: jsii.Number(123),

						// the properties below are optional
						Max: jsii.Number(123),
					},
				},
				AllowedInstanceTypes: []*string{
					jsii.String("allowedInstanceTypes"),
				},
				CustomAmounts: []interface{}{
					&FleetAmountCapabilityProperty{
						Min: jsii.Number(123),
						Name: jsii.String("name"),

						// the properties below are optional
						Max: jsii.Number(123),
					},
				},
				CustomAttributes: []interface{}{
					&FleetAttributeCapabilityProperty{
						Name: jsii.String("name"),
						Values: []*string{
							jsii.String("values"),
						},
					},
				},
				ExcludedInstanceTypes: []*string{
					jsii.String("excludedInstanceTypes"),
				},
				RootEbsVolume: &Ec2EbsVolumeProperty{
					Iops: jsii.Number(123),
					SizeGiB: jsii.Number(123),
					ThroughputMiB: jsii.Number(123),
				},
			},
			InstanceMarketOptions: &ServiceManagedEc2InstanceMarketOptionsProperty{
				Type: jsii.String("type"),
			},

			// the properties below are optional
			AutoScalingConfiguration: &ServiceManagedEc2AutoScalingConfigurationProperty{
				ScaleOutWorkersPerMinute: jsii.Number(123),
				StandbyWorkerCount: jsii.Number(123),
				WorkerIdleDurationSeconds: jsii.Number(123),
			},
			PersistentVolumeConfiguration: &PersistentVolumeConfigurationProperty{
				MountPath: jsii.String("mountPath"),

				// the properties below are optional
				Iops: jsii.Number(123),
				LastUsedTtlHours: jsii.Number(123),
				SizeGiB: jsii.Number(123),
				ThroughputMiB: jsii.Number(123),
			},
			StorageProfileId: jsii.String("storageProfileId"),
			VpcConfiguration: &VpcConfigurationProperty{
				ResourceConfigurationArns: []*string{
					jsii.String("resourceConfigurationArns"),
				},
			},
		},
	},
	DisplayName: jsii.String("displayName"),
	FarmId: jsii.String("farmId"),
	MaxWorkerCount: jsii.Number(123),
	RoleArn: jsii.String("roleArn"),

	// the properties below are optional
	Description: jsii.String("description"),
	HostConfiguration: &HostConfigurationProperty{
		ScriptBody: jsii.String("scriptBody"),

		// the properties below are optional
		ScriptTimeoutSeconds: jsii.Number(123),
	},
	MinWorkerCount: jsii.Number(123),
	Tags: []CfnTag{
		&CfnTag{
			Key: jsii.String("key"),
			Value: jsii.String("value"),
		},
	},
})

Initializer ​

ts
new CfnFleet(scope: Construct, id: string, props: CfnFleetProps)
python
CfnFleet(scope: Construct, id: str, props: CfnFleetProps)
java
new CfnFleet(Construct scope, String id, CfnFleetProps props)
csharp
new CfnFleet(Construct scope, string id, CfnFleetProps props)
go
NewCfnFleet(Scope Construct, Id *string, Props CfnFleetProps)

Construct Props ​

configurationIResolvable | CfnFleet.FleetConfigurationPropertyconfigurationtyping.Union[IResolvable, FleetConfigurationProperty]configurationIResolvableConfigurationIResolvableConfigurationinterface{}required#
The configuration details for the fleet.
descriptionoptionalstringdescriptionoptionalstrdescriptionoptionalStringDescriptionoptionalstringDescriptionoptional*string= ""#
A description that helps identify what the fleet is used for.

This field can store any content. Escape or encode this content before displaying it on a webpage or any other system that might interpret the content of this field.

displayNamestringdisplay_namestrdisplayNameStringDisplayNamestringDisplayName*stringrequired#
The display name of the fleet summary to update.

This field can store any content. Escape or encode this content before displaying it on a webpage or any other system that might interpret the content of this field.

farmIdstringfarm_idstrfarmIdStringFarmIdstringFarmId*stringrequired#
The farm ID.
hostConfigurationoptionalIResolvable | CfnFleet.HostConfigurationPropertyhost_configurationoptionaltyping.Union[IResolvable, HostConfigurationProperty]hostConfigurationoptionalIResolvableHostConfigurationoptionalIResolvableHostConfigurationoptionalinterface{}#
Provides a script that runs as a worker is starting up that you can use to provide additional configuration for workers in your fleet.

To remove a script from a fleet, use the UpdateFleet operation with the hostConfiguration scriptBody parameter set to an empty string ("").

maxWorkerCountnumbermax_worker_countint | floatmaxWorkerCountNumberMaxWorkerCountdoubleMaxWorkerCount*float64required#
The maximum number of workers specified in the fleet.
minWorkerCountoptionalnumbermin_worker_countoptionalint | floatminWorkerCountoptionalNumberMinWorkerCountoptionaldoubleMinWorkerCountoptional*float64= 0#
The minimum number of workers in the fleet.
roleArnstringrole_arnstrroleArnStringRoleArnstringRoleArn*stringrequired#
The IAM role that workers in the fleet use when processing jobs.
tagsoptionalCfnTag[]tagsoptionaltyping.List[CfnTag]tagsoptionalList<CfnTag>TagsoptionalCfnTag[]Tagsoptional*[]CfnTag#
The tags to add to your fleet.

Each tag consists of a tag key and a tag value. Tag keys and values are both required, but tag values can be empty strings.

Properties ​

attrArnstringattr_arnstrattrArnStringAttrArnstringAttrArn*stringrequired#
The Amazon Resource Name (ARN) assigned to the fleet.
attrCapabilitiesIResolvableattr_capabilitiesIResolvableattrCapabilitiesIResolvableAttrCapabilitiesIResolvableAttrCapabilitiesIResolvablerequired#
attrFleetIdstringattr_fleet_idstrattrFleetIdStringAttrFleetIdstringAttrFleetId*stringrequired#
The fleet ID.
attrStatusstringattr_statusstrattrStatusStringAttrStatusstringAttrStatus*stringrequired#
The status of the fleet.
attrStatusMessagestringattr_status_messagestrattrStatusMessageStringAttrStatusMessagestringAttrStatusMessage*stringrequired#
A message that communicates a suspended status of the fleet.
attrWorkerCountnumberattr_worker_countint | floatattrWorkerCountNumberAttrWorkerCountdoubleAttrWorkerCount*float64required#
The number of workers in the fleet summary.
cdkTagManagerTagManagercdk_tag_managerTagManagercdkTagManagerTagManagerCdkTagManagerTagManagerCdkTagManagerTagManagerrequired#
Tag Manager which manages the tags for this resource.
CFN_RESOURCE_TYPE_NAMEstringcfn_resource_type_namestrCFN_RESOURCE_TYPE_NAMEStringCFN_RESOURCE_TYPE_NAMEstringCFN_RESOURCE_TYPE_NAME*stringrequiredstatic#
The CloudFormation resource type name for this resource class.
Options for this resource, such as condition, update policy etc.
cfnResourceTypestringcfn_resource_typestrcfnResourceTypeStringCfnResourceTypestringCfnResourceType*stringrequired#
AWS resource type.
configurationIResolvable | CfnFleet.FleetConfigurationPropertyconfigurationtyping.Union[IResolvable, FleetConfigurationProperty]configurationIResolvableConfigurationIResolvableConfigurationinterface{}required#
The configuration details for the fleet.
creationStackstring[]creation_stacktyping.List[str]creationStackList<String>CreationStackstring[]CreationStack*[]*stringrequired#
descriptionmay be undefinedstringdescriptionmay be undefinedstrdescriptionmay be undefinedStringDescriptionmay be undefinedstringDescriptionmay be undefined*string#
A description that helps identify what the fleet is used for.
displayNamestringdisplay_namestrdisplayNameStringDisplayNamestringDisplayName*stringrequired#
The display name of the fleet summary to update.
farmIdstringfarm_idstrfarmIdStringFarmIdstringFarmId*stringrequired#
The farm ID.
fleetRefFleetReferencefleet_refFleetReferencefleetRefFleetReferenceFleetRefFleetReferenceFleetRefFleetReferencerequired#
A reference to a Fleet resource.
hostConfigurationmay be undefinedIResolvable | CfnFleet.HostConfigurationPropertyhost_configurationmay be undefinedtyping.Union[IResolvable, HostConfigurationProperty]hostConfigurationmay be undefinedIResolvableHostConfigurationmay be undefinedIResolvableHostConfigurationmay be undefinedinterface{}#
Provides a script that runs as a worker is starting up that you can use to provide additional configuration for workers in your fleet.
logicalIdstringlogical_idstrlogicalIdStringLogicalIdstringLogicalId*stringrequired#
The logical ID for this CloudFormation stack element.

The logical ID of the element is calculated from the path of the resource node in the construct tree.

To override this value, use overrideLogicalId(newLogicalId).

maxWorkerCountnumbermax_worker_countint | floatmaxWorkerCountNumberMaxWorkerCountdoubleMaxWorkerCount*float64required#
The maximum number of workers specified in the fleet.
minWorkerCountmay be undefinednumbermin_worker_countmay be undefinedint | floatminWorkerCountmay be undefinedNumberMinWorkerCountmay be undefineddoubleMinWorkerCountmay be undefined*float64#
The minimum number of workers in the fleet.
nodeNodenodeNodenodeNodeNodeNodeNodeNoderequired#
The tree node.
refstringrefstrrefStringRefstringRef*stringrequired#
Return a string that will be resolved to a CloudFormation `{ Ref }` for this element.

If, by any chance, the intrinsic reference of a resource is not a string, you could coerce it to an IResolvable through Lazy.any({ produce: resource.ref }).

roleArnstringrole_arnstrroleArnStringRoleArnstringRoleArn*stringrequired#
The IAM role that workers in the fleet use when processing jobs.
stackStackstackStackstackStackStackStackStackStackrequired#
The stack in which this element is defined.

CfnElements must be defined within a stack scope (directly or indirectly).

tagsmay be undefinedCfnTag[]tagsmay be undefinedtyping.List[CfnTag]tagsmay be undefinedList<CfnTag>Tagsmay be undefinedCfnTag[]Tagsmay be undefined*[]CfnTag#
The tags to add to your fleet.

Methods ​

addDeletionOverride(path: string): voiddef add_deletion_override(self, path: str) -> Nonepublic void addDeletionOverride(String path)public void AddDeletionOverride(string path)func AddDeletionOverride(Path *string)#
Syntactic sugar for `addOverride(path, undefined)`.
1 parameter

Parameters

  • pathpathpathpathPath — The path of the value to delete.
addDependency(target: CfnResource): voiddef add_dependency(self, target: CfnResource) -> Nonepublic void addDependency(CfnResource target)public void AddDependency(CfnResource target)func AddDependency(Target CfnResource)deprecated#
Use `addResourceDependency` instead.

This method has been renamed to addResourceDependency to more clearly set it apart from construct.node.addDependency. See the documentation of that function for more details.

addDependsOn(target: CfnResource): voiddef add_depends_on(self, target: CfnResource) -> Nonepublic void addDependsOn(CfnResource target)public void AddDependsOn(CfnResource target)func AddDependsOn(Target CfnResource)deprecated#
Use `addResourceDependency` instead.
notes

This can be used for resources across stacks (or nested stack) boundaries and the dependency will automatically be transferred to the relevant scope.

This method has been renamed to addResourceDependency, which makes it more clear that this method operates at a different level from the construct-level construct.node.addDependency() mechanism.

addMetadata(key: string, value: any): voiddef add_metadata(self, key: str, value: Any) -> Nonepublic void addMetadata(String key, Object value)public void AddMetadata(string key, object value)func AddMetadata(Key *string, Value interface{})#
Add a value to the CloudFormation Resource Metadata.
addOverride(path: string, value: any): voiddef add_override(self, path: str, value: Any) -> Nonepublic void addOverride(String path, Object value)public void AddOverride(string path, object value)func AddOverride(Path *string, Value interface{})#
Adds an override to the synthesized CloudFormation resource.
notes · 2 parameters

To add a property override, either use addPropertyOverride or prefix path with "Properties." (i.e. Properties.TopicName).

If the override is nested, separate each nested level using a dot (.) in the path parameter. If there is an array as part of the nesting, specify the index in the path.

To include a literal . in the property name, prefix with a \. In most programming languages you will need to write this as "\\." because the \ itself will need to be escaped.

For example,

typescript
cfnResource.addOverride('Properties.GlobalSecondaryIndexes.0.Projection.NonKeyAttributes', ['myattribute']);
cfnResource.addOverride('Properties.GlobalSecondaryIndexes.1.ProjectionType', 'INCLUDE');

would add the overrides

json
"Properties": {
  "GlobalSecondaryIndexes": [
    {
      "Projection": {
        "NonKeyAttributes": [ "myattribute" ]
        ...
      }
      ...
    },
    {
      "ProjectionType": "INCLUDE"
      ...
    },
  ]
  ...
}

The value argument to addOverride will not be processed or translated in any way. Pass raw JSON values in here with the correct capitalization for CloudFormation. If you pass CDK classes or structs, they will be rendered with lowercased key names, and CloudFormation will reject the template.

Parameters

  • pathpathpathpathPath — - The path of the property, you can use dot notation to override values in complex types.
  • valuevaluevaluevalueValue — - The value.
addPropertyDeletionOverride(propertyPath: string): voiddef add_property_deletion_override(self, property_path: str) -> Nonepublic void addPropertyDeletionOverride(String propertyPath)public void AddPropertyDeletionOverride(string propertyPath)func AddPropertyDeletionOverride(PropertyPath *string)#
Adds an override that deletes the value of a property from the resource definition.
1 parameter

Parameters

  • propertyPathproperty_pathpropertyPathpropertyPathPropertyPath — The path to the property.
addPropertyOverride(propertyPath: string, value: any): voiddef add_property_override(self, property_path: str, value: Any) -> Nonepublic void addPropertyOverride(String propertyPath, Object value)public void AddPropertyOverride(string propertyPath, object value)func AddPropertyOverride(PropertyPath *string, Value interface{})#
Adds an override to a resource property.

Syntactic sugar for addOverride("Properties.<...>", value).

2 parameters

Parameters

  • propertyPathproperty_pathpropertyPathpropertyPathPropertyPath — The path of the property.
  • valuevaluevaluevalueValue — The value.
addResourceDependency(target: CfnResource, reason?: string): voiddef add_resource_dependency(self, target: CfnResource, reason: typing.Optional[str] = None) -> Nonepublic void addResourceDependency(CfnResource target, String reason)public void AddResourceDependency(CfnResource target, string? reason = null)func AddResourceDependency(Target CfnResource, Reason *string)#
Indicates that this resource depends on another resource and cannot be provisioned unless the other resource has been successfully provisioned.
notes

This can be used for resources across stacks (or nested stack) boundaries and the dependency will automatically be transferred to the relevant scope.

This method only adds dependencies between L1 resources. If you are looking for a generic construct-to-construct dependency mechanism that works for all constructs including L2s, use construct.node.addDependency instead.

applyCrossStackReferenceStrength(strength: ReferenceStrength): voiddef apply_cross_stack_reference_strength(self, strength: ReferenceStrength) -> Nonepublic void applyCrossStackReferenceStrength(ReferenceStrength strength)public void ApplyCrossStackReferenceStrength(ReferenceStrength strength)func ApplyCrossStackReferenceStrength(Strength ReferenceStrength)#
Sets the cross-stack reference strength for this resource.

When set, any cross-stack reference to this resource will use the specified strength instead of the global default from the consuming stack's context.

1 parameter

Parameters

  • strengthstrengthstrengthstrengthStrength — - The reference strength to use for this resource.
applyRemovalPolicy(policy?: RemovalPolicy, options?: RemovalPolicyOptions): voiddef apply_removal_policy(self, policy: typing.Optional[RemovalPolicy] = None, options: typing.Optional[RemovalPolicyOptions] = None) -> Nonepublic void applyRemovalPolicy(RemovalPolicy policy, RemovalPolicyOptions options)public void ApplyRemovalPolicy(RemovalPolicy? policy = null, RemovalPolicyOptions? options = null)func ApplyRemovalPolicy(Policy RemovalPolicy, Options RemovalPolicyOptions)#
Sets the deletion policy of the resource based on the removal policy specified.
notes

The Removal Policy controls what happens to this resource when it stops being managed by CloudFormation, either because you've removed it from the CDK application or because you've made a change that requires the resource to be replaced.

The resource can be deleted (RemovalPolicy.DESTROY), or left in your AWS account for data recovery and cleanup later (RemovalPolicy.RETAIN). In some cases, a snapshot can be taken of the resource prior to deletion (RemovalPolicy.SNAPSHOT). A list of resources that support this policy can be found in the following link:

arnForFleet(resource: IFleetRef): string@staticmethod def arn_for_fleet(resource: IFleetRef) -> strpublic static String arnForFleet(IFleetRef resource)public static string ArnForFleet(IFleetRef resource)func ArnForFleet(Resource IFleetRef) *stringstatic#
cfnPropertyName(cdkPropertyName: string): stringdef cfn_property_name(self, cdk_property_name: str) -> strpublic String cfnPropertyName(String cdkPropertyName)public string CfnPropertyName(string cdkPropertyName)func CfnPropertyName(CdkPropertyName *string) *string#
getAtt(attributeName: string, typeHint?: ResolutionTypeHint): Referencedef get_att(self, attribute_name: str, type_hint: typing.Optional[ResolutionTypeHint] = None) -> Referencepublic Reference getAtt(String attributeName, ResolutionTypeHint typeHint)public Reference GetAtt(string attributeName, ResolutionTypeHint? typeHint = null)func GetAtt(AttributeName *string, TypeHint ResolutionTypeHint) Reference#
Returns a token for an runtime attribute of this resource.

Ideally, use generated attribute accessors (e.g. resource.arn), but this can be used for future compatibility in case there is no generated attribute.

1 parameter

Parameters

  • attributeNameattribute_nameattributeNameattributeNameAttributeName — The name of the attribute.
getMetadata(key: string): anydef get_metadata(self, key: str) -> Anypublic Object getMetadata(String key)public object GetMetadata(string key)func GetMetadata(Key *string) interface{}#
Retrieve a value value from the CloudFormation Resource Metadata.
inspect(inspector: TreeInspector): voiddef inspect(self, inspector: TreeInspector) -> Nonepublic void inspect(TreeInspector inspector)public void Inspect(TreeInspector inspector)func Inspect(Inspector TreeInspector)#
Examines the CloudFormation resource and discloses attributes.
1 parameter

Parameters

  • inspectorinspectorinspectorinspectorInspector — tree inspector to collect and process attributes.
isCfnElement(x: any): boolean@staticmethod def is_cfn_element(x: Any) -> boolpublic static Boolean isCfnElement(Object x)public static bool IsCfnElement(object x)func IsCfnElement(X interface{}) *boolstatic#
Returns `true` if a construct is a stack element (i.e. part of the synthesized cloudformation template).

Uses duck-typing instead of instanceof to allow stack elements from different versions of this library to be included in the same stack.

returns

Returns: The construct as a stack element or undefined if it is not a stack element.

isCfnFleet(x: any): boolean@staticmethod def is_cfn_fleet(x: Any) -> boolpublic static Boolean isCfnFleet(Object x)public static bool IsCfnFleet(object x)func IsCfnFleet(X interface{}) *boolstatic#
Checks whether the given object is a CfnFleet.
isCfnResource(x: any): boolean@staticmethod def is_cfn_resource(x: Any) -> boolpublic static Boolean isCfnResource(Object x)public static bool IsCfnResource(object x)func IsCfnResource(X interface{}) *boolstatic#
Check whether the given object is a CfnResource.
isConstruct(x: any): boolean@staticmethod def is_construct(x: Any) -> boolpublic static Boolean isConstruct(Object x)public static bool IsConstruct(object x)func IsConstruct(X interface{}) *boolstatic#
Checks if `x` is a construct.
notes · 1 parameter · returns

Use this method instead of instanceof to properly detect Construct instances, even when the construct library is symlinked.

Explanation: in JavaScript, multiple copies of the constructs library on disk are seen as independent, completely different libraries. As a consequence, the class Construct in each copy of the constructs library is seen as a different class, and an instance of one class will not test as instanceof the other class. npm install will not create installations like this, but users may manually symlink construct libraries together or use a monorepo tool: in those cases, multiple copies of the constructs library can be accidentally installed, and instanceof will behave unpredictably. It is safest to avoid using instanceof, and using this type-testing method instead.

Parameters

  • xxxxX — Any object.

Returns: true if x is an object created from a class which extends Construct.

obtainDependencies(): Stack | CfnResource[]def obtain_dependencies(self, ) -> typing.List[typing.Union[Stack, CfnResource]]public List<Stack> obtainDependencies()public Stack[] ObtainDependencies()func ObtainDependencies() *[]interface{}#
Retrieves an array of resources and stacks this resource depends on.

For resources depended on directly, returns the CfnResource object. For dependencies on other stacks, returns the Stack object. The order of the array is not guaranteed.

overrideLogicalId(newLogicalId: string): voiddef override_logical_id(self, new_logical_id: str) -> Nonepublic void overrideLogicalId(String newLogicalId)public void OverrideLogicalId(string newLogicalId)func OverrideLogicalId(NewLogicalId *string)#
Overrides the auto-generated logical ID with a specific ID.
1 parameter

Parameters

  • newLogicalIdnew_logical_idnewLogicalIdnewLogicalIdNewLogicalId — The new logical ID to use for this stack element.
removeDependency(target: CfnResource): voiddef remove_dependency(self, target: CfnResource) -> Nonepublic void removeDependency(CfnResource target)public void RemoveDependency(CfnResource target)func RemoveDependency(Target CfnResource)deprecated#
Use `removeResourceDependency` instead

This can be used for resources across stacks (including nested stacks) and the dependency will automatically be removed from the relevant scope.

removeResourceDependency(target: CfnResource): voiddef remove_resource_dependency(self, target: CfnResource) -> Nonepublic void removeResourceDependency(CfnResource target)public void RemoveResourceDependency(CfnResource target)func RemoveResourceDependency(Target CfnResource)#
Indicates that this resource no longer depends on another resource.

This can be used for resources across stacks (including nested stacks) and the dependency will automatically be removed from the relevant scope.

replaceDependency(target: CfnResource, newTarget: CfnResource): voiddef replace_dependency(self, target: CfnResource, new_target: CfnResource) -> Nonepublic void replaceDependency(CfnResource target, CfnResource newTarget)public void ReplaceDependency(CfnResource target, CfnResource newTarget)func ReplaceDependency(Target CfnResource, NewTarget CfnResource)#
Replaces one dependency with another.
2 parameters

Parameters

  • targettargettargettargetTarget — The dependency to replace.
  • newTargetnew_targetnewTargetnewTargetNewTarget — The new dependency to add.
toString(): stringdef to_string(self, ) -> strpublic String toString()public string ToString()func ToString() *string#
Returns a string representation of this construct.
returns

Returns: a string representation of this resource

with(...mixins: IMixin[]): IConstructdef with(self, mixins: IMixin) -> IConstructpublic IConstruct with(IMixin mixins)public IConstruct With(IMixin mixins)func With(Mixins IMixin) IConstruct#
Applies one or more mixins to this construct.

Mixins are applied in order. The list of constructs is captured at the start of the call, so constructs added by a mixin will not be visited. Use multiple with() calls if subsequent mixins should apply to added constructs.