Show / Hide Table of Contents

Class CfnSpotFleet.LaunchTemplateOverridesProperty

Specifies overrides for a launch template.

Inheritance
object
CfnSpotFleet.LaunchTemplateOverridesProperty
Implements
CfnSpotFleet.ILaunchTemplateOverridesProperty
Inherited Members
object.GetType()
object.MemberwiseClone()
object.ToString()
object.Equals(object)
object.Equals(object, object)
object.ReferenceEquals(object, object)
object.GetHashCode()
Namespace: Amazon.CDK.AWS.EC2
Assembly: Amazon.CDK.Lib.dll
Syntax (csharp)
public class CfnSpotFleet.LaunchTemplateOverridesProperty : CfnSpotFleet.ILaunchTemplateOverridesProperty
Syntax (vb)
Public Class CfnSpotFleet.LaunchTemplateOverridesProperty Implements CfnSpotFleet.ILaunchTemplateOverridesProperty
Remarks

See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-ec2-spotfleet-launchtemplateoverrides.html

ExampleMetadata: fixture=_generated

Examples
// The code below shows an example of how to instantiate this type.
             // The values are placeholders you should change.
             using Amazon.CDK.AWS.EC2;

             var launchTemplateOverridesProperty = new LaunchTemplateOverridesProperty {
                 AvailabilityZone = "availabilityZone",
                 InstanceRequirements = new InstanceRequirementsRequestProperty {
                     AcceleratorCount = new AcceleratorCountRequestProperty {
                         Max = 123,
                         Min = 123
                     },
                     AcceleratorManufacturers = new [] { "acceleratorManufacturers" },
                     AcceleratorNames = new [] { "acceleratorNames" },
                     AcceleratorTotalMemoryMiB = new AcceleratorTotalMemoryMiBRequestProperty {
                         Max = 123,
                         Min = 123
                     },
                     AcceleratorTypes = new [] { "acceleratorTypes" },
                     AllowedInstanceTypes = new [] { "allowedInstanceTypes" },
                     BareMetal = "bareMetal",
                     BaselineEbsBandwidthMbps = new BaselineEbsBandwidthMbpsRequestProperty {
                         Max = 123,
                         Min = 123
                     },
                     BaselinePerformanceFactors = new BaselinePerformanceFactorsRequestProperty {
                         Cpu = new CpuPerformanceFactorRequestProperty {
                             References = new [] { new PerformanceFactorReferenceRequestProperty {
                                 InstanceFamily = "instanceFamily"
                             } }
                         }
                     },
                     BurstablePerformance = "burstablePerformance",
                     CpuManufacturers = new [] { "cpuManufacturers" },
                     ExcludedInstanceTypes = new [] { "excludedInstanceTypes" },
                     InstanceGenerations = new [] { "instanceGenerations" },
                     LocalStorage = "localStorage",
                     LocalStorageTypes = new [] { "localStorageTypes" },
                     MaxSpotPriceAsPercentageOfOptimalOnDemandPrice = 123,
                     MemoryGiBPerVCpu = new MemoryGiBPerVCpuRequestProperty {
                         Max = 123,
                         Min = 123
                     },
                     MemoryMiB = new MemoryMiBRequestProperty {
                         Max = 123,
                         Min = 123
                     },
                     NetworkBandwidthGbps = new NetworkBandwidthGbpsRequestProperty {
                         Max = 123,
                         Min = 123
                     },
                     NetworkInterfaceCount = new NetworkInterfaceCountRequestProperty {
                         Max = 123,
                         Min = 123
                     },
                     OnDemandMaxPricePercentageOverLowestPrice = 123,
                     RequireHibernateSupport = false,
                     SpotMaxPricePercentageOverLowestPrice = 123,
                     TotalLocalStorageGb = new TotalLocalStorageGBRequestProperty {
                         Max = 123,
                         Min = 123
                     },
                     VCpuCount = new VCpuCountRangeRequestProperty {
                         Max = 123,
                         Min = 123
                     }
                 },
                 InstanceType = "instanceType",
                 Priority = 123,
                 SpotPrice = "spotPrice",
                 SubnetId = "subnetId",
                 WeightedCapacity = 123
             };

