Merge pull request #4661 from RenxuanW/rk
Add TraceEvent to see whether RateKeeper is too busy to get SS list or fails to get SS list.
This commit is contained in:
commit
c9cb96b59f
|
@ -737,6 +737,10 @@ ACTOR Future<Void> monitorServerListChange(
|
||||||
|
|
||||||
loop {
|
loop {
|
||||||
try {
|
try {
|
||||||
|
if (now() - self->lastSSListFetchedTimestamp > 2 * SERVER_KNOBS->SERVER_LIST_DELAY) {
|
||||||
|
TraceEvent(SevWarnAlways, "RatekeeperGetSSListLongLatency", self->id)
|
||||||
|
.detail("Latency", now() - self->lastSSListFetchedTimestamp);
|
||||||
|
}
|
||||||
tr.setOption(FDBTransactionOptions::PRIORITY_SYSTEM_IMMEDIATE);
|
tr.setOption(FDBTransactionOptions::PRIORITY_SYSTEM_IMMEDIATE);
|
||||||
vector<std::pair<StorageServerInterface, ProcessClass>> results = wait(getServerListAndProcessClasses(&tr));
|
vector<std::pair<StorageServerInterface, ProcessClass>> results = wait(getServerListAndProcessClasses(&tr));
|
||||||
self->lastSSListFetchedTimestamp = now();
|
self->lastSSListFetchedTimestamp = now();
|
||||||
|
@ -764,6 +768,7 @@ ACTOR Future<Void> monitorServerListChange(
|
||||||
tr = Transaction(self->db);
|
tr = Transaction(self->db);
|
||||||
wait(delay(SERVER_KNOBS->SERVER_LIST_DELAY));
|
wait(delay(SERVER_KNOBS->SERVER_LIST_DELAY));
|
||||||
} catch (Error& e) {
|
} catch (Error& e) {
|
||||||
|
TraceEvent("RatekeeperGetSSListError", self->id).error(e).suppressFor(1.0);
|
||||||
wait(tr.onError(e));
|
wait(tr.onError(e));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue