chirag-wadhwa5 commented on code in PR #17573:
URL: https://github.com/apache/kafka/pull/17573#discussion_r1814707696
##########
core/src/main/java/kafka/server/share/SharePartition.java:
##########
@@ -382,7 +387,35 @@ public CompletableFuture<Void> maybeInitialize() {
}
// Set the state epoch and end offset from the persisted state.
- startOffset = partitionData.startOffset() != -1 ?
partitionData.startOffset() : 0;
+ if (partitionData.startOffset() !=
PartitionFactory.DEFAULT_START_OFFSET) {
Review Comment:
Thanks for the review. Actually I have changed
PartitionFactory.DEFAULT_START_OFFSET to -1. So now the default value sent by
NoOpPersister and the DefaultStatePersister (in case data is not present for
this groupId and sharePartition) is -1, distinguishing it from 0, which is
possible in some cases.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]