Merge branch 'release-5.0'

# Conflicts:
#	versions.target
This commit is contained in:
Stephen Atherton 2017-08-09 23:36:12 -07:00
commit 50fb44be92
4 changed files with 15 additions and 7 deletions

View File

@ -115,6 +115,7 @@ struct ILogSystem {
bool parallelGetMore;
int sequence;
Deque<Future<TLogPeekReply>> futureResults;
Future<Void> interfaceChanged;
ServerPeekCursor( Reference<AsyncVar<OptionalInterface<TLogInterface>>> const& interf, Tag tag, Version begin, Version end, bool returnIfBlocked, bool parallelGetMore );

View File

@ -119,6 +119,10 @@ ACTOR Future<Void> serverPeekParallelGetMore( ILogSystem::ServerPeekCursor* self
throw internal_error();
}
if(!self->interfaceChanged.isValid()) {
self->interfaceChanged = self->interf->onChange();
}
loop {
try {
while(self->futureResults.size() < SERVER_KNOBS->PARALLEL_GET_MORE_REQUESTS && self->interf->get().present()) {
@ -139,7 +143,9 @@ ACTOR Future<Void> serverPeekParallelGetMore( ILogSystem::ServerPeekCursor* self
//TraceEvent("SPC_getMoreB", self->randomID).detail("has", self->hasMessage()).detail("end", res.end).detail("popped", res.popped.present() ? res.popped.get() : 0);
return Void();
}
when( Void _ = wait( self->interf->onChange() ) ) {
when( Void _ = wait( self->interfaceChanged ) ) {
self->interfaceChanged = self->interf->onChange();
self->randomID = g_random->randomUniqueID();
self->sequence = 0;
self->futureResults.clear();
}
@ -150,6 +156,7 @@ ACTOR Future<Void> serverPeekParallelGetMore( ILogSystem::ServerPeekCursor* self
return Void();
} else if(e.code() == error_code_timed_out) {
TraceEvent("PeekCursorTimedOut", self->randomID);
self->interfaceChanged = self->interf->onChange();
self->randomID = g_random->randomUniqueID();
self->sequence = 0;
self->futureResults.clear();

View File

@ -1129,11 +1129,11 @@ ACTOR Future<Void> respondToRecovered( TLogInterface tli, Future<Void> recovery
ACTOR Future<Void> cleanupPeekTrackers( TLogData* self ) {
loop {
double minExpireTime = SERVER_KNOBS->PEEK_TRACKER_EXPIRATION_TIME;
double minTimeUntilExpiration = SERVER_KNOBS->PEEK_TRACKER_EXPIRATION_TIME;
auto it = self->peekTracker.begin();
while(it != self->peekTracker.end()) {
double expireTime = SERVER_KNOBS->PEEK_TRACKER_EXPIRATION_TIME - now()-it->second.lastUpdate;
if(expireTime < 1.0e-6) {
double timeUntilExpiration = it->second.lastUpdate + SERVER_KNOBS->PEEK_TRACKER_EXPIRATION_TIME - now();
if(timeUntilExpiration < 1.0e-6) {
for(auto seq : it->second.sequence_version) {
if(!seq.second.isSet()) {
seq.second.sendError(timed_out());
@ -1141,12 +1141,12 @@ ACTOR Future<Void> cleanupPeekTrackers( TLogData* self ) {
}
it = self->peekTracker.erase(it);
} else {
minExpireTime = std::min(minExpireTime, expireTime);
minTimeUntilExpiration = std::min(minTimeUntilExpiration, timeUntilExpiration);
++it;
}
}
Void _ = wait( delay(minExpireTime) );
Void _ = wait( delay(minTimeUntilExpiration) );
}
}

2
packaging/msi/FDBInstaller.wxs Normal file → Executable file
View File

@ -32,7 +32,7 @@
<Wix xmlns='http://schemas.microsoft.com/wix/2006/wi'>
<Product Name='$(var.Title)'
Id='{6B9B840B-A6E2-4E07-B41A-86910C574923}'
Id='{137B53CD-E95D-450D-B16C-268F2855EA13}'
UpgradeCode='{A95EA002-686E-4164-8356-C715B7F8B1C8}'
Version='$(var.Version)'
Manufacturer='$(var.Manufacturer)'