You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@hbase.apache.org by st...@apache.org on 2020/03/11 23:41:44 UTC

[hbase] branch master updated: HBASE-23929 Shell formatter for for meta table should pretty-print values of info:merge columns

This is an automated email from the ASF dual-hosted git repository.

stack pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/hbase.git


The following commit(s) were added to refs/heads/master by this push:
     new 0b18a7d  HBASE-23929 Shell formatter for for meta table should pretty-print values of info:merge columns
0b18a7d is described below

commit 0b18a7dc263de1825b4910967a5f30d04d54ff2f
Author: stack <st...@apache.org>
AuthorDate: Wed Mar 11 16:40:07 2020 -0700

    HBASE-23929 Shell formatter for for meta table should pretty-print values of info:merge columns
---
 hbase-shell/src/main/ruby/hbase/table.rb | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/hbase-shell/src/main/ruby/hbase/table.rb b/hbase-shell/src/main/ruby/hbase/table.rb
index c5d19a4..8b834d1 100644
--- a/hbase-shell/src/main/ruby/hbase/table.rb
+++ b/hbase-shell/src/main/ruby/hbase/table.rb
@@ -738,7 +738,8 @@ EOF
     # Intercept cells whose format we know such as the info:regioninfo in hbase:meta
     def to_string(column, kv, maxlength = -1, converter_class = nil, converter = nil)
       if is_meta_table?
-        if column == 'info:regioninfo' || column == 'info:splitA' || column == 'info:splitB'
+        if column == 'info:regioninfo' || column == 'info:splitA' || column == 'info:splitB' || \
+            column.start_with?('info:merge')
           hri = org.apache.hadoop.hbase.HRegionInfo.parseFromOrNull(kv.getValueArray,
                                                                     kv.getValueOffset, kv.getValueLength)
           return format('timestamp=%d, value=%s', kv.getTimestamp, hri.nil? ? '' : hri.toString)