Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Timestamps are not added when producing #95

Closed
fuyar opened this issue Dec 5, 2018 · 3 comments
Closed

Timestamps are not added when producing #95

fuyar opened this issue Dec 5, 2018 · 3 comments

Comments

@fuyar
Copy link

fuyar commented Dec 5, 2018

Hello,

When producing with kt, record timestamps (available since Kafka 0.10) are not specified.
Here's an example with what kafkacat is producing.

{"partition": 0,"offset": 0, "timestamp": -1, "key": test, "value": NULL}

echo 'test:' | kafkacat -P -b dbpoc-03 -t test_timestamp -K: -Z -p -1
{"partition": 4,"offset": 0, "timestamp": 1544028030676, "key": test, "value": NULL}

Also kt is not using the default partitioner (the one from Kafka) ?

@fgeller
Copy link
Owner

fgeller commented Dec 30, 2018

will try to get around to that in the coming days, thanks for reporting!

re partitioner: yep, last i checked there was no go implementation of the partitioner, maybe that has changed? the produce command allows you to use a hashCode partitioner which was the "old" way of partitioning (forgot the kafka version when it changed).

fgeller added a commit that referenced this issue Dec 30, 2018
if version allows for it, i.e. >V10
@fgeller
Copy link
Owner

fgeller commented Dec 30, 2018

hey @fuyar got around to adding the timestamp bit today - let me know if you run into any issues - and added a new issue to check again on a default partitioner implementation in go.

closing this optimistically, feel free to re-open!

@fgeller fgeller closed this as completed Dec 30, 2018
@fuyar
Copy link
Author

fuyar commented Jan 11, 2019

Just a heads-up : timestamp is now correctly filled upon producing !

Thanks @fgeller ;)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants