Blacklist for timeout === max, not just >

This commit is contained in:
F. Eugene Aumson 2020-10-02 14:18:31 -04:00
parent 5a3bd716ad
commit 32923ec7e1
No known key found for this signature in database
GPG Key ID: 23E6737B1374A24A

View File

@ -393,7 +393,7 @@ export class QuoteRequestor {
}, },
}, },
}); });
rfqMakerBlacklist.logTimeoutOrLackThereof(url, latencyMs > maxResponseTimeMs); rfqMakerBlacklist.logTimeoutOrLackThereof(url, latencyMs >= maxResponseTimeMs);
result.push({ response: response.data, makerUri: url }); result.push({ response: response.data, makerUri: url });
} catch (err) { } catch (err) {
const latencyMs = Date.now() - timeBeforeAwait; const latencyMs = Date.now() - timeBeforeAwait;
@ -409,7 +409,7 @@ export class QuoteRequestor {
}, },
}, },
}); });
rfqMakerBlacklist.logTimeoutOrLackThereof(url, latencyMs > maxResponseTimeMs); rfqMakerBlacklist.logTimeoutOrLackThereof(url, latencyMs >= maxResponseTimeMs);
this._warningLogger( this._warningLogger(
convertIfAxiosError(err), convertIfAxiosError(err),
`Failed to get RFQ-T ${quoteType} quote from market maker endpoint ${url} for API key ${ `Failed to get RFQ-T ${quoteType} quote from market maker endpoint ${url} for API key ${