I have two related topics, a and b, and want to listen to them, but
commit the appropriate offset in each only when I've processed a pair
of corresponding messages from each. I see that the commit() method (I
use the Python API, FWIW) takes an optional dict, but it's not clear
to this simple guy exactly what {TopicPartition: OffsetAndMetadata}
means. If I am subscibed to two topics, A and B with group_id G, and
want to commit offsets a1 and b5, Is that dictionary defined as

{
    "A": a1,
    "B": b5,
}

or something more complex? (I've clearly not mentioned a partition.)

Thanks,

Skip Montanaro

Reply via email to