Skip to content

Commit 73a672d

Browse files
dox
Signed-off-by: Abhishek Choudhary <shreemaan.abhishek@gmail.com>
1 parent 45e241a commit 73a672d

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

docs/en/latest/plugins/limit-conn.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ The `limit-conn` Plugin limits the rate of requests by the number of concurrent
4444
| only_use_default_delay | boolean | False | false | | If false, delay requests proportionally based on how much they exceed the `conn` limit. The delay grows larger as congestion increases. For instance, with `conn` being `5`, `burst` being `3`, and `default_conn_delay` being `1`, 6 concurrent requests would result in a 1-second delay, 7 requests a 2-second delay, 8 requests a 3-second delay, and so on, until the total limit of `conn + burst` is reached, beyond which requests are rejected. If true, use `default_conn_delay` to delay all excessive requests within the `burst` range. Requests beyond `conn + burst` are rejected immediately. For instance, with `conn` being `5`, `burst` being `3`, and `default_conn_delay` being `1`, 6, 7, or 8 concurrent requests are all delayed by exactly 1 second each. |
4545
| key_type | string | False | var | ["var","var_combination"] | The type of key. If the `key_type` is `var`, the `key` is interpreted a variable. If the `key_type` is `var_combination`, the `key` is interpreted as a combination of variables. |
4646
| key | string | False | remote_addr | | The key to count requests by. If the `key_type` is `var`, the `key` is interpreted a variable. The variable does not need to be prefixed by a dollar sign (`$`). If the `key_type` is `var_combination`, the `key` is interpreted as a combination of variables. All variables should be prefixed by dollar signs (`$`). For example, to configure the `key` to use a combination of two request headers `custom-a` and `custom-b`, the `key` should be configured as `$http_custom_a $http_custom_b`. |
47-
| key_ttl | integer | False | 60 | | The TTL of the Redis key in seconds. Used when `policy` is `redis` or `redis-cluster`. |
47+
| key_ttl | integer | False | 3600 | | The TTL of the Redis key in seconds. Used when `policy` is `redis` or `redis-cluster`. |
4848
| rejected_code | integer | False | 503 | [200,...,599] | The HTTP status code returned when a request is rejected for exceeding the threshold. |
4949
| rejected_msg | string | False | | non-empty | The response body returned when a request is rejected for exceeding the threshold. |
5050
| allow_degradation | boolean | False | false | | If true, allow APISIX to continue handling requests without the Plugin when the Plugin or its dependencies become unavailable. |

docs/zh/latest/plugins/limit-conn.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ description: limit-conn 插件通过管理并发连接来限制请求速率。
4444
| only_use_default_delay | boolean || false | | 如果为 false,则根据请求超出`conn`限制的程度按比例延迟请求。拥塞越严重,延迟就越大。例如,当 `conn``5``burst``3``default_conn_delay``1` 时,6 个并发请求将导致 1 秒的延迟,7 个请求将导致 2 秒的延迟,8 个请求将导致 3 秒的延迟,依此类推,直到达到 `conn + burst` 的总限制,超过此限制的请求将被拒绝。如果为 true,则使用 `default_conn_delay` 延迟 `burst` 范围内的所有超额请求。超出 `conn + burst` 的请求将被立即拒绝。例如,当 `conn``5``burst``3``default_conn_delay``1` 时,6、7 或 8 个并发请求都将延迟 1 秒。|
4545
| key_type | string || var | ["var","var_combination"] | key 的类型。如果`key_type``var`,则 `key` 将被解释为变量。如果 `key_type``var_combination`,则 `key` 将被解释为变量的组合。 |
4646
| key | string || remote_addr | | 用于计数请求的 key。如果 `key_type``var`,则 `key` 将被解释为变量。变量不需要以美元符号(`$`)为前缀。如果 `key_type``var_combination`,则 `key` 会被解释为变量的组合。所有变量都应该以美元符号 (`$`) 为前缀。例如,要配置 `key` 使用两个请求头 `custom-a``custom-b` 的组合,则 `key` 应该配置为 `$http_custom_a $http_custom_b`|
47-
| key_ttl | integer || 60 | | Redis 键的 TTL(以秒为单位)。当 `policy``redis``redis-cluster` 时使用。 |
47+
| key_ttl | integer || 3600 | | Redis 键的 TTL(以秒为单位)。当 `policy``redis``redis-cluster` 时使用。 |
4848
| rejection_code | integer || 503 | [200,...,599] | 请求因超出阈值而被拒绝时返回的 HTTP 状态代码。|
4949
| rejection_msg | string || | 非空 | 请求因超出阈值而被拒绝时返回的响应主体。|
5050
| allow_degradation | boolean || false | | 如果为 true,则允许 APISIX 在插件或其依赖项不可用时继续处理没有插件的请求。|

0 commit comments

Comments
 (0)