{"push_id":740613266,"size":2,"distinct_size":2,"ref":"refs/heads/feature/test_reset_offsets","head":"cbdbfa32dc0ea0f3a0c79c7f90e582134acba431","before":"17d4aa633731394c55018dc2a1e05959429c80c0","commits":[{"sha":"5892104ef4da33c8176d451db21f06d4219aa7fa","author":{"email":"e4c1ab9da74060df152545062ee274845648ed6c@yungchin.nl","name":"Yung-Chin Oei"},"message":"simpleconsumer: sync semaphore when flushing queue\n\nThis deals with a problem where a manual reset_offsets() (which flushes\nthe queues of the affected partitions) followed by a consume() would get\nstuck in an infinite loop: the semaphore didn't get decremented during\nthe flush(), and so the consume() keeps cycling partitions trying to\nfind messages it thinks are there.\n\nThe fix seems kind of inefficient, but I hope that's ok because flush()\nshouldn't ever be part of a performance-critical operation.\n\nThe accompanying test update is how I hit the problem.\n\nSigned-off-by: Yung-Chin Oei <yungchin@yungchin.nl>","distinct":true,"url":"https://api.github.com/repos/Parsely/pykafka/commits/5892104ef4da33c8176d451db21f06d4219aa7fa"},{"sha":"cbdbfa32dc0ea0f3a0c79c7f90e582134acba431","author":{"email":"e4c1ab9da74060df152545062ee274845648ed6c@yungchin.nl","name":"Yung-Chin Oei"},"message":"test_simpleconsumer: relax reset_offsets requirements\n\nIt turned out the \"set an invalid offset\" part of the last test was\nasking a bit more than RdKafkaSimpleConsumer (see #176) can deliver: it\nexpected invalid offsets to be reset almost immediately, whereas this\nreset, if it happens internally to the rdkafka consumer, only gets\nvisible to us after we consume() a message.\n\nI think that's ok, for the uses where we do this at all: if we passed an\ninvalid offset to reset_offsets(), that means we have some external\noffset store that held an invalid offset anyway, so the fact that\nself.held_offsets may keep reporting that invalid offset back to us\nfor a bit longer (ie until a message is consumed) doesn't make matters\nworse.\n\nSigned-off-by: Yung-Chin Oei <yungchin@yungchin.nl>","distinct":true,"url":"https://api.github.com/repos/Parsely/pykafka/commits/cbdbfa32dc0ea0f3a0c79c7f90e582134acba431"}]}