mirror of
https://gitee.com/iresty/apisix.git
synced 2024-12-15 01:11:58 +08:00
docs(kafka-logger): optimize the description of the attribute. (#2867)
close #2861
This commit is contained in:
parent
f4161d39a4
commit
ef87048b00
@ -47,14 +47,14 @@ For more info on Batch-Processor in Apache APISIX please refer.
|
|||||||
| kafka_topic | string | required | | | Target topic to push data. |
|
| kafka_topic | string | required | | | Target topic to push data. |
|
||||||
| key | string | optional | | | Used for partition allocation of messages. |
|
| key | string | optional | | | Used for partition allocation of messages. |
|
||||||
| timeout | integer | optional | 3 | [1,...] | Timeout for the upstream to send data. |
|
| timeout | integer | optional | 3 | [1,...] | Timeout for the upstream to send data. |
|
||||||
| name | string | optional | "kafka logger" | | A unique identifier to identity the batch processor |
|
| name | string | optional | "kafka logger" | | A unique identifier to identity the batch processor. |
|
||||||
| meta_format | string | optional | "default" | enum: `default`, `origin`| `default`: collect the request information with detfault JSON way. `origin`: collect the request information with original HTTP request. [example](#examples-of-meta_format)|
|
| meta_format | enum | optional | "default" | ["default","origin"] | `default`: collect the request information with detfault JSON way. `origin`: collect the request information with original HTTP request. [example](#examples-of-meta_format)|
|
||||||
| batch_max_size | integer | optional | 1000 | [1,...] | Max size of each batch |
|
| batch_max_size | integer | optional | 1000 | [1,...] | Set the maximum number of logs sent in each batch. When the number of logs reaches the set maximum, all logs will be automatically pushed to the `Kafka` service. |
|
||||||
| inactive_timeout | integer | optional | 5 | [1,...] | Maximum age in seconds when the buffer will be flushed if inactive |
|
| inactive_timeout | integer | optional | 5 | [1,...] | The maximum time to refresh the buffer (in seconds). When the maximum refresh time is reached, all logs will be automatically pushed to the `Kafka` service regardless of whether the number of logs in the buffer reaches the set maximum number. |
|
||||||
| buffer_duration | integer | optional | 60 | [1,...] | Maximum age in seconds of the oldest entry in a batch before the batch must be processed |
|
| buffer_duration | integer | optional | 60 | [1,...] | Maximum age in seconds of the oldest entry in a batch before the batch must be processed.|
|
||||||
| max_retry_count | integer | optional | 0 | [0,...] | Maximum number of retries before removing from the processing pipe line |
|
| max_retry_count | integer | optional | 0 | [0,...] | Maximum number of retries before removing from the processing pipe line. |
|
||||||
| retry_delay | integer | optional | 1 | [0,...] | Number of seconds the process execution should be delayed if the execution fails |
|
| retry_delay | integer | optional | 1 | [0,...] | Number of seconds the process execution should be delayed if the execution fails. |
|
||||||
| include_req_body | boolean | optional | false | | Whether to include the request body |
|
| include_req_body | boolean | optional | false | [false, true] | Whether to include the request body. false: indicates that the requested body is not included; true: indicates that the requested body is included. |
|
||||||
|
|
||||||
### examples of meta_format
|
### examples of meta_format
|
||||||
|
|
||||||
|
@ -46,13 +46,13 @@
|
|||||||
| key | string | 可选 | | | 用于消息的分区分配。 |
|
| key | string | 可选 | | | 用于消息的分区分配。 |
|
||||||
| timeout | integer | 可选 | 3 | [1,...] | 发送数据的超时时间。 |
|
| timeout | integer | 可选 | 3 | [1,...] | 发送数据的超时时间。 |
|
||||||
| name | string | 可选 | "kafka logger" | | batch processor 的唯一标识。 |
|
| name | string | 可选 | "kafka logger" | | batch processor 的唯一标识。 |
|
||||||
| meta_format | string | 可选 | "default" | 枚举:`default`,`origin`| `default`:获取请求信息以默认的 JSON 编码方式。`origin`:获取请求信息以 HTTP 原始请求方式。[具体示例](#meta_format-参考示例)|
|
| meta_format | enum | 可选 | "default" | ["default","origin"] | `default`:获取请求信息以默认的 JSON 编码方式。`origin`:获取请求信息以 HTTP 原始请求方式。[具体示例](#meta_format-参考示例)|
|
||||||
| batch_max_size | integer | 可选 | 1000 | [1,...] | 每批的最大大小 |
|
| batch_max_size | integer | 可选 | 1000 | [1,...] | 设置每批发送日志的最大条数,当日志条数达到设置的最大值时,会自动推送全部日志到 `Kafka` 服务。|
|
||||||
| inactive_timeout | integer | 可选 | 5 | [1,...] | 刷新缓冲区的最大时间(以秒为单位) |
|
| inactive_timeout | integer | 可选 | 5 | [1,...] | 刷新缓冲区的最大时间(以秒为单位),当达到最大的刷新时间时,无论缓冲区中的日志数量是否达到设置的最大条数,也会自动将全部日志推送到 `Kafka` 服务。 |
|
||||||
| buffer_duration | integer | 可选 | 60 | [1,...] | 必须先处理批次中最旧条目的最长期限(以秒为单位) |
|
| buffer_duration | integer | 可选 | 60 | [1,...] | 必须先处理批次中最旧条目的最长期限(以秒为单位)。 |
|
||||||
| max_retry_count | integer | 可选 | 0 | [0,...] | 从处理管道中移除之前的最大重试次数 |
|
| max_retry_count | integer | 可选 | 0 | [0,...] | 从处理管道中移除之前的最大重试次数。 |
|
||||||
| retry_delay | integer | 可选 | 1 | [0,...] | 如果执行失败,则应延迟执行流程的秒数 |
|
| retry_delay | integer | 可选 | 1 | [0,...] | 如果执行失败,则应延迟执行流程的秒数。 |
|
||||||
| include_req_body | boolean | 可选 | | | 是否包括请求 body |
|
| include_req_body | boolean | 可选 | false | [false, true] | 是否包括请求 body。false: 表示不包含请求的 body ; true: 表示包含请求的 body 。|
|
||||||
|
|
||||||
### meta_format 参考示例
|
### meta_format 参考示例
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user