falcon-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From samar...@apache.org
Subject git commit: FALCON-563 Fix checkstyle issues of falcon-regression contributed by Raghav Kumar Gautam
Date Tue, 05 Aug 2014 04:34:44 GMT
Repository: incubator-falcon
Updated Branches:
  refs/heads/master bdcf001fe -> ad51ca03f


FALCON-563 Fix checkstyle issues of falcon-regression contributed by Raghav Kumar Gautam


Project: http://git-wip-us.apache.org/repos/asf/incubator-falcon/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-falcon/commit/ad51ca03
Tree: http://git-wip-us.apache.org/repos/asf/incubator-falcon/tree/ad51ca03
Diff: http://git-wip-us.apache.org/repos/asf/incubator-falcon/diff/ad51ca03

Branch: refs/heads/master
Commit: ad51ca03f3af9fe7dcec47291c9f7a6ea586cb1d
Parents: bdcf001
Author: Samarth Gupta <samarth.gupta@inmobi.com>
Authored: Tue Aug 5 10:04:27 2014 +0530
Committer: Samarth Gupta <samarth.gupta@inmobi.com>
Committed: Tue Aug 5 10:04:27 2014 +0530

----------------------------------------------------------------------
 .../regression/Entities/ClusterMerlin.java      |   5 +-
 .../falcon/regression/Entities/FeedMerlin.java  |  21 ++--
 .../regression/Entities/ProcessMerlin.java      |   9 +-
 .../falcon/regression/core/bundle/Bundle.java   |  14 +--
 .../core/enumsAndConstants/RetentionUnit.java   |   1 +
 .../core/helpers/ClusterEntityHelperImpl.java   |   6 +-
 .../regression/core/helpers/ColoHelper.java     |   3 +-
 .../core/helpers/DataEntityHelperImpl.java      |   4 +-
 .../core/helpers/ProcessEntityHelperImpl.java   |   4 +-
 .../core/interfaces/EntityHelperFactory.java    |  19 ++--
 .../core/interfaces/IEntityManagerHelper.java   |  44 ++++----
 .../regression/core/response/APIResult.java     |   3 +-
 .../core/response/EntitiesResult.java           |   5 +-
 .../regression/core/response/EntityResult.java  |   6 +-
 .../core/response/InstancesResult.java          |   2 +-
 .../regression/core/response/ResponseKeys.java  |   6 +-
 .../core/response/ServiceResponse.java          |  16 +--
 .../core/response/lineage/Direction.java        |   1 +
 .../regression/core/response/lineage/Edge.java  |  24 ++--
 .../core/response/lineage/EdgeResult.java       |   7 +-
 .../core/response/lineage/EdgesResult.java      |  10 +-
 .../core/response/lineage/GraphEntity.java      |   1 +
 .../core/response/lineage/GraphResult.java      |   1 +
 .../core/response/lineage/NODE_TYPE.java        |   1 +
 .../core/response/lineage/Vertex.java           | 112 ++++++++++---------
 .../core/response/lineage/VertexIdsResult.java  |   8 +-
 .../core/response/lineage/VertexResult.java     |   3 +-
 .../core/response/lineage/VerticesResult.java   |  18 ++-
 .../regression/core/supportClasses/Brother.java | 101 ++++++++---------
 .../core/supportClasses/HadoopFileEditor.java   |  17 +--
 .../core/supportClasses/JmsMessageConsumer.java |  23 ++--
 .../falcon/regression/core/util/AssertUtil.java |   4 +-
 .../falcon/regression/core/util/Config.java     |   7 +-
 .../falcon/regression/core/util/Generator.java  |   9 +-
 .../org/apache/falcon/request/BaseRequest.java  |  39 ++++---
 .../org/apache/falcon/request/RequestKeys.java  |   7 +-
 .../security/FalconAuthorizationToken.java      |  11 +-
 37 files changed, 295 insertions(+), 277 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-falcon/blob/ad51ca03/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/Entities/ClusterMerlin.java
----------------------------------------------------------------------
diff --git a/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/Entities/ClusterMerlin.java b/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/Entities/ClusterMerlin.java
index 182f36e..4d9fcb8 100644
--- a/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/Entities/ClusterMerlin.java
+++ b/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/Entities/ClusterMerlin.java
@@ -33,6 +33,7 @@ import java.util.HashMap;
 import java.util.List;
 import java.util.Map;
 
