You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@hbase.apache.org by "Yuki Tawara (JIRA)" <ji...@apache.org> on 2018/03/27 18:03:00 UTC
[jira] [Commented] (HBASE-20297) Remove Logger#isErrorEnabled check
[ https://issues.apache.org/jira/browse/HBASE-20297?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16416017#comment-16416017 ]
Yuki Tawara commented on HBASE-20297:
-------------------------------------
I attached a patch.
How can I assign a issue to me?
If permissions are necessary, please give me permissions.
> Remove Logger#isErrorEnabled check
> ----------------------------------
>
> Key: HBASE-20297
> URL: https://issues.apache.org/jira/browse/HBASE-20297
> Project: HBase
> Issue Type: Improvement
> Reporter: Yuki Tawara
> Priority: Trivial
> Attachments: HBASE-20297.master.001.patch
>
>
> Logger#isErrorEnabled check is unnecessary, so it should be removed.
> I greped the code base and found 3 occurrences.
> (The checks in Logging.scala seem necessary.)
> {noformat}
> ./hbase-common/src/main/java/org/apache/hadoop/hbase/ScheduledChore.java: if (LOG.isErrorEnabled()) LOG.error("Caught error", t);
> ./hbase-spark/src/main/scala/org/apache/hadoop/hbase/spark/Logging.scala: if (log.isErrorEnabled) log.error(msg)
> ./hbase-spark/src/main/scala/org/apache/hadoop/hbase/spark/Logging.scala: if (log.isErrorEnabled) log.error(msg, throwable)
> {noformat}
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)