[jira] [Updated] (HBASE-10842) Some logger not declared static final

2014-03-26 Thread Enis Soztutar (JIRA)

 [ 
https://issues.apache.org/jira/browse/HBASE-10842?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Enis Soztutar updated HBASE-10842:
--

   Resolution: Fixed
Fix Version/s: 0.99.0
 Hadoop Flags: Reviewed
   Status: Resolved  (was: Patch Available)

Committed this to trunk. Thanks Richard. 


> Some logger not declared static final
> -
>
> Key: HBASE-10842
> URL: https://issues.apache.org/jira/browse/HBASE-10842
> Project: HBase
>  Issue Type: Improvement
>Affects Versions: 0.98.1, 0.96.1.1
>Reporter: Richard Ding
>Assignee: Richard Ding
>Priority: Minor
> Fix For: 0.99.0
>
> Attachments: HBASE-10842.patch, HBASE-10842.patch
>
>
> In a few of source files, the logger is defined as 
> {code}
> private final Log LOG = LogFactory.getLog(MyClass.class);
> {code}
> This should be changed to static final.
> One question is about the following declaration:
> {code}
> private final Log LOG = LogFactory.getLog(this.getClass());
> {code}
> In this form, the logger can be shared by derived classes. But one will get 
> NPE when logging in methods that are invoked inside the constructors.



--
This message was sent by Atlassian JIRA
(v6.2#6252)


[jira] [Updated] (HBASE-10842) Some logger not declared static final

2014-03-26 Thread Richard Ding (JIRA)

 [ 
https://issues.apache.org/jira/browse/HBASE-10842?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Richard Ding updated HBASE-10842:
-

Attachment: HBASE-10842.patch

Missed two files. Attach new patch.

> Some logger not declared static final
> -
>
> Key: HBASE-10842
> URL: https://issues.apache.org/jira/browse/HBASE-10842
> Project: HBase
>  Issue Type: Improvement
>Affects Versions: 0.98.1, 0.96.1.1
>Reporter: Richard Ding
>Assignee: Richard Ding
>Priority: Minor
> Attachments: HBASE-10842.patch, HBASE-10842.patch
>
>
> In a few of source files, the logger is defined as 
> {code}
> private final Log LOG = LogFactory.getLog(MyClass.class);
> {code}
> This should be changed to static final.
> One question is about the following declaration:
> {code}
> private final Log LOG = LogFactory.getLog(this.getClass());
> {code}
> In this form, the logger can be shared by derived classes. But one will get 
> NPE when logging in methods that are invoked inside the constructors.



--
This message was sent by Atlassian JIRA
(v6.2#6252)


[jira] [Updated] (HBASE-10842) Some logger not declared static final

2014-03-26 Thread Richard Ding (JIRA)

 [ 
https://issues.apache.org/jira/browse/HBASE-10842?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Richard Ding updated HBASE-10842:
-

Status: Patch Available  (was: Open)

> Some logger not declared static final
> -
>
> Key: HBASE-10842
> URL: https://issues.apache.org/jira/browse/HBASE-10842
> Project: HBase
>  Issue Type: Improvement
>Affects Versions: 0.96.1.1, 0.98.1
>Reporter: Richard Ding
>Assignee: Richard Ding
>Priority: Minor
> Attachments: HBASE-10842.patch
>
>
> In a few of source files, the logger is defined as 
> {code}
> private final Log LOG = LogFactory.getLog(MyClass.class);
> {code}
> This should be changed to static final.
> One question is about the following declaration:
> {code}
> private final Log LOG = LogFactory.getLog(this.getClass());
> {code}
> In this form, the logger can be shared by derived classes. But one will get 
> NPE when logging in methods that are invoked inside the constructors.



--
This message was sent by Atlassian JIRA
(v6.2#6252)


[jira] [Updated] (HBASE-10842) Some logger not declared static final

2014-03-26 Thread Richard Ding (JIRA)

 [ 
https://issues.apache.org/jira/browse/HBASE-10842?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Richard Ding updated HBASE-10842:
-

Attachment: HBASE-10842.patch

This patch fixed the first case. 

> Some logger not declared static final
> -
>
> Key: HBASE-10842
> URL: https://issues.apache.org/jira/browse/HBASE-10842
> Project: HBase
>  Issue Type: Improvement
>Affects Versions: 0.98.1, 0.96.1.1
>Reporter: Richard Ding
>Assignee: Richard Ding
>Priority: Minor
> Attachments: HBASE-10842.patch
>
>
> In a few of source files, the logger is defined as 
> {code}
> private final Log LOG = LogFactory.getLog(MyClass.class);
> {code}
> This should be changed to static final.
> One question is about the following declaration:
> {code}
> private final Log LOG = LogFactory.getLog(this.getClass());
> {code}
> In this form, the logger can be shared by derived classes. But one will get 
> NPE when logging in methods that are invoked inside the constructors.



--
This message was sent by Atlassian JIRA
(v6.2#6252)