-
Notifications
You must be signed in to change notification settings - Fork 335
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[Issue 183] [Feat] Support cumulative acknowledge (#903)
Master Issue: #183 ### Motivation Cumulative acknowledgement is a useful feature. Users can use this feature to ack messages in the stream up to (and including) provided message. Issue #183 shows more details. ### Modifications - Add two api `AckCumulative` and `AckIDCumulative` for `Consumer`. ``` golang // AckCumulative the reception of all the messages in the stream up to (and including) // the provided message. AckCumulative(msg Message) error // AckIDCumulative the reception of all the messages in the stream up to (and including) // the provided message, identified by its MessageID AckIDCumulative(msgID MessageID) error ``` - Add the `AckCumulative` and `AckIDCumulative` implementation for `consumer`, `multiTopicConsumer`, `regexConsumer` and `mockConsumer`. - Add the unit test `TestConsumerNoBatchCumulativeAck` `TestConsumerBatchCumulativeAck` `TestCumulativeAckWithResponse` for cumulative ack in `consumer_test.go`.
- Loading branch information
1 parent
cb983a7
commit 2377736
Showing
9 changed files
with
449 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.