You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@apisix.apache.org by GitBox <gi...@apache.org> on 2022/06/16 12:48:16 UTC
[GitHub] [apisix] mikawudi opened a new issue, #7267: feat: some question about kafka-logger
mikawudi opened a new issue, #7267:
URL: https://github.com/apache/apisix/issues/7267
### Description
about kafka-logger plugin
1) in kafka, “key” will decide message route to what partition
but in kafka-logger plugin, key params only is a const str......
i think if key param can support exp for get value from variable, it will be more useful!
2) the second question is about message format of kafka-logger
when i use batch_max_size = 1, the message send to kafka is a json object
but when batch_max_size > 1, the message is a json array
```lua
if batch_max_size == 1 then
data = entries[1]
if type(data) ~= "string" then
data, err = core.json.encode(data) -- encode as single {}
end
else
data, err = core.json.encode(entries) -- encode as array [{}]
end
```
as a kafka consumer.....befor i parse message and consume it, i need know apisix how to config batch_max_size? i think it not unreasonable
3) lua-resty-kafka have ringbuffer and sendbuffer....in kafka-logger plugin i think the “batch_max_size > 1” is not need to exist?
--
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: notifications-unsubscribe@apisix.apache.org.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [apisix] mikawudi closed issue #7267: feat: some question about kafka-logger
Posted by GitBox <gi...@apache.org>.
mikawudi closed issue #7267: feat: some question about kafka-logger
URL: https://github.com/apache/apisix/issues/7267
--
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: notifications-unsubscribe@apisix.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [apisix] mikawudi commented on issue #7267: feat: some question about kafka-logger
Posted by GitBox <gi...@apache.org>.
mikawudi commented on issue #7267:
URL: https://github.com/apache/apisix/issues/7267#issuecomment-1159507804
ok, will try to impl first item~
--
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: notifications-unsubscribe@apisix.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [apisix] spacewander commented on issue #7267: feat: some question about kafka-logger
Posted by GitBox <gi...@apache.org>.
spacewander commented on issue #7267:
URL: https://github.com/apache/apisix/issues/7267#issuecomment-1158561084
> in kafka, “key” will decide message route to what partition
but in kafka-logger plugin, key params only is a const str......
i think if key param can support exp for get value from variable, it will be more useful!
PR is welcome!
> the second question is about message format of kafka-logger
It is a historical legacy.
> lua-resty-kafka have ringbuffer and sendbuffer....in kafka-logger plugin i think the “batch_max_size > 1” is not need to exist?
They are buffers in different places.
--
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: notifications-unsubscribe@apisix.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org