ElasticLoadBalancingv2 / Client / modify_capacity_reservation
modify_capacity_reservation#
- ElasticLoadBalancingv2.Client.modify_capacity_reservation(**kwargs)#
Modifies the capacity reservation of the specified load balancer.
When modifying capacity reservation, you must include at least one
MinimumLoadBalancerCapacity
orResetCapacityReservation
.See also: AWS API Documentation
Request Syntax
response = client.modify_capacity_reservation( LoadBalancerArn='string', MinimumLoadBalancerCapacity={ 'CapacityUnits': 123 }, ResetCapacityReservation=True|False )
- Parameters:
LoadBalancerArn (string) –
[REQUIRED]
The Amazon Resource Name (ARN) of the load balancer.
MinimumLoadBalancerCapacity (dict) –
The minimum load balancer capacity reserved.
CapacityUnits (integer) –
The number of capacity units.
ResetCapacityReservation (boolean) – Resets the capacity reservation.
- Return type:
dict
- Returns:
Response Syntax
{ 'LastModifiedTime': datetime(2015, 1, 1), 'DecreaseRequestsRemaining': 123, 'MinimumLoadBalancerCapacity': { 'CapacityUnits': 123 }, 'CapacityReservationState': [ { 'State': { 'Code': 'provisioned'|'pending'|'rebalancing'|'failed', 'Reason': 'string' }, 'AvailabilityZone': 'string', 'EffectiveCapacityUnits': 123.0 }, ] }
Response Structure
(dict) –
LastModifiedTime (datetime) –
The last time the capacity reservation was modified.
DecreaseRequestsRemaining (integer) –
The amount of daily capacity decreases remaining.
MinimumLoadBalancerCapacity (dict) –
The requested minimum capacity reservation for the load balancer
CapacityUnits (integer) –
The number of capacity units.
CapacityReservationState (list) –
The state of the capacity reservation.
(dict) –
The capacity reservation status for each availability zone.
State (dict) –
The state of the capacity reservation.
Code (string) –
The status code.
Reason (string) –
The reason code for the status.
AvailabilityZone (string) –
Information about the availability zone.
EffectiveCapacityUnits (float) –
The number of effective capacity units.
Exceptions
ElasticLoadBalancingv2.Client.exceptions.LoadBalancerNotFoundException
ElasticLoadBalancingv2.Client.exceptions.InvalidConfigurationRequestException
ElasticLoadBalancingv2.Client.exceptions.CapacityUnitsLimitExceededException
ElasticLoadBalancingv2.Client.exceptions.CapacityReservationPendingException
ElasticLoadBalancingv2.Client.exceptions.InsufficientCapacityException
ElasticLoadBalancingv2.Client.exceptions.CapacityDecreaseRequestsLimitExceededException
ElasticLoadBalancingv2.Client.exceptions.PriorRequestNotCompleteException
ElasticLoadBalancingv2.Client.exceptions.OperationNotPermittedException