Elia-Renzoni commented on PR #1612: URL: https://github.com/apache/ratis/pull/1612#issuecomment-6982933641
> @Elia-Renzoni , thanks for the update! The change looks good. > > See the minor comments below from Claude: > > 1. Order in updateSnapshotIndex: update commitIndex before snapshotIndex. Without the lock, a reader can briefly see snapshotIndex > commitIndex with the current order. Updating commit first keeps commit >= snapshot true for every reader. > 2. Dead code: tryWriteLock(TimeDuration) (RaftLogBase.java:362) has no callers now. Remove it, or keep it if external subclasses might use it. It's public, but it isn't declared in the RaftLog interface. > 3. Trace log text changes from "updateIncreasingly" to "updateToMax old=.., new=.., updated? true". That's fine, but the "updated? " part is redundant because the message only prints when updated is true (RaftLogIndex.java:79). This is optional cleanup in [ratis-server-api](https://issues.apache.org/jira/browse/RATIS-server-api). I've addressed the suggested cleanups here: 5aac2040a1cfba6b5bacd8dca84ed28462d8fb89 -- 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]
