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

Update Python docs to with correct timestamp granularity #384

Closed
7 tasks
rnpridgeon opened this issue May 24, 2018 · 3 comments
Closed
7 tasks

Update Python docs to with correct timestamp granularity #384

rnpridgeon opened this issue May 24, 2018 · 3 comments
Assignees
Labels

Comments

@rnpridgeon
Copy link
Contributor

Description

Python documentation incorrectly states that the timestamp field should use microseconds. If we take a look at rdkafka.h however we can see that the expected unit is actually Milliseconds

Python Docs
https://docs.confluent.io/current/clients/confluent-kafka-python/#confluent_kafka.Producer.produce

rdkafka.h
https://github.com/edenhill/librdkafka/blob/13befa7053c43593fd6f2effdffbd83c3ea52eb7/src/rdkafka.h#L804

This will ultimately cause issues from Kafka as the broker will actually record this timestamp which will break things

https://issues.apache.org/jira/browse/KAFKA-6939

How to reproduce

produce a message with a timestamp with microsecond granularity.

Checklist

Please provide the following information:

  • confluent-kafka-python and librdkafka version (confluent_kafka.version() and confluent_kafka.libversion()):
  • Apache Kafka broker version:
  • Client configuration: {...}
  • Operating system:
  • Provide client logs (with 'debug': '..' as necessary)
  • Provide broker log excerpts
  • Critical issue
@johnistan
Copy link
Contributor

Let me tell you pain this can cause!!!!

@edenhill
Copy link
Contributor

@johnistan Sorry about that :( such a small but important mistake

@qiao-meng-zefr
Copy link

qiao-meng-zefr commented May 25, 2018

Great find. We've had issues with this too. It's better to just leave it out for default after all..

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

No branches or pull requests

4 participants