metron-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From mmiklav...@apache.org
Subject [1/3] metron git commit: METRON-975: Normalize logging and switch to common idiom with SLF4J (mmiklavc) closes apache/metron#599
Date Tue, 01 Aug 2017 15:34:04 GMT
Repository: metron
Updated Branches:
  refs/heads/master 7b9f20c93 -> ec959d20e


http://git-wip-us.apache.org/repos/asf/metron/blob/ec959d20/metron-platform/metron-parsers/src/main/java/org/apache/metron/parsers/GrokParser.java
----------------------------------------------------------------------
diff --git a/metron-platform/metron-parsers/src/main/java/org/apache/metron/parsers/GrokParser.java b/metron-platform/metron-parsers/src/main/java/org/apache/metron/parsers/GrokParser.java
index 61cb448..99ac390 100644
--- a/metron-platform/metron-parsers/src/main/java/org/apache/metron/parsers/GrokParser.java
+++ b/metron-platform/metron-parsers/src/main/java/org/apache/metron/parsers/GrokParser.java
@@ -19,21 +19,11 @@ package org.apache.metron.parsers;
 
 import com.google.common.base.Joiner;
 import com.google.common.base.Splitter;
-import oi.thekraken.grok.api.Grok;
-import oi.thekraken.grok.api.Match;
-import org.apache.hadoop.conf.Configuration;
-import org.apache.hadoop.fs.FileSystem;
-import org.apache.hadoop.fs.Path;
-import org.apache.metron.common.Constants;
-import org.apache.metron.parsers.interfaces.MessageParser;
-import org.json.simple.JSONObject;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
 import java.io.IOException;
 import java.io.InputStream;
 import java.io.InputStreamReader;
 import java.io.Serializable;
+import java.lang.invoke.MethodHandles;
 import java.text.ParseException;
 import java.text.SimpleDateFormat;
 import java.util.ArrayList;
@@ -41,10 +31,20 @@ import java.util.Date;
 import java.util.List;
 import java.util.Map;
 import java.util.TimeZone;
