查询周期任务策略
调试
您可以在OpenAPI Explorer中直接运行该接口,免去您计算签名的困扰。运行成功后,OpenAPI Explorer可以自动生成SDK代码示例。

授权信息
操作 |
访问级别 |
资源类型 |
条件关键字 |
关联操作 |
polardb:DescribeCronJobPolicyServerless |
list |
*全部资源
|
无 | 无 |
请求参数
名称 |
类型 |
必填 |
描述 |
示例值 |
DBClusterId |
string |
是 |
Serverless 集群 ID。 |
pc-**************** |
RegionId |
string |
是 |
地域 ID。 |
cn-hangzhou |
JobId |
string |
否 |
定时任务 ID。 |
8006e51c-dab3-4602-bc69-4f728002c6ce |
PageSize |
integer |
否 |
每页记录数,取值范围:
默认值为 30。 |
30 |
PageNumber |
integer |
否 |
分页查询时的页码。默认值:1。 |
1 |
返回参数
名称 |
类型 |
描述 |
示例值 |
object |
Schema of Response |
||
RequestId |
string |
Id of the request |
9B7BFB11-C077-4FE3-B051-F69CEB****** |
TotalRecordCount |
integer |
总的记录数量 |
5 |
PageNumber |
integer |
页码。 |
1 |
PageSize |
integer |
每页记录数,取值范围:
默认值为 30。 |
30 |
Items |
array<object> |
任务列表。 |
|
object |
定时任务对象集。 |
||
JobId |
string |
定时任务 ID。 |
12eee3eb-60bd-40ac-a403-218e02eb99c7 |
DBClusterId |
string |
集群 ID。 |
pc-***************** |
RegionId |
string |
地域 ID。 |
cn-hangzhou |
StartTime |
string |
任务开始时间,格式为 |
2020-06-09T18:00:00Z |
EndTime |
string |
任务结束时间,格式为 yyyy-MM-ddTHH:mm:ssZ(UTC 时间)。 |
2024-12-04T02:25:00Z |
Status |
string |
任务状态。 取值范围如下:
|
3 |
OrderId |
string |
订单 ID。 |
254752088000354 |
CronExpression |
string |
定时任务 Cron 表达式。 |
0 0 8 * * ? |
Action |
string |
系统规定参数,取值为 ModifyDBClusterServerlessConf。 |
ModifyDBClusterServerlessConf |
ScaleMin |
string |
最小值:0.25~32 PCU,且最小值 <= 最大值。单位:PCU。 |
1 |
ScaleMax |
string |
最大值:1~32 PCU。单位:PCU。 |
9 |
ScaleRoNumMin |
string |
只读节点个数伸缩下限。取值范围:0~15。 |
2 |
ScaleRoNumMax |
string |
只读节点个数的伸缩上限 0~15 个可选, 且不能大于上限的值。取值范围:0~15。 |
3 |
AllowShutDown |
string |
是否开启无活动暂停。取值:
|
true |
SecondsUntilAutoPause |
string |
无活动暂停的检测时长。取值范围:5~1440。单位分钟。检测时长必须是 5 分钟的倍数。 |
1200 |
ScaleApRoNumMin |
string |
只读列存节点个数下限。取值范围:0~15。 |
1 |
ScaleApRoNumMax |
string |
只读列存节点个数上限。取值范围:1~15。 |
2 |
ServerlessRuleMode |
string |
弹性灵敏度。取值:
|
normal |
ServerlessRuleCpuEnlargeThreshold |
string |
cpu 弹升阈值。最大值:40~100 % |
70 |
ServerlessRuleCpuShrinkThreshold |
string |
cpu 弹降阈值。最小值:10~100 %,且最大值 - 最小值 >= 30 |
40 |
示例
正常返回示例
JSON
格式
{
"RequestId": "9B7BFB11-C077-4FE3-B051-F69CEB******",
"TotalRecordCount": 5,
"PageNumber": 1,
"PageSize": 30,
"Items": [
{
"JobId": "12eee3eb-60bd-40ac-a403-218e02eb99c7",
"DBClusterId": "pc-*****************",
"RegionId": "cn-hangzhou",
"StartTime": "2020-06-09T18:00:00Z",
"EndTime": "2024-12-04T02:25:00Z",
"Status": "3",
"OrderId": "254752088000354",
"CronExpression": "0 0 8 * * ?",
"Action": "ModifyDBClusterServerlessConf",
"ScaleMin": "1",
"ScaleMax": "9",
"ScaleRoNumMin": "2",
"ScaleRoNumMax": "3",
"AllowShutDown": "true",
"SecondsUntilAutoPause": "1200",
"ScaleApRoNumMin": "1",
"ScaleApRoNumMax": "2",
"ServerlessRuleMode": "normal",
"ServerlessRuleCpuEnlargeThreshold": "70",
"ServerlessRuleCpuShrinkThreshold": "40"
}
]
}
错误码
HTTP status code |
错误码 |
错误信息 |
描述 |
---|---|---|---|
400 | InvalidRegionId.Malformed | The specified parameter RegionId is not valid. | 指定的参数RegionId无效 |
400 | InvalidStartTime.Malformed | The specified parameter StartTime is not valid. | 指定的参数StartTime无效 |
400 | InvalidEndTime.Malformed | The specified parameter EndTime is not valid. | 指定的参数EndTime无效 |
404 | InvalidDBClusterId.Malformed | The specified parameter DBClusterId is not valid. | 指定的参数DBClusterId无效 |
404 | InvalidJobId.NotFound | The Specified jobId does not found. | 找不到指定的jobId。 |
404 | InvalidCronJob.NotFound | The CronJob for jobId does not found. | 找不到指定CronJob。 |
访问错误中心查看更多错误码。
变更历史
更多信息,参考变更详情。