harlow / kinesis-consumer

Golang library for consuming Kinesis stream data
MIT License
263 stars 88 forks source link

Include ShardID in Record passed to ScanFunc #121

Closed jtackaberry closed 4 years ago

jtackaberry commented 4 years ago

Implements #120

Is backward compatible with existing code. Everything under cmd/ continues to build and function. ScanFunc can now reference a ShardID field on the Record passed to the callback, which can be used to e.g. enable users of the library to implement custom checkpointing.

jtackaberry commented 4 years ago

Investigating CI failure. Looks like one of the mocks needs a slight tweak.

harlow commented 4 years ago

Thanks for the PR @jtackaberry I think this feels like clean solution to your problem 👍

jtackaberry commented 4 years ago

Yeah, it works well, with minimal fuss, and no backward incompatibility. Win win. :)

I also just noticed #104 which was abandoned for reasons unknown, but at least it's a sign that I'm not the only one who's run up against this.

jtackaberry commented 4 years ago

Appreciate the speedy turnaround, Harlow.