smjn commented on code in PR #19443: URL: https://github.com/apache/kafka/pull/19443#discussion_r2041964318
########## share-coordinator/src/main/java/org/apache/kafka/coordinator/share/ShareGroupOffset.java: ########## @@ -245,4 +246,15 @@ public String toString() { ", stateBatches=" + stateBatches + '}'; } + + public Builder builderSupplier() { + return new Builder() + .setSnapshotEpoch(snapshotEpoch) + .setStateEpoch(stateEpoch) + .setLeaderEpoch(leaderEpoch) + .setStartOffset(startOffset) + .setStateBatches(new ArrayList<>(stateBatches)) Review Comment: Otherwise they will point to the same internal state batches list. But I understand what you mean. -- 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: jira-unsubscr...@kafka.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org