{"base_path":"/","components":null,"consumes":"","definitions":{"ErrorResp":{"description":"失败时返回的错误对象","properties":{"error_code":{"description":"错误码","maxLength":36,"minLength":8,"type":"string"},"error_msg":{"description":"错误描述","maxLength":512,"minLength":2,"type":"string"}},"required":["error_code","error_msg"]},"GetTransactionListResp":{"description":"历史事务列表返回体","properties":{"total":{"description":"历史事务总数","example":120,"format":"int32","type":"integer"},"transaction_info_list":{"description":"历史事务信息列表","items":{"properties":{"collect_time":{"description":"收集时间","format":"int64","type":"integer"},"detail":{"description":"事务内容","example":"MySQL thread id 17485282, OS thread handle 140455451772672, query id 48549222 100.125.9.95 root updating\ndelete from dead_lock_test where v1 = 5 and v2 = 5\n*** HOLDS THE LOCK:\nRECORD LOCKS space id 34691 page no 3 n bits 80 index PRIMARY of table `at_cloud_dba_001`.`dead_lock_test` trx id 690888 lock_mode X locks rec but not gap\nRecord lock, heap no 7 PHYSICAL RECORD: n_fields 5; compact format; info bits 0\n","type":"string"},"hold_locks":{"description":"持有锁数量","example":3,"format":"int32","type":"integer"},"last_sec":{"description":"事务持续时间","example":5,"format":"int32","type":"integer"},"occurrence_time":{"description":"发生时间","example":1717398965000,"format":"int64","type":"integer"},"wait_locks":{"description":"等待锁数量","example":3,"format":"int32","type":"integer"}},"required":["last_sec","wait_locks","hold_locks","occurrence_time","detail","collect_time"]},"type":"array"}},"required":["total","transaction_info_list"],"type":"object"}},"description":null,"group_id":"7f831fc0dd494cfe86eff0b79e4f207d","host":"das.cn-north-4.myhuaweicloud.com","id":"255c95b345ac423e967947d78f98b80a","info_version":"v3","method":"get","name":"ListTransactions","parameters":{},"paths":{"/v3/{project_id}/instances/{instance_id}/transaction":{"get":{"description":"查询历史事务列表。\n目前仅支持MySQL实例,仅支持查看最近7天的历史事务。","operationId":"ListTransactions","parameters":[{"description":"项目ID","in":"path","name":"project_id","required":true,"type":"string"},{"description":"实例ID","in":"path","name":"instance_id","required":true,"type":"string"},{"description":"数据库类型。仅支持MySQL","enum":["MySQL"],"in":"query","name":"datastore_type","required":true,"type":"string"},{"description":"用户token","in":"header","name":"X-Auth-Token","required":true,"type":"string"},{"description":"语言","enum":["zh-cn","en-us"],"in":"header","name":"X-Language","required":false,"type":"string"},{"description":"采集开始时间(Unix timestamp),单位:毫秒。","format":"int64","in":"query","name":"start_at","required":true,"type":"integer"},{"description":"采集结束时间(Unix timestamp),单位:毫秒。","format":"int64","in":"query","name":"end_at","required":true,"type":"integer"},{"default":1,"description":"页数","format":"int32","in":"query","name":"page_num","required":false,"type":"integer"},{"default":10,"description":"页大小","format":"int32","in":"query","name":"page_size","required":false,"type":"integer"},{"default":"collectTime","description":"排序字段","enum":["occurrenceTime","lastSec","waitLockStructCount","holdLockStructCount","collectTime"],"in":"query","name":"order","required":false,"type":"string"},{"default":"desc","description":"升序|降序","enum":["asc","desc"],"in":"query","name":"order_by","required":false,"type":"string"},{"description":"持续时间下限","format":"int64","in":"query","name":"last_sec_min","required":false,"type":"integer"},{"description":"持续时间上限","format":"int64","in":"query","name":"last_sec_max","required":false,"type":"integer"}],"responses":{"200":{"description":"Success.","examples":{"application/json":{"total":1,"transaction_info_list":[{"collect_time":1717398965000,"detail":"MySQL thread id 17485282, OS thread handle 140455451772672, query id 48549222 xxx root updating\ndelete from dead_lock_test where v1 = 5 and v2 = 5\n*** HOLDS THE LOCK:\nRECORD LOCKS space id 34691 page no 3 n bits 80 index PRIMARY of table `at_cloud_dba_001`.`dead_lock_test` trx id 690888 lock_mode X locks rec but not gap\nRecord lock, heap no 7 PHYSICAL RECORD: n_fields 5; compact format; info bits 0\n","hold_locks":3,"last_sec":5,"occurrence_time":1717398965000,"wait_locks":3}]}},"schema":{"$ref":"#/definitions/GetTransactionListResp"}},"400":{"description":"Client error.","schema":{"$ref":"#/definitions/ErrorResp"}},"500":{"description":"Server error.","schema":{"$ref":"#/definitions/ErrorResp"}}},"summary":"查询历史事务列表","tags":["云DBA"],"x-das-is-publish":"#GetTransactionSwitch_Placeholder#","x-is-registered":"Y","x-request-examples-description-1":"获取历史事务列表","x-request-examples-url-1":"GET https://das.cn-north-1.myhuaweicloud.com/v3/054c630ff780d4cc2f40c00d7f6fb21d/instances/a77c88dcfd404a64a466ca2cd2f5b8e5in01/transaction?datastore_type=MySQL&start_at=1&end_at=1717399020000","x-support-sdk":"Y"}}},"product_short":"DAS","region_id":"cn-north-4","schemes":["HTTPS"],"security_definitions":null,"summary":"查询历史事务列表","tags":"云DBA","uri":null,"version":"2.0"}