RDS / Paginator / DescribeDBCapacityReservations
DescribeDBCapacityReservations¶
- class RDS.Paginator.DescribeDBCapacityReservations¶
paginator = client.get_paginator('describe_db_capacity_reservations')
- paginate(**kwargs)¶
Creates an iterator that will paginate through responses from
RDS.Client.describe_db_capacity_reservations().See also: AWS API Documentation
Request Syntax
response_iterator = paginator.paginate( DBCapacityReservationIdentifier='string', Filters=[ { 'Name': 'string', 'Values': [ 'string', ] }, ], PaginationConfig={ 'MaxItems': 123, 'PageSize': 123, 'StartingToken': 'string' } )
- Parameters:
DBCapacityReservationIdentifier (string) – The identifier or the name of the DB capacity reservation to describe. You can specify the identifier, which has the prefix
dbcr-, or the reservation name.Filters (list) –
A filter that specifies which DB capacity reservations to describe.
Supported filters:
db-capacity-reservation-name- Accepts DB capacity reservation names. The response includes only the reservations that these names identify. Use this filter to describe several reservations by name in one request.state- Accepts reservation states. The response includes only the reservations in these states.engine- Accepts database engine names. The response includes only the reservations that reserve capacity for these engines.db-instance-class- Accepts DB instance classes. The response includes only the reservations that reserve capacity for these DB instance classes.availability-zone- Accepts Availability Zone names. The response includes only the reservations that cover these Availability Zones.
When you specify more than one value for a filter, the response includes the reservations that match any of those values. When you specify more than one filter, the response includes only the reservations that match every filter.
Amazon RDS rejects the request when a filter name isn’t in this list, or when a filter specifies no values.
Note
The
statefilter doesn’t acceptexpired. To find an expired reservation, compareEndDateagainst the current date and time.(dict) –
A filter name and value pair that is used to return a more specific list of results from a describe operation. Filters can be used to match a set of resources by specific criteria, such as IDs. The filters supported by a describe operation are documented with the describe operation.
Note
Currently, wildcards are not supported in filters.
The following actions can be filtered:
DescribeDBCapacityReservationsDescribeDBClusterBacktracksDescribeDBClusterEndpointsDescribeDBClustersDescribeDBInstancesDescribeDBRecommendationsDescribeDBShardGroupsDescribePendingMaintenanceActions
Name (string) – [REQUIRED]
The name of the filter. Filter names are case-sensitive.
Values (list) – [REQUIRED]
One or more filter values. Filter values are case-sensitive.
(string) –
PaginationConfig (dict) –
A dictionary that provides parameters to control pagination.
MaxItems (integer) –
The total number of items to return. If the total number of items available is more than the value specified in max-items then a
NextTokenwill be provided in the output that you can use to resume pagination.PageSize (integer) –
The size of each page.
StartingToken (string) –
A token to specify where to start paginating. This is the
NextTokenfrom a previous response.
- Return type:
dict
- Returns:
Response Syntax
{ 'DBCapacityReservations': [ { 'DBCapacityReservationName': 'string', 'DBInstanceClass': 'string', 'Engine': 'string', 'LicenseModel': 'string', 'ReservedCapacityPerAvailabilityZone': 123, 'AvailableCapacityPerAvailabilityZoneList': [ { 'AvailabilityZone': 'string', 'AvailableCapacity': 123 }, ], 'EndDate': datetime(2015, 1, 1), 'CreateDate': datetime(2015, 1, 1), 'StartDate': datetime(2015, 1, 1), 'CommitmentInfo': { 'CommittedCapacityPerAvailabilityZone': 123, 'CommitmentEndDate': datetime(2015, 1, 1) }, 'State': 'active'|'expired'|'cancelled'|'pending'|'failed'|'assessing'|'scheduled'|'delayed'|'unsupported', 'DBCapacityReservationArn': 'string', 'DBCapacityReservationIdentifier': 'string', 'TagList': [ { 'Key': 'string', 'Value': 'string' }, ] }, ], 'NextToken': 'string' }
Response Structure
(dict) –
DBCapacityReservations (list) –
A list of DB capacity reservations.
(dict) –
Contains the details of a DB capacity reservation.
This data type is used as a response element in the following operations:
CancelDBCapacityReservationCreateDBCapacityReservationDescribeDBCapacityReservationsModifyDBCapacityReservation
DBCapacityReservationName (string) –
The name that you specified for the DB capacity reservation.
DBInstanceClass (string) –
The DB instance class for the reserved capacity. You specify this value when you create the reservation, and you can’t change it afterward.
Engine (string) –
The database engine for the reserved capacity. You specify this value when you create the reservation, and you can’t change it afterward.
LicenseModel (string) –
The license model for the reserved capacity. Amazon RDS returns this value only for a reservation that reserves capacity for a specific license model. Amazon RDS doesn’t return this value for a reservation whose database engine doesn’t support a license model.
A DB instance launches into the reservation only when the license model of the DB instance matches this value. For a reservation that holds no license model, Amazon RDS applies no license model check at launch.
Valid Values:
RDS for Microsoft SQL Server Enterprise Edition and Standard Edition -
license-included | bring-your-own-mediaRDS for Microsoft SQL Server Developer Edition -
bring-your-own-licenseRDS for Oracle -
bring-your-own-license | license-includedRDS for Db2 Standard Edition and Advanced Edition -
bring-your-own-license | marketplace-license
For RDS for Db2 Standard Edition and Advanced Edition, a reservation created without a license model holds
bring-your-own-license.ReservedCapacityPerAvailabilityZone (integer) –
The number of DB instances that Amazon RDS reserves in each Availability Zone of the reservation. This value matches the
CapacityPerAvailabilityZoneparameter of the request. The total reserved capacity is this value multiplied by the number of Availability Zones of the reservation.AvailableCapacityPerAvailabilityZoneList (list) –
The unused capacity of the reservation, reported for each Availability Zone of the reservation. Each entry names one Availability Zone, and it reports the number of DB instances that remain available in that Availability Zone.
Amazon RDS reports available capacity only for a reservation that is in the
activestate and not past its end date. Otherwise, each entry reports an available capacity of0. A future-dated reservation that hasn’t started reports0, and a reservation that Amazon RDS is modifying reports0.A reservation reports the
pendingstate while Amazon RDS modifies it. Therefore, a reservation in theactivestate that reports no available capacity has no unused capacity.(dict) –
Contains the unused capacity of a DB capacity reservation in one Availability Zone.
This data type is used as a response element in the following operations:
CancelDBCapacityReservationCreateDBCapacityReservationDescribeDBCapacityReservationsModifyDBCapacityReservation
AvailabilityZone (string) –
The name of the Availability Zone.
AvailableCapacity (integer) –
The number of DB instances that remain available in this Availability Zone. Amazon RDS decreases this value when a DB instance takes a unit of reserved capacity in this Availability Zone, and it increases this value when a DB instance releases that unit.
A DB instance with a pending modification also holds a unit of reserved capacity. A DB instance has a pending modification when Amazon RDS accepts a change to the DB instance and applies that change later, during the maintenance window. Amazon RDS holds the unit from the time that it accepts the request. To find a DB instance with a pending modification, check
PendingModifiedValuesin the response ofDescribeDBInstances.Amazon RDS reports available capacity only for a reservation that is in the
activestate and not past its end date. Otherwise, this value is0.
EndDate (datetime) –
The date and time when the reservation expires, in Universal Coordinated Time (UTC). Amazon RDS doesn’t return this value if the reservation doesn’t expire.
Warning
A DB instance that uses the reservation keeps running after the reservation expires. It continues on unreserved capacity, and Amazon RDS doesn’t stop it or modify it. However, Amazon RDS no longer reserves capacity for the DB instance. Amazon RDS might later move the DB instance to different hardware, for example during hardware maintenance. That move can fail when the Amazon Web Services Region has insufficient capacity for the DB instance class.
CreateDate (datetime) –
The date and time when the reservation was created, in Universal Coordinated Time (UTC).
StartDate (datetime) –
The date and time when a future-dated reservation starts, in Universal Coordinated Time (UTC). Amazon RDS doesn’t return this value for a reservation that started immediately.
CommitmentInfo (dict) –
The capacity commitment of the reservation. Amazon RDS returns this object only for a future-dated reservation.
CommittedCapacityPerAvailabilityZone (integer) –
The number of DB instances that Amazon RDS holds in each Availability Zone of the reservation for the length of the commitment.
CommitmentEndDate (datetime) –
The date and time when the commitment ends, in Universal Coordinated Time (UTC). This date reports the capacity commitment that Amazon RDS granted.
Amazon RDS can grant a shorter capacity commitment than you request in
CommitmentDuration. Therefore, this date can fall earlier thanStartDateplusCommitmentDuration.
State (string) –
The current state of the DB capacity reservation. A DB instance can use the reservation in the
activestate only.Valid Values:
active- Amazon RDS holds the reserved capacity, and a DB instance can use it.pending- The reservation isn’t ready to use yet. Amazon RDS is creating the reserved capacity, or it is applying a requested modification.assessing- Amazon RDS is evaluating the request for a future-dated reservation.scheduled- Amazon RDS accepted a future-dated reservation, and the reservation is waiting for its start date.delayed- Amazon RDS couldn’t provide the reserved capacity of a future-dated reservation by its start date.unsupported- Amazon RDS can’t fulfill the future-dated reservation as requested.expired- The reservation passed its end date. Amazon RDS releases the reserved capacity.cancelled- You cancelled the reservation, and Amazon RDS released the reserved capacity.failed- Amazon RDS couldn’t reserve the capacity.
The values
assessing,scheduled,delayed, andunsupportedapply to a future-dated reservation only.DBCapacityReservationArn (string) –
The Amazon Resource Name (ARN) of the DB capacity reservation.
DBCapacityReservationIdentifier (string) –
The unique identifier of the DB capacity reservation. The identifier has the prefix
dbcr-. Every other DB capacity reservation operation takes this identifier.TagList (list) –
The tags associated with the DB capacity reservation.
(dict) –
Metadata assigned to an Amazon RDS resource consisting of a key-value pair.
For more information, see Tagging Amazon RDS resources in the Amazon RDS User Guide or Tagging Amazon Aurora and Amazon RDS resources in the Amazon Aurora User Guide.
Key (string) –
A key is the required name of the tag. The string value can be from 1 to 128 Unicode characters in length and can’t be prefixed with
aws:orrds:. The string can only contain only the set of Unicode letters, digits, white-space, ‘_’, ‘.’, ‘:’, ‘/’, ‘=’, ‘+’, ‘-’, ‘@’ (Java regex: “^([\p{L}\p{Z}\p{N}_.:/=+\-@]*)$”).Value (string) –
A value is the optional value of the tag. The string value can be from 1 to 256 Unicode characters in length and can’t be prefixed with
aws:orrds:. The string can only contain only the set of Unicode letters, digits, white-space, ‘_’, ‘.’, ‘:’, ‘/’, ‘=’, ‘+’, ‘-’, ‘@’ (Java regex: “^([\p{L}\p{Z}\p{N}_.:/=+\-@]*)$”).
NextToken (string) –
A token to resume pagination.