Baoyuantop commented on code in PR #13040:
URL: https://github.com/apache/apisix/pull/13040#discussion_r2866846717
##########
apisix/plugins/kafka-logger.lua:
##########
@@ -294,7 +294,9 @@ function _M.log(conf, ctx)
broker_config["request_timeout"] = conf.timeout * 1000
broker_config["producer_type"] = conf.producer_type
broker_config["required_acks"] = conf.required_acks
- broker_config["api_version"] = conf.api_version or 2
+ if conf.api_version ~= nil then
+ broker_config["api_version"] = conf.api_version
+ end
Review Comment:
No extra checks are needed; the schema already guarantees that the data here
meets the requirements.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]