+/** Class for representing a cluster xml. */
 public class ClusterMerlin extends Cluster {
 
     public ClusterMerlin(String clusterData) {
@@ -49,7 +50,7 @@ public class ClusterMerlin extends Cluster {
     }
 
     public static List<ClusterMerlin> fromString(List<String> clusterStrings) {
-        List <ClusterMerlin> clusters = new ArrayList<ClusterMerlin>();
+        List<ClusterMerlin> clusters = new ArrayList<ClusterMerlin>();
         for (String clusterString : clusterStrings) {
             clusters.add(new ClusterMerlin(clusterString));
         }
@@ -68,7 +69,7 @@ public class ClusterMerlin extends Cluster {
     }
 
     /**
-     * Sets unique names for the cluster
+     * Sets unique names for the cluster.
      * @return mapping of old name to new name
      */
     public Map<? extends String, ? extends String> setUniqueName() {

http://git-wip-us.apache.org/repos/asf/incubator-falcon/blob/ad51ca03/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/Entities/FeedMerlin.java
----------------------------------------------------------------------
diff --git a/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/Entities/FeedMerlin.java b/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/Entities/FeedMerlin.java
index 11d3fb0..eecaa7c 100644
--- a/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/Entities/FeedMerlin.java
+++ b/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/Entities/FeedMerlin.java
@@ -47,9 +47,10 @@ import java.util.HashMap;
 import java.util.List;
 import java.util.Map;
 
+/** Class for representing a feed xml. */
 public class FeedMerlin extends Feed {
 
-    private static final Logger logger = Logger.getLogger(FeedMerlin.class);
+    private static final Logger LOGGER = Logger.getLogger(FeedMerlin.class);
 
     public FeedMerlin(String feedData) {
         this((Feed) fromString(EntityType.FEED, feedData));
@@ -68,7 +69,7 @@ public class FeedMerlin extends Feed {
     }
 
     public static List<FeedMerlin> fromString(List<String> feedStrings) {
-        List <FeedMerlin> feeds = new ArrayList<FeedMerlin>();
+        List<FeedMerlin> feeds = new ArrayList<FeedMerlin>();
         for (String feedString : feedStrings) {
             feeds.add(new FeedMerlin(feedString));
         }
@@ -76,7 +77,7 @@ public class FeedMerlin extends Feed {
     }
 
     /**
-     * Method sets a number of clusters to feed definition
+     * Method sets a number of clusters to feed definition.
      *
      * @param newClusters list of definitions of clusters which are to be set to feed
      * @param location location of data on every cluster
@@ -137,21 +138,21 @@ public class FeedMerlin extends Feed {
 
     public void setLocation(LocationType locationType, String feedInputPath) {
         for (Location location : getLocations().getLocations()) {
-            if(location.getType() == locationType) {
+            if (location.getType() == locationType) {
                 location.setPath(feedInputPath);
             }
         }
     }
 
     public void addProperty(String someProp, String someVal) {
-            Property property = new Property();
-            property.setName(someProp);
-            property.setValue(someVal);
-            this.getProperties().getProperties().add(property);
+        Property property = new Property();
+        property.setName(someProp);
+        property.setValue(someVal);
+        this.getProperties().getProperties().add(property);
     }
 
     /**
-     * Sets unique names for the feed
+     * Sets unique names for the feed.
      * @return mapping of old name to new name
      */
     public Map<? extends String, ? extends String> setUniqueName() {
@@ -167,7 +168,7 @@ public class FeedMerlin extends Feed {
         for (Cluster cluster : getClusters().getClusters()) {
             final String oldName = cluster.getName();
             final String newName = clusterNameMap.get(oldName);
-            if(!StringUtils.isEmpty(newName)) {
+            if (!StringUtils.isEmpty(newName)) {
                 cluster.setName(newName);
             }
         }

http://git-wip-us.apache.org/repos/asf/incubator-falcon/blob/ad51ca03/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/Entities/ProcessMerlin.java
----------------------------------------------------------------------
diff --git a/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/Entities/ProcessMerlin.java b/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/Entities/ProcessMerlin.java
index b9db07e..f58ea2a 100644
--- a/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/Entities/ProcessMerlin.java
+++ b/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/Entities/ProcessMerlin.java
@@ -46,7 +46,7 @@ import java.util.Date;
 import java.util.HashMap;
 import java.util.List;
 import java.util.Map;
-
+/** Class for representing a process xml. */
 public class ProcessMerlin extends Process {
     public ProcessMerlin(String processData) {
         this((Process) fromString(EntityType.PROCESS, processData));
@@ -65,7 +65,7 @@ public class ProcessMerlin extends Process {
     }
 
     /**
-     * Method sets a number of clusters to process definition
+     * Method sets a number of clusters to process definition.
      *
      * @param newClusters list of definitions of clusters which are to be set to process
      *                    (clusters on which process should run)
@@ -173,7 +173,7 @@ public class ProcessMerlin extends Process {
     }
 
     /**
-     * Sets unique names for the process
+     * Sets unique names for the process.
      * @return mapping of old name to new name
      */
     public Map<? extends String, ? extends String> setUniqueName() {
@@ -215,8 +215,9 @@ public class ProcessMerlin extends Process {
                 if (isFirst) {
                     in.setName("inputData");
                     isFirst = false;
-                } else
+                } else {
                     in.setName("inputData" + i);
+                }
             }
             in.setFeed(new FeedMerlin(newDataSets.get(i)).getName());
             is.getInputs().add(in);

http://git-wip-us.apache.org/repos/asf/incubator-falcon/blob/ad51ca03/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/bundle/Bundle.java
----------------------------------------------------------------------
diff --git a/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/bundle/Bundle.java b/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/bundle/Bundle.java
index 84ecb9c..1152493 100644
--- a/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/bundle/Bundle.java
+++ b/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/bundle/Bundle.java
@@ -180,9 +180,9 @@ public class Bundle {
      * @param c      Cluster object to be unwrapped and set into bundle
      */
     public void writeClusterElement(org.apache.falcon.entity.v0.cluster.Cluster c) {
-        final List<String> clusters = new ArrayList<String>();
-        clusters.add(c.toString());
-        setClusterData(clusters);
+        final List<String> newClusters = new ArrayList<String>();
+        newClusters.add(c.toString());
+        setClusterData(newClusters);
     }
 
     /**
@@ -522,7 +522,7 @@ public class Bundle {
         Feed feedElement = getFeedElement(feedName);
         final List<Location> locations = feedElement.getLocations().getLocations();
         for (Location location : locations) {
-            if(location.getType() == LocationType.DATA) {
+            if (location.getType() == LocationType.DATA) {
                 locations.get(0).setPath(path);
             }
         }
@@ -1003,8 +1003,7 @@ public class Bundle {
     }
 
     public String getInputFeedFromBundle() {
-        String processData = getProcessData();
-        Process processObject = (Process) Entity.fromString(EntityType.PROCESS, processData);
+        Process processObject = (Process) Entity.fromString(EntityType.PROCESS, getProcessData());
         for (Input input : processObject.getInputs().getInputs()) {
             for (String feed : getDataSets()) {
                 if (Util.readEntityName(feed).equalsIgnoreCase(input.getFeed())) {
@@ -1016,8 +1015,7 @@ public class Bundle {
     }
 
     public String getOutputFeedFromBundle() {
-        String processData = getProcessData();
-        Process processObject = (Process) Entity.fromString(EntityType.PROCESS, processData);
+        Process processObject = (Process) Entity.fromString(EntityType.PROCESS, getProcessData());
 
         for (Output output : processObject.getOutputs().getOutputs()) {
             for (String feed : getDataSets()) {

http://git-wip-us.apache.org/repos/asf/incubator-falcon/blob/ad51ca03/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/enumsAndConstants/RetentionUnit.java
----------------------------------------------------------------------
diff --git a/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/enumsAndConstants/RetentionUnit.java b/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/enumsAndConstants/RetentionUnit.java
index d1ece18..92ea25e 100644
--- a/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/enumsAndConstants/RetentionUnit.java
+++ b/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/enumsAndConstants/RetentionUnit.java
@@ -20,6 +20,7 @@ package org.apache.falcon.regression.core.enumsAndConstants;
 
 import org.joda.time.DateTime;
 
+/** Enum to represent different Retention Units. */
 public enum RetentionUnit {
     MINUTES("minutes") {
         @Override

http://git-wip-us.apache.org/repos/asf/incubator-falcon/blob/ad51ca03/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/helpers/ClusterEntityHelperImpl.java
----------------------------------------------------------------------
diff --git a/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/helpers/ClusterEntityHelperImpl.java b/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/helpers/ClusterEntityHelperImpl.java
index 129ea62..babf178 100644
--- a/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/helpers/ClusterEntityHelperImpl.java
+++ b/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/helpers/ClusterEntityHelperImpl.java
@@ -24,16 +24,15 @@ import org.apache.falcon.regression.core.response.InstancesResult;
 import org.apache.falcon.regression.core.response.ServiceResponse;
 import org.apache.falcon.regression.core.util.Util;
 import org.apache.falcon.regression.core.util.Util.URLS;
-import org.apache.log4j.Logger;
 
 import java.io.IOException;
 import java.net.URISyntaxException;
 
+/** Helper class to work with cluster endpoints of a colo. */
 public class ClusterEntityHelperImpl extends IEntityManagerHelper {
 
 
     private static final String INVALID_ERR = "Not Valid for Cluster Entity";
-    private static final Logger logger = Logger.getLogger(ClusterEntityHelperImpl.class);
 
     public ClusterEntityHelperImpl(String prefix) {
         super(prefix);
@@ -119,8 +118,7 @@ public class ClusterEntityHelperImpl extends IEntityManagerHelper {
                                                      String string
     ) throws
         IOException, URISyntaxException {
-        logger.info(INVALID_ERR);
-        return null;
+        throw new UnsupportedOperationException(INVALID_ERR);
     }
 
 }

http://git-wip-us.apache.org/repos/asf/incubator-falcon/blob/ad51ca03/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/helpers/ColoHelper.java
----------------------------------------------------------------------
diff --git a/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/helpers/ColoHelper.java b/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/helpers/ColoHelper.java
index 05b4f73..3a3ddce 100644
--- a/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/helpers/ColoHelper.java
+++ b/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/helpers/ColoHelper.java
@@ -21,10 +21,9 @@ package org.apache.falcon.regression.core.helpers;
 import org.apache.falcon.entity.v0.EntityType;
 import org.apache.falcon.regression.core.interfaces.EntityHelperFactory;
 import org.apache.falcon.regression.core.interfaces.IEntityManagerHelper;
-import org.apache.log4j.Logger;
 
+/** Helper class to work with a colo. */
 public class ColoHelper {
-    private static final Logger logger = Logger.getLogger(ColoHelper.class);
     private final IEntityManagerHelper clusterHelper;
     private final IEntityManagerHelper processHelper;
     private final IEntityManagerHelper feedHelper;

http://git-wip-us.apache.org/repos/asf/incubator-falcon/blob/ad51ca03/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/helpers/DataEntityHelperImpl.java
----------------------------------------------------------------------
diff --git a/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/helpers/DataEntityHelperImpl.java b/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/helpers/DataEntityHelperImpl.java
index 7800c50..5127a91 100644
--- a/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/helpers/DataEntityHelperImpl.java
+++ b/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/helpers/DataEntityHelperImpl.java
@@ -20,12 +20,10 @@ package org.apache.falcon.regression.core.helpers;
 
 import org.apache.falcon.regression.core.interfaces.IEntityManagerHelper;
 import org.apache.falcon.regression.core.util.Util;
-import org.apache.log4j.Logger;
 
+/** Helper class to work with feed endpoints of a colo. */
 public class DataEntityHelperImpl extends IEntityManagerHelper {
 
-    private static final Logger logger = Logger.getLogger(DataEntityHelperImpl.class);
-
     public DataEntityHelperImpl(String prefix) {
         super(prefix);
     }

http://git-wip-us.apache.org/repos/asf/incubator-falcon/blob/ad51ca03/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/helpers/ProcessEntityHelperImpl.java
----------------------------------------------------------------------
diff --git a/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/helpers/ProcessEntityHelperImpl.java b/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/helpers/ProcessEntityHelperImpl.java
index c037b5e..e86caaf 100644
--- a/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/helpers/ProcessEntityHelperImpl.java
+++ b/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/helpers/ProcessEntityHelperImpl.java
@@ -20,12 +20,10 @@ package org.apache.falcon.regression.core.helpers;
 
 import org.apache.falcon.regression.core.interfaces.IEntityManagerHelper;
 import org.apache.falcon.regression.core.util.Util;
-import org.apache.log4j.Logger;
 
+/** Helper class to work with process endpoints of a colo. */
 public class ProcessEntityHelperImpl extends IEntityManagerHelper {
 
-    private static final Logger logger = Logger.getLogger(ProcessEntityHelperImpl.class);
-
     public ProcessEntityHelperImpl(String prefix) {
         super(prefix);
     }

http://git-wip-us.apache.org/repos/asf/incubator-falcon/blob/ad51ca03/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/interfaces/EntityHelperFactory.java
----------------------------------------------------------------------
diff --git a/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/interfaces/EntityHelperFactory.java b/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/interfaces/EntityHelperFactory.java
index ffda6e5..fe57927 100644
--- a/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/interfaces/EntityHelperFactory.java
+++ b/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/interfaces/EntityHelperFactory.java
@@ -23,20 +23,21 @@ import org.apache.falcon.regression.core.helpers.ClusterEntityHelperImpl;
 import org.apache.falcon.regression.core.helpers.DataEntityHelperImpl;
 import org.apache.falcon.regression.core.helpers.ProcessEntityHelperImpl;
 
-public class EntityHelperFactory {
+/** Factory class to create helper objects. */
+public final class EntityHelperFactory {
     private EntityHelperFactory() {
     }
 
     public static IEntityManagerHelper getEntityHelper(EntityType type, String prefix) {
         switch (type) {
-            case FEED:
-                return new DataEntityHelperImpl(prefix);
-            case CLUSTER:
-                return new ClusterEntityHelperImpl(prefix);
-            case PROCESS:
-                return new ProcessEntityHelperImpl(prefix);
-            default:
-                return null;
+        case FEED:
+            return new DataEntityHelperImpl(prefix);
+        case CLUSTER:
+            return new ClusterEntityHelperImpl(prefix);
+        case PROCESS:
+            return new ProcessEntityHelperImpl(prefix);
+        default:
+            return null;
         }
     }
 }

http://git-wip-us.apache.org/repos/asf/incubator-falcon/blob/ad51ca03/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/interfaces/IEntityManagerHelper.java
----------------------------------------------------------------------
diff --git a/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/interfaces/IEntityManagerHelper.java b/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/interfaces/IEntityManagerHelper.java
index 01eb02f..bf99740 100644
--- a/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/interfaces/IEntityManagerHelper.java
+++ b/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/interfaces/IEntityManagerHelper.java
@@ -45,15 +45,16 @@ import java.io.IOException;
 import java.net.URISyntaxException;
 import java.util.List;
 
+/** Abstract class for helper classes. */
 public abstract class IEntityManagerHelper {
 
-    public static boolean AUTHENTICATE = setAuthenticate();
+    public static final boolean AUTHENTICATE = setAuthenticate();
 
-    private static final Logger logger = Logger.getLogger(IEntityManagerHelper.class);
+    private static final Logger LOGGER = Logger.getLogger(IEntityManagerHelper.class);
 
-    protected String CLIENT_LOCATION = OSUtil.RESOURCES
+    protected static final String CLIENT_LOCATION = OSUtil.RESOURCES
         + OSUtil.getPath("IvoryClient", "IvoryCLI.jar");
-    protected String BASE_COMMAND = "java -jar " + CLIENT_LOCATION;
+    protected static final String BASE_COMMAND = "java -jar " + CLIENT_LOCATION;
 
     private static boolean setAuthenticate() {
         String value = Config.getProperty("isAuthenticationSet");
@@ -108,8 +109,8 @@ public abstract class IEntityManagerHelper {
             try {
                 this.hCatClient = HCatUtil.getHCatClient(hcatEndpoint, hiveMetaStorePrincipal);
             } catch (HCatException e) {
-                Assert.fail("Unable to create hCatClient because of exception:\n" +
-                    ExceptionUtils.getStackTrace(e));
+                Assert.fail("Unable to create hCatClient because of exception:\n"
+                    + ExceptionUtils.getStackTrace(e));
             }
         }
         return this.hCatClient;
@@ -220,9 +221,8 @@ public abstract class IEntityManagerHelper {
         this.oozieURL = Config.getProperty(prefix + "oozie_url");
         this.activeMQ = Config.getProperty(prefix + "activemq_url");
         this.storeLocation = Config.getProperty(prefix + "storeLocation");
-        this.hadoopGetCommand =
-            hadoopLocation + "  fs -cat hdfs://" + hadoopURL +
-                "/projects/ivory/staging/ivory/workflows/process";
+        this.hadoopGetCommand = hadoopLocation + "  fs -cat hdfs://" + hadoopURL
+                + "/projects/ivory/staging/ivory/workflows/process";
         this.allColo = "?colo=" + Config.getProperty(prefix + "colo", "*");
         this.colo = (!Config.getProperty(prefix + "colo", "").isEmpty()) ? "?colo=" + Config
             .getProperty(prefix + "colo") : "";
@@ -241,8 +241,8 @@ public abstract class IEntityManagerHelper {
         this.hadoopFS = null;
         this.oozieClient = null;
         this.namenodePrincipal = Config.getProperty(prefix + "namenode.kerberos.principal", "none");
-        this.hiveMetaStorePrincipal = Config.getProperty(prefix + "hive.metastore.kerberos" +
-            ".principal", "none");
+        this.hiveMetaStorePrincipal = Config.getProperty(
+                prefix + "hive.metastore.kerberos.principal", "none");
     }
 
     public abstract String getEntityType();
@@ -260,7 +260,7 @@ public abstract class IEntityManagerHelper {
 
     public ServiceResponse listEntities(Util.URLS url, String user)
         throws IOException, URISyntaxException, AuthenticationException {
-        logger.info("fetching " + getEntityType() + " list");
+        LOGGER.info("fetching " + getEntityType() + " list");
         return Util.sendRequest(createUrl(this.hostname + url.getValue(), getEntityType() + colo),
             "get", null, user);
     }
@@ -272,7 +272,7 @@ public abstract class IEntityManagerHelper {
 
     public ServiceResponse submitEntity(URLS url, String data, String user)
         throws IOException, URISyntaxException, AuthenticationException {
-        logger.info("Submitting " + getEntityType() + ": \n" + Util.prettyPrintXml(data));
+        LOGGER.info("Submitting " + getEntityType() + ": \n" + Util.prettyPrintXml(data));
         return Util.sendRequest(createUrl(this.hostname + url.getValue(), getEntityType() + colo),
             "post", data, user);
     }
@@ -295,7 +295,7 @@ public abstract class IEntityManagerHelper {
 
     public ServiceResponse submitAndSchedule(URLS url, String data, String user)
         throws IOException, URISyntaxException, AuthenticationException {
-        logger.info("Submitting " + getEntityType() + ": \n" + Util.prettyPrintXml(data));
+        LOGGER.info("Submitting " + getEntityType() + ": \n" + Util.prettyPrintXml(data));
         return Util.sendRequest(createUrl(this.hostname + url.getValue(), getEntityType()), "post",
             data, user);
     }
@@ -425,8 +425,8 @@ public abstract class IEntityManagerHelper {
     public ServiceResponse update(String oldEntity, String newEntity, String updateTime,
                                   String user)
         throws IOException, URISyntaxException, AuthenticationException {
-        String url = this.hostname + URLS.UPDATE.getValue() + "/" + getEntityType() + "/" +
-            Util.readEntityName(oldEntity);
+        String url = this.hostname + URLS.UPDATE.getValue() + "/" + getEntityType() + "/"
+            + Util.readEntityName(oldEntity);
         String urlPart = colo == null || colo.isEmpty() ? "?" : colo + "&";
         return Util.sendRequest(url + urlPart + "effective=" + updateTime, "post",
             newEntity, user);
@@ -446,9 +446,9 @@ public abstract class IEntityManagerHelper {
             .createAndSendRequestProcessInstance(url, params, allColo, user);
     }
 
-    public InstancesResult getProcessInstanceRerun(String EntityName, String params)
+    public InstancesResult getProcessInstanceRerun(String entityName, String params)
         throws IOException, URISyntaxException, AuthenticationException {
-        return getProcessInstanceRerun(EntityName, params, null);
+        return getProcessInstanceRerun(entityName, params, null);
     }
 
     public InstancesResult getProcessInstanceRerun(String entityName, String params,
@@ -460,9 +460,9 @@ public abstract class IEntityManagerHelper {
             .createAndSendRequestProcessInstance(url, params, allColo, user);
     }
 
-    public InstancesResult getProcessInstanceResume(String EntityName, String params)
+    public InstancesResult getProcessInstanceResume(String entityName, String params)
         throws IOException, URISyntaxException, AuthenticationException {
-        return getProcessInstanceResume(EntityName, params, null);
+        return getProcessInstanceResume(entityName, params, null);
     }
 
     public InstancesResult getProcessInstanceResume(String entityName, String params,
@@ -490,8 +490,8 @@ public abstract class IEntityManagerHelper {
 
     public String getDependencies(String entityName) {
         return ExecUtil.executeCommandGetOutput(
-            BASE_COMMAND + " entity -dependency -url " + this.hostname + " -type " +
-                getEntityType() + " -name " + entityName);
+            BASE_COMMAND + " entity -dependency -url " + this.hostname + " -type "
+                + getEntityType() + " -name " + entityName);
     }
 
     public List<String> getArchiveInfo() throws IOException, JSchException {

http://git-wip-us.apache.org/repos/asf/incubator-falcon/blob/ad51ca03/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/response/APIResult.java
----------------------------------------------------------------------
diff --git a/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/response/APIResult.java b/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/response/APIResult.java
index 40d640a..7464e18 100644
--- a/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/response/APIResult.java
+++ b/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/response/APIResult.java
@@ -28,7 +28,7 @@ import java.io.StringWriter;
 
 /**
  * APIResult is the output returned by all the APIs; status-SUCCEEDED or FAILED
- * message- detailed message
+ * message- detailed message.
  */
 @XmlRootElement(name = "result")
 @XmlAccessorType(XmlAccessType.FIELD)
@@ -64,6 +64,7 @@ public class APIResult {
         }
     }
 
+    /** Enum for status of the APIResult. */
     public static enum Status {
         SUCCEEDED, PARTIAL, FAILED
     }

http://git-wip-us.apache.org/repos/asf/incubator-falcon/blob/ad51ca03/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/response/EntitiesResult.java
----------------------------------------------------------------------
diff --git a/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/response/EntitiesResult.java b/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/response/EntitiesResult.java
index 5a77680..7344d21 100644
--- a/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/response/EntitiesResult.java
+++ b/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/response/EntitiesResult.java
@@ -25,6 +25,7 @@ import javax.xml.bind.annotation.XmlRootElement;
 import java.util.ArrayList;
 import java.util.List;
 
+/** Class for api result of list entities. */
 @XmlRootElement(name = "entities")
 @XmlAccessorType(XmlAccessType.FIELD)
 public class EntitiesResult {
@@ -37,8 +38,6 @@ public class EntitiesResult {
 
     @Override
     public String toString() {
-        return "EntitiesResult{" +
-            "entities=" + entities +
-            '}';
+        return String.format("EntitiesResult{entities=%s}", entities);
     }
 }

http://git-wip-us.apache.org/repos/asf/incubator-falcon/blob/ad51ca03/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/response/EntityResult.java
----------------------------------------------------------------------
diff --git a/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/response/EntityResult.java b/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/response/EntityResult.java
index f44c340..45d4f8d 100644
--- a/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/response/EntityResult.java
+++ b/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/response/EntityResult.java
@@ -23,6 +23,7 @@ import javax.xml.bind.annotation.XmlAccessorType;
 import javax.xml.bind.annotation.XmlElement;
 import javax.xml.bind.annotation.XmlRootElement;
 
+/** Class for api result of one entity. */
 @XmlRootElement(name = "entity")
 @XmlAccessorType(XmlAccessType.FIELD)
 public class EntityResult {
@@ -41,10 +42,7 @@ public class EntityResult {
 
     @Override
     public String toString() {
-        return "EntityResult{" +
-            "type='" + type + '\'' +
-            ", name='" + name + '\'' +
-            '}';
+        return String.format("EntityResult{type='%s', name='%s'}", type, name);
     }
 
 }

http://git-wip-us.apache.org/repos/asf/incubator-falcon/blob/ad51ca03/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/response/InstancesResult.java
----------------------------------------------------------------------
diff --git a/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/response/InstancesResult.java b/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/response/InstancesResult.java
index 8d1311b..45ca85e 100644
--- a/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/response/InstancesResult.java
+++ b/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/response/InstancesResult.java
@@ -207,4 +207,4 @@ public class InstancesResult extends APIResult {
         }
     }
 }
-//RESUME CHECKSTYLE CHECK VisibilityModifierCheck
\ No newline at end of file
+//RESUME CHECKSTYLE CHECK VisibilityModifierCheck

http://git-wip-us.apache.org/repos/asf/incubator-falcon/blob/ad51ca03/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/response/ResponseKeys.java
----------------------------------------------------------------------
diff --git a/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/response/ResponseKeys.java b/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/response/ResponseKeys.java
index a9ea122..45896f9 100644
--- a/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/response/ResponseKeys.java
+++ b/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/response/ResponseKeys.java
@@ -18,7 +18,11 @@
 
 package org.apache.falcon.regression.core.response;
 
-public class ResponseKeys {
+/** Class containing response keys of rest requests. */
+public final class ResponseKeys {
+    private ResponseKeys() {
+        throw new AssertionError();
+    }
 
     public static final int PROCESS_NOT_FOUND = 777;
     public static final int UNPARSEABLE_DATE = 2;

http://git-wip-us.apache.org/repos/asf/incubator-falcon/blob/ad51ca03/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/response/ServiceResponse.java
----------------------------------------------------------------------
diff --git a/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/response/ServiceResponse.java b/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/response/ServiceResponse.java
index 259e6e4..004da4a 100644
--- a/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/response/ServiceResponse.java
+++ b/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/response/ServiceResponse.java
@@ -26,11 +26,12 @@ import java.io.BufferedReader;
 import java.io.IOException;
 import java.io.InputStreamReader;
 
+/** Class to represent falcon's response to a rest request. */
 public class ServiceResponse {
-    private static final Logger logger = Logger.getLogger(ServiceResponse.class);
+    private static final Logger LOGGER = Logger.getLogger(ServiceResponse.class);
 
-    public String message;
-    int code;
+    private String message;
+    private int code;
     private HttpResponse response;
 
     public int getCode() {
@@ -67,17 +68,16 @@ public class ServiceResponse {
             new BufferedReader(new InputStreamReader(response.getEntity().getContent()));
 
         String line;
-        StringBuilder string_response = new StringBuilder();
+        StringBuilder stringResponse = new StringBuilder();
 
         while ((line = reader.readLine()) != null) {
-            string_response.append(line);
+            stringResponse.append(line);
         }
-        this.message = string_response.toString();
+        this.message = stringResponse.toString();
         this.code = response.getStatusLine().getStatusCode();
         this.response = response;
 
-        logger.info("The web service response is:\n" +
-            Util.prettyPrintXmlOrJson(message));
+        LOGGER.info("The web service response is:\n" + Util.prettyPrintXmlOrJson(message));
     }
 
     public ServiceResponse() {

http://git-wip-us.apache.org/repos/asf/incubator-falcon/blob/ad51ca03/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/response/lineage/Direction.java
----------------------------------------------------------------------
diff --git a/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/response/lineage/Direction.java b/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/response/lineage/Direction.java
index 6d3665f..56e3d7c 100644
--- a/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/response/lineage/Direction.java
+++ b/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/response/lineage/Direction.java
@@ -18,6 +18,7 @@
 
 package org.apache.falcon.regression.core.response.lineage;
 
+/** Enum for all the direction values associated with edges. */
 public enum Direction {
     outGoingEdges("outE"),
     inComingEdges("inE"),

http://git-wip-us.apache.org/repos/asf/incubator-falcon/blob/ad51ca03/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/response/lineage/Edge.java
----------------------------------------------------------------------
diff --git a/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/response/lineage/Edge.java b/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/response/lineage/Edge.java
index 66e6664..4b5616c 100644
--- a/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/response/lineage/Edge.java
+++ b/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/response/lineage/Edge.java
@@ -20,8 +20,10 @@ package org.apache.falcon.regression.core.response.lineage;
 
 import com.google.gson.annotations.SerializedName;
 
+/** Class for representing an edge. */
 public class Edge extends GraphEntity {
 
+    /** Class for representing different labels of edge. */
     public static enum LEBEL_TYPE {
         @SerializedName("stored-in")STORED_IN,
         @SerializedName("runs-on")RUNS_ON,
@@ -38,10 +40,10 @@ public class Edge extends GraphEntity {
         @SerializedName("testname")TESTNAME,
     }
 
-    String _id;
-    int _outV;
-    int _inV;
-    LEBEL_TYPE _label;
+    private String _id;
+    private int _outV;
+    private int _inV;
+    private LEBEL_TYPE _label;
 
     public String get_id() {
         return _id;
@@ -61,12 +63,12 @@ public class Edge extends GraphEntity {
 
     @Override
     public String toString() {
-        return "Edge{" +
-            "_id='" + _id + '\'' +
-            ", _outV=" + _outV +
-            ", _inV=" + _inV +
-            ", _label=" + _label +
-            '}';
+        return "Edge{"
+                + "_id='" + _id + '\''
+                + ", _outV=" + _outV
+                + ", _inV=" + _inV
+                + ", _label=" + _label
+                + '}';
     }
 
-}
\ No newline at end of file
+}

http://git-wip-us.apache.org/repos/asf/incubator-falcon/blob/ad51ca03/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/response/lineage/EdgeResult.java
----------------------------------------------------------------------
diff --git a/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/response/lineage/EdgeResult.java b/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/response/lineage/EdgeResult.java
index 420d88f..9a062e0 100644
--- a/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/response/lineage/EdgeResult.java
+++ b/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/response/lineage/EdgeResult.java
@@ -18,8 +18,9 @@
 
 package org.apache.falcon.regression.core.response.lineage;
 
+/** Class for Lineage API result having an edge. */
 public class EdgeResult {
-    Edge results;
+    private Edge results;
 
     public Edge getResults() {
         return results;
@@ -27,9 +28,7 @@ public class EdgeResult {
 
     @Override
     public String toString() {
-        return "EdgeResult{" +
-            "results=" + results +
-            '}';
+        return "EdgeResult{" + "results=" + results + '}';
     }
 
 }

http://git-wip-us.apache.org/repos/asf/incubator-falcon/blob/ad51ca03/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/response/lineage/EdgesResult.java
----------------------------------------------------------------------
diff --git a/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/response/lineage/EdgesResult.java b/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/response/lineage/EdgesResult.java
index 6b15cfa..21d897c 100644
--- a/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/response/lineage/EdgesResult.java
+++ b/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/response/lineage/EdgesResult.java
@@ -21,8 +21,9 @@ package org.apache.falcon.regression.core.response.lineage;
 import java.util.ArrayList;
 import java.util.List;
 
+/** Class for Lineage API result having edges. */
 public class EdgesResult extends GraphResult {
-    List<Edge> results;
+    private List<Edge> results;
 
     public List<Edge> getResults() {
         return results;
@@ -30,10 +31,7 @@ public class EdgesResult extends GraphResult {
 
     @Override
     public String toString() {
-        return "AllEdges{" +
-            "totalSize=" + totalSize +
-            ", results=" + results +
-            '}';
+        return String.format("EdgesResult{totalSize=%d, results=%s}", totalSize, results);
     }
 
     public List<Edge> filterByType(Edge.LEBEL_TYPE edgeLabel) {
@@ -43,7 +41,7 @@ public class EdgesResult extends GraphResult {
     public List<Edge> filterEdgesByType(List<Edge> edges, Edge.LEBEL_TYPE edgeLabel) {
         final List<Edge> result = new ArrayList<Edge>();
         for (Edge edge : edges) {
-            if(edge.get_label() == edgeLabel) {
+            if (edge.get_label() == edgeLabel) {
                 result.add(edge);
             }
         }

http://git-wip-us.apache.org/repos/asf/incubator-falcon/blob/ad51ca03/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/response/lineage/GraphEntity.java
----------------------------------------------------------------------
diff --git a/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/response/lineage/GraphEntity.java b/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/response/lineage/GraphEntity.java
index 2bef659..d35ced6 100644
--- a/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/response/lineage/GraphEntity.java
+++ b/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/response/lineage/GraphEntity.java
@@ -18,6 +18,7 @@
 
 package org.apache.falcon.regression.core.response.lineage;
 
+/** Abstract class for graph entities. */
 public abstract class GraphEntity {
     NODE_TYPE _type;
 

http://git-wip-us.apache.org/repos/asf/incubator-falcon/blob/ad51ca03/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/response/lineage/GraphResult.java
----------------------------------------------------------------------
diff --git a/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/response/lineage/GraphResult.java b/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/response/lineage/GraphResult.java
index ac8ed77..d4be61d 100644
--- a/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/response/lineage/GraphResult.java
+++ b/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/response/lineage/GraphResult.java
@@ -20,6 +20,7 @@ package org.apache.falcon.regression.core.response.lineage;
 
 import java.util.List;
 
+/** Abstract class for representing a result of lineage api call.*/
 public abstract class GraphResult {
     int totalSize;
 

http://git-wip-us.apache.org/repos/asf/incubator-falcon/blob/ad51ca03/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/response/lineage/NODE_TYPE.java
----------------------------------------------------------------------
diff --git a/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/response/lineage/NODE_TYPE.java b/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/response/lineage/NODE_TYPE.java
index c315bd4..da2132e 100644
--- a/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/response/lineage/NODE_TYPE.java
+++ b/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/response/lineage/NODE_TYPE.java
@@ -20,6 +20,7 @@ package org.apache.falcon.regression.core.response.lineage;
 
 import com.google.gson.annotations.SerializedName;
 
+/** Enum for all the allowed node types. */
 public enum NODE_TYPE {
     @SerializedName("vertex")VERTEX,
     @SerializedName("edge")EDGE,

http://git-wip-us.apache.org/repos/asf/incubator-falcon/blob/ad51ca03/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/response/lineage/Vertex.java
----------------------------------------------------------------------
diff --git a/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/response/lineage/Vertex.java b/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/response/lineage/Vertex.java
index d2690ae..1eaf6c6 100644
--- a/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/response/lineage/Vertex.java
+++ b/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/response/lineage/Vertex.java
@@ -20,14 +20,17 @@ package org.apache.falcon.regression.core.response.lineage;
 
 import com.google.gson.annotations.SerializedName;
 
+/** Class for representing a vertex. */
 public class Vertex extends GraphEntity {
 
+    /** Enum for all the allowed filter keys. */
     public static enum FilterKey {
         name, type, timestamp, version,
         userWorkflowEngine, userWorkflowName, userWorkflowVersion,
         workflowId, runId, status, workflowEngineUrl, subflowId,
     }
 
+    /** Enum for all the allowed vertex types. */
     public static enum VERTEX_TYPE {
         @SerializedName("cluster-entity")CLUSTER_ENTITY("cluster-entity"),
         @SerializedName("feed-entity")FEED_ENTITY("feed-entity"),
@@ -39,7 +42,7 @@ public class Vertex extends GraphEntity {
         @SerializedName("user")USER("user"),
         @SerializedName("data-center")COLO("data-center"),
         @SerializedName("classification")TAGS("classification"),
-        @SerializedName("group")GROUPS("group"),;
+        @SerializedName("group")GROUPS("group");
 
         private final String value;
         VERTEX_TYPE(String value) {
@@ -51,21 +54,21 @@ public class Vertex extends GraphEntity {
         }
     }
 
-    int _id;
-    String name;
-    VERTEX_TYPE type;
-    String timestamp;
-    String version;
+    private int _id;
+    private String name;
+    private VERTEX_TYPE type;
+    private String timestamp;
+    private String version;
 
-    String userWorkflowEngine;
-    String userWorkflowName;
-    String userWorkflowVersion;
+    private String userWorkflowEngine;
+    private String userWorkflowName;
+    private String userWorkflowVersion;
 
-    String workflowId;
-    String runId;
-    String status;
-    String workflowEngineUrl;
-    String subflowId;
+    private String workflowId;
+    private String runId;
+    private String status;
+    private String workflowEngineUrl;
+    private String subflowId;
 
     public int get_id() {
         return _id;
@@ -89,51 +92,58 @@ public class Vertex extends GraphEntity {
 
     @Override
     public String toString() {
-        return "Vertex{" +
-            "_id=" + _id +
-            ", _type=" + _type +
-            ", name='" + name + '\'' +
-            ", type=" + type +
-            ", timestamp='" + timestamp + '\'' +
-            ", version='" + version + '\'' +
-            ", userWorkflowEngine='" + userWorkflowEngine + '\'' +
-            ", userWorkflowName='" + userWorkflowName + '\'' +
-            ", userWorkflowVersion='" + userWorkflowVersion + '\'' +
-            ", workflowId='" + workflowId + '\'' +
-            ", runId='" + runId + '\'' +
-            ", status='" + status + '\'' +
-            ", workflowEngineUrl='" + workflowEngineUrl + '\'' +
-            ", subflowId='" + subflowId + '\'' +
-            '}';
+        return "Vertex{"
+                + "_id=" + _id
+                + ", _type=" + _type
+                + ", name='" + name + '\''
+                + ", type=" + type
+                + ", timestamp='" + timestamp + '\''
+                + ", version='" + version + '\''
+                + ", userWorkflowEngine='" + userWorkflowEngine + '\''
+                + ", userWorkflowName='" + userWorkflowName + '\''
+                + ", userWorkflowVersion='" + userWorkflowVersion + '\''
+                + ", workflowId='" + workflowId + '\''
+                + ", runId='" + runId + '\''
+                + ", status='" + status + '\''
+                + ", workflowEngineUrl='" + workflowEngineUrl + '\''
+                + ", subflowId='" + subflowId + '\''
+                + '}';
     }
 
     @Override
     public boolean equals(Object o) {
-        if (this == o) return true;
-        if (!(o instanceof Vertex)) return false;
+        if (this == o) {
+            return true;
+        }
+        if (!(o instanceof Vertex)) {
+            return false;
+        }
 
         Vertex vertex = (Vertex) o;
 
-        if (_id != vertex._id) return false;
-        if (!name.equals(vertex.name)) return false;
-        if (runId != null ? !runId.equals(vertex.runId) : vertex.runId != null) return false;
-        if (status != null ? !status.equals(vertex.status) : vertex.status != null) return false;
-        if (subflowId != null ? !subflowId.equals(vertex.subflowId) : vertex.subflowId != null)
-            return false;
-        if (!timestamp.equals(vertex.timestamp)) return false;
-        if (type != vertex.type) return false;
-        if (userWorkflowEngine != null ? !userWorkflowEngine.equals(vertex.userWorkflowEngine) :
-            vertex.userWorkflowEngine != null) return false;
-        if (userWorkflowName != null ? !userWorkflowName.equals(vertex.userWorkflowName) :
-            vertex.userWorkflowName != null) return false;
-        if (userWorkflowVersion != null ? !userWorkflowVersion.equals(vertex.userWorkflowVersion) :
-            vertex.userWorkflowVersion != null) return false;
-        if (version != null ? !version.equals(vertex.version) : vertex.version != null)
-            return false;
-        if (workflowEngineUrl != null ? !workflowEngineUrl.equals(vertex.workflowEngineUrl) :
-            vertex.workflowEngineUrl != null) return false;
-        if (workflowId != null ? !workflowId.equals(vertex.workflowId) : vertex.workflowId != null)
+        if (_id != vertex._id || !name.equals(vertex.name)
+                || (runId != null ? !runId.equals(vertex.runId) : vertex.runId != null)
+                || (status != null ? !status.equals(vertex.status) : vertex.status != null)
+                || (subflowId != null ? !subflowId.equals(vertex.subflowId)
+                        : vertex.subflowId != null)
+                || !timestamp.equals(vertex.timestamp)
+                || type != vertex.type
+                || (userWorkflowEngine != null
+                        ? !userWorkflowEngine.equals(vertex.userWorkflowEngine)
+                        : vertex.userWorkflowEngine != null)
+                || (userWorkflowName != null ? !userWorkflowName.equals(vertex.userWorkflowName)
+                        : vertex.userWorkflowName != null)
+                || (userWorkflowVersion != null
+                        ? !userWorkflowVersion.equals(vertex.userWorkflowVersion)
+                        : vertex.userWorkflowVersion != null)
+                || (version != null ? !version.equals(vertex.version) : vertex.version != null)
+                || (workflowEngineUrl != null
+                        ? !workflowEngineUrl.equals(vertex.workflowEngineUrl)
+                        : vertex.workflowEngineUrl != null)
+                || (workflowId != null ? !workflowId.equals(vertex.workflowId)
+                        : vertex.workflowId != null)) {
             return false;
+        }
 
         return true;
     }

http://git-wip-us.apache.org/repos/asf/incubator-falcon/blob/ad51ca03/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/response/lineage/VertexIdsResult.java
----------------------------------------------------------------------
diff --git a/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/response/lineage/VertexIdsResult.java b/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/response/lineage/VertexIdsResult.java
index 8f77b5e..4279bdd 100644
--- a/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/response/lineage/VertexIdsResult.java
+++ b/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/response/lineage/VertexIdsResult.java
@@ -20,8 +20,9 @@ package org.apache.falcon.regression.core.response.lineage;
 
 import java.util.List;
 
+/** Class for Lineage API result having vertex ids. */
 public class VertexIdsResult extends GraphResult {
-    List<Integer> results;
+    private List<Integer> results;
 
     public List<Integer> getResults() {
         return results;
@@ -29,9 +30,6 @@ public class VertexIdsResult extends GraphResult {
 
     @Override
     public String toString() {
-        return "AllVertices{" +
-            "totalSize=" + totalSize +
-            ", results=" + results +
-            '}';
+        return String.format("VertexIdsResult{totalSize=%d, results=%s}", totalSize, results);
     }
 }

http://git-wip-us.apache.org/repos/asf/incubator-falcon/blob/ad51ca03/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/response/lineage/VertexResult.java
----------------------------------------------------------------------
diff --git a/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/response/lineage/VertexResult.java b/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/response/lineage/VertexResult.java
index 01954f0..6d419bc 100644
--- a/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/response/lineage/VertexResult.java
+++ b/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/response/lineage/VertexResult.java
@@ -18,8 +18,9 @@
 
 package org.apache.falcon.regression.core.response.lineage;
 
+/** Class for Lineage API result having one vertex. */
 public class VertexResult {
-    Vertex results;
+    private Vertex results;
 
     public Vertex getResults() {
         return results;

http://git-wip-us.apache.org/repos/asf/incubator-falcon/blob/ad51ca03/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/response/lineage/VerticesResult.java
----------------------------------------------------------------------
diff --git a/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/response/lineage/VerticesResult.java b/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/response/lineage/VerticesResult.java
index a35cd2d..abb909c 100644
--- a/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/response/lineage/VerticesResult.java
+++ b/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/response/lineage/VerticesResult.java
@@ -21,8 +21,9 @@ package org.apache.falcon.regression.core.response.lineage;
 import java.util.ArrayList;
 import java.util.List;
 
+/** Class for Lineage API result having vertices. */
 public class VerticesResult extends GraphResult {
-    List<Vertex> results;
+    private List<Vertex> results;
 
     public List<Vertex> getResults() {
         return results;
@@ -30,21 +31,18 @@ public class VerticesResult extends GraphResult {
 
     @Override
     public String toString() {
-        return "AllVertices{" +
-            "totalSize=" + totalSize +
-            ", results=" + results +
-            '}';
+        return String.format("VerticesResult{totalSize=%d, results=%s}", totalSize, results);
     }
 
-    public List<Vertex> filterByType(Vertex.VERTEX_TYPE vertex_type) {
-        return filterVerticesByType(vertex_type, results);
+    public List<Vertex> filterByType(Vertex.VERTEX_TYPE vertexType) {
+        return filterVerticesByType(vertexType, results);
     }
 
-    public List<Vertex> filterVerticesByType(Vertex.VERTEX_TYPE vertex_type,
+    public List<Vertex> filterVerticesByType(Vertex.VERTEX_TYPE vertexType,
                                              List<Vertex> vertexList) {
         List<Vertex> result = new ArrayList<Vertex>();
         for (Vertex vertex : vertexList) {
-            if(vertex.getType() == vertex_type) {
+            if (vertex.getType() == vertexType) {
                 result.add(vertex);
             }
         }
@@ -58,7 +56,7 @@ public class VerticesResult extends GraphResult {
     public List<Vertex> filterVerticesByName(String name, List<Vertex> vertexList) {
         List<Vertex> result = new ArrayList<Vertex>();
         for (Vertex vertex : vertexList) {
-            if(vertex.getName().equals(name)) {
+            if (vertex.getName().equals(name)) {
                 result.add(vertex);
             }
         }

http://git-wip-us.apache.org/repos/asf/incubator-falcon/blob/ad51ca03/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/supportClasses/Brother.java
----------------------------------------------------------------------
diff --git a/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/supportClasses/Brother.java b/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/supportClasses/Brother.java
index 77a5cc6..3fa17e2 100755
--- a/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/supportClasses/Brother.java
+++ b/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/supportClasses/Brother.java
@@ -27,38 +27,39 @@ import org.apache.falcon.regression.core.util.Util.URLS;
 import org.testng.TestNGException;
 import org.apache.log4j.Logger;
 
+/** Class for running a rest request in a parallel thread. */
 public class Brother extends Thread {
-    String operation;
-    String data;
-    URLS url;
-    ServiceResponse output;
-    private static final Logger logger = Logger.getLogger(Brother.class);
+    private String operation;
+    private String data;
+    private URLS url;
+    private ServiceResponse output;
+    private static final Logger LOGGER = Logger.getLogger(Brother.class);
 
     public ServiceResponse getOutput() {
         return output;
     }
 
-    IEntityManagerHelper entityManagerHelper;
+    private IEntityManagerHelper entityManagerHelper;
 
     public Brother(String threadName, String operation, EntityType entityType, ThreadGroup tGroup,
                    Bundle b, ColoHelper p, URLS url) {
         super(tGroup, threadName);
         this.operation = operation;
         switch (entityType) {
-            case PROCESS:
-                this.data = b.getProcessData();
-                this.entityManagerHelper = p.getProcessHelper();
-                break;
-            case CLUSTER:
-                this.entityManagerHelper = p.getClusterHelper();
-                this.data = b.getClusters().get(0);
-                break;
-            case FEED:
-                this.entityManagerHelper = p.getFeedHelper();
-                this.data = b.getDataSets().get(0);
-                break;
-            default:
-                logger.error("Unexpected entityType=" + entityType);
+        case PROCESS:
+            this.data = b.getProcessData();
+            this.entityManagerHelper = p.getProcessHelper();
+            break;
+        case CLUSTER:
+            this.entityManagerHelper = p.getClusterHelper();
+            this.data = b.getClusters().get(0);
+            break;
+        case FEED:
+            this.entityManagerHelper = p.getFeedHelper();
+            this.data = b.getDataSets().get(0);
+            break;
+        default:
+            LOGGER.error("Unexpected entityType=" + entityType);
         }
         this.url = url;
         this.output = new ServiceResponse();
@@ -71,39 +72,39 @@ public class Brother extends Thread {
             e.printStackTrace();
             throw new TestNGException(e.getMessage());
         }
-        logger.info("Brother " + this.getName() + " will be executing " + operation);
+        LOGGER.info("Brother " + this.getName() + " will be executing " + operation);
         try {
             switch (url) {
-                case SUBMIT_URL:
-                    output = entityManagerHelper.submitEntity(url, data);
-                    break;
-                case GET_ENTITY_DEFINITION:
-                    output = entityManagerHelper.getEntityDefinition(url, data);
-                    break;
-                case DELETE_URL:
-                    output = entityManagerHelper.delete(url, data);
-                    break;
-                case SUSPEND_URL:
-                    output = entityManagerHelper.suspend(url, data);
-                    break;
-                case SCHEDULE_URL:
-                    output = entityManagerHelper.schedule(url, data);
-                    break;
-                case RESUME_URL:
-                    output = entityManagerHelper.resume(url, data);
-                    break;
-                case SUBMIT_AND_SCHEDULE_URL:
-                    output = entityManagerHelper.submitAndSchedule(url, data);
-                    break;
-                case STATUS_URL:
-                    output = entityManagerHelper.getStatus(url, data);
-                    break;
-                default:
-                    logger.error("Unexpected url: " + url);
-                    break;
+            case SUBMIT_URL:
+                output = entityManagerHelper.submitEntity(url, data);
+                break;
+            case GET_ENTITY_DEFINITION:
+                output = entityManagerHelper.getEntityDefinition(url, data);
+                break;
+            case DELETE_URL:
+                output = entityManagerHelper.delete(url, data);
+                break;
+            case SUSPEND_URL:
+                output = entityManagerHelper.suspend(url, data);
+                break;
+            case SCHEDULE_URL:
+                output = entityManagerHelper.schedule(url, data);
+                break;
+            case RESUME_URL:
+                output = entityManagerHelper.resume(url, data);
+                break;
+            case SUBMIT_AND_SCHEDULE_URL:
+                output = entityManagerHelper.submitAndSchedule(url, data);
+                break;
+            case STATUS_URL:
+                output = entityManagerHelper.getStatus(url, data);
+                break;
+            default:
+                LOGGER.error("Unexpected url: " + url);
+                break;
             }
-            logger.info("Brother " + getName() + "'s response to the " + operation + " is: " +
-                output);
+            LOGGER.info("Brother " + getName() + "'s response to the "
+                + operation + " is: " + output);
         } catch (Exception e) {
             e.printStackTrace();
         }

http://git-wip-us.apache.org/repos/asf/incubator-falcon/blob/ad51ca03/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/supportClasses/HadoopFileEditor.java
----------------------------------------------------------------------
diff --git a/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/supportClasses/HadoopFileEditor.java b/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/supportClasses/HadoopFileEditor.java
index 0ebcb53..c544e51 100644
--- a/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/supportClasses/HadoopFileEditor.java
+++ b/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/supportClasses/HadoopFileEditor.java
@@ -33,11 +33,12 @@ import java.io.IOException;
 import java.util.ArrayList;
 import java.util.List;
 
+/** Class for simulating editing and restoring of a file in hdfs. */
 public class HadoopFileEditor {
-    private static final Logger logger = Logger.getLogger(HadoopFileEditor.class);
-    FileSystem fs;
-    List<String> paths;
-    List<String> files;
+    private static final Logger LOGGER = Logger.getLogger(HadoopFileEditor.class);
+    private FileSystem fs;
+    private List<String> paths;
+    private List<String> files;
 
     public HadoopFileEditor(FileSystem fs) {
         this.fs = fs;
@@ -64,8 +65,7 @@ public class HadoopFileEditor {
         if (fs.exists(file)) {
             fs.copyToLocalFile(file, new Path(currentFile));
             FileUtils.copyFile(new File(currentFile), new File(currentFile + ".bck"));
-            BufferedWriter bufwriter = new BufferedWriter(new FileWriter
-                ("tmp"));
+            BufferedWriter bufwriter = new BufferedWriter(new FileWriter("tmp"));
             BufferedReader br = new BufferedReader(new FileReader(currentFile));
             String line;
             boolean isInserted = false;
@@ -85,11 +85,12 @@ public class HadoopFileEditor {
 
             fs.delete(file, false);
             File crcFile = new File("." + currentFile + ".crc");
-            if (crcFile.exists())
+            if (crcFile.exists()) {
                 crcFile.delete();
+            }
             fs.copyFromLocalFile(new Path(currentFile), file);
         } else {
-            logger.info("Nothing to do, " + currentFile + " does not exists");
+            LOGGER.info("Nothing to do, " + currentFile + " does not exists");
         }
     }
 

http://git-wip-us.apache.org/repos/asf/incubator-falcon/blob/ad51ca03/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/supportClasses/JmsMessageConsumer.java
----------------------------------------------------------------------
diff --git a/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/supportClasses/JmsMessageConsumer.java b/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/supportClasses/JmsMessageConsumer.java
index d7e952b..3304ae7 100644
--- a/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/supportClasses/JmsMessageConsumer.java
+++ b/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/supportClasses/JmsMessageConsumer.java
@@ -31,6 +31,7 @@ import javax.jms.Session;
 import java.util.ArrayList;
 import java.util.List;
 
+/** Collects JMS messages in a separate thread. */
 public class JmsMessageConsumer extends Thread {
     /*URL of the JMS server
     brokerURL = "tcp://host:61616?daemon=true";
@@ -38,12 +39,12 @@ public class JmsMessageConsumer extends Thread {
     Name of the queue we will receive messages from
     String subject = "IVORY.TOPIC";*/
 
-    private static final Logger logger = Logger.getLogger(JmsMessageConsumer.class);
+    private static final Logger LOGGER = Logger.getLogger(JmsMessageConsumer.class);
     private static final int MAX_MESSAGE_COUNT = 1000;
 
-    final String brokerURL;
-    final String topicName;
-    final List<MapMessage> receivedMessages;
+    private final String brokerURL;
+    private final String topicName;
+    private final List<MapMessage> receivedMessages;
 
     public List<MapMessage> getReceivedMessages() {
         return receivedMessages;
@@ -69,26 +70,26 @@ public class JmsMessageConsumer extends Thread {
             MessageConsumer consumer = session.createConsumer(destination);
 
             try {
-                logger.info("Starting to receive messages.");
+                LOGGER.info("Starting to receive messages.");
                 int count = 0;
-                for (; count < MAX_MESSAGE_COUNT; ++ count) {
+                for (; count < MAX_MESSAGE_COUNT; ++count) {
                     Message message = consumer.receive(); //blocking call
                     if (message == null) {
-                        logger.info("Received empty message, count = " + count);
+                        LOGGER.info("Received empty message, count = " + count);
                     } else {
-                        logger.info("Received message, id = " + message.getJMSMessageID());
+                        LOGGER.info("Received message, id = " + message.getJMSMessageID());
                         receivedMessages.add((MapMessage) message);
                     }
                 }
                 if (count >= MAX_MESSAGE_COUNT) {
-                    logger.warn("Not reading more messages, already read " + count + " messages.");
+                    LOGGER.warn("Not reading more messages, already read " + count + " messages.");
                 }
             } finally {
-                logger.info("Stopping to receive messages.");
+                LOGGER.info("Stopping to receive messages.");
                 connection.close();
             }
         } catch (Exception e) {
-            logger.info("caught exception: " + ExceptionUtils.getStackTrace(e));
+            LOGGER.info("caught exception: " + ExceptionUtils.getStackTrace(e));
         }
     }
 

http://git-wip-us.apache.org/repos/asf/incubator-falcon/blob/ad51ca03/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/util/AssertUtil.java
----------------------------------------------------------------------
diff --git a/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/util/AssertUtil.java b/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/util/AssertUtil.java
index db73eda..d8ac903 100644
--- a/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/util/AssertUtil.java
+++ b/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/util/AssertUtil.java
@@ -197,7 +197,7 @@ public final class AssertUtil {
      */
     public static void assertFailedWithStatus(final ServiceResponse response, final int statusCode,
                                               final String message) throws JAXBException {
-        Assert.assertNotEquals(response.message, "null", "response message should not be null");
+        Assert.assertNotEquals(response.getMessage(), "null", "response message should not be null");
         Assert.assertEquals(Util.parseResponse(response).getStatus(),
             APIResult.Status.FAILED, message);
         Assert.assertEquals(Util.parseResponse(response).getStatusCode(), statusCode,
@@ -224,7 +224,7 @@ public final class AssertUtil {
      * @throws JAXBException
      */
     public static void assertFailed(ServiceResponse response) throws JAXBException {
-        Assert.assertNotEquals(response.message, "null", "response message should not be null");
+        Assert.assertNotEquals(response.getMessage(), "null", "response message should not be null");
 
         Assert.assertEquals(Util.parseResponse(response).getStatus(), APIResult.Status.FAILED);
         Assert.assertEquals(Util.parseResponse(response).getStatusCode(), 400);

http://git-wip-us.apache.org/repos/asf/incubator-falcon/blob/ad51ca03/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/util/Config.java
----------------------------------------------------------------------
diff --git a/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/util/Config.java b/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/util/Config.java
index a6e83ef..a897661 100644
--- a/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/util/Config.java
+++ b/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/util/Config.java
@@ -23,8 +23,9 @@ import org.apache.commons.configuration.PropertiesConfiguration;
 import org.apache.log4j.Logger;
 import org.testng.Assert;
 
-public class Config {
-    private static final Logger logger = Logger.getLogger(Config.class);
+/** Class for reading properties from Merlin.properties file. */
+public final class Config {
+    private static final Logger LOGGER = Logger.getLogger(Config.class);
 
     private static final String MERLIN_PROPERTIES = "Merlin.properties";
     private static final Config INSTANCE = new Config(MERLIN_PROPERTIES);
@@ -32,7 +33,7 @@ public class Config {
     private PropertiesConfiguration confObj;
     private Config(String propFileName) {
         try {
-            logger.info("Going to read properties from: " + propFileName);
+            LOGGER.info("Going to read properties from: " + propFileName);
             confObj = new PropertiesConfiguration(Config.class.getResource("/" + propFileName));
         } catch (ConfigurationException e) {
             Assert.fail("Could not read properties because of exception: " + e);

http://git-wip-us.apache.org/repos/asf/incubator-falcon/blob/ad51ca03/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/util/Generator.java
----------------------------------------------------------------------
diff --git a/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/util/Generator.java b/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/util/Generator.java
index 86f9d6f..5842ced 100644
--- a/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/util/Generator.java
+++ b/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/util/Generator.java
@@ -18,10 +18,11 @@
 
 package org.apache.falcon.regression.core.util;
 
-public class Generator {
-    final String prefix;
-    final String postfix;
-    final String formatString;
+/** Generator class for generating predictable names and paths. */
+public final class Generator {
+    private final String prefix;
+    private final String postfix;
+    private final String formatString;
     private int count;
 
 

http://git-wip-us.apache.org/repos/asf/incubator-falcon/blob/ad51ca03/falcon-regression/merlin-core/src/main/java/org/apache/falcon/request/BaseRequest.java
----------------------------------------------------------------------
diff --git a/falcon-regression/merlin-core/src/main/java/org/apache/falcon/request/BaseRequest.java b/falcon-regression/merlin-core/src/main/java/org/apache/falcon/request/BaseRequest.java
index 8d125b0..549b986 100644
--- a/falcon-regression/merlin-core/src/main/java/org/apache/falcon/request/BaseRequest.java
+++ b/falcon-regression/merlin-core/src/main/java/org/apache/falcon/request/BaseRequest.java
@@ -45,9 +45,10 @@ import java.net.URISyntaxException;
 import java.util.ArrayList;
 import java.util.List;
 
+/** Class for making rest requests. */
 public class BaseRequest {
 
-    private static final Logger logger = Logger.getLogger(BaseRequest.class);
+    private static final Logger LOGGER = Logger.getLogger(BaseRequest.class);
 
     private String method;
     private String url;
@@ -115,17 +116,17 @@ public class BaseRequest {
         /*get the token and add it to the header.
         works in secure and un secure mode.*/
         AuthenticatedURL.Token token;
-        if(IEntityManagerHelper.AUTHENTICATE) {
+        if (IEntityManagerHelper.AUTHENTICATE) {
             token = FalconAuthorizationToken.getToken(user, uri.getScheme(),
                     uri.getHost(), uri.getPort());
             request.addHeader(RequestKeys.COOKIE, RequestKeys.AUTH_COOKIE_EQ + token);
         }
         DefaultHttpClient client = new DefaultHttpClient();
-        logger.info("Request Url: " + request.getRequestLine().getUri());
-        logger.info("Request Method: " + request.getRequestLine().getMethod());
+        LOGGER.info("Request Url: " + request.getRequestLine().getUri());
+        LOGGER.info("Request Method: " + request.getRequestLine().getMethod());
 
         for (Header header : request.getAllHeaders()) {
-            logger.info(String.format("Request Header: Name=%s Value=%s", header.getName(),
+            LOGGER.info(String.format("Request Header: Name=%s Value=%s", header.getName(),
                 header.getValue()));
         }
         HttpResponse response = client.execute(target, request);
@@ -134,30 +135,28 @@ public class BaseRequest {
         and send the request*/
         if ((response.getStatusLine().getStatusCode() == HttpStatus.SC_UNAUTHORIZED)) {
             Header[] wwwAuthHeaders = response.getHeaders(RequestKeys.WWW_AUTHENTICATE);
-            if (wwwAuthHeaders != null && wwwAuthHeaders.length != 0 &&
-                wwwAuthHeaders[0].getValue().trim().startsWith(RequestKeys.NEGOTIATE)) {
-            	if(IEntityManagerHelper.AUTHENTICATE) {
-            		token = FalconAuthorizationToken.getToken(user, uri.getScheme(),
-                            uri.getHost(), uri.getPort(), true);
+            if (wwwAuthHeaders != null && wwwAuthHeaders.length != 0
+                && wwwAuthHeaders[0].getValue().trim().startsWith(RequestKeys.NEGOTIATE)) {
+                if (IEntityManagerHelper.AUTHENTICATE) {
+                    token = FalconAuthorizationToken.getToken(user, uri.getScheme(),
+                        uri.getHost(), uri.getPort(), true);
                     request.removeHeaders(RequestKeys.COOKIE);
                     request.addHeader(RequestKeys.COOKIE, RequestKeys.AUTH_COOKIE_EQ + token);
-            	}
-                logger.info("Request Url: " + request.getRequestLine().getUri());
-                logger.info("Request Method: " + request.getRequestLine().getMethod());
+                }
+                LOGGER.info("Request Url: " + request.getRequestLine().getUri());
+                LOGGER.info("Request Method: " + request.getRequestLine().getMethod());
                 for (Header header : request.getAllHeaders()) {
-                    logger.info(
-                        String.format("Request Header: Name=%s Value=%s", header.getName(),
-                            header.getValue())
-                    );
+                    LOGGER.info(String.format("Request Header: Name=%s Value=%s", header.getName(),
+                        header.getValue()));
                 }
                 response = client.execute(target, request);
             }
         }
-        logger.info("Response Status: " + response.getStatusLine());
+        LOGGER.info("Response Status: " + response.getStatusLine());
         for (Header header : response.getAllHeaders()) {
-            logger.info(String.format("Response Header: Name=%s Value=%s", header.getName(),
+            LOGGER.info(String.format("Response Header: Name=%s Value=%s", header.getName(),
                 header.getValue()));
         }
         return response;
     }
-}
\ No newline at end of file
+}

http://git-wip-us.apache.org/repos/asf/incubator-falcon/blob/ad51ca03/falcon-regression/merlin-core/src/main/java/org/apache/falcon/request/RequestKeys.java
----------------------------------------------------------------------
diff --git a/falcon-regression/merlin-core/src/main/java/org/apache/falcon/request/RequestKeys.java b/falcon-regression/merlin-core/src/main/java/org/apache/falcon/request/RequestKeys.java
index b2a02f7..3232978 100644
--- a/falcon-regression/merlin-core/src/main/java/org/apache/falcon/request/RequestKeys.java
+++ b/falcon-regression/merlin-core/src/main/java/org/apache/falcon/request/RequestKeys.java
@@ -18,7 +18,12 @@
 
 package org.apache.falcon.request;
 
-public class RequestKeys {
+/** Class containing different request keys. */
+public final class RequestKeys {
+    private RequestKeys() {
+        throw new AssertionError("Instantiating utility class...");
+    }
+
     public static final String CONTENT_TYPE_HEADER = "Content-Type";
     public static final String XML_CONTENT_TYPE = "text/xml";
 

http://git-wip-us.apache.org/repos/asf/incubator-falcon/blob/ad51ca03/falcon-regression/merlin-core/src/main/java/org/apache/falcon/security/FalconAuthorizationToken.java
----------------------------------------------------------------------
diff --git a/falcon-regression/merlin-core/src/main/java/org/apache/falcon/security/FalconAuthorizationToken.java b/falcon-regression/merlin-core/src/main/java/org/apache/falcon/security/FalconAuthorizationToken.java
index 3c26567..f5a075e 100644
--- a/falcon-regression/merlin-core/src/main/java/org/apache/falcon/security/FalconAuthorizationToken.java
+++ b/falcon-regression/merlin-core/src/main/java/org/apache/falcon/security/FalconAuthorizationToken.java
@@ -28,11 +28,12 @@ import java.io.IOException;
 import java.net.URL;
 import java.util.concurrent.ConcurrentHashMap;
 
-public class FalconAuthorizationToken {
+/** Class for obtaining authorization token. */
+public final class FalconAuthorizationToken {
     private static final String AUTH_URL = "api/options";
     private static final KerberosAuthenticator AUTHENTICATOR = new KerberosAuthenticator();
     private static final FalconAuthorizationToken INSTANCE = new FalconAuthorizationToken();
-    private static final Logger logger = Logger.getLogger(FalconAuthorizationToken.class);
+    private static final Logger LOGGER = Logger.getLogger(FalconAuthorizationToken.class);
 
     // Use a hashmap so that we can cache the tokens.
     private final ConcurrentHashMap<String, AuthenticatedURL.Token> tokens =
@@ -46,7 +47,7 @@ public class FalconAuthorizationToken {
         throws IOException, AuthenticationException {
         URL url = new URL(String.format("%s://%s:%d/%s", protocol, host, port,
             AUTH_URL + "?" + PseudoAuthenticator.USER_NAME + "=" + user));
-        logger.info("Authorize using url: " + url.toString());
+        LOGGER.info("Authorize using url: " + url.toString());
         AuthenticatedURL.Token currentToken = new AuthenticatedURL.Token();
 
         /*using KerberosAuthenticator which falls back to PsuedoAuthenticator
@@ -55,7 +56,7 @@ public class FalconAuthorizationToken {
         String key = getKey(user, protocol, host, port);
 
         // initialize a hash map if its null.
-        logger.info("Authorization Token: " + currentToken.toString());
+        LOGGER.info("Authorization Token: " + currentToken.toString());
         INSTANCE.tokens.put(key, currentToken);
     }
 
@@ -83,4 +84,4 @@ public class FalconAuthorizationToken {
     private static String getKey(String user, String protocol, String host, int port) {
         return String.format("%s-%s-%s-%d", user, protocol, host, port);
     }
-}
\ No newline at end of file
+}


Mime
View raw message