mumrah commented on code in PR #18684: URL: https://github.com/apache/kafka/pull/18684#discussion_r1979666856
########## server-common/src/main/java/org/apache/kafka/timeline/Snapshot.java: ########## @@ -47,6 +48,7 @@ <T extends Delta> T getDelta(Revertable owner) { } void setDelta(Revertable owner, Delta delta) { + Objects.requireNonNull(map, "Snapshot cannot be modified after erase is called."); Review Comment: Nice! Now we may as well add this check for other methods which access `map`. Also, how about > Snapshot cannot be accessed after erase is called -- 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