+import oi.thekraken.grok.api.Grok;
+import oi.thekraken.grok.api.Match;
+import org.apache.hadoop.conf.Configuration;
+import org.apache.hadoop.fs.FileSystem;
+import org.apache.hadoop.fs.Path;
+import org.apache.metron.common.Constants;
+import org.apache.metron.parsers.interfaces.MessageParser;
+import org.json.simple.JSONObject;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
 
 public class GrokParser implements MessageParser<JSONObject>, Serializable {
 
-  protected static final Logger LOG = LoggerFactory.getLogger(GrokParser.class);
+  protected static final Logger LOG = LoggerFactory.getLogger(MethodHandles.lookup().lookupClass());
 
   protected transient Grok grok;
   protected String grokPath;
@@ -92,9 +92,7 @@ public class GrokParser implements MessageParser<JSONObject>, Serializable {
     grok = new Grok();
     try {
       InputStream commonInputStream = openInputStream(patternsCommonDir);
-      if (LOG.isDebugEnabled()) {
-        LOG.debug("Grok parser loading common patterns from: " + patternsCommonDir);
-      }
+      LOG.debug("Grok parser loading common patterns from: {}", patternsCommonDir);
 
       if (commonInputStream == null) {
         throw new RuntimeException(
@@ -102,9 +100,7 @@ public class GrokParser implements MessageParser<JSONObject>, Serializable {
       }
 
       grok.addPatternFromReader(new InputStreamReader(commonInputStream));
-      if (LOG.isDebugEnabled()) {
-        LOG.debug("Loading parser-specific patterns from: " + grokPath);
-      }
+      LOG.debug("Loading parser-specific patterns from: {}", grokPath);
 
       InputStream patterInputStream = openInputStream(grokPath);
       if (patterInputStream == null) {
@@ -114,15 +110,13 @@ public class GrokParser implements MessageParser<JSONObject>, Serializable {
       grok.addPatternFromReader(new InputStreamReader(patterInputStream));
 
       if (LOG.isDebugEnabled()) {
-        LOG.debug("Grok parser set the following grok expression: " + grok.getNamedRegexCollectionById(patternLabel));
+        LOG.debug("Grok parser set the following grok expression: {}", grok.getNamedRegexCollectionById(patternLabel));
       }
 
       String grokPattern = "%{" + patternLabel + "}";
 
       grok.compile(grokPattern);
-      if (LOG.isDebugEnabled()) {
-        LOG.debug("Compiled grok pattern" + grokPattern);
-      }
+      LOG.debug("Compiled grok pattern {}", grokPattern);
 
     } catch (Throwable e) {
       LOG.error(e.getMessage(), e);
@@ -140,9 +134,7 @@ public class GrokParser implements MessageParser<JSONObject>, Serializable {
     String originalMessage = null;
     try {
       originalMessage = new String(rawMessage, "UTF-8");
-      if (LOG.isDebugEnabled()) {
-        LOG.debug("Grok parser parsing message: " + originalMessage);
-      }
+      LOG.debug("Grok parser parsing message: {}",originalMessage);
       Match gm = grok.match(originalMessage);
       gm.captures();
       JSONObject message = new JSONObject();
@@ -166,9 +158,7 @@ public class GrokParser implements MessageParser<JSONObject>, Serializable {
       message.remove(patternLabel);
       postParse(message);
       messages.add(message);
-      if (LOG.isDebugEnabled()) {
-        LOG.debug("Grok parser parsed message: " + message);
-      }
+      LOG.debug("Grok parser parsed message: {}", message);
     } catch (Exception e) {
       LOG.error(e.getMessage(), e);
       throw new IllegalStateException("Grok parser Error: " + e.getMessage() + " on " + originalMessage , e);
@@ -178,48 +168,35 @@ public class GrokParser implements MessageParser<JSONObject>, Serializable {
 
   @Override
   public boolean validate(JSONObject message) {
-    if (LOG.isDebugEnabled()) {
-      LOG.debug("Grok parser validating message: " + message);
-    }
+    LOG.debug("Grok parser validating message: {}", message);
 
     Object timestampObject = message.get(Constants.Fields.TIMESTAMP.getName());
     if (timestampObject instanceof Long) {
       Long timestamp = (Long) timestampObject;
       if (timestamp > 0) {
-        if (LOG.isDebugEnabled()) {
-          LOG.debug("Grok parser validated message: " + message);
-        }
+        LOG.debug("Grok parser validated message: {}", message);
         return true;
       }
     }
 
-    if (LOG.isDebugEnabled()) {
-      LOG.debug("Grok parser did not validate message: " + message);
-    }
+    LOG.debug("Grok parser did not validate message: {}", message);
     return false;
   }
 
   protected void postParse(JSONObject message) {}
 
   protected long toEpoch(String datetime) throws ParseException {
-
     LOG.debug("Grok parser converting timestamp to epoch: {}", datetime);
     LOG.debug("Grok parser's DateFormat has TimeZone: {}", dateFormat.getTimeZone());
 
     Date date = dateFormat.parse(datetime);
-    if (LOG.isDebugEnabled()) {
-      LOG.debug("Grok parser converted timestamp to epoch: " + date);
-    }
+    LOG.debug("Grok parser converted timestamp to epoch: {}", date);
 
     return date.getTime();
   }
 
   protected long formatTimestamp(Object value) {
-
-    if (LOG.isDebugEnabled()) {
-      LOG.debug("Grok parser formatting timestamp" + value);
-    }
-
+    LOG.debug("Grok parser formatting timestamp {}", value);
 
     if (value == null) {
       throw new RuntimeException(patternLabel + " pattern does not include field " + timestampField);

http://git-wip-us.apache.org/repos/asf/metron/blob/ec959d20/metron-platform/metron-parsers/src/main/java/org/apache/metron/parsers/asa/BasicAsaParser.java
----------------------------------------------------------------------
diff --git a/metron-platform/metron-parsers/src/main/java/org/apache/metron/parsers/asa/BasicAsaParser.java b/metron-platform/metron-parsers/src/main/java/org/apache/metron/parsers/asa/BasicAsaParser.java
index daac141..7ac2398 100644
--- a/metron-platform/metron-parsers/src/main/java/org/apache/metron/parsers/asa/BasicAsaParser.java
+++ b/metron-platform/metron-parsers/src/main/java/org/apache/metron/parsers/asa/BasicAsaParser.java
@@ -18,6 +18,17 @@
 package org.apache.metron.parsers.asa;
 
 import com.google.common.collect.ImmutableMap;
+import java.io.InputStream;
+import java.io.InputStreamReader;
+import java.io.UnsupportedEncodingException;
+import java.lang.invoke.MethodHandles;
+import java.time.Clock;
+import java.time.ZoneId;
+import java.util.ArrayList;
+import java.util.HashMap;
+import java.util.List;
+import java.util.Map;
+import java.util.Map.Entry;
 import oi.thekraken.grok.api.Grok;
 import oi.thekraken.grok.api.Match;
 import oi.thekraken.grok.api.exception.GrokException;
@@ -29,15 +40,9 @@ import org.json.simple.JSONObject;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
-import java.io.*;
-import java.time.Clock;
-import java.time.ZoneId;
-import java.util.*;
-import java.util.Map.Entry;
-
 public class BasicAsaParser extends BasicParser {
 
-  protected static final Logger LOG = LoggerFactory.getLogger(BasicAsaParser.class);
+  protected static final Logger LOG = LoggerFactory.getLogger(MethodHandles.lookup().lookupClass());
 
   protected Clock deviceClock;
   private String syslogPattern = "%{CISCO_TAGGED_SYSLOG}";
@@ -122,9 +127,9 @@ public class BasicAsaParser extends BasicParser {
 
     for (Entry<String, String> pattern : patternMap.entrySet()) {
       try {
-	addGrok(pattern.getKey(), pattern.getValue());
+        addGrok(pattern.getKey(), pattern.getValue());
       } catch (GrokException e) {
-	LOG.error("[Metron] Failed to load grok pattern %s for ASA tag %s", pattern.getValue(), pattern.getKey());
+        LOG.error("[Metron] Failed to load grok pattern {} for ASA tag {}", pattern.getValue(), pattern.getKey());
       }
     }
 

http://git-wip-us.apache.org/repos/asf/metron/blob/ec959d20/metron-platform/metron-parsers/src/main/java/org/apache/metron/parsers/bolt/ParserBolt.java
----------------------------------------------------------------------
diff --git a/metron-platform/metron-parsers/src/main/java/org/apache/metron/parsers/bolt/ParserBolt.java b/metron-platform/metron-parsers/src/main/java/org/apache/metron/parsers/bolt/ParserBolt.java
index d78487b..b3b9586 100644
--- a/metron-platform/metron-parsers/src/main/java/org/apache/metron/parsers/bolt/ParserBolt.java
+++ b/metron-platform/metron-parsers/src/main/java/org/apache/metron/parsers/bolt/ParserBolt.java
@@ -17,15 +17,27 @@
  */
 package org.apache.metron.parsers.bolt;
 
+import static org.apache.metron.common.Constants.METADATA_PREFIX;
+
 import com.fasterxml.jackson.core.type.TypeReference;
+import java.io.IOException;
+import java.io.Serializable;
+import java.lang.invoke.MethodHandles;
+import java.util.ArrayList;
+import java.util.Collections;
+import java.util.HashMap;
+import java.util.List;
+import java.util.Map;
+import java.util.Optional;
+import java.util.Set;
+import java.util.UUID;
+import java.util.stream.Collectors;
 import org.apache.commons.lang3.StringUtils;
 import org.apache.metron.common.Constants;
 import org.apache.metron.common.bolt.ConfiguredParserBolt;
 import org.apache.metron.common.configuration.FieldTransformer;
 import org.apache.metron.common.configuration.FieldValidator;
 import org.apache.metron.common.configuration.SensorParserConfig;
-import org.apache.metron.stellar.dsl.Context;
-import org.apache.metron.stellar.dsl.StellarFunctions;
 import org.apache.metron.common.error.MetronError;
 import org.apache.metron.common.message.MessageGetStrategy;
 import org.apache.metron.common.message.MessageGetters;
@@ -34,6 +46,8 @@ import org.apache.metron.common.utils.JSONUtils;
 import org.apache.metron.parsers.filters.Filters;
 import org.apache.metron.parsers.interfaces.MessageFilter;
 import org.apache.metron.parsers.interfaces.MessageParser;
+import org.apache.metron.stellar.dsl.Context;
+import org.apache.metron.stellar.dsl.StellarFunctions;
 import org.apache.storm.task.OutputCollector;
 import org.apache.storm.task.TopologyContext;
 import org.apache.storm.topology.OutputFieldsDeclarer;
@@ -43,17 +57,10 @@ import org.json.simple.JSONObject;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
-import java.io.IOException;
-import java.io.Serializable;
-import java.util.*;
-import java.util.stream.Collectors;
-
-import static org.apache.metron.common.Constants.METADATA_PREFIX;
-
 public class ParserBolt extends ConfiguredParserBolt implements Serializable {
 
   private static final int KEY_INDEX = 1;
-  private static final Logger LOG = LoggerFactory.getLogger(ParserBolt.class);
+  private static final Logger LOG = LoggerFactory.getLogger(MethodHandles.lookup().lookupClass());
   private OutputCollector collector;
   private MessageParser<JSONObject> parser;
   //default filter is noop, so pass everything through.

http://git-wip-us.apache.org/repos/asf/metron/blob/ec959d20/metron-platform/metron-parsers/src/main/java/org/apache/metron/parsers/bro/BasicBroParser.java
----------------------------------------------------------------------
diff --git a/metron-platform/metron-parsers/src/main/java/org/apache/metron/parsers/bro/BasicBroParser.java b/metron-platform/metron-parsers/src/main/java/org/apache/metron/parsers/bro/BasicBroParser.java
index 17bdb2c..5264750 100644
--- a/metron-platform/metron-parsers/src/main/java/org/apache/metron/parsers/bro/BasicBroParser.java
+++ b/metron-platform/metron-parsers/src/main/java/org/apache/metron/parsers/bro/BasicBroParser.java
@@ -18,6 +18,12 @@
 
 package org.apache.metron.parsers.bro;
 
+import java.lang.invoke.MethodHandles;
+import java.text.DecimalFormat;
+import java.text.NumberFormat;
+import java.util.ArrayList;
+import java.util.List;
+import java.util.Map;
 import org.apache.metron.common.Constants;
 import org.apache.metron.parsers.BasicParser;
 import org.json.simple.JSONArray;
@@ -25,16 +31,10 @@ import org.json.simple.JSONObject;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
-import java.text.DecimalFormat;
-import java.text.NumberFormat;
-import java.util.ArrayList;
-import java.util.List;
-import java.util.Map;
-
 @SuppressWarnings("serial")
 public class BasicBroParser extends BasicParser {
 
-  protected static final Logger _LOG = LoggerFactory.getLogger(BasicBroParser.class);
+  protected static final Logger _LOG = LoggerFactory.getLogger(MethodHandles.lookup().lookupClass());
   public static final ThreadLocal<NumberFormat> DECIMAL_FORMAT = new ThreadLocal<NumberFormat>() {
     @Override
     protected NumberFormat initialValue() {
@@ -63,10 +63,10 @@ public class BasicBroParser extends BasicParser {
     List<JSONObject> messages = new ArrayList<>();
     try {
       rawMessage = new String(msg, "UTF-8");
-      _LOG.trace("[Metron] Received message: " + rawMessage);
+      _LOG.trace("[Metron] Received message: {}", rawMessage);
 
       JSONObject cleanedMessage = cleaner.clean(rawMessage);
-      _LOG.debug("[Metron] Cleaned message: " + cleanedMessage);
+      _LOG.debug("[Metron] Cleaned message: {}", cleanedMessage);
 
       if (cleanedMessage == null || cleanedMessage.isEmpty()) {
         throw new Exception("Unable to clean message: " + rawMessage);
@@ -114,9 +114,9 @@ public class BasicBroParser extends BasicParser {
           timestamp = convertToMillis(broTimestamp);
           payload.put(Constants.Fields.TIMESTAMP.getName(), timestamp);
           payload.put("bro_timestamp", broTimestampFormatted);
-          _LOG.trace(String.format("[Metron] new bro record - timestamp : %s", payload.get(Constants.Fields.TIMESTAMP.getName())));
+          _LOG.trace("[Metron] new bro record - timestamp : {}", payload.get(Constants.Fields.TIMESTAMP.getName()));
         } catch (NumberFormatException nfe) {
-          _LOG.error(String.format("[Metron] timestamp is invalid: %s", payload.get("timestamp")));
+          _LOG.error("[Metron] timestamp is invalid: {}", payload.get("timestamp"));
           payload.put(Constants.Fields.TIMESTAMP.getName(), 0);
         }
       }
@@ -135,7 +135,7 @@ public class BasicBroParser extends BasicParser {
       replaceKey(payload, Constants.Fields.DST_PORT.getName(), new String[]{"dest_port", "id.resp_p"});
 
       payload.put(Constants.Fields.PROTOCOL.getName(), key);
-      _LOG.debug("[Metron] Returning parsed message: " + payload);
+      _LOG.debug("[Metron] Returning parsed message: {}", payload);
       messages.add(payload);
       return messages;
 
@@ -156,7 +156,7 @@ public class BasicBroParser extends BasicParser {
       if (payload.containsKey(fromKey)) {
         Object value = payload.remove(fromKey);
         payload.put(toKey, value);
-        _LOG.trace(String.format("[Metron] Added %s to %s", toKey, payload));
+        _LOG.trace("[Metron] Added {} to {}", toKey, payload);
         return true;
       }
     }
@@ -169,7 +169,7 @@ public class BasicBroParser extends BasicParser {
         JSONArray value = (JSONArray) payload.remove(fromKey);
         if (value != null && !value.isEmpty()) {
           payload.put(toKey, value.get(0));
-          _LOG.trace(String.format("[Metron] Added %s to %s", toKey, payload));
+          _LOG.trace("[Metron] Added {} to {}", toKey, payload);
           return true;
         }
       }

http://git-wip-us.apache.org/repos/asf/metron/blob/ec959d20/metron-platform/metron-parsers/src/main/java/org/apache/metron/parsers/cef/CEFParser.java
----------------------------------------------------------------------
diff --git a/metron-platform/metron-parsers/src/main/java/org/apache/metron/parsers/cef/CEFParser.java b/metron-platform/metron-parsers/src/main/java/org/apache/metron/parsers/cef/CEFParser.java
index 352c781..03de37c 100644
--- a/metron-platform/metron-parsers/src/main/java/org/apache/metron/parsers/cef/CEFParser.java
+++ b/metron-platform/metron-parsers/src/main/java/org/apache/metron/parsers/cef/CEFParser.java
@@ -18,6 +18,7 @@
 
 package org.apache.metron.parsers.cef;
 
+import java.lang.invoke.MethodHandles;
 import java.nio.charset.Charset;
 import java.time.Clock;
 import java.util.ArrayList;
@@ -27,7 +28,6 @@ import java.util.Map;
 import java.util.Map.Entry;
 import java.util.regex.Matcher;
 import java.util.regex.Pattern;
-
 import org.apache.metron.parsers.BasicParser;
 import org.apache.metron.parsers.ParseException;
 import org.apache.metron.parsers.utils.DateUtils;
@@ -39,7 +39,7 @@ import org.slf4j.LoggerFactory;
 public class CEFParser extends BasicParser {
 	private static final long serialVersionUID = 1L;
 
-	protected static final Logger LOG = LoggerFactory.getLogger(CEFParser.class);
+	protected static final Logger LOG = LoggerFactory.getLogger(MethodHandles.lookup().lookupClass());
 	private static final String HEADER_CAPTURE_PATTERN = "[^\\|]*";
 	private static final String EXTENSION_CAPTURE_PATTERN = "(?<!\\\\)=";
 	private static final Charset UTF_8 = Charset.forName("UTF-8");
@@ -109,7 +109,7 @@ public class CEFParser extends BasicParser {
 		while (matcher.find()) {
 			JSONObject obj = new JSONObject();
 			if (matcher.matches()) {
-				LOG.info(String.format("Found %d groups", matcher.groupCount()));
+				LOG.info("Found %d groups", matcher.groupCount());
 				obj.put("DeviceVendor", matcher.group("DeviceVendor"));
 				obj.put("DeviceProduct", matcher.group("DeviceProduct"));
 				obj.put("DeviceVersion", matcher.group("DeviceVersion"));

http://git-wip-us.apache.org/repos/asf/metron/blob/ec959d20/metron-platform/metron-parsers/src/main/java/org/apache/metron/parsers/csv/CSVParser.java
----------------------------------------------------------------------
diff --git a/metron-platform/metron-parsers/src/main/java/org/apache/metron/parsers/csv/CSVParser.java b/metron-platform/metron-parsers/src/main/java/org/apache/metron/parsers/csv/CSVParser.java
index 9f7cd51..444f021 100644
--- a/metron-platform/metron-parsers/src/main/java/org/apache/metron/parsers/csv/CSVParser.java
+++ b/metron-platform/metron-parsers/src/main/java/org/apache/metron/parsers/csv/CSVParser.java
@@ -19,6 +19,11 @@
 package org.apache.metron.parsers.csv;
 
 import com.google.common.collect.ImmutableList;
+import java.lang.invoke.MethodHandles;
+import java.text.SimpleDateFormat;
+import java.util.Collections;
+import java.util.List;
+import java.util.Map;
 import org.apache.metron.common.csv.CSVConverter;
 import org.apache.metron.stellar.common.utils.ConversionUtils;
 import org.apache.metron.parsers.BasicParser;
@@ -26,13 +31,8 @@ import org.json.simple.JSONObject;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
-import java.text.SimpleDateFormat;
-import java.util.Collections;
-import java.util.List;
-import java.util.Map;
-
 public class CSVParser extends BasicParser {
-  protected static final Logger LOG = LoggerFactory.getLogger(CSVParser.class);
+  protected static final Logger LOG = LoggerFactory.getLogger(MethodHandles.lookup().lookupClass());
   public static final String TIMESTAMP_FORMAT_CONF = "timestampFormat";
   private transient CSVConverter converter;
   private SimpleDateFormat timestampFormat;
@@ -73,7 +73,7 @@ public class CSVParser extends BasicParser {
               timestamp = timestampFormat.parse(timestampObj.toString()).getTime();
             }
             catch(Exception e) {
-              LOG.error("Unable to format " + timestampObj.toString());
+              LOG.error("Unable to format {}", timestampObj.toString());
             }
           }
         }

http://git-wip-us.apache.org/repos/asf/metron/blob/ec959d20/metron-platform/metron-parsers/src/main/java/org/apache/metron/parsers/fireeye/BasicFireEyeParser.java
----------------------------------------------------------------------
diff --git a/metron-platform/metron-parsers/src/main/java/org/apache/metron/parsers/fireeye/BasicFireEyeParser.java b/metron-platform/metron-parsers/src/main/java/org/apache/metron/parsers/fireeye/BasicFireEyeParser.java
index 839b8f9..04e1591 100644
--- a/metron-platform/metron-parsers/src/main/java/org/apache/metron/parsers/fireeye/BasicFireEyeParser.java
+++ b/metron-platform/metron-parsers/src/main/java/org/apache/metron/parsers/fireeye/BasicFireEyeParser.java
@@ -124,7 +124,7 @@ public class BasicFireEyeParser extends BasicParser {
 			time = tsMatcher.group(3);
 	
 				} else {
-			LOG.warn("Unable to find timestamp in message: " + toParse);
+			LOG.warn("Unable to find timestamp in message: {}", toParse);
 			ts = ParserUtils.convertToEpoch(month, day, time, true);
 		}
 

http://git-wip-us.apache.org/repos/asf/metron/blob/ec959d20/metron-platform/metron-parsers/src/main/java/org/apache/metron/parsers/ise/BasicIseParser.java
----------------------------------------------------------------------
diff --git a/metron-platform/metron-parsers/src/main/java/org/apache/metron/parsers/ise/BasicIseParser.java b/metron-platform/metron-parsers/src/main/java/org/apache/metron/parsers/ise/BasicIseParser.java
index 2d559ac..4e91585 100644
--- a/metron-platform/metron-parsers/src/main/java/org/apache/metron/parsers/ise/BasicIseParser.java
+++ b/metron-platform/metron-parsers/src/main/java/org/apache/metron/parsers/ise/BasicIseParser.java
@@ -56,7 +56,7 @@ public class BasicIseParser extends BasicParser {
 		try {
 
 			raw_message = new String(msg, "UTF-8");
-			_LOG.debug("Received message: " + raw_message);
+			_LOG.debug("Received message: {}", raw_message);
 
 			/*
 			 * Reinitialize Parser. It has the effect of calling the constructor again.

http://git-wip-us.apache.org/repos/asf/metron/blob/ec959d20/metron-platform/metron-parsers/src/main/java/org/apache/metron/parsers/lancope/BasicLancopeParser.java
----------------------------------------------------------------------
diff --git a/metron-platform/metron-parsers/src/main/java/org/apache/metron/parsers/lancope/BasicLancopeParser.java b/metron-platform/metron-parsers/src/main/java/org/apache/metron/parsers/lancope/BasicLancopeParser.java
index 83eedcc..b12e98f 100644
--- a/metron-platform/metron-parsers/src/main/java/org/apache/metron/parsers/lancope/BasicLancopeParser.java
+++ b/metron-platform/metron-parsers/src/main/java/org/apache/metron/parsers/lancope/BasicLancopeParser.java
@@ -18,25 +18,24 @@
 
 package org.apache.metron.parsers.lancope;
 
-import org.apache.metron.parsers.BasicParser;
-import org.json.simple.JSONObject;
-import org.json.simple.JSONValue;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
+import java.lang.invoke.MethodHandles;
 import java.text.SimpleDateFormat;
 import java.util.ArrayList;
 import java.util.Date;
 import java.util.List;
 import java.util.Map;
+import org.apache.metron.parsers.BasicParser;
+import org.json.simple.JSONObject;
+import org.json.simple.JSONValue;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
 
 @SuppressWarnings("serial")
 public class BasicLancopeParser extends BasicParser {
 	// Sample Lancope Message
 	// {"message":"<131>Jul 17 15:59:01 smc-01 StealthWatch[12365]: 2014-07-17T15:58:30Z 10.40.10.254 0.0.0.0 Minor High Concern Index The host's concern index has either exceeded the CI threshold or rapidly increased. Observed 36.55M points. Policy maximum allows up to 20M points.","@version":"1","@timestamp":"2014-07-17T15:56:05.992Z","type":"syslog","host":"10.122.196.201"}
 
-	private static final Logger _LOG = LoggerFactory.getLogger(BasicLancopeParser
-					.class);
+	private static final Logger _LOG = LoggerFactory.getLogger(MethodHandles.lookup().lookupClass());
 
 	@Override
 	public void configure(Map<String, Object> parserConfig) {
@@ -87,7 +86,7 @@ public class BasicLancopeParser extends BasicParser {
 			return messages;
 		} catch (Exception e) {
 
-			_LOG.error("Unable to parse message: " + payload.toJSONString());
+			_LOG.error("Unable to parse message: {}", payload.toJSONString());
 			return null;
 		}
 	}

http://git-wip-us.apache.org/repos/asf/metron/blob/ec959d20/metron-platform/metron-parsers/src/main/java/org/apache/metron/parsers/paloalto/BasicPaloAltoFirewallParser.java
----------------------------------------------------------------------
diff --git a/metron-platform/metron-parsers/src/main/java/org/apache/metron/parsers/paloalto/BasicPaloAltoFirewallParser.java b/metron-platform/metron-parsers/src/main/java/org/apache/metron/parsers/paloalto/BasicPaloAltoFirewallParser.java
index e7e78d4..46155b3 100644
--- a/metron-platform/metron-parsers/src/main/java/org/apache/metron/parsers/paloalto/BasicPaloAltoFirewallParser.java
+++ b/metron-platform/metron-parsers/src/main/java/org/apache/metron/parsers/paloalto/BasicPaloAltoFirewallParser.java
@@ -111,7 +111,7 @@ public class BasicPaloAltoFirewallParser extends BasicParser {
     try {
 
       toParse = new String(msg, "UTF-8");
-      _LOG.debug("Received message: " + toParse);
+      _LOG.debug("Received message: {}", toParse);
 
 
       parseMessage(toParse, outputMessage);
@@ -128,7 +128,7 @@ public class BasicPaloAltoFirewallParser extends BasicParser {
       return messages;
     } catch (Exception e) {
       e.printStackTrace();
-      _LOG.error("Failed to parse: " + toParse);
+      _LOG.error("Failed to parse: {}", toParse);
       return null;
     }
   }

http://git-wip-us.apache.org/repos/asf/metron/blob/ec959d20/metron-platform/metron-parsers/src/main/java/org/apache/metron/parsers/snort/BasicSnortParser.java
----------------------------------------------------------------------
diff --git a/metron-platform/metron-parsers/src/main/java/org/apache/metron/parsers/snort/BasicSnortParser.java b/metron-platform/metron-parsers/src/main/java/org/apache/metron/parsers/snort/BasicSnortParser.java
index d2adfba..4dfe19a 100644
--- a/metron-platform/metron-parsers/src/main/java/org/apache/metron/parsers/snort/BasicSnortParser.java
+++ b/metron-platform/metron-parsers/src/main/java/org/apache/metron/parsers/snort/BasicSnortParser.java
@@ -18,14 +18,7 @@
 package org.apache.metron.parsers.snort;
 
 import com.google.common.collect.Lists;
-import org.apache.commons.lang3.StringUtils;
-import org.apache.metron.common.Constants;
-import org.apache.metron.common.csv.CSVConverter;
-import org.apache.metron.parsers.BasicParser;
-import org.json.simple.JSONObject;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
+import java.lang.invoke.MethodHandles;
 import java.text.ParseException;
 import java.time.ZoneId;
 import java.time.ZonedDateTime;
@@ -34,11 +27,18 @@ import java.util.ArrayList;
 import java.util.HashMap;
 import java.util.List;
 import java.util.Map;
+import org.apache.commons.lang3.StringUtils;
+import org.apache.metron.common.Constants;
+import org.apache.metron.common.csv.CSVConverter;
+import org.apache.metron.parsers.BasicParser;
+import org.json.simple.JSONObject;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
 
 @SuppressWarnings("serial")
 public class BasicSnortParser extends BasicParser {
 
-  private static final Logger _LOG = LoggerFactory.getLogger(BasicSnortParser.class);
+  private static final Logger _LOG = LoggerFactory.getLogger(MethodHandles.lookup().lookupClass());
 
   /**
    * The default field names for Snort Alerts.

http://git-wip-us.apache.org/repos/asf/metron/blob/ec959d20/metron-platform/metron-parsers/src/main/java/org/apache/metron/parsers/sourcefire/BasicSourcefireParser.java
----------------------------------------------------------------------
diff --git a/metron-platform/metron-parsers/src/main/java/org/apache/metron/parsers/sourcefire/BasicSourcefireParser.java b/metron-platform/metron-parsers/src/main/java/org/apache/metron/parsers/sourcefire/BasicSourcefireParser.java
index 969e469..91faca2 100644
--- a/metron-platform/metron-parsers/src/main/java/org/apache/metron/parsers/sourcefire/BasicSourcefireParser.java
+++ b/metron-platform/metron-parsers/src/main/java/org/apache/metron/parsers/sourcefire/BasicSourcefireParser.java
@@ -62,7 +62,7 @@ public class BasicSourcefireParser extends BasicParser {
 		try {
 
 			toParse = new String(msg, "UTF-8");
-			_LOG.debug("Received message: " + toParse);
+			_LOG.debug("Received message: {}", toParse);
 
 			String tmp = toParse.substring(toParse.lastIndexOf("{"));
 			payload.put("key", tmp);
@@ -109,7 +109,7 @@ public class BasicSourcefireParser extends BasicParser {
 				signatureId = sidMatcher.group(2);
 				originalString = sidMatcher.group(1) +" "+ sidMatcher.group(2) + " " + sidMatcher.group(3);
 			} else {
-				_LOG.warn("Unable to find SID in message: " + toParse);
+				_LOG.warn("Unable to find SID in message: {}", toParse);
 				originalString = toParse;
 			}
 			payload.put("original_string", originalString);
@@ -118,7 +118,7 @@ public class BasicSourcefireParser extends BasicParser {
 			return messages;
 		} catch (Exception e) {
 			e.printStackTrace();
-			_LOG.error("Failed to parse: " + toParse);
+			_LOG.error("Failed to parse: {}", toParse);
 			return null;
 		}
 	}

http://git-wip-us.apache.org/repos/asf/metron/blob/ec959d20/metron-platform/metron-parsers/src/test/java/org/apache/metron/parsers/integration/components/ParserTopologyComponent.java
----------------------------------------------------------------------
diff --git a/metron-platform/metron-parsers/src/test/java/org/apache/metron/parsers/integration/components/ParserTopologyComponent.java b/metron-platform/metron-parsers/src/test/java/org/apache/metron/parsers/integration/components/ParserTopologyComponent.java
index 171ff47..3e8e2db 100644
--- a/metron-platform/metron-parsers/src/test/java/org/apache/metron/parsers/integration/components/ParserTopologyComponent.java
+++ b/metron-platform/metron-parsers/src/test/java/org/apache/metron/parsers/integration/components/ParserTopologyComponent.java
@@ -17,25 +17,28 @@
  */
 package org.apache.metron.parsers.integration.components;
 
+import static org.apache.metron.integration.components.FluxTopologyComponent.assassinateSlots;
+import static org.apache.metron.integration.components.FluxTopologyComponent.cleanupWorkerDir;
+
+import java.lang.invoke.MethodHandles;
+import java.util.HashMap;
+import java.util.Map;
+import java.util.Optional;
+import java.util.Properties;
+import org.apache.metron.integration.InMemoryComponent;
+import org.apache.metron.integration.UnableToStartException;
 import org.apache.metron.integration.components.ZKServerComponent;
+import org.apache.metron.parsers.topology.ParserTopologyBuilder;
 import org.apache.storm.Config;
 import org.apache.storm.LocalCluster;
 import org.apache.storm.generated.KillOptions;
 import org.apache.storm.topology.TopologyBuilder;
-import org.apache.metron.integration.InMemoryComponent;
-import org.apache.metron.integration.UnableToStartException;
-import org.apache.metron.parsers.topology.ParserTopologyBuilder;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
-import java.util.*;
-
-import static org.apache.metron.integration.components.FluxTopologyComponent.assassinateSlots;
-import static org.apache.metron.integration.components.FluxTopologyComponent.cleanupWorkerDir;
-
 public class ParserTopologyComponent implements InMemoryComponent {
 
-  protected static final Logger LOG = LoggerFactory.getLogger(ParserTopologyComponent.class);
+  protected static final Logger LOG = LoggerFactory.getLogger(MethodHandles.lookup().lookupClass());
   private Properties topologyProperties;
   private String brokerUrl;
   private String sensorType;

http://git-wip-us.apache.org/repos/asf/metron/blob/ec959d20/metron-platform/metron-pcap-backend/src/main/java/org/apache/metron/pcap/query/PcapCli.java
----------------------------------------------------------------------
diff --git a/metron-platform/metron-pcap-backend/src/main/java/org/apache/metron/pcap/query/PcapCli.java b/metron-platform/metron-pcap-backend/src/main/java/org/apache/metron/pcap/query/PcapCli.java
index b02e2e2..b50d488 100644
--- a/metron-platform/metron-pcap-backend/src/main/java/org/apache/metron/pcap/query/PcapCli.java
+++ b/metron-platform/metron-pcap-backend/src/main/java/org/apache/metron/pcap/query/PcapCli.java
@@ -18,6 +18,11 @@
 package org.apache.metron.pcap.query;
 
 import com.google.common.collect.Iterables;
+import java.io.IOException;
+import java.lang.invoke.MethodHandles;
+import java.util.Arrays;
+import java.util.List;
+import java.util.UUID;
 import org.apache.commons.cli.ParseException;
 import org.apache.commons.lang3.tuple.Pair;
 import org.apache.hadoop.conf.Configuration;
@@ -33,13 +38,8 @@ import org.apache.metron.pcap.mr.PcapJob;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
-import java.io.IOException;
-import java.util.Arrays;
-import java.util.List;
-import java.util.UUID;
-
 public class PcapCli {
-  private static final Logger LOGGER = LoggerFactory.getLogger(PcapCli.class);
+  private static final Logger LOGGER = LoggerFactory.getLogger(MethodHandles.lookup().lookupClass());
   public static final CliConfig.PrefixStrategy PREFIX_STRATEGY = clock -> {
     String timestamp = new Clock().currentTimeFormatted("yyyyMMddHHmm");
     String uuid = UUID.randomUUID().toString().replaceAll("-", "");
@@ -73,7 +73,7 @@ public class PcapCli {
     try {
       otherArgs = new GenericOptionsParser(hadoopConf, commandArgs).getRemainingArgs();
     } catch (IOException e) {
-      LOGGER.error("Failed to configure hadoop with provided options: " + e.getMessage(), e);
+      LOGGER.error("Failed to configure hadoop with provided options: {}", e.getMessage(), e);
       return -1;
     }
     CliConfig commonConfig = null;
@@ -109,10 +109,10 @@ public class PcapCli {
                 FileSystem.get(hadoopConf),
                 new FixedPcapFilter.Configurator());
       } catch (IOException | ClassNotFoundException e) {
-        LOGGER.error("Failed to execute fixed filter job: " + e.getMessage(), e);
+        LOGGER.error("Failed to execute fixed filter job: {}", e.getMessage(), e);
         return -1;
       } catch (InterruptedException e) {
-        LOGGER.error("Failed to execute fixed filter job: " + e.getMessage(), e);
+        LOGGER.error("Failed to execute fixed filter job: {}", e.getMessage(), e);
         return -1;
       }
     } else if ("query".equals(jobType)) {
@@ -146,10 +146,10 @@ public class PcapCli {
                 FileSystem.get(hadoopConf),
                 new QueryPcapFilter.Configurator());
       } catch (IOException | ClassNotFoundException e) {
-        LOGGER.error("Failed to execute query filter job: " + e.getMessage(), e);
+        LOGGER.error("Failed to execute query filter job: {}", e.getMessage(), e);
         return -1;
       } catch (InterruptedException e) {
-        LOGGER.error("Failed to execute query filter job: " + e.getMessage(), e);
+        LOGGER.error("Failed to execute query filter job: {}", e.getMessage(), e);
         return -1;
       }
     } else {

http://git-wip-us.apache.org/repos/asf/metron/blob/ec959d20/metron-platform/metron-pcap-backend/src/main/java/org/apache/metron/spout/pcap/HDFSWriterCallback.java
----------------------------------------------------------------------
diff --git a/metron-platform/metron-pcap-backend/src/main/java/org/apache/metron/spout/pcap/HDFSWriterCallback.java b/metron-platform/metron-pcap-backend/src/main/java/org/apache/metron/spout/pcap/HDFSWriterCallback.java
index 21d5110..04d05f1 100644
--- a/metron-platform/metron-pcap-backend/src/main/java/org/apache/metron/spout/pcap/HDFSWriterCallback.java
+++ b/metron-platform/metron-pcap-backend/src/main/java/org/apache/metron/spout/pcap/HDFSWriterCallback.java
@@ -19,6 +19,13 @@
 package org.apache.metron.spout.pcap;
 
 import com.google.common.base.Joiner;
+import java.io.IOException;
+import java.lang.invoke.MethodHandles;
+import java.util.ArrayList;
+import java.util.HashMap;
+import java.util.List;
+import java.util.Map;
+import javax.xml.bind.DatatypeConverter;
 import org.apache.metron.spout.pcap.deserializer.KeyValueDeserializer;
 import org.apache.storm.kafka.Callback;
 import org.apache.storm.kafka.EmitContext;
@@ -26,19 +33,13 @@ import org.apache.storm.kafka.spout.KafkaSpoutConfig;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
-import javax.xml.bind.DatatypeConverter;
-import java.io.IOException;
-import java.util.ArrayList;
-import java.util.HashMap;
-import java.util.List;
-import java.util.Map;
-
 /**
  * A callback which gets executed as part of the spout to write pcap data to HDFS.
  */
 public class HDFSWriterCallback implements Callback {
+
     static final long serialVersionUID = 0xDEADBEEFL;
-    private static final Logger LOG = LoggerFactory.getLogger(HDFSWriterCallback.class);
+    private static final Logger LOG = LoggerFactory.getLogger(MethodHandles.lookup().lookupClass());
 
     /**
      * A topic+partition.  We split the files up by topic+partition so the writers don't clobber each other
@@ -90,7 +91,7 @@ public class HDFSWriterCallback implements Callback {
     }
 
     public HDFSWriterCallback withConfig(HDFSWriterConfig config) {
-        LOG.info("Configured: " + config);
+        LOG.info("Configured: {}", config);
         this.config = config;
         return this;
     }
@@ -118,7 +119,7 @@ public class HDFSWriterCallback implements Callback {
             } else {
                 debugStatements.add("Value is null!");
             }
-            LOG.debug("Dropping malformed packet: " + Joiner.on(" / ").join(debugStatements));
+            LOG.debug("Dropping malformed packet: {}", Joiner.on(" / ").join(debugStatements));
         }
 
         long tsWriteStart = System.nanoTime();
@@ -132,8 +133,8 @@ public class HDFSWriterCallback implements Callback {
         }
         long tsWriteEnd = System.nanoTime();
         if(LOG.isDebugEnabled() && (Math.random() < 0.001 || !inited)) {
-            LOG.debug("Deserialize time (ns): " + (tsDeserializeEnd - tsDeserializeStart));
-            LOG.debug("Write time (ns): " + (tsWriteEnd - tsWriteStart));
+            LOG.debug("Deserialize time (ns): {}", (tsDeserializeEnd - tsDeserializeStart));
+            LOG.debug("Write time (ns): {}", (tsWriteEnd - tsWriteStart));
         }
         inited = true;
         return tuple;

http://git-wip-us.apache.org/repos/asf/metron/blob/ec959d20/metron-platform/metron-pcap-backend/src/main/java/org/apache/metron/spout/pcap/PartitionHDFSWriter.java
----------------------------------------------------------------------
diff --git a/metron-platform/metron-pcap-backend/src/main/java/org/apache/metron/spout/pcap/PartitionHDFSWriter.java b/metron-platform/metron-pcap-backend/src/main/java/org/apache/metron/spout/pcap/PartitionHDFSWriter.java
index ebd60dc..384cdaa 100644
--- a/metron-platform/metron-pcap-backend/src/main/java/org/apache/metron/spout/pcap/PartitionHDFSWriter.java
+++ b/metron-platform/metron-pcap-backend/src/main/java/org/apache/metron/spout/pcap/PartitionHDFSWriter.java
@@ -18,6 +18,13 @@
 
 package org.apache.metron.spout.pcap;
 
+import java.io.File;
+import java.io.FileOutputStream;
+import java.io.IOException;
+import java.io.Serializable;
+import java.lang.invoke.MethodHandles;
+import java.util.EnumSet;
+import java.util.Map;
 import org.apache.hadoop.conf.Configuration;
 import org.apache.hadoop.fs.FSDataOutputStream;
 import org.apache.hadoop.fs.FileSystem;
@@ -31,19 +38,12 @@ import org.apache.metron.pcap.PcapHelper;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
-import java.io.File;
-import java.io.FileOutputStream;
-import java.io.IOException;
-import java.io.Serializable;
-import java.util.EnumSet;
-import java.util.Map;
-
 /**
  * This class is intended to handle the writing of an individual file.
  */
 public class PartitionHDFSWriter implements AutoCloseable, Serializable {
   static final long serialVersionUID = 0xDEADBEEFL;
-  private static final Logger LOG = LoggerFactory.getLogger(PartitionHDFSWriter.class);
+  private static final Logger LOG = LoggerFactory.getLogger(MethodHandles.lookup().lookupClass());
 
 
   public static interface SyncHandler {
@@ -95,7 +95,7 @@ public class PartitionHDFSWriter implements AutoCloseable, Serializable {
         func.sync(input);
       }
       catch(IOException ioe) {
-        LOG.warn("Problems during sync, but this shouldn't be too concerning as long as it's intermittent: " + ioe.getMessage(), ioe);
+        LOG.warn("Problems during sync, but this shouldn't be too concerning as long as it's intermittent: {}", ioe.getMessage(), ioe);
       }
     }
   }
@@ -165,7 +165,7 @@ public class PartitionHDFSWriter implements AutoCloseable, Serializable {
     }
     catch(ArrayIndexOutOfBoundsException aioobe) {
       LOG.warn("This appears to be HDFS-7765 (https://issues.apache.org/jira/browse/HDFS-7765), " +
-              "which is an issue with syncing and not problematic: " + aioobe.getMessage(), aioobe);
+              "which is an issue with syncing and not problematic: {}", aioobe.getMessage(), aioobe);
     }
     numWritten++;
     if(numWritten % config.getSyncEvery() == 0) {

http://git-wip-us.apache.org/repos/asf/metron/blob/ec959d20/metron-platform/metron-pcap-backend/src/main/java/org/apache/metron/spout/pcap/deserializer/FromKeyDeserializer.java
----------------------------------------------------------------------
diff --git a/metron-platform/metron-pcap-backend/src/main/java/org/apache/metron/spout/pcap/deserializer/FromKeyDeserializer.java b/metron-platform/metron-pcap-backend/src/main/java/org/apache/metron/spout/pcap/deserializer/FromKeyDeserializer.java
index 749d74c..c1a6d5a 100644
--- a/metron-platform/metron-pcap-backend/src/main/java/org/apache/metron/spout/pcap/deserializer/FromKeyDeserializer.java
+++ b/metron-platform/metron-pcap-backend/src/main/java/org/apache/metron/spout/pcap/deserializer/FromKeyDeserializer.java
@@ -18,6 +18,7 @@
 
 package org.apache.metron.spout.pcap.deserializer;
 
+import java.lang.invoke.MethodHandles;
 import org.apache.metron.common.utils.timestamp.TimestampConverter;
 import org.apache.metron.pcap.PcapHelper;
 import org.apache.metron.spout.pcap.Endianness;
@@ -29,7 +30,7 @@ import org.slf4j.LoggerFactory;
  * Extract the timestamp from the key and raw data from the packet.
  */
 public class FromKeyDeserializer extends KeyValueDeserializer {
-  private static final Logger LOG = LoggerFactory.getLogger(FromKeyDeserializer.class);
+  private static final Logger LOG = LoggerFactory.getLogger(MethodHandles.lookup().lookupClass());
   private static Endianness endianness = Endianness.getNativeEndianness();
 
 

http://git-wip-us.apache.org/repos/asf/metron/blob/ec959d20/metron-platform/metron-pcap-backend/src/main/java/org/apache/metron/spout/pcap/deserializer/FromPacketDeserializer.java
----------------------------------------------------------------------
diff --git a/metron-platform/metron-pcap-backend/src/main/java/org/apache/metron/spout/pcap/deserializer/FromPacketDeserializer.java b/metron-platform/metron-pcap-backend/src/main/java/org/apache/metron/spout/pcap/deserializer/FromPacketDeserializer.java
index 0ba92f8..668733a 100644
--- a/metron-platform/metron-pcap-backend/src/main/java/org/apache/metron/spout/pcap/deserializer/FromPacketDeserializer.java
+++ b/metron-platform/metron-pcap-backend/src/main/java/org/apache/metron/spout/pcap/deserializer/FromPacketDeserializer.java
@@ -18,6 +18,7 @@
 
 package org.apache.metron.spout.pcap.deserializer;
 
+import java.lang.invoke.MethodHandles;
 import org.apache.metron.pcap.PcapHelper;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
@@ -26,7 +27,7 @@ import org.slf4j.LoggerFactory;
  * Extract the timestamp and raw data from the packet.
  */
 public class FromPacketDeserializer extends KeyValueDeserializer {
-  private static final Logger LOG = LoggerFactory.getLogger(FromPacketDeserializer.class);
+  private static final Logger LOG = LoggerFactory.getLogger(MethodHandles.lookup().lookupClass());
 
   @Override
   public Result deserializeKeyValue(byte[] key, byte[] value) {

http://git-wip-us.apache.org/repos/asf/metron/blob/ec959d20/metron-platform/metron-pcap/src/main/java/org/apache/metron/pcap/PacketInfo.java
----------------------------------------------------------------------
diff --git a/metron-platform/metron-pcap/src/main/java/org/apache/metron/pcap/PacketInfo.java b/metron-platform/metron-pcap/src/main/java/org/apache/metron/pcap/PacketInfo.java
index f3a7e25..9dbb771 100644
--- a/metron-platform/metron-pcap/src/main/java/org/apache/metron/pcap/PacketInfo.java
+++ b/metron-platform/metron-pcap/src/main/java/org/apache/metron/pcap/PacketInfo.java
@@ -17,17 +17,17 @@
  */
 package org.apache.metron.pcap;
 
+import java.lang.invoke.MethodHandles;
 import java.text.MessageFormat;
-import org.apache.log4j.Logger;
-
+import org.apache.metron.pcap.utils.PcapUtils;
 import org.krakenapps.pcap.decoder.ip.Ipv4Packet;
 import org.krakenapps.pcap.decoder.tcp.TcpPacket;
 import org.krakenapps.pcap.decoder.udp.UdpPacket;
 import org.krakenapps.pcap.file.GlobalHeader;
 import org.krakenapps.pcap.packet.PacketHeader;
 import org.krakenapps.pcap.packet.PcapPacket;
-
-import org.apache.metron.pcap.utils.PcapUtils;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
 
 /**
  * The Class PacketInfo.
@@ -36,6 +36,7 @@ import org.apache.metron.pcap.utils.PcapUtils;
  * @version $Revision: 1.0 $
  */
 public class PacketInfo {
+  private static final Logger LOG = LoggerFactory.getLogger(MethodHandles.lookup().lookupClass());
 
   /** The packet data */
   private byte[] packetBytes = null;
@@ -70,9 +71,6 @@ public class PacketInfo {
   /** The Constant udpHeaderJsonTemplateSB. */
   private static final StringBuffer udpHeaderJsonTemplateSB = new StringBuffer();
 
-  /** The Constant LOG. */
-  private static final Logger LOG = Logger.getLogger(PacketInfo.class);
-  
   static {
     globalHeaderJsonTemplateSB.append("<\"global_header\":<\"pcap_id\":\"").append("{0}").append('"');
     globalHeaderJsonTemplateSB.append(",\"inc_len\":").append("{1}");

http://git-wip-us.apache.org/repos/asf/metron/blob/ec959d20/metron-platform/metron-pcap/src/main/java/org/apache/metron/pcap/PcapByteOutputStream.java
----------------------------------------------------------------------
diff --git a/metron-platform/metron-pcap/src/main/java/org/apache/metron/pcap/PcapByteOutputStream.java b/metron-platform/metron-pcap/src/main/java/org/apache/metron/pcap/PcapByteOutputStream.java
index be2240d..8c12124 100644
--- a/metron-platform/metron-pcap/src/main/java/org/apache/metron/pcap/PcapByteOutputStream.java
+++ b/metron-platform/metron-pcap/src/main/java/org/apache/metron/pcap/PcapByteOutputStream.java
@@ -20,16 +20,17 @@ package org.apache.metron.pcap;
 
 import java.io.ByteArrayOutputStream;
 import java.io.IOException;
+import java.lang.invoke.MethodHandles;
 import java.nio.BufferUnderflowException;
 import java.util.ArrayList;
 import java.util.List;
-
-import org.apache.log4j.Logger;
 import org.krakenapps.pcap.PcapOutputStream;
 import org.krakenapps.pcap.file.GlobalHeader;
 import org.krakenapps.pcap.packet.PacketHeader;
 import org.krakenapps.pcap.packet.PcapPacket;
 import org.krakenapps.pcap.util.Buffer;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
 
 // TODO: Auto-generated Javadoc
 /**
@@ -39,10 +40,7 @@ import org.krakenapps.pcap.util.Buffer;
  * @version $Revision: 1.0 $
  */
 public class PcapByteOutputStream implements PcapOutputStream {
-
-  /** The Constant LOG. */
-  private static final Logger LOG = Logger
-      .getLogger(PcapByteOutputStream.class);
+  private static final Logger LOG = LoggerFactory.getLogger(MethodHandles.lookup().lookupClass());
 
   /** The Constant MAX_CACHED_PACKET_NUMBER. */
   private static final int MAX_CACHED_PACKET_NUMBER = 1000;

http://git-wip-us.apache.org/repos/asf/metron/blob/ec959d20/metron-platform/metron-pcap/src/main/java/org/apache/metron/pcap/PcapHelper.java
----------------------------------------------------------------------
diff --git a/metron-platform/metron-pcap/src/main/java/org/apache/metron/pcap/PcapHelper.java b/metron-platform/metron-pcap/src/main/java/org/apache/metron/pcap/PcapHelper.java
index bb7d9f0..1ebdf7c 100644
--- a/metron-platform/metron-pcap/src/main/java/org/apache/metron/pcap/PcapHelper.java
+++ b/metron-platform/metron-pcap/src/main/java/org/apache/metron/pcap/PcapHelper.java
@@ -21,12 +21,12 @@ package org.apache.metron.pcap;
 import com.google.common.base.Joiner;
 import java.io.EOFException;
 import java.io.IOException;
+import java.lang.invoke.MethodHandles;
 import java.util.ArrayList;
 import java.util.HashMap;
 import java.util.List;
 import java.util.Map;
 import org.apache.hadoop.hbase.util.Bytes;
-import org.apache.log4j.Logger;
 import org.apache.metron.spout.pcap.Endianness;
 import org.json.simple.JSONObject;
 import org.json.simple.JSONValue;
@@ -40,12 +40,14 @@ import org.krakenapps.pcap.packet.PacketHeader;
 import org.krakenapps.pcap.packet.PcapPacket;
 import org.krakenapps.pcap.util.Buffer;
 import org.krakenapps.pcap.util.ByteOrderConverter;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
 
 public class PcapHelper {
+  private static final Logger LOG = LoggerFactory.getLogger(MethodHandles.lookup().lookupClass());
 
   public static final int PACKET_HEADER_SIZE = 4*Integer.BYTES;
   public static final int GLOBAL_HEADER_SIZE = 24;
-  private static final Logger LOG = Logger.getLogger(PcapHelper.class);
 
   public enum PacketFields implements org.apache.metron.common.Constants.Field{
     PACKET_DATA("packet"),

http://git-wip-us.apache.org/repos/asf/metron/blob/ec959d20/metron-platform/metron-pcap/src/main/java/org/apache/metron/pcap/PcapMerger.java
----------------------------------------------------------------------
diff --git a/metron-platform/metron-pcap/src/main/java/org/apache/metron/pcap/PcapMerger.java b/metron-platform/metron-pcap/src/main/java/org/apache/metron/pcap/PcapMerger.java
index 48d25c7..5e360e8 100644
--- a/metron-platform/metron-pcap/src/main/java/org/apache/metron/pcap/PcapMerger.java
+++ b/metron-platform/metron-pcap/src/main/java/org/apache/metron/pcap/PcapMerger.java
@@ -21,16 +21,15 @@ import java.io.ByteArrayOutputStream;
 import java.io.EOFException;
 import java.io.File;
 import java.io.IOException;
+import java.lang.invoke.MethodHandles;
 import java.util.ArrayList;
 import java.util.Arrays;
 import java.util.Collections;
 import java.util.List;
-
 import org.apache.commons.io.FileUtils;
-import org.apache.log4j.Logger;
-
 import org.krakenapps.pcap.packet.PcapPacket;
-import org.krakenapps.pcap.file.GlobalHeader;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
 
 // TODO: Auto-generated Javadoc
 /**
@@ -40,9 +39,7 @@ import org.krakenapps.pcap.file.GlobalHeader;
  * @version $Revision: 1.0 $
  */
 public final class PcapMerger {
-
-  /** The Constant LOG. */
-  private static final Logger LOG = Logger.getLogger(PcapMerger.class);
+  private static final Logger LOG = LoggerFactory.getLogger(MethodHandles.lookup().lookupClass());
   
   /** The comparator for PcapPackets */
   private static PcapPacketComparator PCAP_PACKET_COMPARATOR = new PcapPacketComparator();
@@ -156,7 +153,7 @@ public final class PcapMerger {
 			  if (packet == null)
 				  break;
 			  packetList.add(packet);
-			  LOG.debug("Presort packet: " + packet.getPacketHeader().toString());
+			  LOG.debug("Presort packet: {}", packet.getPacketHeader().toString());
 		  }
 	  } catch (EOFException e) {
 		  //LOG.debug("Ignoreable exception in sort", e);
@@ -165,7 +162,7 @@ public final class PcapMerger {
 	  Collections.sort(packetList, PCAP_PACKET_COMPARATOR);
 	  for (PcapPacket p : packetList) {
 		  pcapOs.write(p);
-		  LOG.debug("Postsort packet: " + p.getPacketHeader().toString());
+		  LOG.debug("Postsort packet: {}", p.getPacketHeader().toString());
 	  }
 	  pcapOs.close();  
   }

http://git-wip-us.apache.org/repos/asf/metron/blob/ec959d20/metron-platform/metron-pcap/src/main/java/org/apache/metron/pcap/PcapPacketComparator.java
----------------------------------------------------------------------
diff --git a/metron-platform/metron-pcap/src/main/java/org/apache/metron/pcap/PcapPacketComparator.java b/metron-platform/metron-pcap/src/main/java/org/apache/metron/pcap/PcapPacketComparator.java
index 0e947ff..fc4d41e 100644
--- a/metron-platform/metron-pcap/src/main/java/org/apache/metron/pcap/PcapPacketComparator.java
+++ b/metron-platform/metron-pcap/src/main/java/org/apache/metron/pcap/PcapPacketComparator.java
@@ -17,22 +17,20 @@
  */
 package org.apache.metron.pcap;
 
+import java.lang.invoke.MethodHandles;
 import java.util.Comparator;
-
-import org.apache.log4j.Logger;
-
 import org.krakenapps.pcap.packet.PcapPacket;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
 
 public class PcapPacketComparator implements Comparator<PcapPacket> {
-
-  /** The Constant LOG. */
-  private static final Logger LOG = Logger.getLogger(PcapPacketComparator.class);
+  private static final Logger LOG = LoggerFactory.getLogger(MethodHandles.lookup().lookupClass());
 
   @Override
   public int compare(PcapPacket p1, PcapPacket p2) {
     long p1time = p1.getPacketHeader().getTsSec() * 1000000L + p1.getPacketHeader().getTsUsec();
     long p2time = p2.getPacketHeader().getTsSec() * 1000000L + p2.getPacketHeader().getTsUsec();
-    LOG.debug("p1time: " + p1time + " p2time: " + p2time);
+    LOG.debug("p1time: {} p2time: {}", p1time, p2time);
     return Long.compare(p1time, p2time);
   }
 }

http://git-wip-us.apache.org/repos/asf/metron/blob/ec959d20/metron-platform/metron-pcap/src/main/java/org/apache/metron/pcap/mr/PcapJob.java
----------------------------------------------------------------------
diff --git a/metron-platform/metron-pcap/src/main/java/org/apache/metron/pcap/mr/PcapJob.java b/metron-platform/metron-pcap/src/main/java/org/apache/metron/pcap/mr/PcapJob.java
index 62f9844..14ea3cb 100644
--- a/metron-platform/metron-pcap/src/main/java/org/apache/metron/pcap/mr/PcapJob.java
+++ b/metron-platform/metron-pcap/src/main/java/org/apache/metron/pcap/mr/PcapJob.java
@@ -23,6 +23,7 @@ import static org.apache.metron.pcap.PcapHelper.lessThanOrEqualTo;
 
 import com.google.common.base.Joiner;
 import java.io.IOException;
+import java.lang.invoke.MethodHandles;
 import java.text.DateFormat;
 import java.text.SimpleDateFormat;
 import java.util.ArrayList;
@@ -58,7 +59,7 @@ import org.slf4j.LoggerFactory;
 
 public class PcapJob {
 
-  private static final Logger LOG = LoggerFactory.getLogger(PcapJob.class);
+  private static final Logger LOG = LoggerFactory.getLogger(MethodHandles.lookup().lookupClass());
   public static final String START_TS_CONF = "start_ts";
   public static final String END_TS_CONF = "end_ts";
   public static final String WIDTH_CONF = "width";
@@ -189,7 +190,7 @@ public class PcapJob {
                                                               );
       String from = format.format(new Date(Long.divideUnsigned(beginNS, 1000000)));
       String to = format.format(new Date(Long.divideUnsigned(endNS, 1000000)));
-      LOG.debug("Executing query " + filterImpl.queryToString(fields) + " on timerange " + from + " to " + to);
+      LOG.debug("Executing query {} on timerange from {} to {}", filterImpl.queryToString(fields), from, to);
     }
     Path outputPath =  new Path(baseOutputPath, fileName);
     Job job = createJob( basePath

http://git-wip-us.apache.org/repos/asf/metron/blob/ec959d20/metron-platform/metron-pcap/src/main/java/org/apache/metron/pcap/utils/FileFilterUtil.java
----------------------------------------------------------------------
diff --git a/metron-platform/metron-pcap/src/main/java/org/apache/metron/pcap/utils/FileFilterUtil.java b/metron-platform/metron-pcap/src/main/java/org/apache/metron/pcap/utils/FileFilterUtil.java
index bbbc4bb..2bfebcc 100644
--- a/metron-platform/metron-pcap/src/main/java/org/apache/metron/pcap/utils/FileFilterUtil.java
+++ b/metron-platform/metron-pcap/src/main/java/org/apache/metron/pcap/utils/FileFilterUtil.java
@@ -22,6 +22,7 @@ import static org.apache.metron.pcap.PcapHelper.greaterThanOrEqualTo;
 import static org.apache.metron.pcap.PcapHelper.lessThanOrEqualTo;
 
 import com.google.common.base.Joiner;
+import java.lang.invoke.MethodHandles;
 import java.util.ArrayList;
 import java.util.Collections;
 import java.util.HashMap;
@@ -35,7 +36,7 @@ import org.slf4j.LoggerFactory;
 
 public class FileFilterUtil {
 
-  private static final Logger LOG = LoggerFactory.getLogger(FileFilterUtil.class);
+  private static final Logger LOG = LoggerFactory.getLogger(MethodHandles.lookup().lookupClass());
 
   private FileFilterUtil() {
   }
@@ -49,7 +50,7 @@ public class FileFilterUtil {
     Map<Integer, List<Path>> filesByPartition = getFilesByPartition(files);
     List<String> filteredFiles = filterByTimestampLT(beginTs, endTs, filesByPartition);
     if (LOG.isDebugEnabled()) {
-      LOG.debug("Including files " + Joiner.on(",").join(filteredFiles));
+      LOG.debug("Including files {}", Joiner.on(",").join(filteredFiles));
     }
     return filteredFiles;
   }

http://git-wip-us.apache.org/repos/asf/metron/blob/ec959d20/metron-platform/metron-storm-kafka/src/main/java/org/apache/metron/storm/kafka/flux/StormKafkaSpout.java
----------------------------------------------------------------------
diff --git a/metron-platform/metron-storm-kafka/src/main/java/org/apache/metron/storm/kafka/flux/StormKafkaSpout.java b/metron-platform/metron-storm-kafka/src/main/java/org/apache/metron/storm/kafka/flux/StormKafkaSpout.java
index 8c66a92..9bbcf87 100644
--- a/metron-platform/metron-storm-kafka/src/main/java/org/apache/metron/storm/kafka/flux/StormKafkaSpout.java
+++ b/metron-platform/metron-storm-kafka/src/main/java/org/apache/metron/storm/kafka/flux/StormKafkaSpout.java
@@ -18,13 +18,13 @@
 
 package org.apache.metron.storm.kafka.flux;
 
-import java.util.Arrays;
-import java.util.Date;
+import java.lang.invoke.MethodHandles;
 import java.util.concurrent.atomic.AtomicBoolean;
 import org.apache.kafka.common.errors.WakeupException;
-import org.apache.log4j.Logger;
 import org.apache.storm.kafka.spout.KafkaSpout;
 import org.apache.storm.kafka.spout.KafkaSpoutConfig;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
 
 /**
  * A thin wrapper atop the KafkaSpout to allow us to pass in the Builder rather than the SpoutConfig.
@@ -33,7 +33,7 @@ import org.apache.storm.kafka.spout.KafkaSpoutConfig;
  * @param <V>
  */
 public class StormKafkaSpout<K, V> extends KafkaSpout<K, V> {
-  private static final Logger LOG = Logger.getLogger(StormKafkaSpout.class);
+  private static final Logger LOG = LoggerFactory.getLogger(MethodHandles.lookup().lookupClass());
   protected KafkaSpoutConfig<K,V> _spoutConfig;
   protected AtomicBoolean isShutdown = new AtomicBoolean(false);
 
@@ -49,7 +49,7 @@ public class StormKafkaSpout<K, V> extends KafkaSpout<K, V> {
     }
     catch(WakeupException we) {
       //see https://issues.apache.org/jira/browse/STORM-2184
-      LOG.warn("You can generally ignore these, as per https://issues.apache.org/jira/browse/STORM-2184 -- " + we.getMessage(), we);
+      LOG.warn("You can generally ignore these, as per https://issues.apache.org/jira/browse/STORM-2184 -- {}", we.getMessage(), we);
     }
     finally {
       isShutdown.set(true);
@@ -66,7 +66,7 @@ public class StormKafkaSpout<K, V> extends KafkaSpout<K, V> {
     }
     catch(WakeupException we) {
       //see https://issues.apache.org/jira/browse/STORM-2184
-      LOG.warn("You can generally ignore these, as per https://issues.apache.org/jira/browse/STORM-2184 -- " + we.getMessage(), we);
+      LOG.warn("You can generally ignore these, as per https://issues.apache.org/jira/browse/STORM-2184 -- {}", we.getMessage(), we);
     }
     catch(IllegalStateException ise) {
       if(ise.getMessage().contains("This consumer has already been closed")) {

http://git-wip-us.apache.org/repos/asf/metron/blob/ec959d20/metron-platform/metron-writer/src/main/java/org/apache/metron/writer/BulkWriterComponent.java
----------------------------------------------------------------------
diff --git a/metron-platform/metron-writer/src/main/java/org/apache/metron/writer/BulkWriterComponent.java b/metron-platform/metron-writer/src/main/java/org/apache/metron/writer/BulkWriterComponent.java
index 54a758b..df6ee90 100644
--- a/metron-platform/metron-writer/src/main/java/org/apache/metron/writer/BulkWriterComponent.java
+++ b/metron-platform/metron-writer/src/main/java/org/apache/metron/writer/BulkWriterComponent.java
@@ -60,7 +60,7 @@ public class BulkWriterComponent<MESSAGE_T> {
   public void commit(Iterable<Tuple> tuples) {
     tuples.forEach(t -> collector.ack(t));
     if(LOG.isDebugEnabled()) {
-      LOG.debug("Acking " + Iterables.size(tuples) + " tuples");
+      LOG.debug("Acking {} tuples", Iterables.size(tuples));
     }
   }
 
@@ -75,7 +75,7 @@ public class BulkWriterComponent<MESSAGE_T> {
             .withErrorType(Constants.ErrorType.INDEXING_ERROR)
             .withThrowable(e);
     if(!Iterables.isEmpty(tuples)) {
-      LOG.error("Failing " + Iterables.size(tuples) + " tuples", e);
+      LOG.error("Failing {} tuples", Iterables.size(tuples), e);
     }
     tuples.forEach(t -> error.addRawMessage(messageGetStrategy.get(t)));
     ErrorUtils.handleError(collector, error);
@@ -162,7 +162,7 @@ public class BulkWriterComponent<MESSAGE_T> {
       }
       long endTime = System.nanoTime();
       long elapsed = endTime - startTime;
-      LOG.debug("Bulk batch completed in ~" + elapsed + " ns");
+      LOG.debug("Bulk batch completed in ~{} ns", elapsed);
     }
   }
 }

http://git-wip-us.apache.org/repos/asf/metron/blob/ec959d20/metron-platform/metron-writer/src/main/java/org/apache/metron/writer/hdfs/SourceAwareMoveAction.java
----------------------------------------------------------------------
diff --git a/metron-platform/metron-writer/src/main/java/org/apache/metron/writer/hdfs/SourceAwareMoveAction.java b/metron-platform/metron-writer/src/main/java/org/apache/metron/writer/hdfs/SourceAwareMoveAction.java
index 7a6f2b5..1c55ffa 100644
--- a/metron-platform/metron-writer/src/main/java/org/apache/metron/writer/hdfs/SourceAwareMoveAction.java
+++ b/metron-platform/metron-writer/src/main/java/org/apache/metron/writer/hdfs/SourceAwareMoveAction.java
@@ -18,15 +18,16 @@
 
 package org.apache.metron.writer.hdfs;
 
+import java.io.IOException;
+import java.lang.invoke.MethodHandles;
 import org.apache.hadoop.fs.FileSystem;
 import org.apache.hadoop.fs.Path;
-import org.apache.log4j.Logger;
 import org.apache.storm.hdfs.common.rotation.RotationAction;
-
-import java.io.IOException;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
 
 public class SourceAwareMoveAction implements RotationAction{
-  private static final Logger LOG = Logger.getLogger(SourceAwareMoveAction.class);
+  private static final Logger LOG = LoggerFactory.getLogger(MethodHandles.lookup().lookupClass());
   private String destination;
 
   public SourceAwareMoveAction toDestination(String destDir){
@@ -41,7 +42,7 @@ public class SourceAwareMoveAction implements RotationAction{
   @Override
   public void execute(FileSystem fileSystem, Path filePath) throws IOException {
     Path destPath = new Path(new Path(destination, getSource(filePath)), filePath.getName());
-    LOG.info("Moving file " + filePath + " to " + destPath);
+    LOG.info("Moving file {} to {}", filePath, destPath);
     boolean success = fileSystem.rename(filePath, destPath);
   }
 }

http://git-wip-us.apache.org/repos/asf/metron/blob/ec959d20/metron-platform/metron-writer/src/main/java/org/apache/metron/writer/hdfs/SourceHandler.java
----------------------------------------------------------------------
diff --git a/metron-platform/metron-writer/src/main/java/org/apache/metron/writer/hdfs/SourceHandler.java b/metron-platform/metron-writer/src/main/java/org/apache/metron/writer/hdfs/SourceHandler.java
index d895465..fbb5561 100644
--- a/metron-platform/metron-writer/src/main/java/org/apache/metron/writer/hdfs/SourceHandler.java
+++ b/metron-platform/metron-writer/src/main/java/org/apache/metron/writer/hdfs/SourceHandler.java
@@ -18,28 +18,31 @@
 
 package org.apache.metron.writer.hdfs;
 
+import java.io.FileOutputStream;
+import java.io.IOException;
+import java.lang.invoke.MethodHandles;
+import java.util.ArrayList;
+import java.util.EnumSet;
+import java.util.List;
+import java.util.Timer;
+import java.util.TimerTask;
 import org.apache.hadoop.conf.Configuration;
 import org.apache.hadoop.fs.FSDataOutputStream;
 import org.apache.hadoop.fs.FileSystem;
 import org.apache.hadoop.fs.Path;
 import org.apache.hadoop.hdfs.client.HdfsDataOutputStream;
-import org.apache.log4j.Logger;
 import org.apache.metron.common.configuration.writer.WriterConfiguration;
 import org.apache.storm.hdfs.bolt.format.FileNameFormat;
 import org.apache.storm.hdfs.bolt.rotation.FileRotationPolicy;
 import org.apache.storm.hdfs.bolt.rotation.TimedRotationPolicy;
-import org.apache.storm.hdfs.bolt.sync.CountSyncPolicy;
 import org.apache.storm.hdfs.bolt.sync.SyncPolicy;
 import org.apache.storm.hdfs.common.rotation.RotationAction;
 import org.json.simple.JSONObject;
-
-import java.io.FileOutputStream;
-import java.io.IOException;
-import java.util.*;
-import java.util.function.Function;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
 
 public class SourceHandler {
-  private static final Logger LOG = Logger.getLogger(SourceHandler.class);
+  private static final Logger LOG = LoggerFactory.getLogger(MethodHandles.lookup().lookupClass());
   List<RotationAction> rotationActions = new ArrayList<>();
   FileRotationPolicy rotationPolicy;
   SyncPolicy syncPolicy;
@@ -120,14 +123,14 @@ public class SourceHandler {
       this.rotation++;
 
       Path newFile = createOutputFile();
-      LOG.info("Performing " +  this.rotationActions.size() + " file rotation actions." );
+      LOG.info("Performing {} file rotation actions.", this.rotationActions.size());
       for (RotationAction action : this.rotationActions) {
         action.execute(this.fs, this.currentFile);
       }
       this.currentFile = newFile;
     }
     long time = System.currentTimeMillis() - start;
-    LOG.info("File rotation took " + time + " ms.");
+    LOG.info("File rotation took {} ms", time);
   }
 
   private Path createOutputFile() throws IOException {

http://git-wip-us.apache.org/repos/asf/metron/blob/ec959d20/metron-stellar/stellar-common/src/main/java/org/apache/metron/stellar/common/utils/VFSClassloaderUtil.java
----------------------------------------------------------------------
diff --git a/metron-stellar/stellar-common/src/main/java/org/apache/metron/stellar/common/utils/VFSClassloaderUtil.java b/metron-stellar/stellar-common/src/main/java/org/apache/metron/stellar/common/utils/VFSClassloaderUtil.java
index b70df11..6916e8f 100644
--- a/metron-stellar/stellar-common/src/main/java/org/apache/metron/stellar/common/utils/VFSClassloaderUtil.java
+++ b/metron-stellar/stellar-common/src/main/java/org/apache/metron/stellar/common/utils/VFSClassloaderUtil.java
@@ -17,8 +17,16 @@
  */
 package org.apache.metron.stellar.common.utils;
 
+import java.io.File;
+import java.lang.invoke.MethodHandles;
+import java.util.ArrayList;
+import java.util.Optional;
 import org.apache.accumulo.start.classloader.vfs.UniqueFileReplicator;
-import org.apache.commons.vfs2.*;
+import org.apache.commons.vfs2.CacheStrategy;
+import org.apache.commons.vfs2.FileObject;
+import org.apache.commons.vfs2.FileSystemException;
+import org.apache.commons.vfs2.FileSystemManager;
+import org.apache.commons.vfs2.FileType;
 import org.apache.commons.vfs2.cache.SoftRefFilesCache;
 import org.apache.commons.vfs2.impl.DefaultFileSystemManager;
 import org.apache.commons.vfs2.impl.FileContentInfoFilenameFactory;
@@ -27,11 +35,8 @@ import org.apache.commons.vfs2.provider.hdfs.HdfsFileProvider;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
-import java.io.File;
-import java.util.*;
-
 public class VFSClassloaderUtil {
-  private static final Logger LOG = LoggerFactory.getLogger(VFSClassloaderUtil.class);
+  private static final Logger LOG = LoggerFactory.getLogger(MethodHandles.lookup().lookupClass());
 
   /**
    * Create a FileSystem manager suitable for our purposes.
@@ -155,11 +160,11 @@ public class VFSClassloaderUtil {
               }
             }
           } else {
-            LOG.warn("ignoring classpath entry " + fo);
+            LOG.warn("ignoring classpath entry {}", fo);
           }
           break;
         default:
-          LOG.warn("ignoring classpath entry " + fo);
+          LOG.warn("ignoring classpath entry {}", fo);
           break;
       }
     }

http://git-wip-us.apache.org/repos/asf/metron/blob/ec959d20/metron-stellar/stellar-common/src/main/java/org/apache/metron/stellar/dsl/functions/resolver/BaseFunctionResolver.java
----------------------------------------------------------------------
diff --git a/metron-stellar/stellar-common/src/main/java/org/apache/metron/stellar/dsl/functions/resolver/BaseFunctionResolver.java b/metron-stellar/stellar-common/src/main/java/org/apache/metron/stellar/dsl/functions/resolver/BaseFunctionResolver.java
index a2a6721..aeed9d9 100644
--- a/metron-stellar/stellar-common/src/main/java/org/apache/metron/stellar/dsl/functions/resolver/BaseFunctionResolver.java
+++ b/metron-stellar/stellar-common/src/main/java/org/apache/metron/stellar/dsl/functions/resolver/BaseFunctionResolver.java
@@ -18,9 +18,17 @@
 
 package org.apache.metron.stellar.dsl.functions.resolver;
 
+import static java.lang.String.format;
+
 import com.google.common.base.Joiner;
 import com.google.common.base.Supplier;
 import com.google.common.base.Suppliers;
+import java.io.Serializable;
+import java.lang.invoke.MethodHandles;
+import java.util.Arrays;
+import java.util.HashMap;
+import java.util.Map;
+import java.util.Set;
 import org.apache.commons.lang.ObjectUtils;
 import org.apache.metron.stellar.dsl.Context;
 import org.apache.metron.stellar.dsl.Stellar;
@@ -29,14 +37,6 @@ import org.apache.metron.stellar.dsl.StellarFunctionInfo;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
-import java.io.Serializable;
-import java.util.Arrays;
-import java.util.HashMap;
-import java.util.Map;
-import java.util.Set;
-
-import static java.lang.String.format;
-
 /**
  * The base implementation of a function resolver that provides a means for lazy
  * initialization, thread-safety, and a mechanism for function resolution.
@@ -46,7 +46,7 @@ import static java.lang.String.format;
  */
 public abstract class BaseFunctionResolver implements FunctionResolver, Serializable {
 
-  protected static final Logger LOG = LoggerFactory.getLogger(BaseFunctionResolver.class);
+  protected static final Logger LOG = LoggerFactory.getLogger(MethodHandles.lookup().lookupClass());
 
   /**
    * Maps a function name to the metadata necessary to execute the Stellar function.
@@ -122,9 +122,8 @@ public abstract class BaseFunctionResolver implements FunctionResolver, Serializ
         // check for duplicate function names
         StellarFunctionInfo fnSameName = functions.get(fn.getName());
         if (fnSameName != null && ObjectUtils.notEqual(fnSameName, fn)) {
-          LOG.warn(format(
-                  "Namespace conflict: duplicate function names; `%s` implemented by [%s, %s]",
-                  fn.getName(), fnSameName.getFunction(), fn.getFunction()));
+          LOG.warn("Namespace conflict: duplicate function names; `{}` implemented by [{}, {}]",
+              fn.getName(), fnSameName.getFunction(), fn.getFunction());
         }
 
         functions.put(fn.getName(), fn);
@@ -195,7 +194,7 @@ public abstract class BaseFunctionResolver implements FunctionResolver, Serializ
       return clazz.getConstructor().newInstance();
 
     } catch (Exception e) {
-      LOG.error("Unable to load " + clazz.getName() + " because " + e.getMessage(), e);
+      LOG.error("Unable to load {} because {}", clazz.getName(), e.getMessage(), e);
       return null;
     }
   }

http://git-wip-us.apache.org/repos/asf/metron/blob/ec959d20/metron-stellar/stellar-common/src/main/java/org/apache/metron/stellar/dsl/functions/resolver/ClasspathFunctionResolver.java
----------------------------------------------------------------------
diff --git a/metron-stellar/stellar-common/src/main/java/org/apache/metron/stellar/dsl/functions/resolver/ClasspathFunctionResolver.java b/metron-stellar/stellar-common/src/main/java/org/apache/metron/stellar/dsl/functions/resolver/ClasspathFunctionResolver.java
index a74aa4c..70f3bc4 100644
--- a/metron-stellar/stellar-common/src/main/java/org/apache/metron/stellar/dsl/functions/resolver/ClasspathFunctionResolver.java
+++ b/metron-stellar/stellar-common/src/main/java/org/apache/metron/stellar/dsl/functions/resolver/ClasspathFunctionResolver.java
@@ -18,24 +18,29 @@
 
 package org.apache.metron.stellar.dsl.functions.resolver;
 
+import static org.apache.metron.stellar.dsl.Context.Capabilities.STELLAR_CONFIG;
+import static org.apache.metron.stellar.dsl.functions.resolver.ClasspathFunctionResolver.Config.STELLAR_SEARCH_EXCLUDES_KEY;
+import static org.apache.metron.stellar.dsl.functions.resolver.ClasspathFunctionResolver.Config.STELLAR_SEARCH_INCLUDES_KEY;
+import static org.apache.metron.stellar.dsl.functions.resolver.ClasspathFunctionResolver.Config.STELLAR_VFS_PATHS;
+
+import java.util.ArrayList;
+import java.util.Arrays;
+import java.util.HashSet;
+import java.util.List;
+import java.util.Map;
+import java.util.Optional;
+import java.util.Set;
 import org.apache.commons.vfs2.FileObject;
 import org.apache.commons.vfs2.FileSystemException;
 import org.apache.commons.vfs2.impl.VFSClassLoader;
+import org.apache.metron.stellar.common.utils.ConversionUtils;
+import org.apache.metron.stellar.common.utils.VFSClassloaderUtil;
 import org.apache.metron.stellar.dsl.Context;
 import org.apache.metron.stellar.dsl.Stellar;
 import org.apache.metron.stellar.dsl.StellarFunction;
-import org.apache.metron.stellar.common.utils.VFSClassloaderUtil;
-import org.apache.metron.stellar.common.utils.ConversionUtils;
 import org.atteo.classindex.ClassIndex;
 import org.reflections.util.FilterBuilder;
 
-import java.util.*;
-
-import static org.apache.metron.stellar.dsl.Context.Capabilities.STELLAR_CONFIG;
-import static org.apache.metron.stellar.dsl.functions.resolver.ClasspathFunctionResolver.Config.STELLAR_SEARCH_EXCLUDES_KEY;
-import static org.apache.metron.stellar.dsl.functions.resolver.ClasspathFunctionResolver.Config.STELLAR_SEARCH_INCLUDES_KEY;
-import static org.apache.metron.stellar.dsl.functions.resolver.ClasspathFunctionResolver.Config.STELLAR_VFS_PATHS;
-
 /**
  * Performs function resolution for Stellar by searching the classpath.
  *
@@ -176,7 +181,7 @@ public class ClasspathFunctionResolver extends BaseFunctionResolver {
       if (optional.isPresent()) {
         Map<String, Object> stellarConfig = (Map<String, Object>) optional.get();
         if(LOG.isDebugEnabled()) {
-          LOG.debug("Setting up classloader using the following config: " + stellarConfig);
+          LOG.debug("Setting up classloader using the following config: {}", stellarConfig);
         }
 
         include(STELLAR_SEARCH_INCLUDES_KEY.get(stellarConfig, String.class).split(STELLAR_SEARCH_DELIMS));
@@ -185,16 +190,16 @@ public class ClasspathFunctionResolver extends BaseFunctionResolver {
         try {
           vfsLoader = VFSClassloaderUtil.configureClassloader(STELLAR_VFS_PATHS.get(stellarConfig, String.class));
           if(vfsLoader.isPresent()) {
-            LOG.debug("CLASSLOADER LOADED WITH: " + STELLAR_VFS_PATHS.get(stellarConfig, String.class));
+            LOG.debug("CLASSLOADER LOADED WITH: {}", STELLAR_VFS_PATHS.get(stellarConfig, String.class));
             if(LOG.isDebugEnabled()) {
               for (FileObject fo : ((VFSClassLoader) vfsLoader.get()).getFileObjects()) {
-                LOG.error(fo.getURL() + " - " + fo.exists());
+                LOG.error("{} - {}", fo.getURL(), fo.exists());
               }
             }
             classLoaders(vfsLoader.get());
           }
         } catch (FileSystemException e) {
-          LOG.error("Unable to process filesystem: " + e.getMessage(), e);
+          LOG.error("Unable to process filesystem: {}", e.getMessage(), e);
         }
       }
       else {

http://git-wip-us.apache.org/repos/asf/metron/blob/ec959d20/metron-stellar/stellar-common/src/main/java/org/apache/metron/stellar/dsl/functions/resolver/SimpleFunctionResolver.java
----------------------------------------------------------------------
diff --git a/metron-stellar/stellar-common/src/main/java/org/apache/metron/stellar/dsl/functions/resolver/SimpleFunctionResolver.java b/metron-stellar/stellar-common/src/main/java/org/apache/metron/stellar/dsl/functions/resolver/SimpleFunctionResolver.java
index 6bab61a..d2d0e62 100644
--- a/metron-stellar/stellar-common/src/main/java/org/apache/metron/stellar/dsl/functions/resolver/SimpleFunctionResolver.java
+++ b/metron-stellar/stellar-common/src/main/java/org/apache/metron/stellar/dsl/functions/resolver/SimpleFunctionResolver.java
@@ -18,13 +18,13 @@
 
 package org.apache.metron.stellar.dsl.functions.resolver;
 
+import java.lang.invoke.MethodHandles;
+import java.util.HashSet;
+import java.util.Set;
 import org.apache.metron.stellar.dsl.StellarFunction;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
-import java.util.HashSet;
-import java.util.Set;
-
 /**
  * A simple Stellar function resolver that resolves functions from specific
  * classes rather than by searching the classpath.
@@ -36,7 +36,7 @@ import java.util.Set;
  */
 public class SimpleFunctionResolver extends BaseFunctionResolver {
 
-  protected static final Logger LOG = LoggerFactory.getLogger(SimpleFunctionResolver.class);
+  protected static final Logger LOG = LoggerFactory.getLogger(MethodHandles.lookup().lookupClass());
 
   /**
    * The classes that will be further interrogated for Stellar functions.


Mime
View raw message