rmdmattingly commented on code in PR #5275:
URL: https://github.com/apache/hbase/pull/5275#discussion_r1240822929
##########
hbase-client/src/main/java/org/apache/hadoop/hbase/client/AsyncScanSingleRegionRpcRetryingCaller.java:
##########
@@ -418,19 +416,14 @@ private void onError(Throwable error) {
completeExceptionally(!scannerClosed);
return;
}
- long delayNs;
- long pauseNsToUse =
- HBaseServerException.isServerOverloaded(error) ?
pauseNsForServerOverloaded : pauseNs;
- if (scanTimeoutNs > 0) {
- long maxDelayNs = remainingTimeNs() - SLEEP_DELTA_NS;
- if (maxDelayNs <= 0) {
- completeExceptionally(!scannerClosed);
- return;
- }
- delayNs = Math.min(maxDelayNs, getPauseTime(pauseNsToUse, tries - 1));
- } else {
- delayNs = getPauseTime(pauseNsToUse, tries - 1);
+
+ OptionalLong maybePauseNsToUse =
pauseManager.getPauseNsFromException(error,
+ remainingTimeNs() - SLEEP_DELTA_NS, tries, scanTimeoutNs > 0);
Review Comment:
👍 good idea, I just pushed this change
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]