[ 
https://issues.apache.org/jira/browse/HBASE-20654?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16493665#comment-16493665
 ] 

Ted Yu commented on HBASE-20654:
--------------------------------

{code}
+      
metricsRecordBuilder.tag(Interns.info(REGIONS_STATE_FAILED_OPEN,REGIONS_STATE_FAILED_OPEN_DESC),metricsAssignmentWrapper.getFailedOpenRegions());
{code}
Please limit line length to 100 characters.
{code}
+//    assignmentManagerSource = CompatibilitySingletonFactory.getInstance(
+//        MetricsAssignmentManagerSource.class);
{code}
Drop commented out code.
{code}
+  public static final String 
METRIC_MAXNUM_REGIONS_IN_EACH_STATE="hbase.assignment.metric.maxmum.regions.in.each.state";

typo: maxnum -> maximum. If you meant maximum number of regions, use "max.num" 
instead.
{code}
+  private static final int DEFAULT_METRIC_MAXNUM_REGIONS_IN_EACH_STATE = 200;
{code}
Consider lowering the default count since the count is per state. How about 
using 100 as the default ?
{code}
+  protected int getMaxnumRegionInEachState(){
{code}
num -> Num
Region -> Regions
{code}
+        return StringUtils.join(regions, ",");
{code}
I think using ', ' as delimiter would make the output more readable.

> Expose regions in transition thru JMX
> -------------------------------------
>
>                 Key: HBASE-20654
>                 URL: https://issues.apache.org/jira/browse/HBASE-20654
>             Project: HBase
>          Issue Type: Improvement
>            Reporter: Ted Yu
>            Assignee: liubangchen
>            Priority: Major
>         Attachments: HBASE-20654-1.patch
>
>
> Currently only the count of regions in transition is exposed thru JMX.
> Here is a sample snippet of the /jmx output:
> {code}
> {
>   "beans" : [ {
> ...
>   }, {
>     "name" : "Hadoop:service=HBase,name=Master,sub=AssignmentManager",
>     "modelerType" : "Master,sub=AssignmentManager",
>     "tag.Context" : "master",
> ...
>     "ritCount" : 3
> {code}
> It would be desirable to expose region name, state for the regions in 
> transition as well.
> We can place configurable upper bound on the number of entries returned in 
> case there're a lot of regions in transition.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Reply via email to