From ec0e39b40fff961b02dab969e93fc4773074a140 Mon Sep 17 00:00:00 2001 From: Steve Atherton Date: Tue, 24 Aug 2021 15:16:20 -0700 Subject: [PATCH] Bug fix: Popped versions are exclusive, so after recovery a tag for which there is no longer data should be considered popped up until the version *after* recovery, indicating that data at the recovery version itself has been popped. --- fdbserver/OldTLogServer_6_0.actor.cpp | 2 +- fdbserver/OldTLogServer_6_2.actor.cpp | 2 +- fdbserver/TLogServer.actor.cpp | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/fdbserver/OldTLogServer_6_0.actor.cpp b/fdbserver/OldTLogServer_6_0.actor.cpp index 192eaaaf29..9a5934b205 100644 --- a/fdbserver/OldTLogServer_6_0.actor.cpp +++ b/fdbserver/OldTLogServer_6_0.actor.cpp @@ -1157,7 +1157,7 @@ Version poppedVersion(Reference self, Tag tag) { if (tag == txsTag || tag.locality == tagLocalityTxs) { return 0; } - return self->recoveredAt; + return self->recoveredAt + 1; } return tagData->popped; } diff --git a/fdbserver/OldTLogServer_6_2.actor.cpp b/fdbserver/OldTLogServer_6_2.actor.cpp index 0fcf76d5a3..0a11df9e99 100644 --- a/fdbserver/OldTLogServer_6_2.actor.cpp +++ b/fdbserver/OldTLogServer_6_2.actor.cpp @@ -1376,7 +1376,7 @@ Version poppedVersion(Reference self, Tag tag) { if (tag == txsTag || tag.locality == tagLocalityTxs) { return 0; } - return self->recoveredAt; + return self->recoveredAt + 1; } return tagData->popped; } diff --git a/fdbserver/TLogServer.actor.cpp b/fdbserver/TLogServer.actor.cpp index df0c3a07d3..a88595e974 100644 --- a/fdbserver/TLogServer.actor.cpp +++ b/fdbserver/TLogServer.actor.cpp @@ -1503,7 +1503,7 @@ Version poppedVersion(Reference self, Tag tag) { if (tag == txsTag || tag.locality == tagLocalityTxs) { return 0; } - return self->recoveredAt; + return self->recoveredAt + 1; } return tagData->popped; }