hbase-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Xiang Li (JIRA)" <j...@apache.org>
Subject [jira] [Comment Edited] (HBASE-15391) Avoid too large "deleted from META" info log
Date Fri, 30 Jun 2017 13:34:00 GMT

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

Xiang Li edited comment on HBASE-15391 at 6/30/17 1:33 PM:
-----------------------------------------------------------

Hi [~stack]  and [~liushaohui], would you please check the patch committed? Seems a typo which
breaks the compile:  regionInfo{color:#d04437}s{color} --> region{color:#d04437}s{color}Info

Start from line 1980:
LOG.info("Deleted " + {color:#d04437}regionInfos{color}.size() + " regions from META");
if (LOG.isDebugEnabled()) {
    LOG.debug("Deleted regions: " + {color:#d04437}regionInfos{color});
}




was (Author: water):
Hi [~stack]  and [~liushaohui], would you please check the patch committed? Seems a typo which
breaks the compile:  <--> regionInfo{color:#d04437}s{color} --> region{color:#d04437}s{color}Info
line 1980:
LOG.info("Deleted " + {color:#d04437}regionInfos{color}.size() + " regions from META");
if (LOG.isDebugEnabled()) {
    LOG.debug("Deleted regions: " + {color:#d04437}regionInfos{color});
}



> Avoid too large "deleted from META" info log
> --------------------------------------------
>
>                 Key: HBASE-15391
>                 URL: https://issues.apache.org/jira/browse/HBASE-15391
>             Project: HBase
>          Issue Type: Improvement
>            Reporter: Liu Shaohui
>            Assignee: Liu Shaohui
>            Priority: Minor
>             Fix For: 2.0.0
>
>         Attachments: HBASE-15391-trunk-v1.diff, HBASE-15391-trunk-v2.diff
>
>
> When deleting a large table in HBase, there will be a large info log in HMaster.
> {code}
> 2016-02-29,05:58:45,920 INFO org.apache.hadoop.hbase.catalog.MetaEditor: Deleted [{ENCODED
=> 4b54572150941cd03f5addfdeab0a754, NAME => 'YCSBTest,,1453186492932.4b54572150941cd03f5addfdeab0a754.',
STARTKEY => '', ENDKEY => 'user01'}, {ENCODED => 715e142bcd6a31d7842abf286ef8a5fe,
NAME => 'YCSBTest,user01,1453186492933.715e142bcd6a31d7842abf286ef8a5fe.', STARTKEY =>
'user01', ENDKEY => 'user02'}, {ENCODED => 5f9cef5714973f13baa63fba29a68d70, NAME =>
'YCSBTest,user02,1453186492933.5f9cef5714973f13baa63fba29a68d70.', STARTKEY => 'user02',
ENDKEY => 'user03'}, {ENCODED => 86cf3fa4c0a6b911275512c1d4b78533, NAME => 'YCSBTest,user0...
> {code}
> The reason is that MetaTableAccessor will log all regions when deleting them from meta.
See, MetaTableAccessor.java#deleteRegions
> {code}
>   public static void deleteRegions(Connection connection,
>                                    List<HRegionInfo> regionsInfo, long ts) throws
IOException {
>     List<Delete> deletes = new ArrayList<Delete>(regionsInfo.size());
>     for (HRegionInfo hri: regionsInfo) {
>       Delete e = new Delete(hri.getRegionName());
>       e.addFamily(getCatalogFamily(), ts);
>       deletes.add(e);
>     }
>     deleteFromMetaTable(connection, deletes);
>     LOG.info("Deleted " + regionsInfo);
>   }
> {code}
> Just change the info log to debug and add a info log about the number of deleted regions.
Others suggestions are welcomed~



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)

Mime
View raw message