HBASE-27494: Fix missing meta cache dropping exception metrics (#4902)

Signed-off-by: Bryan Beaudreault <bbeaudreault@apache.org>
This commit is contained in:
Bri Augenreich 2022-11-30 13:03:19 -05:00 committed by Bryan Beaudreault
parent 6e562bb84b
commit 751b6b9b68
1 changed files with 4 additions and 0 deletions

View File

@ -908,6 +908,10 @@ class AsyncRequestFutureImpl<CResult> implements AsyncRequestFuture {
if (ClientExceptionsUtil.isMetaClearingException(regionException)) {
// We want to make sure to clear the cache in case there were location-related exceptions.
// We don't to clear the cache for every possible exception that comes through, however.
MetricsConnection metrics = asyncProcess.connection.getConnectionMetrics();
if (metrics != null) {
metrics.incrCacheDroppingExceptions(regionException);
}
asyncProcess.connection.clearCaches(server);
}
}