title: Java Logging - Wrapper?
body: <p>I am starting with a new Project and have done some considerations about logging. I always used the pattern where every class, in which logging is done, has its own static Logger:</p>
  
  <pre><code>private static final Logger logger = Logger.getLogger(LoggingInterceptor.class);
  </code></pre>
  
  <p>I do not really like this approach as I have to copy this line into every class where I will log something. I considered using the Android approach where there is the Log class with it's static methods to log. I started searching on the internet for a similar approach done by someone else, but did not find anything. </p>
  
  <p>So my question is: What could be disatvantages of this approach?</p>
  
  <p>I cannot think of any but rather of some advantages, as it follows the DRY pattern. The different categories could be handled as in Android with 'tags', which are parameters of the static Log methods.  For example:</p>
  
  <pre><code> Log.debug(tag, message, exception);
  </code></pre>
  
  <p>The Log class itself would then use a common Logging Framework such as Log4j or even SLF4J.</p>
  
  <p>So I am interested in your opinions.</p>