This API is used to query SQL throttling rules.
GET https://{endpoint}/v3/{project_id}/instances/{instance_id}/sql-limit?db_name={db_name}&offset={offset}&limit={limit}
Parameter |
Mandatory |
Type |
Description |
|---|---|---|---|
project_id |
Yes |
String |
Specifies the project ID of a tenant in a region. For details about how to obtain the project ID, see Obtaining a Project ID. |
instance_id |
Yes |
String |
Instance ID. |
db_name |
Yes |
String |
Database name. For example: "postgres". |
offset |
No |
Integer |
Index offset. If offset is set to N, the resource query starts from the N+1 piece of data. The value is 0 by default, indicating that the query starts from the first piece of data. The value must be a number but cannot be a negative number. |
limit |
No |
Integer |
Number of query records. The default value is 10. The value must be a positive integer. The minimum value is 1 and the maximum value is 100. |
Parameter |
Mandatory |
Type |
Description |
|---|---|---|---|
X-Auth-Token |
Yes |
String |
Specifies the user token. The user token is a response to the API used to obtain a user token. |
GET https://rds.eu-de.otc.t-systems.com/v3/0483b6b16e954cb88930a360d2c4e663/instances/49b9dd1d6f464ba4bc91df5cbd2e52ebin03/sql-limit?db_name=postgres&offset=0&limit=10
Parameter |
Type |
Description |
|---|---|---|
count |
Integer |
Number of SQL throttling rules. |
sql_limit_objects |
Array of objects |
SQL throttling rule details. For details, see Table 4. |
Parameter |
Type |
Description |
|---|---|---|
id |
String |
SQL throttling rule ID. |
query_id |
String |
Internal hash code calculated by the SQL parse tree. The default value is 0. The value range is from -9223372036854775808 to 9223372036854775807. |
query_string |
String |
Text format of an SQL statement. |
max_concurrency |
Integer |
Number of SQL statements that can be executed at the same time. If the value is less than or equal to 0, the number is not limited. The default value is 0. The value range is from -1 to 50000. |
is_effective |
Boolean |
Wether the rule is effective. |
max_waiting |
Integer |
Maximum waiting time, in seconds. |
search_path |
String |
Schema search order set for names that are not schema-qualified. The default value is public. |
{
"count": 2,
"sql_limit_objects": [
{
"id": "3",
"query_id": "1147616880456321454",
"query_string": "select 1;",
"max_concurrency": 10,
"is_effective": false,
"max_waiting": 10,
"search_path": "public"
},
{
"id": "4",
"query_id": "-7472493489976133824",
"query_string": "select * from pg_type;",
"max_concurrency": 10,
"is_effective": false,
"max_waiting": 10,
"search_path": "public"
}
]
}
For details, see Abnormal Request Results.
For details, see Status Codes.
For details, see Error Codes.