Using kafka-python-1.0.2.
If I have a topic with 10 sections, how can I commit a specific section by going through the various sections and messages. I just can't find an example of this anywhere, in docs or otherwise
In the docs I want to use:
consumer.commit(offset=offsets)
In particular, how do I create the OffsetAndMetadata dictionary and dictionary needed for the offset (dict, optional) - {TopicPartition: OffsetAndMetadata}.
I was hoping the function call would look something like this:
consumer.commit(partition, offset)
but this does not seem to be the case.
Thanks in advance.
source
share