Skip to content

Commit

Permalink
Changed the sequence of commit&reset before consuming againq
Browse files Browse the repository at this point in the history
Signed-off-by: Krishna Kondaka <[email protected]>
  • Loading branch information
Krishna Kondaka committed Aug 21, 2023
1 parent 784a9d5 commit 251dfd1
Showing 1 changed file with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -287,12 +287,12 @@ public void run() {
Thread.sleep(10000);
}
synchronized(this) {
commitOffsets();
resetOffsets();
if (currentEpoch != newEpoch) {
partitionCommitTrackerMap.clear();
currentEpoch = newEpoch;
}
resetOffsets();
commitOffsets();
currentEpoch = newEpoch;
}
consumeRecords();
topicMetrics.update(consumer);
Expand Down

0 comments on commit 251dfd1

Please sign in to comment.