Permalink
Browse files

Reset ReplyStore on submit, not on message delivery (reception)

  • Loading branch information...
1 parent 32de19c commit b4685bc399316271bd8fc658ddfff26ea90fe291 @dgomezferro dgomezferro committed Sep 28, 2012
View
1 src/main/java/com/yahoo/pasc/paxos/client/handlers/ReplyHandler.java
@@ -53,7 +53,6 @@ public boolean guardPredicate(Reply receivedMessage) {
byte[] value = store.getStableReply(quorum);
if (value != null) {
descriptors = Arrays.asList(new Received.Descriptor(value));
- state.setReplyStore(new ReplyStore(state.getServers()));
}
}
return descriptors;
View
2 src/main/java/com/yahoo/pasc/paxos/client/handlers/SubmitHandler.java
@@ -22,6 +22,7 @@
import com.yahoo.pasc.Message;
import com.yahoo.pasc.MessageHandler;
import com.yahoo.pasc.paxos.client.ClientState;
+import com.yahoo.pasc.paxos.client.ReplyStore;
import com.yahoo.pasc.paxos.client.messages.Submit;
import com.yahoo.pasc.paxos.messages.InlineRequest;
import com.yahoo.pasc.paxos.messages.Request;
@@ -45,6 +46,7 @@ public boolean guardPredicate(Submit receivedMessage) {
}
state.setPendingRequest(request);
state.setTimestamp(timestamp);
+ state.setReplyStore(new ReplyStore(state.getServers()));
return Arrays.asList(request);
}

0 comments on commit b4685bc

Please sign in to comment.