ifesdjeen commented on code in PR #121:
URL: https://github.com/apache/cassandra-accord/pull/121#discussion_r1764646286


##########
accord-core/src/main/java/accord/local/cfk/SafeCommandsForKey.java:
##########
@@ -55,12 +55,13 @@ void updatePruned(SafeCommandStore safeStore, Command 
nextCommand, NotifySink no
     public void update(SafeCommandStore safeStore, Command nextCommand)
     {
         CommandsForKey prevCfk = current();
-        update(safeStore, nextCommand, prevCfk, prevCfk.update(nextCommand));
+        CommandsForKeyUpdate cfkUpdate = prevCfk.update(nextCommand);
+        update(safeStore, nextCommand, prevCfk, cfkUpdate);
     }
 
     private void update(SafeCommandStore safeStore, @Nullable Command command, 
CommandsForKey prevCfk, CommandsForKeyUpdate updateCfk)
     {
-        update(safeStore, command, prevCfk, updateCfk, 
NotifySink.DefaultNotifySink.INSTANCE);
+        update(safeStore, command, prevCfk, updateCfk, safeStore.replay() ? 
NotifySink.NoOpSink.INSTANCE : NotifySink.DefaultNotifySink.INSTANCE);

Review Comment:
   Made it that we do submit notifications for now. The problem was that 
notifications were causing submission of new tasks, which was leading to some 
exceptions. Should be clean by now thanks to your patches.



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


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to