This commit is contained in:
Xiaoxi Wang 2022-07-08 16:34:55 -07:00
parent b48b1e93f9
commit 9fe76ecf21
2 changed files with 3 additions and 2 deletions

View File

@ -105,5 +105,5 @@ Future<MoveKeysLock> DDTxnProcessor::takeMoveKeysLock(UID ddId) const {
}
Future<DatabaseConfiguration> DDTxnProcessor::getDatabaseConfiguration() const {
return ::getDatabaseConfiguration(cx);
return ::getDatabaseConfiguration(cx);
}

View File

@ -649,7 +649,8 @@ ACTOR Future<Void> dataDistribution(Reference<DataDistributor> self,
auto dcId = decodeDatacenterReplicasKey(kv.key);
auto replicas = decodeDatacenterReplicasValue(kv.value);
if ((self->primaryDcId.size() && self->primaryDcId[0] == dcId) ||
(self->remoteDcIds.size() && self->remoteDcIds[0] == dcId && self->configuration.usableRegions > 1)) {
(self->remoteDcIds.size() && self->remoteDcIds[0] == dcId &&
self->configuration.usableRegions > 1)) {
if (replicas > self->configuration.storageTeamSize) {
tr.set(kv.key, datacenterReplicasValue(self->configuration.storageTeamSize));
}