Skip to content

EC2  >  Operations  >  update_interruptible_capacity_reservation_allocation

update_interruptible_capacity_reservation_allocation

Operation

update_interruptible_capacity_reservation_allocation async

update_interruptible_capacity_reservation_allocation(*, plugins: list[Plugin] | None = None, **kwargs: Unpack[UpdateInterruptibleCapacityReservationAllocationInputDict]) -> UpdateInterruptibleCapacityReservationAllocationOutput

Modifies the number of instances allocated to an interruptible reservation, allowing you to add more capacity or reclaim capacity to your source Capacity Reservation.

Parameters:

Name Type Description Default
plugins list[Plugin] | None

A list of callables that modify the configuration dynamically. Changes made by these plugins only apply for the duration of the operation execution and will not affect any other operation invocations.

None

Returns:

Type Description
UpdateInterruptibleCapacityReservationAllocationOutput

An instance of UpdateInterruptibleCapacityReservationAllocationOutput.

Input

Pass the input fields as keyword arguments, or pass a model or dictionary as the first positional argument. Pass plugins separately as a keyword argument.

Model

UpdateInterruptibleCapacityReservationAllocationInput dataclass

Bases: _SerdeShape

Dataclass for UpdateInterruptibleCapacityReservationAllocationInput structure.

Attributes
capacity_reservation_id class-attribute instance-attribute
capacity_reservation_id: str | None = ...

The ID of the source Capacity Reservation containing the interruptible allocation to modify.

dry_run class-attribute instance-attribute
dry_run: bool | None = ...

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response.

target_instance_count class-attribute instance-attribute
target_instance_count: int | None = ...

The new number of instances to allocate. Enter a higher number to add more capacity to share, or a lower number to reclaim capacity to your source Capacity Reservation.

zero_size_preference class-attribute instance-attribute
zero_size_preference: str | None = ...

Specifies the updated behavior for the interruptible Capacity Reservation when you reduce its allocation to zero instances. Specify retain to keep the interruptible Capacity Reservation active at zero capacity so that you can allocate instances to it again later. Specify default to cancel the interruptible Capacity Reservation and return the capacity to your source Capacity Reservation.

Dictionaries

UpdateInterruptibleCapacityReservationAllocationInputDict

Bases: TypedDict

Dictionary form of UpdateInterruptibleCapacityReservationAllocationInput.

Attributes
capacity_reservation_id instance-attribute
capacity_reservation_id: Required[str]

The ID of the source Capacity Reservation containing the interruptible allocation to modify.

dry_run instance-attribute
dry_run: bool | None

Checks whether you have the required permissions for the action, without actually making the request, and provides an error response.

target_instance_count instance-attribute
target_instance_count: int | None

The new number of instances to allocate. Enter a higher number to add more capacity to share, or a lower number to reclaim capacity to your source Capacity Reservation.

zero_size_preference instance-attribute
zero_size_preference: str | None

Specifies the updated behavior for the interruptible Capacity Reservation when you reduce its allocation to zero instances. Specify retain to keep the interruptible Capacity Reservation active at zero capacity so that you can allocate instances to it again later. Specify default to cancel the interruptible Capacity Reservation and return the capacity to your source Capacity Reservation.

Output

UpdateInterruptibleCapacityReservationAllocationOutput dataclass

Bases: _SerdeShape

Dataclass for UpdateInterruptibleCapacityReservationAllocationOutput structure.

Attributes

instance_count class-attribute instance-attribute
instance_count: int | None = ...

The current number of instances allocated to the interruptible reservation.

interruptible_capacity_reservation_id class-attribute instance-attribute
interruptible_capacity_reservation_id: str | None = ...

The ID of the interruptible Capacity Reservation that was modified.

interruption_type class-attribute instance-attribute
interruption_type: str | None = ...

The interruption type for the interruptible reservation.

response_metadata class-attribute instance-attribute
response_metadata: ResponseMetadata = ...

Metadata about the response that produced this output. Use this to recover the request identifiers a service's support team needs in order to investigate a call. Members of the metadata are individually optional.

source_capacity_reservation_id class-attribute instance-attribute
source_capacity_reservation_id: str | None = ...

The ID of the source Capacity Reservation to which capacity was reclaimed or from which capacity was allocated.

status class-attribute instance-attribute
status: str | None = ...

The current status of the allocation (updating during reclamation, active when complete).

target_instance_count class-attribute instance-attribute
target_instance_count: int | None = ...

The requested number of instances for the interruptible Capacity Reservation.