You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@hbase.apache.org by ap...@apache.org on 2018/04/06 22:34:11 UTC

hbase git commit: HBASE-20286 Improving shell command compaction_state

Repository: hbase
Updated Branches:
  refs/heads/master e4b8bd665 -> a422310da


HBASE-20286 Improving shell command compaction_state

Signed-off-by: Apekshit Sharma <ap...@apache.org>


Project: http://git-wip-us.apache.org/repos/asf/hbase/repo
Commit: http://git-wip-us.apache.org/repos/asf/hbase/commit/a422310d
Tree: http://git-wip-us.apache.org/repos/asf/hbase/tree/a422310d
Diff: http://git-wip-us.apache.org/repos/asf/hbase/diff/a422310d

Branch: refs/heads/master
Commit: a422310dadf1fe3c7bb999fe51d6a754fd979b46
Parents: e4b8bd6
Author: Csaba Skrabak <ke...@gmail.com>
Authored: Fri Apr 6 15:32:37 2018 -0700
Committer: Apekshit Sharma <ap...@apache.org>
Committed: Fri Apr 6 15:32:37 2018 -0700

----------------------------------------------------------------------
 hbase-shell/src/main/ruby/shell/commands/compaction_state.rb | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/hbase/blob/a422310d/hbase-shell/src/main/ruby/shell/commands/compaction_state.rb
----------------------------------------------------------------------
diff --git a/hbase-shell/src/main/ruby/shell/commands/compaction_state.rb b/hbase-shell/src/main/ruby/shell/commands/compaction_state.rb
index 91bd79d..05b7521 100644
--- a/hbase-shell/src/main/ruby/shell/commands/compaction_state.rb
+++ b/hbase-shell/src/main/ruby/shell/commands/compaction_state.rb
@@ -22,14 +22,16 @@ module Shell
     class CompactionState < Command
       def help
         <<-EOF
-          Gets compaction status for a table:
+          Gets compaction status (MAJOR, MAJOR_AND_MINOR, MINOR, NONE) for a table:
           hbase> compaction_state 'ns1:t1'
           hbase> compaction_state 't1'
         EOF
       end
 
       def command(table_name)
-        admin.getCompactionState(table_name)
+        rv = admin.getCompactionState(table_name)
+        formatter.row([rv])
+        rv
       end
     end
   end