From 2ef9615f97117eb6e1dc65537ba89dcd0627623b Mon Sep 17 00:00:00 2001 From: Zhenyu Luo <2424809934@qq.com> Date: Thu, 14 Dec 2023 10:29:37 +0800 Subject: [PATCH] docs: description client-control plugin configuration `max_body_size` unit (#10635) --- apisix/plugins/client-control.lua | 1 + docs/en/latest/plugins/client-control.md | 2 +- docs/zh/latest/plugins/client-control.md | 6 +++--- 3 files changed, 5 insertions(+), 4 deletions(-) diff --git a/apisix/plugins/client-control.lua b/apisix/plugins/client-control.lua index 63c0cacb9d5b..1975098c83ce 100644 --- a/apisix/plugins/client-control.lua +++ b/apisix/plugins/client-control.lua @@ -26,6 +26,7 @@ local schema = { max_body_size = { type = "integer", minimum = 0, + description = "Maximum message body size in bytes. No restriction when set to 0." }, }, } diff --git a/docs/en/latest/plugins/client-control.md b/docs/en/latest/plugins/client-control.md index 61d15ca60d3e..03541066d517 100644 --- a/docs/en/latest/plugins/client-control.md +++ b/docs/en/latest/plugins/client-control.md @@ -40,7 +40,7 @@ This Plugin requires APISIX to run on APISIX-Runtime. See [apisix-build-tools](h | Name | Type | Required | Valid values | Description | | ------------- | ------- | -------- | ------------ | ------------------------------------------------------------------------------------------------------------------------------------ | -| max_body_size | integer | False | [0,...] | Dynamically set the [`client_max_body_size`](https://nginx.org/en/docs/http/ngx_http_core_module.html#client_max_body_size) directive. | +| max_body_size | integer | False | [0,...] | Set the maximum limit for the client request body and dynamically adjust the size of [`client_max_body_size`](https://nginx.org/en/docs/http/ngx_http_core_module.html#client_max_body_size), measured in bytes. If you set the `max_body_size` to 0, then the size of the client's request body will not be checked. | ## Enable Plugin diff --git a/docs/zh/latest/plugins/client-control.md b/docs/zh/latest/plugins/client-control.md index 9994437f4bdc..fa73680d0322 100644 --- a/docs/zh/latest/plugins/client-control.md +++ b/docs/zh/latest/plugins/client-control.md @@ -38,9 +38,9 @@ description: 本文介绍了 Apache APISIX proxy-control 插件的相关操作 ## 属性 -| 名称 | 类型 | 必选项 | 有效值 | 描述 | -| --------- | ------------- | ----------- | ------------------------------------------------------------------------ | --------------------------------------------------------------------------------------------------------------------------------------------------- | -| max_body_size | integer | 否 | [0,...] | 动态设置 [`client_max_body_size`](https://nginx.org/en/docs/http/ngx_http_core_module.html#client_max_body_size) 的大小。 | +| 名称 | 类型 | 必选项 | 有效值 | 描述 | +| --------- | ------------- | ----------- | ------------------------------------------------------------------------ |---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------| +| max_body_size | integer | 否 | [0,...] | 设置客户端请求体的最大上限,动态调整 [`client_max_body_size`](https://nginx.org/en/docs/http/ngx_http_core_module.html#client_max_body_size) 的大小,单位为字节。当设置 `max_body_size` 为 0 时,将不会对客户端请求体大小进行检查。 | ## 启用插件