sanpwc commented on code in PR #6954:
URL: https://github.com/apache/ignite-3/pull/6954#discussion_r2518793496


##########
modules/metastorage/src/main/java/org/apache/ignite/internal/metastorage/server/raft/MetaStorageWriteHandler.java:
##########
@@ -380,20 +380,20 @@ private static RevisionCondition.Type 
toRevisionConditionType(ConditionType type
         }
     }
 
-    boolean beforeApply(Command command) {
+    Command beforeApply(Command command) {
         if (command instanceof MetaStorageWriteCommand) {
             // Initiator sends us a timestamp to adjust to.
             // Alter command by setting safe time based on the adjusted clock.
-            MetaStorageWriteCommand writeCommand = (MetaStorageWriteCommand) 
command;
+            MetaStorageWriteCommand writeCommand = (MetaStorageWriteCommand) 
command.clone();

Review Comment:
   Could you please add a comment explaining why we need clone() here?



-- 
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]

Reply via email to