You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@hbase.apache.org by bb...@apache.org on 2022/11/21 13:23:50 UTC
[hbase] branch branch-2.5 updated: HBASE-27408 Improve BucketAllocatorException log to always include HFile name (#4886)
This is an automated email from the ASF dual-hosted git repository.
bbeaudreault pushed a commit to branch branch-2.5
in repository https://gitbox.apache.org/repos/asf/hbase.git
The following commit(s) were added to refs/heads/branch-2.5 by this push:
new 060ca843745 HBASE-27408 Improve BucketAllocatorException log to always include HFile name (#4886)
060ca843745 is described below
commit 060ca8437453da5faee96057ea5d1c470ca71238
Author: Bryan Beaudreault <bb...@apache.org>
AuthorDate: Mon Nov 21 08:21:29 2022 -0500
HBASE-27408 Improve BucketAllocatorException log to always include HFile name (#4886)
Signed-off-by: Duo Zhang <zh...@apache.org>
Signed-off-by: Xiaolin Ha <ha...@apache.org>
---
.../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.java | 10 ++++++++--
1 file changed, 8 insertions(+), 2 deletions(-)
diff --git a/hbase-server/src/main/java/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.java b/hbase-server/src/main/java/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.java
index 7398762bdf3..6659bd10c6f 100644
--- a/hbase-server/src/main/java/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.java
+++ b/hbase-server/src/main/java/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.java
@@ -1025,13 +1025,19 @@ public class BucketCache implements BlockCache, HeapSize {
final HFileContext fileContext = ((HFileBlock) re.getData()).getHFileContext();
final String columnFamily = Bytes.toString(fileContext.getColumnFamily());
final String tableName = Bytes.toString(fileContext.getTableName());
- if (tableName != null && columnFamily != null) {
+ if (tableName != null) {
sb.append(" Table: ");
sb.append(tableName);
+ }
+ if (columnFamily != null) {
sb.append(" CF: ");
sb.append(columnFamily);
- sb.append(" HFile: ");
+ }
+ sb.append(" HFile: ");
+ if (fileContext.getHFileName() != null) {
sb.append(fileContext.getHFileName());
+ } else {
+ sb.append(re.getKey());
}
} else {
sb.append(" HFile: ");