Synopsis

Constructors

LaunchTemplateOverridesProperty()

Specifies overrides for a launch template.

Properties

AvailabilityZone

The Availability Zone in which to launch the instances.

InstanceRequirements

The instance requirements.

InstanceType

The instance type.

Priority

The priority for the launch template override. The highest priority is launched first.

SpotPrice

The maximum price per unit hour that you are willing to pay for a Spot Instance.

SubnetId

The ID of the subnet in which to launch the instances.

WeightedCapacity

The number of units provided by the specified instance type.

Constructors

LaunchTemplateOverridesProperty()

Specifies overrides for a launch template.

public LaunchTemplateOverridesProperty()
Remarks

See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-ec2-spotfleet-launchtemplateoverrides.html

ExampleMetadata: fixture=_generated

Examples
// The code below shows an example of how to instantiate this type.
             // The values are placeholders you should change.
             using Amazon.CDK.AWS.EC2;

             var launchTemplateOverridesProperty = new LaunchTemplateOverridesProperty {
                 AvailabilityZone = "availabilityZone",
                 InstanceRequirements = new InstanceRequirementsRequestProperty {
                     AcceleratorCount = new AcceleratorCountRequestProperty {
                         Max = 123,
                         Min = 123
                     },
                     AcceleratorManufacturers = new [] { "acceleratorManufacturers" },
                     AcceleratorNames = new [] { "acceleratorNames" },
                     AcceleratorTotalMemoryMiB = new AcceleratorTotalMemoryMiBRequestProperty {
                         Max = 123,
                         Min = 123
                     },
                     AcceleratorTypes = new [] { "acceleratorTypes" },
                     AllowedInstanceTypes = new [] { "allowedInstanceTypes" },
                     BareMetal = "bareMetal",
                     BaselineEbsBandwidthMbps = new BaselineEbsBandwidthMbpsRequestProperty {
                         Max = 123,
                         Min = 123
                     },
                     BaselinePerformanceFactors = new BaselinePerformanceFactorsRequestProperty {
                         Cpu = new CpuPerformanceFactorRequestProperty {
                             References = new [] { new PerformanceFactorReferenceRequestProperty {
                                 InstanceFamily = "instanceFamily"
                             } }
                         }
                     },
                     BurstablePerformance = "burstablePerformance",
                     CpuManufacturers = new [] { "cpuManufacturers" },
                     ExcludedInstanceTypes = new [] { "excludedInstanceTypes" },
                     InstanceGenerations = new [] { "instanceGenerations" },
                     LocalStorage = "localStorage",
                     LocalStorageTypes = new [] { "localStorageTypes" },
                     MaxSpotPriceAsPercentageOfOptimalOnDemandPrice = 123,
                     MemoryGiBPerVCpu = new MemoryGiBPerVCpuRequestProperty {
                         Max = 123,
                         Min = 123
                     },
                     MemoryMiB = new MemoryMiBRequestProperty {
                         Max = 123,
                         Min = 123
                     },
                     NetworkBandwidthGbps = new NetworkBandwidthGbpsRequestProperty {
                         Max = 123,
                         Min = 123
                     },
                     NetworkInterfaceCount = new NetworkInterfaceCountRequestProperty {
                         Max = 123,
                         Min = 123
                     },
                     OnDemandMaxPricePercentageOverLowestPrice = 123,
                     RequireHibernateSupport = false,
                     SpotMaxPricePercentageOverLowestPrice = 123,
                     TotalLocalStorageGb = new TotalLocalStorageGBRequestProperty {
                         Max = 123,
                         Min = 123
                     },
                     VCpuCount = new VCpuCountRangeRequestProperty {
                         Max = 123,
                         Min = 123
                     }
                 },
                 InstanceType = "instanceType",
                 Priority = 123,
                 SpotPrice = "spotPrice",
                 SubnetId = "subnetId",
                 WeightedCapacity = 123
             };

