更新时间:2024-03-28 GMT+08:00

查询实例参数修改历史

功能介绍

查询数据库实例的参数修改历史。

接口约束

  • 支持的数据库引擎:MySQL、PostgreSQL、Microsoft SQL Server。

URI

  • URI格式

    GET /v3/{project_id}/instances/{instance_id}/configuration-histories?offset={offset}&limit={limit}&start_time={start_time}&end_time={end_time}&param_name={param_name}

  • 参数说明
    表1 参数说明

    名称

    是否必选

    参数类型

    说明

    project_id

    String

    租户在某一Region下的项目ID。

    获取方法请参见获取项目ID

    instance_id

    String

    实例ID。

    offset

    Integer

    分页参数。

    缺省值:0

    limit

    Integer

    分页参数。

    缺省值:10

    start_time

    String

    开始时间默认为当前时间的前7天,格式:2020-09-01T18:50:20Z

    end_time

    String

    结束时间默认为当前时间,格式:2020-09-01T18:50:20Z

    param_name

    String

    参数名称。

请求消息

  • 参数说明

    无。

  • URI样例

    GET https://{endpoint}/v3/054e292c9880d4992f02c0196d3ea468/instances/1922f9c9144a421d9d1dfcb7377a849ain04/configuration-histories

响应消息

  • 正常响应要素说明
    表2 要素说明

    参数

    参数类型

    描述

    total_count

    Integer

    历史记录总数。

    histories

    Array of objects

    参数修改历史。

    详情请参见表3

    表3 histories字段数据结构说明

    名称

    参数类型

    说明

    parameter_name

    String

    参数名称。

    old_value

    String

    旧参数值。

    new_value

    String

    新参数值。

    update_result

    String

    更新结果。

    • SUCCESS:成功。
    • FAILED:失败。

    applied

    Boolean

    是否已应用。

    • true:已应用。
    • false:未应用。

    update_time

    String

    参数修改时间。

    apply_time

    String

    参数应用时间。

  • 正常响应样例
    {
       "total_count" : 3, 
       "histories" : [ { 
         "parameter_name" : "fill factor (%)", 
         "old_value" : "0", 
         "new_value" : "2", 
         "update_result" : "SUCCESS", 
         "applied" : true, 
         "update_time" : "2022-10-29T09:39:21+0000", 
         "apply_time" : "2022-10-31T01:46:29+0000" 
       }, { 
         "parameter_name" : "remote login timeout (s)", 
         "old_value" : "10", 
         "new_value" : "20", 
         "update_result" : "SUCCESS", 
         "applied" : true, 
         "update_time" : "2022-10-29T09:38:36+0000", 
         "apply_time" : "2022-10-29T09:38:36+0000" 
       }, { 
         "parameter_name" : "remote query timeout (s)", 
         "old_value" : "600", 
         "new_value" : "601", 
         "update_result" : "SUCCESS", 
         "applied" : true, 
         "update_time" : "2022-10-29T09:40:30+0000", 
         "apply_time" : "2022-10-29T09:40:30+0000" 
       } ] 
     }
  • 异常响应

    请参见异常请求结果

状态码

错误码

请参见错误码