sanjeet006py commented on code in PR #6868:
URL: https://github.com/apache/hbase/pull/6868#discussion_r2057820053
##########
hbase-client/src/main/java/org/apache/hadoop/hbase/client/AbstractClientScanner.java:
##########
@@ -44,6 +64,24 @@ protected void initScanMetrics(Scan scan) {
*/
@Override
public ScanMetrics getScanMetrics() {
- return scanMetrics;
+ if (scanMetricsByRegion != null) {
+ if (scanMetricsByRegion.isEmpty()) {
+ return null;
Review Comment:
Actually, I see current getter returns `null` if scanMetrics are retrieved
before being initialized. So, I think we can keep returning null. WDYT?
--
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]