commit
f4bcfcd53c
|
@ -668,6 +668,7 @@ ACTOR Future<MonitorLeaderInfo> monitorProxiesOneGeneration( Reference<ClusterCo
|
|||
state int successIdx = 0;
|
||||
state Optional<double> incorrectTime;
|
||||
state std::vector<UID> lastProxyUIDs;
|
||||
state std::vector<MasterProxyInterface> lastProxies;
|
||||
|
||||
deterministicRandom()->randomShuffle(addrs);
|
||||
loop {
|
||||
|
@ -726,12 +727,14 @@ ACTOR Future<MonitorLeaderInfo> monitorProxiesOneGeneration( Reference<ClusterCo
|
|||
}
|
||||
if(proxyUIDs != lastProxyUIDs) {
|
||||
lastProxyUIDs = proxyUIDs;
|
||||
deterministicRandom()->randomShuffle(ni.proxies);
|
||||
ni.proxies.resize(CLIENT_KNOBS->MAX_CLIENT_PROXY_CONNECTIONS);
|
||||
for(int i = 0; i < ni.proxies.size(); i++) {
|
||||
TraceEvent("ClientConnectedProxy").detail("Proxy", ni.proxies[i].id());
|
||||
lastProxies = ni.proxies;
|
||||
deterministicRandom()->randomShuffle(lastProxies);
|
||||
lastProxies.resize(CLIENT_KNOBS->MAX_CLIENT_PROXY_CONNECTIONS);
|
||||
for(int i = 0; i < lastProxies.size(); i++) {
|
||||
TraceEvent("ClientConnectedProxy").detail("Proxy", lastProxies[i].id());
|
||||
}
|
||||
}
|
||||
ni.proxies = lastProxies;
|
||||
}
|
||||
|
||||
clientInfo->set( rep.get() );
|
||||
|
|
|
@ -940,6 +940,7 @@ struct DDTeamCollection : ReferenceCounted<DDTeamCollection> {
|
|||
for(auto& it : self->resultEntries) {
|
||||
serverIds.push_back(*tempMap->getObject(it));
|
||||
}
|
||||
std::sort(serverIds.begin(), serverIds.end());
|
||||
self->addTeam(serverIds.begin(), serverIds.end(), true);
|
||||
}
|
||||
} else {
|
||||
|
|
|
@ -171,7 +171,7 @@ ServerKnobs::ServerKnobs(bool randomize, ClientKnobs* clientKnobs) {
|
|||
init( FREE_SPACE_RATIO_CUTOFF, 0.1 );
|
||||
init( FREE_SPACE_RATIO_DD_CUTOFF, 0.2 );
|
||||
init( DESIRED_TEAMS_PER_SERVER, 5 ); if( randomize && BUGGIFY ) DESIRED_TEAMS_PER_SERVER = 1;
|
||||
init( MAX_TEAMS_PER_SERVER, 3*DESIRED_TEAMS_PER_SERVER );
|
||||
init( MAX_TEAMS_PER_SERVER, 5*DESIRED_TEAMS_PER_SERVER );
|
||||
init( DD_SHARD_SIZE_GRANULARITY, 5000000 );
|
||||
init( DD_SHARD_SIZE_GRANULARITY_SIM, 500000 ); if( randomize && BUGGIFY ) DD_SHARD_SIZE_GRANULARITY_SIM = 0;
|
||||
init( DD_MOVE_KEYS_PARALLELISM, 20 ); if( randomize && BUGGIFY ) DD_MOVE_KEYS_PARALLELISM = 1;
|
||||
|
|
|
@ -402,7 +402,7 @@ struct LogData : NonCopyable, public ReferenceCounted<LogData> {
|
|||
|
||||
//only callable after getTagData returns a null reference
|
||||
Reference<TagData> createTagData(Tag tag, Version popped, bool nothingPersistent, bool poppedRecently, bool unpoppedRecovered) {
|
||||
if(tag.locality != tagLocalityLogRouter && tag.locality != tagLocalityTxs && tag != txsTag && allTags.size() && !allTags.count(tag) && popped <= recoveredAt) {
|
||||
if(tag.locality != tagLocalityLogRouter && allTags.size() && !allTags.count(tag) && popped <= recoveredAt) {
|
||||
popped = recoveredAt + 1;
|
||||
}
|
||||
Reference<TagData> newTagData = Reference<TagData>( new TagData(tag, popped, nothingPersistent, poppedRecently, unpoppedRecovered) );
|
||||
|
@ -909,9 +909,6 @@ void commitMessages( TLogData *self, Reference<LogData> logData, Version version
|
|||
Version poppedVersion( Reference<LogData> self, Tag tag) {
|
||||
auto tagData = self->getTagData(tag);
|
||||
if (!tagData) {
|
||||
if (tag == txsTag || tag.locality == tagLocalityTxs) {
|
||||
return 0;
|
||||
}
|
||||
return self->recoveredAt;
|
||||
}
|
||||
return tagData->popped;
|
||||
|
|
|
@ -452,7 +452,7 @@ struct LogData : NonCopyable, public ReferenceCounted<LogData> {
|
|||
|
||||
//only callable after getTagData returns a null reference
|
||||
Reference<TagData> createTagData(Tag tag, Version popped, bool nothingPersistent, bool poppedRecently, bool unpoppedRecovered) {
|
||||
if(tag.locality != tagLocalityLogRouter && tag.locality != tagLocalityTxs && tag != txsTag && allTags.size() && !allTags.count(tag) && popped <= recoveredAt) {
|
||||
if(tag.locality != tagLocalityLogRouter && allTags.size() && !allTags.count(tag) && popped <= recoveredAt) {
|
||||
popped = recoveredAt + 1;
|
||||
}
|
||||
Reference<TagData> newTagData = Reference<TagData>( new TagData(tag, popped, 0, nothingPersistent, poppedRecently, unpoppedRecovered) );
|
||||
|
@ -1159,9 +1159,6 @@ void commitMessages( TLogData *self, Reference<LogData> logData, Version version
|
|||
Version poppedVersion( Reference<LogData> self, Tag tag) {
|
||||
auto tagData = self->getTagData(tag);
|
||||
if (!tagData) {
|
||||
if (tag == txsTag || tag.locality == tagLocalityTxs) {
|
||||
return 0;
|
||||
}
|
||||
return self->recoveredAt;
|
||||
}
|
||||
return tagData->popped;
|
||||
|
|
|
@ -1868,12 +1868,15 @@ struct TagPartitionedLogSystem : ILogSystem, ReferenceCounted<TagPartitionedLogS
|
|||
for(int loc : locations)
|
||||
remoteTLogReqs[ loc ].recoverTags.push_back( tag );
|
||||
}
|
||||
if(nonShardedTxs) {
|
||||
localTags.push_back(txsTag);
|
||||
} else {
|
||||
for(int i = 0; i < self->txsTags; i++) {
|
||||
localTags.push_back(Tag(tagLocalityTxs, i));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if(oldLogSystem->tLogs.size()) {
|
||||
if(nonShardedTxs) {
|
||||
localTags.push_back(txsTag);
|
||||
} else {
|
||||
for(int i = 0; i < self->txsTags; i++) {
|
||||
localTags.push_back(Tag(tagLocalityTxs, i));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue