set LOCK_AWARE on several transactions used for getting cluster info for the consistency check

This commit is contained in:
John King 2017-07-28 18:50:32 -07:00
parent 4243486f54
commit d0fbc41338
2 changed files with 4 additions and 0 deletions

View File

@ -139,6 +139,7 @@ ACTOR Future<vector<StorageServerInterface>> getStorageServers( Database cx, boo
state Transaction tr( cx );
if (use_system_priority)
tr.setOption(FDBTransactionOptions::PRIORITY_SYSTEM_IMMEDIATE);
tr.setOption(FDBTransactionOptions::LOCK_AWARE);
loop {
try {
Standalone<RangeResultRef> serverList = wait( tr.getRange( serverListKeys, CLIENT_KNOBS->TOO_MANY ) );

View File

@ -171,6 +171,7 @@ struct ConsistencyCheckWorkload : TestWorkload
state DatabaseConfiguration configuration;
state Transaction tr(cx);
tr.setOption(FDBTransactionOptions::LOCK_AWARE);
loop {
try {
Standalone<RangeResultRef> res = wait( tr.getRange(configKeys, 1000) );
@ -285,6 +286,7 @@ struct ConsistencyCheckWorkload : TestWorkload
loop
{
state Transaction tr(cx);
tr.setOption(FDBTransactionOptions::LOCK_AWARE);
try
{
Version version = wait(tr.getReadVersion());
@ -532,6 +534,7 @@ struct ConsistencyCheckWorkload : TestWorkload
ACTOR Future<int64_t> getDatabaseSize(Database cx) {
state Transaction tr( cx );
tr.setOption(FDBTransactionOptions::LOCK_AWARE);
loop {
try {
StorageMetrics metrics = wait( tr.getStorageMetrics( KeyRangeRef(allKeys.begin, keyServersPrefix), 100000 ) );