junrao commented on code in PR #16842:
URL: https://github.com/apache/kafka/pull/16842#discussion_r1725477414
##########
core/src/main/java/kafka/server/share/SharePartition.java:
##########
@@ -228,6 +240,11 @@ public static RecordState forId(byte id) {
*/
private int stateEpoch;
+ /**
+ * The leader epoch is used to track the partition epoch.
+ */
+ private int leaderEpoch;
Review Comment:
Should this be volatile since it's written and read by different threads?
--
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]