Exclude MergeInProgress status from errors in stress tests (#6257)

Summary:
When called on transactions, MultiGet could return a legit MergeInProgress status. The patch excludes this case from errors.
Pull Request resolved: https://github.com/facebook/rocksdb/pull/6257

Differential Revision: D19275787

Pulled By: maysamyabandeh

fbshipit-source-id: f7158229422af015947e592ae066b4273c9fb9a4
This commit is contained in:
Maysam Yabandeh 2020-01-03 13:05:21 -08:00 committed by Facebook Github Bot
parent 7c98d71567
commit 83957dc510

View File

@ -242,6 +242,9 @@ class NonBatchedOpsStressTest : public StressTest {
} else if (s.IsNotFound()) {
// not found case
thread->stats.AddGets(1, 0);
} else if (s.IsMergeInProgress() && use_txn) {
// With txn this is sometimes expected.
thread->stats.AddGets(1, 1);
} else {
// errors case
fprintf(stderr, "MultiGet error: %s\n", s.ToString().c_str());