« blib/lib/Paws/AutoScaling/InstanceRefreshWarmPoolProgress.pm
↑ Summary
blib/lib/Paws/AutoScaling/LaunchTemplate.pm »
| 1 | # Generated by default/object.tt | ||
| 2 | package Paws::AutoScaling::InstancesDistribution; | ||
| 3 | use Moose; | ||
| 4 | has OnDemandAllocationStrategy => (is => 'ro', isa => 'Str'); | ||
| 5 | has OnDemandBaseCapacity => (is => 'ro', isa => 'Int'); | ||
| 6 | has OnDemandPercentageAboveBaseCapacity => (is => 'ro', isa => 'Int'); | ||
| 7 | has SpotAllocationStrategy => (is => 'ro', isa => 'Str'); | ||
| 8 | has SpotInstancePools => (is => 'ro', isa => 'Int'); | ||
| 9 | has SpotMaxPrice => (is => 'ro', isa => 'Str'); | ||
| 10 | |||
| 11 | 1; | ||
| 12 | |||
| 13 | ### main pod documentation begin ### | ||
| 14 | |||
| 15 | =head1 NAME | ||
| 16 | |||
| 17 | Paws::AutoScaling::InstancesDistribution | ||
| 18 | |||
| 19 | =head1 USAGE | ||
| 20 | |||
| 21 | This class represents one of two things: | ||
| 22 | |||
| 23 | =head3 Arguments in a call to a service | ||
| 24 | |||
| 25 | Use the attributes of this class as arguments to methods. You shouldn't make instances of this class. | ||
| 26 | Each attribute should be used as a named argument in the calls that expect this type of object. | ||
| 27 | |||
| 28 | As an example, if Att1 is expected to be a Paws::AutoScaling::InstancesDistribution object: | ||
| 29 | |||
| 30 | $service_obj->Method(Att1 => { OnDemandAllocationStrategy => $value, ..., SpotMaxPrice => $value }); | ||
| 31 | |||
| 32 | =head3 Results returned from an API call | ||
| 33 | |||
| 34 | Use accessors for each attribute. If Att1 is expected to be an Paws::AutoScaling::InstancesDistribution object: | ||
| 35 | |||
| 36 | $result = $service_obj->Method(...); | ||
| 37 | $result->Att1->OnDemandAllocationStrategy | ||
| 38 | |||
| 39 | =head1 DESCRIPTION | ||
| 40 | |||
| 41 | Describes an instances distribution for an Auto Scaling group with a | ||
| 42 | MixedInstancesPolicy. | ||
| 43 | |||
| 44 | The instances distribution specifies the distribution of On-Demand | ||
| 45 | Instances and Spot Instances, the maximum price to pay for Spot | ||
| 46 | Instances, and how the Auto Scaling group allocates instance types to | ||
| 47 | fulfill On-Demand and Spot capacities. | ||
| 48 | |||
| 49 | When you update C<SpotAllocationStrategy>, C<SpotInstancePools>, or | ||
| 50 | C<SpotMaxPrice>, this update action does not deploy any changes across | ||
| 51 | the running Amazon EC2 instances in the group. Your existing Spot | ||
| 52 | Instances continue to run as long as the maximum price for those | ||
| 53 | instances is higher than the current Spot price. When scale out occurs, | ||
| 54 | Amazon EC2 Auto Scaling launches instances based on the new settings. | ||
| 55 | When scale in occurs, Amazon EC2 Auto Scaling terminates instances | ||
| 56 | according to the group's termination policies. | ||
| 57 | |||
| 58 | =head1 ATTRIBUTES | ||
| 59 | |||
| 60 | |||
| 61 | =head2 OnDemandAllocationStrategy => Str | ||
| 62 | |||
| 63 | Indicates how to allocate instance types to fulfill On-Demand capacity. | ||
| 64 | The only valid value is C<prioritized>, which is also the default | ||
| 65 | value. This strategy uses the order of instance types in the | ||
| 66 | C<LaunchTemplateOverrides> to define the launch priority of each | ||
| 67 | instance type. The first instance type in the array is prioritized | ||
| 68 | higher than the last. If all your On-Demand capacity cannot be | ||
| 69 | fulfilled using your highest priority instance, then the Auto Scaling | ||
| 70 | groups launches the remaining capacity using the second priority | ||
| 71 | instance type, and so on. | ||
| 72 | |||
| 73 | |||
| 74 | =head2 OnDemandBaseCapacity => Int | ||
| 75 | |||
| 76 | The minimum amount of the Auto Scaling group's capacity that must be | ||
| 77 | fulfilled by On-Demand Instances. This base portion is provisioned | ||
| 78 | first as your group scales. Defaults to 0 if not specified. If you | ||
| 79 | specify weights for the instance types in the overrides, set the value | ||
| 80 | of C<OnDemandBaseCapacity> in terms of the number of capacity units, | ||
| 81 | and not the number of instances. | ||
| 82 | |||
| 83 | |||
| 84 | =head2 OnDemandPercentageAboveBaseCapacity => Int | ||
| 85 | |||
| 86 | Controls the percentages of On-Demand Instances and Spot Instances for | ||
| 87 | your additional capacity beyond C<OnDemandBaseCapacity>. Expressed as a | ||
| 88 | number (for example, 20 specifies 20% On-Demand Instances, 80% Spot | ||
| 89 | Instances). Defaults to 100 if not specified. If set to 100, only | ||
| 90 | On-Demand Instances are provisioned. | ||
| 91 | |||
| 92 | |||
| 93 | =head2 SpotAllocationStrategy => Str | ||
| 94 | |||
| 95 | Indicates how to allocate instances across Spot Instance pools. | ||
| 96 | |||
| 97 | If the allocation strategy is C<lowest-price>, the Auto Scaling group | ||
| 98 | launches instances using the Spot pools with the lowest price, and | ||
| 99 | evenly allocates your instances across the number of Spot pools that | ||
| 100 | you specify. Defaults to C<lowest-price> if not specified. | ||
| 101 | |||
| 102 | If the allocation strategy is C<capacity-optimized> (recommended), the | ||
| 103 | Auto Scaling group launches instances using Spot pools that are | ||
| 104 | optimally chosen based on the available Spot capacity. Alternatively, | ||
| 105 | you can use C<capacity-optimized-prioritized> and set the order of | ||
| 106 | instance types in the list of launch template overrides from highest to | ||
| 107 | lowest priority (from first to last in the list). Amazon EC2 Auto | ||
| 108 | Scaling honors the instance type priorities on a best-effort basis but | ||
| 109 | optimizes for capacity first. | ||
| 110 | |||
| 111 | |||
| 112 | =head2 SpotInstancePools => Int | ||
| 113 | |||
| 114 | The number of Spot Instance pools across which to allocate your Spot | ||
| 115 | Instances. The Spot pools are determined from the different instance | ||
| 116 | types in the overrides. Valid only when the Spot allocation strategy is | ||
| 117 | C<lowest-price>. Value must be in the range of 1 to 20. Defaults to 2 | ||
| 118 | if not specified. | ||
| 119 | |||
| 120 | |||
| 121 | =head2 SpotMaxPrice => Str | ||
| 122 | |||
| 123 | The maximum price per unit hour that you are willing to pay for a Spot | ||
| 124 | Instance. If you leave the value at its default (empty), Amazon EC2 | ||
| 125 | Auto Scaling uses the On-Demand price as the maximum Spot price. To | ||
| 126 | remove a value that you previously set, include the property but | ||
| 127 | specify an empty string ("") for the value. | ||
| 128 | |||
| 129 | |||
| 130 | |||
| 131 | =head1 SEE ALSO | ||
| 132 | |||
| 133 | This class forms part of L<Paws>, describing an object used in L<Paws::AutoScaling> | ||
| 134 | |||
| 135 | =head1 BUGS and CONTRIBUTIONS | ||
| 136 | |||
| 137 | The source code is located here: L<https://github.com/pplu/aws-sdk-perl> | ||
| 138 | |||
| 139 | Please report bugs to: L<https://github.com/pplu/aws-sdk-perl/issues> | ||
| 140 | |||
| 141 | =cut | ||
| 142 |