/AWS1/IF_RDS=>MODIFYCURRENTDBCLUSTERCAP()¶
About ModifyCurrentDBClusterCapacity¶
Set the capacity of an Aurora Serverless v1 DB cluster to a specific value.
Aurora Serverless v1 scales seamlessly based on the workload on the DB cluster. In some cases, the capacity might not scale
fast enough to meet a sudden change in workload, such as a large number of new transactions. Call ModifyCurrentDBClusterCapacity
to set the capacity explicitly.
After this call sets the DB cluster capacity, Aurora Serverless v1 can automatically scale the DB cluster based on the cooldown period for scaling up and the cooldown period for scaling down.
For more information about Aurora Serverless v1, see Using Amazon Aurora Serverless v1 in the Amazon Aurora User Guide.
If you call ModifyCurrentDBClusterCapacity with the default TimeoutAction, connections that
prevent Aurora Serverless v1 from finding a scaling point might be dropped. For more information about scaling points,
see
Autoscaling for Aurora Serverless v1 in the Amazon Aurora User Guide.
This operation only applies to Aurora Serverless v1 DB clusters.
Method Signature¶
METHODS /AWS1/IF_RDS~MODIFYCURRENTDBCLUSTERCAP
IMPORTING
!IV_DBCLUSTERIDENTIFIER TYPE /AWS1/RDSSTRING OPTIONAL
!IV_CAPACITY TYPE /AWS1/RDSINTEGEROPTIONAL OPTIONAL
!IV_SECONDSBEFORETIMEOUT TYPE /AWS1/RDSINTEGEROPTIONAL OPTIONAL
!IV_TIMEOUTACTION TYPE /AWS1/RDSSTRING OPTIONAL
RETURNING
VALUE(OO_OUTPUT) TYPE REF TO /aws1/cl_rdsdbclustercapinfo
RAISING
/AWS1/CX_RDSDBCLUSTNOTFNDFAULT
/AWS1/CX_RDSINVDBCLUSTCAPFAULT
/AWS1/CX_RDSINVDBCLSTSTATEFA00
/AWS1/CX_RDSCLIENTEXC
/AWS1/CX_RDSSERVEREXC
/AWS1/CX_RT_TECHNICAL_GENERIC
/AWS1/CX_RT_SERVICE_GENERIC.
IMPORTING¶
Required arguments:¶
iv_dbclusteridentifier TYPE /AWS1/RDSSTRING /AWS1/RDSSTRING¶
The DB cluster identifier for the cluster being modified. This parameter isn't case-sensitive.
Constraints:
Must match the identifier of an existing DB cluster.
Optional arguments:¶
iv_capacity TYPE /AWS1/RDSINTEGEROPTIONAL /AWS1/RDSINTEGEROPTIONAL¶
The DB cluster capacity.
When you change the capacity of a paused Aurora Serverless v1 DB cluster, it automatically resumes.
Constraints:
For Aurora MySQL, valid capacity values are
1,2,4,8,16,32,64,128, and256.For Aurora PostgreSQL, valid capacity values are
2,4,8,16,32,64,192, and384.
iv_secondsbeforetimeout TYPE /AWS1/RDSINTEGEROPTIONAL /AWS1/RDSINTEGEROPTIONAL¶
The amount of time, in seconds, that Aurora Serverless v1 tries to find a scaling point to perform seamless scaling before enforcing the timeout action. The default is 300.
Specify a value between 10 and 600 seconds.
iv_timeoutaction TYPE /AWS1/RDSSTRING /AWS1/RDSSTRING¶
The action to take when the timeout is reached, either
ForceApplyCapacityChangeorRollbackCapacityChange.
ForceApplyCapacityChange, the default, sets the capacity to the specified value as soon as possible.
RollbackCapacityChangeignores the capacity change if a scaling point isn't found in the timeout period.
RETURNING¶
oo_output TYPE REF TO /aws1/cl_rdsdbclustercapinfo /AWS1/CL_RDSDBCLUSTERCAPINFO¶
Domain /AWS1/RT_ACCOUNT_ID Primitive Type NUMC
Examples¶
Syntax Example¶
This is an example of the syntax for calling the method. It includes every possible argument and initializes every possible value. The data provided is not necessarily semantically accurate (for example the value "string" may be provided for something that is intended to be an instance ID, or in some cases two arguments may be mutually exclusive). The syntax shows the ABAP syntax for creating the various data structures.
DATA(lo_result) = lo_client->modifycurrentdbclustercap(
iv_capacity = 123
iv_dbclusteridentifier = |string|
iv_secondsbeforetimeout = 123
iv_timeoutaction = |string|
).
This is an example of reading all possible response values
lo_result = lo_result.
IF lo_result IS NOT INITIAL.
lv_string = lo_result->get_dbclusteridentifier( ).
lv_integeroptional = lo_result->get_pendingcapacity( ).
lv_integeroptional = lo_result->get_currentcapacity( ).
lv_integeroptional = lo_result->get_secondsbeforetimeout( ).
lv_string = lo_result->get_timeoutaction( ).
ENDIF.
To scale the capacity of an Aurora Serverless DB cluster¶
The following example scales the capacity of an Aurora Serverless DB cluster to 8.
DATA(lo_result) = lo_client->modifycurrentdbclustercap(
iv_capacity = 8
iv_dbclusteridentifier = |mydbcluster|
).