belliottsmith commented on code in PR #50:
URL: https://github.com/apache/cassandra-accord/pull/50#discussion_r1261736109
##########
accord-core/src/main/java/accord/local/Commands.java:
##########
@@ -869,11 +913,45 @@ public NotifyWaitingOn(SafeCommand root)
@Override
public void accept(SafeCommandStore safeStore)
{
- SafeCommand prevSafe = get(safeStore, depth - 1);
+ SafeCommand prevSafe = ifInitialised(safeStore, depth - 1);
+ {
+ // we know we loaded it, so if it's null it's either truncated
or we haven't witnessed it and need to initialise;
+ // in this case use our predecessor's intersecting keys to
decide which
+ SafeCommand curSafe = ifInitialised(safeStore, depth);
+ if (curSafe == null)
+ {
+ if (prevSafe != null)
+ {
+ if
(safeStore.commandStore().redundantBefore().isRedundant(txnIds[depth],
prevSafe.current().executeAt(),
prevSafe.current().partialDeps().participants(txnIds[depth])))
Review Comment:
I think again you have it the wrong way around - cur is the dependency of
prev, so prev must be committed and have deps (by which we were found)
--
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]