Properties

AvailabilityZone

The Availability Zone in which to launch the instances.

public string? AvailabilityZone { get; set; }
Property Value

string

Remarks

See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-ec2-spotfleet-launchtemplateoverrides.html#cfn-ec2-spotfleet-launchtemplateoverrides-availabilityzone

InstanceRequirements

The instance requirements.

public object? InstanceRequirements { get; set; }
Property Value

object

Remarks

When you specify instance requirements, Amazon EC2 will identify instance types with the provided requirements, and then use your On-Demand and Spot allocation strategies to launch instances from these instance types, in the same way as when you specify a list of instance types.

If you specify <code>InstanceRequirements</code> , you can't specify <code>InstanceType</code> .

See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-ec2-spotfleet-launchtemplateoverrides.html#cfn-ec2-spotfleet-launchtemplateoverrides-instancerequirements

Type union: either IResolvable or CfnSpotFleet.IInstanceRequirementsRequestProperty

InstanceType

The instance type.

public string? InstanceType { get; set; }
Property Value

string

Remarks

See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-ec2-spotfleet-launchtemplateoverrides.html#cfn-ec2-spotfleet-launchtemplateoverrides-instancetype

Priority

The priority for the launch template override. The highest priority is launched first.

public double? Priority { get; set; }
Property Value

double?

Remarks

If OnDemandAllocationStrategy is set to prioritized , Spot Fleet uses priority to determine which launch template override to use first in fulfilling On-Demand capacity.

If the Spot AllocationStrategy is set to capacityOptimizedPrioritized , Spot Fleet uses priority on a best-effort basis to determine which launch template override to use in fulfilling Spot capacity, but optimizes for capacity first.

Valid values are whole numbers starting at 0 . The lower the number, the higher the priority. If no number is set, the launch template override has the lowest priority. You can set the same priority for different launch template overrides.

See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-ec2-spotfleet-launchtemplateoverrides.html#cfn-ec2-spotfleet-launchtemplateoverrides-priority

SpotPrice

The maximum price per unit hour that you are willing to pay for a Spot Instance.

public string? SpotPrice { get; set; }
Property Value

string

Remarks

We do not recommend using this parameter because it can lead to increased interruptions. If you do not specify this parameter, you will pay the current Spot price.

If you specify a maximum price, your instances will be interrupted more frequently than if you do not specify this parameter.

See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-ec2-spotfleet-launchtemplateoverrides.html#cfn-ec2-spotfleet-launchtemplateoverrides-spotprice

SubnetId

The ID of the subnet in which to launch the instances.

public string? SubnetId { get; set; }
Property Value

string

Remarks

See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-ec2-spotfleet-launchtemplateoverrides.html#cfn-ec2-spotfleet-launchtemplateoverrides-subnetid

WeightedCapacity

The number of units provided by the specified instance type.

public double? WeightedCapacity { get; set; }
Property Value

double?

Remarks

These are the same units that you chose to set the target capacity in terms of instances, or a performance characteristic such as vCPUs, memory, or I/O.

If the target capacity divided by this value is not a whole number, Amazon EC2 rounds the number of instances to the next whole number. If this value is not specified, the default is 1.

When specifying weights, the price used in the <code>lowestPrice</code> and <code>priceCapacityOptimized</code> allocation strategies is per <em>unit</em> hour (where the instance price is divided by the specified weight). However, if all the specified weights are above the requested <code>TargetCapacity</code> , resulting in only 1 instance being launched, the price used is per <em>instance</em> hour.

See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-ec2-spotfleet-launchtemplateoverrides.html#cfn-ec2-spotfleet-launchtemplateoverrides-weightedcapacity

Implements

CfnSpotFleet.ILaunchTemplateOverridesProperty
Back to top Generated by DocFX