vldpyatkov commented on code in PR #1551: URL: https://github.com/apache/ignite-3/pull/1551#discussion_r1084200437
########## modules/table/src/main/java/org/apache/ignite/internal/table/distributed/replicator/PartitionReplicaListener.java: ########## @@ -1388,6 +1418,62 @@ private CompletableFuture<Object> applyCmdWithExceptionHandling(Command cmd) { }); } + /** + * Executes an Update command. + * + * @param cmd Update command. + * @return Raft future, see {@link #applyCmdWithExceptionHandling(Command)}. + */ + private CompletableFuture<Object> applyUpdateCommand(UpdateCommand cmd) { Review Comment: Honestly, I do not see a sense to divide applyCmdWithExceptionHandling and updateCommand in two difference method, because they always execute both. In your case. I would merge applyUpdateCommand and updateCommand. ########## modules/table/src/main/java/org/apache/ignite/internal/table/distributed/replicator/PartitionReplicaListener.java: ########## @@ -1388,6 +1418,62 @@ private CompletableFuture<Object> applyCmdWithExceptionHandling(Command cmd) { }); } + /** + * Executes an Update command. + * + * @param cmd Update command. + * @return Raft future, see {@link #applyCmdWithExceptionHandling(Command)}. + */ + private CompletableFuture<Object> applyUpdateCommand(UpdateCommand cmd) { + return applyUpdatingCommand(cmd.txId(), () -> { + storageUpdateHandler.handleUpdate( + cmd.txId(), + cmd.rowUuid(), + cmd.tablePartitionId().asTablePartitionId(), + cmd.rowBuffer(), + null + ); + + return applyCmdWithExceptionHandling(cmd); + }); + } + + /** + * Executes an UpdateAll command. + * + * @param cmd UpdateAll command. + * @return Raft future, see {@link #applyCmdWithExceptionHandling(Command)}. + */ + private CompletableFuture<Object> applyUpdateAllCommand(UpdateAllCommand cmd) { Review Comment: The same as before, I wouldn't divide applyUpdateAllCommand and updateAllCommand. -- 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: notifications-unsubscr...@ignite.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org