kcat
kcat copied to clipboard
MAC Version : Producer with delimiter problems
Hi, with the new version 1.7.0 I have problems when I try to produce messages, apparently the problem is because the kcat version does not recognize
Please provide your full command line.
Hi , I used : kcat -F ./kafkacat.conf -P -t mytopic kcat -F ./kafkacat.conf -P -t mytopic -D #
But messages only was dispach when I use Control+D
You probably need to escape the #
, otherwise the shell will remove it as it is the shell comment token.
Try kcat ... -D '#'
mmm ... I continue with the same problem, the messages are only sent if I press Control + D, but I can't identify if it is a version problem or something in my encoding ... but the sure thing is that with the previous version of kafkacat I had no problems ... for some reason the new version cannot identify any delimiter ... nor newline ... nor any that is entered with the -D option
I believe the problem is that your terminal buffers its output (waiting for newline).
You can verify this by trying something like:
echo 'a#b#c#d#' | kcat -F kafkacat.conf -P -t mytopic -D '#'
Hi, you're right ... for some reason my terminal doesn't send a new line ... but I still don't know why ... Thanks a lot ...
Hello :)
I have the same issue on Mac as @jcmonsalve2021.
If I give to the kcat command a file, it does not recognise any delimiter. The work-around used was to echo the content of the file similarly to @edenhill's command echo 'a#b#c#d#' | kcat -F kafkacat.conf -P -t mytopic -D '#'
but this is a bit troublesome. Previous version of kcat did not have this issue.
@jcmonsalve2021 if you are trying to send message from a file with a delimiter embedded in the file, you need to use the -l
option:
-l Send messages from a file separated by
delimiter, as with stdin.
(only one file allowed)
Having the same issue. Why has this not been addressed? Previous Version didn't have this Problem.
@DanielBo Please be more specific. Provide command lines, input data, expected behaviour, actual behaviour.
I do: kcat -b localhost:9092 -t chat -P
write test into the command line and hit enter. Consumer wont show the message until i hit ctrl+d
Running on an apple silicon mac, using iterm2 and zsh.
Just press enter a couple of times
I found the issue, fix is coming up
Just press enter a couple of times
I also have the same problem and I tried out this workaround but after pressing enter for 600 times I gave up.
You actually need to press enter 1024 times 😄 .. that's the size of the input buffer... Seriously though, soon fixed.
Two thousand years later 👀
@edenhill Facing this issue on Mac, I see this issue is fixed but still not released.
@edenhill When do you plan to release the fixed version?