Details
Description
When quota is off the shell gives a error that requires knowledge of our implementation details to understand:
2.2.1 :001 > list_snapshot_sizes SNAPSHOT SIZE ERROR: Unknown table hbase:quota! For usage try 'help "list_snapshot_sizes"' Took 1.6285 seconds 2.2.1 :002 > list_quota_snapshots TABLE USAGE LIMIT IN_VIOLATION POLICY ERROR: Unknown table hbase:quota! For usage try 'help "list_quota_snapshots"' Took 0.0371 seconds
Or it just doesn't mention that quotas can't exist:
2.2.1 :003 > list_quotas OWNER QUOTAS 0 row(s) Took 0.0475 seconds 2.2.1 :004 > list_quota_table_sizes TABLE SIZE 0 row(s) Took 0.1221 seconds
set quota gives a better pointer that the problem is the feature is off:
2.2.1 :005 > set_quota USER => 'busbey', GLOBAL_BYPASS => true ERROR: org.apache.hadoop.hbase.DoNotRetryIOException: java.lang.UnsupportedOperationException: quota support disabled at org.apache.hadoop.hbase.quotas.MasterQuotaManager.checkQuotaSupport(MasterQuotaManager.java:442) at org.apache.hadoop.hbase.quotas.MasterQuotaManager.setQuota(MasterQuotaManager.java:124) at org.apache.hadoop.hbase.master.MasterRpcServices.setQuota(MasterRpcServices.java:1555) at org.apache.hadoop.hbase.shaded.protobuf.generated.MasterProtos$MasterService$2.callBlockingMethod(MasterProtos.java) at org.apache.hadoop.hbase.ipc.RpcServer.call(RpcServer.java:409) at org.apache.hadoop.hbase.ipc.CallRunner.run(CallRunner.java:130) at org.apache.hadoop.hbase.ipc.RpcExecutor$Handler.run(RpcExecutor.java:324) at org.apache.hadoop.hbase.ipc.RpcExecutor$Handler.run(RpcExecutor.java:304) Caused by: java.lang.UnsupportedOperationException: quota support disabled ... 8 more For usage try 'help "set_quota"'
Instead we should give a nice message, like you get if visibility labels is off:
2.2.1 :06 > list_labels ERROR: DISABLED: Visibility labels feature is not available For usage try 'help "list_labels"' Took 0.0426 seconds