diff --git a/datarouter-prov/src/main/java/org/onap/dmaap/datarouter/provisioning/beans/Feed.java b/datarouter-prov/src/main/java/org/onap/dmaap/datarouter/provisioning/beans/Feed.java
index 852321a..c08bce5 100644
--- a/datarouter-prov/src/main/java/org/onap/dmaap/datarouter/provisioning/beans/Feed.java
+++ b/datarouter-prov/src/main/java/org/onap/dmaap/datarouter/provisioning/beans/Feed.java
@@ -24,20 +24,6 @@
 
 package org.onap.dmaap.datarouter.provisioning.beans;
 
-import java.io.InvalidObjectException;
-import java.sql.Connection;
-import java.sql.PreparedStatement;
-import java.sql.ResultSet;
-import java.sql.SQLException;
-import java.sql.Statement;
-import java.util.ArrayList;
-import java.util.Collection;
-import java.util.Date;
-import java.util.HashMap;
-import java.util.List;
-import java.util.Map;
-import java.util.Set;
-
 import org.apache.log4j.Logger;
 import org.json.JSONArray;
 import org.json.JSONObject;
@@ -45,6 +31,11 @@
 import org.onap.dmaap.datarouter.provisioning.utils.JSONUtilities;
 import org.onap.dmaap.datarouter.provisioning.utils.URLUtilities;
 
+import java.io.InvalidObjectException;
+import java.sql.*;
+import java.util.*;
+import java.util.Date;
+
 /**
  * The representation of a Feed.  Feeds can be retrieved from the DB, or stored/updated in the DB.
  *
@@ -81,13 +72,13 @@
         try {
             DB db = new DB();
             Connection conn = db.getConnection();
-            Statement stmt = conn.createStatement();
-            ResultSet rs = stmt.executeQuery("select COUNT(*) from FEEDS where FEEDID = " + id);
-            if (rs.next()) {
-                count = rs.getInt(1);
+            try(Statement stmt = conn.createStatement()) {
+                try(ResultSet rs = stmt.executeQuery("select COUNT(*) from FEEDS where FEEDID = " + id)) {
+                    if (rs.next()) {
+                        count = rs.getInt(1);
+                    }
+                }
             }
-            rs.close();
-            stmt.close();
             db.release(conn);
         } catch (SQLException e) {
             e.printStackTrace();
@@ -131,13 +122,13 @@
             DB db = new DB();
             @SuppressWarnings("resource")
             Connection conn = db.getConnection();
-            Statement stmt = conn.createStatement();
-            ResultSet rs = stmt.executeQuery("select count(*) from FEEDS where DELETED = 0");
-            if (rs.next()) {
-                count = rs.getInt(1);
+            try(Statement stmt = conn.createStatement()) {
+                try (ResultSet rs = stmt.executeQuery("select count(*) from FEEDS where DELETED = 0")) {
+                    if (rs.next()) {
+                        count = rs.getInt(1);
+                    }
+                }
             }
-            rs.close();
-            stmt.close();
             db.release(conn);
         } catch (SQLException e) {
             intlogger.info("countActiveFeeds: " + e.getMessage());
@@ -152,13 +143,13 @@
             DB db = new DB();
             @SuppressWarnings("resource")
             Connection conn = db.getConnection();
-            Statement stmt = conn.createStatement();
-            ResultSet rs = stmt.executeQuery("select MAX(feedid) from FEEDS");
-            if (rs.next()) {
-                max = rs.getInt(1);
+            try(Statement stmt = conn.createStatement()) {
+                try (ResultSet rs = stmt.executeQuery("select MAX(feedid) from FEEDS")) {
+                    if (rs.next()) {
+                        max = rs.getInt(1);
+                    }
+                }
             }
-            rs.close();
-            stmt.close();
             db.release(conn);
         } catch (SQLException e) {
             intlogger.info("getMaxFeedID: " + e.getMessage());
@@ -173,40 +164,39 @@
             DB db = new DB();
             @SuppressWarnings("resource")
             Connection conn = db.getConnection();
-            Statement stmt = conn.createStatement();
-            ResultSet rs = stmt.executeQuery("select * from FEEDS");
-            while (rs.next()) {
-                Feed feed = new Feed(rs);
-                map.put(feed.getFeedid(), feed);
-            }
-            rs.close();
+            try(Statement stmt = conn.createStatement()) {
+                try(ResultSet rs = stmt.executeQuery("select * from FEEDS")) {
+                    while (rs.next()) {
+                        Feed feed = new Feed(rs);
+                        map.put(feed.getFeedid(), feed);
+                    }
+                }
 
-            String sql = "select * from FEED_ENDPOINT_IDS";
-            rs = stmt.executeQuery(sql);
-            while (rs.next()) {
-                int id = rs.getInt("FEEDID");
-                Feed feed = map.get(id);
-                if (feed != null) {
-                    FeedEndpointID epi = new FeedEndpointID(rs);
-                    Collection<FeedEndpointID> ecoll = feed.getAuthorization().getEndpoint_ids();
-                    ecoll.add(epi);
+                String sql = "select * from FEED_ENDPOINT_IDS";
+                try(ResultSet rs = stmt.executeQuery(sql)){
+                    while (rs.next()) {
+                        int id = rs.getInt("FEEDID");
+                        Feed feed = map.get(id);
+                        if (feed != null) {
+                            FeedEndpointID epi = new FeedEndpointID(rs);
+                            Collection<FeedEndpointID> ecoll = feed.getAuthorization().getEndpoint_ids();
+                            ecoll.add(epi);
+                        }
+                    }
+                }
+
+                sql = "select * from FEED_ENDPOINT_ADDRS";
+                try(ResultSet rs = stmt.executeQuery(sql)) {
+                    while (rs.next()) {
+                        int id = rs.getInt("FEEDID");
+                        Feed feed = map.get(id);
+                        if (feed != null) {
+                            Collection<String> acoll = feed.getAuthorization().getEndpoint_addrs();
+                            acoll.add(rs.getString("ADDR"));
+                        }
+                    }
                 }
             }
-            rs.close();
-
-            sql = "select * from FEED_ENDPOINT_ADDRS";
-            rs = stmt.executeQuery(sql);
-            while (rs.next()) {
-                int id = rs.getInt("FEEDID");
-                Feed feed = map.get(id);
-                if (feed != null) {
-                    Collection<String> acoll = feed.getAuthorization().getEndpoint_addrs();
-                    acoll.add(rs.getString("ADDR"));
-                }
-            }
-            rs.close();
-
-            stmt.close();
             db.release(conn);
         } catch (SQLException e) {
             e.printStackTrace();
@@ -231,16 +221,16 @@
             DB db = new DB();
             @SuppressWarnings("resource")
             Connection conn = db.getConnection();
-            PreparedStatement ps = conn.prepareStatement(sql);
-            if (sql.indexOf('?') >= 0)
-                ps.setString(1, val);
-            ResultSet rs = ps.executeQuery();
-            while (rs.next()) {
-                String t = rs.getString(1);
-                list.add(t.trim());
+            try(PreparedStatement ps = conn.prepareStatement(sql)) {
+                if (sql.indexOf('?') >= 0)
+                    ps.setString(1, val);
+                try(ResultSet rs = ps.executeQuery()) {
+                    while (rs.next()) {
+                        String t = rs.getString(1);
+                        list.add(t.trim());
+                    }
+                }
             }
-            rs.close();
-            ps.close();
             db.release(conn);
         } catch (SQLException e) {
             e.printStackTrace();
@@ -254,30 +244,30 @@
         try {
             DB db = new DB();
             Connection conn = db.getConnection();
-            Statement stmt = conn.createStatement();
-            ResultSet rs = stmt.executeQuery(sql);
-            if (rs.next()) {
-                feed = new Feed(rs);
-                rs.close();
-
-                sql = "select * from FEED_ENDPOINT_IDS where FEEDID = " + feed.feedid;
-                rs = stmt.executeQuery(sql);
-                Collection<FeedEndpointID> ecoll = feed.getAuthorization().getEndpoint_ids();
-                while (rs.next()) {
-                    FeedEndpointID epi = new FeedEndpointID(rs);
-                    ecoll.add(epi);
+            try (Statement stmt = conn.createStatement()) {
+                try (ResultSet rs = stmt.executeQuery(sql)) {
+                    if (rs.next()) {
+                        feed = new Feed(rs);
+                    }
                 }
-                rs.close();
-
-                sql = "select * from FEED_ENDPOINT_ADDRS where FEEDID = " + feed.feedid;
-                rs = stmt.executeQuery(sql);
-                Collection<String> acoll = feed.getAuthorization().getEndpoint_addrs();
-                while (rs.next()) {
-                    acoll.add(rs.getString("ADDR"));
+                if (feed != null) {
+                    sql = "select * from FEED_ENDPOINT_IDS where FEEDID = " + feed.feedid;
+                    try (ResultSet rs = stmt.executeQuery(sql)) {
+                        Collection<FeedEndpointID> ecoll = feed.getAuthorization().getEndpoint_ids();
+                        while (rs.next()) {
+                            FeedEndpointID epi = new FeedEndpointID(rs);
+                            ecoll.add(epi);
+                        }
+                    }
+                    sql = "select * from FEED_ENDPOINT_ADDRS where FEEDID = " + feed.feedid;
+                    try (ResultSet rs = stmt.executeQuery(sql)) {
+                        Collection<String> acoll = feed.getAuthorization().getEndpoint_addrs();
+                        while (rs.next()) {
+                            acoll.add(rs.getString("ADDR"));
+                        }
+                    }
                 }
             }
-            rs.close();
-            stmt.close();
             db.release(conn);
         } catch (SQLException e) {
             e.printStackTrace();
@@ -546,7 +536,9 @@
             e.printStackTrace();
         } finally {
             try {
-                ps.close();
+                if(ps!=null) {
+                    ps.close();
+                }
             } catch (SQLException e) {
                 e.printStackTrace();
             }
@@ -557,17 +549,8 @@
     @Override
     public synchronized boolean doInsert(Connection c) {
         boolean rv = true;
-//        PreparedStatement ps = null;
         try {
             if (feedid == -1) {
-//                // Get the next feedid
-//                String sql = "insert into FEEDS_UNIQUEID (FEEDID) values (0)";
-//                ps = c.prepareStatement(sql, new String[] { "FEEDID" });
-//                ps.execute();
-//                ResultSet rs = ps.getGeneratedKeys();
-//                rs.first();
-//                setFeedid(rs.getInt(1));
-                // No feed ID assigned yet, so assign the next available one
                 setFeedid(next_feedid++);
             }
             // In case we insert a feed from synchronization
@@ -577,54 +560,48 @@
             // Create FEED_ENDPOINT_IDS rows
             FeedAuthorization auth = getAuthorization();
             String sql = "insert into FEED_ENDPOINT_IDS values (?, ?, ?)";
-            PreparedStatement ps2 = c.prepareStatement(sql);
-            for (FeedEndpointID fid : auth.getEndpoint_ids()) {
-                ps2.setInt(1, feedid);
-                ps2.setString(2, fid.getId());
-                ps2.setString(3, fid.getPassword());
-                ps2.executeUpdate();
+            try(PreparedStatement ps2 = c.prepareStatement(sql)) {
+                for (FeedEndpointID fid : auth.getEndpoint_ids()) {
+                    ps2.setInt(1, feedid);
+                    ps2.setString(2, fid.getId());
+                    ps2.setString(3, fid.getPassword());
+                    ps2.executeUpdate();
+                }
             }
-            ps2.close();
 
             // Create FEED_ENDPOINT_ADDRS rows
             sql = "insert into FEED_ENDPOINT_ADDRS values (?, ?)";
-            ps2 = c.prepareStatement(sql);
-            for (String t : auth.getEndpoint_addrs()) {
-                ps2.setInt(1, feedid);
-                ps2.setString(2, t);
-                ps2.executeUpdate();
+            try(PreparedStatement ps2 = c.prepareStatement(sql)) {
+                for (String t : auth.getEndpoint_addrs()) {
+                    ps2.setInt(1, feedid);
+                    ps2.setString(2, t);
+                    ps2.executeUpdate();
+                }
             }
-            ps2.close();
 
             // Finally, create the FEEDS row
             sql = "insert into FEEDS (FEEDID, NAME, VERSION, DESCRIPTION, AUTH_CLASS, PUBLISHER, SELF_LINK, PUBLISH_LINK, SUBSCRIBE_LINK, LOG_LINK, DELETED, SUSPENDED,BUSINESS_DESCRIPTION, GROUPID) values (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?,?, ?)";
-            ps2 = c.prepareStatement(sql);
-            ps2.setInt(1, feedid);
-            ps2.setString(2, getName());
-            ps2.setString(3, getVersion());
-            ps2.setString(4, getDescription());
-            ps2.setString(5, getAuthorization().getClassification());
-            ps2.setString(6, getPublisher());
-            ps2.setString(7, getLinks().getSelf());
-            ps2.setString(8, getLinks().getPublish());
-            ps2.setString(9, getLinks().getSubscribe());
-            ps2.setString(10, getLinks().getLog());
-            ps2.setBoolean(11, isDeleted());
-            ps2.setBoolean(12, isSuspended());
-            ps2.setString(13, getBusiness_description()); // New field is added - Groups feature Rally:US708102 - 1610
-            ps2.setInt(14, groupid); //New field is added - Groups feature Rally:US708115 - 1610
-            ps2.executeUpdate();
-            ps2.close();
+            try(PreparedStatement ps2 = c.prepareStatement(sql)) {
+                ps2.setInt(1, feedid);
+                ps2.setString(2, getName());
+                ps2.setString(3, getVersion());
+                ps2.setString(4, getDescription());
+                ps2.setString(5, getAuthorization().getClassification());
+                ps2.setString(6, getPublisher());
+                ps2.setString(7, getLinks().getSelf());
+                ps2.setString(8, getLinks().getPublish());
+                ps2.setString(9, getLinks().getSubscribe());
+                ps2.setString(10, getLinks().getLog());
+                ps2.setBoolean(11, isDeleted());
+                ps2.setBoolean(12, isSuspended());
+                ps2.setString(13, getBusiness_description()); // New field is added - Groups feature Rally:US708102 - 1610
+                ps2.setInt(14, groupid); //New field is added - Groups feature Rally:US708115 - 1610
+                ps2.executeUpdate();
+            }
         } catch (SQLException e) {
             rv = false;
             intlogger.warn("PROV0005 doInsert: " + e.getMessage());
             e.printStackTrace();
-//        } finally {
-//            try {
-//                ps.close();
-//            } catch (SQLException e) {
-//                e.printStackTrace();
-//            }
         }
         return rv;
     }
@@ -741,7 +718,9 @@
             e.printStackTrace();
         } finally {
             try {
-                ps.close();
+                if(ps!=null) {
+                    ps.close();
+                }
             } catch (SQLException e) {
                 e.printStackTrace();
             }
@@ -789,4 +768,9 @@
     public String toString() {
         return "FEED: feedid=" + feedid + ", name=" + name + ", version=" + version;
     }
+
+    @Override
+    public int hashCode() {
+        return Objects.hash(feedid, groupid, name, version, description, business_description, authorization, publisher, links, deleted, suspended, last_mod, created_date);
+    }
 }
diff --git a/datarouter-prov/src/main/java/org/onap/dmaap/datarouter/provisioning/beans/Group.java b/datarouter-prov/src/main/java/org/onap/dmaap/datarouter/provisioning/beans/Group.java
index a021a60..a460d64 100644
--- a/datarouter-prov/src/main/java/org/onap/dmaap/datarouter/provisioning/beans/Group.java
+++ b/datarouter-prov/src/main/java/org/onap/dmaap/datarouter/provisioning/beans/Group.java
@@ -29,10 +29,7 @@
 import java.sql.ResultSet;
 import java.sql.SQLException;
 import java.sql.Statement;
-import java.util.ArrayList;
-import java.util.Collection;
-import java.util.Date;
-import java.util.List;
+import java.util.*;
 
 import org.apache.log4j.Logger;
 import org.json.JSONObject;
@@ -99,14 +96,14 @@
             DB db = new DB();
             @SuppressWarnings("resource")
             Connection conn = db.getConnection();
-            Statement stmt = conn.createStatement();
-            ResultSet rs = stmt.executeQuery(sql);
-            while (rs.next()) {
-                Group group = new Group(rs);
-                list.add(group);
+            try(Statement stmt = conn.createStatement()) {
+                try(ResultSet rs = stmt.executeQuery(sql)) {
+                    while (rs.next()) {
+                        Group group = new Group(rs);
+                        list.add(group);
+                    }
+                }
             }
-            rs.close();
-            stmt.close();
             db.release(conn);
         } catch (SQLException e) {
             e.printStackTrace();
@@ -120,13 +117,13 @@
             DB db = new DB();
             @SuppressWarnings("resource")
             Connection conn = db.getConnection();
-            Statement stmt = conn.createStatement();
-            ResultSet rs = stmt.executeQuery("select MAX(groupid) from GROUPS");
-            if (rs.next()) {
-                max = rs.getInt(1);
+            try(Statement stmt = conn.createStatement()) {
+                try(ResultSet rs = stmt.executeQuery("select MAX(groupid) from GROUPS")) {
+                    if (rs.next()) {
+                        max = rs.getInt(1);
+                    }
+                }
             }
-            rs.close();
-            stmt.close();
             db.release(conn);
         } catch (SQLException e) {
             intlogger.info("getMaxSubID: " + e.getMessage());
@@ -142,14 +139,14 @@
             DB db = new DB();
             @SuppressWarnings("resource")
             Connection conn = db.getConnection();
-            Statement stmt = conn.createStatement();
-            ResultSet rs = stmt.executeQuery(sql);
-            while (rs.next()) {
-                int groupid = rs.getInt("groupid");
-                //list.add(URLUtilities.generateSubscriptionURL(groupid));
+            try(Statement stmt = conn.createStatement()) {
+                try(ResultSet rs = stmt.executeQuery(sql)) {
+                    while (rs.next()) {
+                        int groupid = rs.getInt("groupid");
+
+                    }
+                }
             }
-            rs.close();
-            stmt.close();
             db.release(conn);
         } catch (SQLException e) {
             e.printStackTrace();
@@ -168,13 +165,13 @@
             DB db = new DB();
             @SuppressWarnings("resource")
             Connection conn = db.getConnection();
-            Statement stmt = conn.createStatement();
-            ResultSet rs = stmt.executeQuery("select count(*) from SUBSCRIPTIONS");
-            if (rs.next()) {
-                count = rs.getInt(1);
+            try(Statement stmt = conn.createStatement()) {
+                try(ResultSet rs = stmt.executeQuery("select count(*) from SUBSCRIPTIONS")) {
+                    if (rs.next()) {
+                        count = rs.getInt(1);
+                    }
+                }
             }
-            rs.close();
-            stmt.close();
             db.release(conn);
         } catch (SQLException e) {
             intlogger.warn("PROV0008 countActiveSubscriptions: " + e.getMessage());
@@ -351,7 +348,9 @@
             e.printStackTrace();
         } finally {
             try {
-                ps.close();
+                if(ps!=null) {
+                    ps.close();
+                }
             } catch (SQLException e) {
                 e.printStackTrace();
             }
@@ -379,7 +378,9 @@
             e.printStackTrace();
         } finally {
             try {
-                ps.close();
+                if(ps!=null) {
+                    ps.close();
+                }
             } catch (SQLException e) {
                 e.printStackTrace();
             }
@@ -402,7 +403,9 @@
             e.printStackTrace();
         } finally {
             try {
-                ps.close();
+                if(ps!=null) {
+                    ps.close();
+                }
             } catch (SQLException e) {
                 e.printStackTrace();
             }
@@ -440,4 +443,9 @@
     public String toString() {
         return "GROUP: groupid=" + groupid;
     }
+
+    @Override
+    public int hashCode() {
+        return Objects.hash(groupid, authid, name, description, classification, members, last_mod);
+    }
 }
diff --git a/datarouter-prov/src/main/java/org/onap/dmaap/datarouter/provisioning/beans/IngressRoute.java b/datarouter-prov/src/main/java/org/onap/dmaap/datarouter/provisioning/beans/IngressRoute.java
index 0de57df..a4ed60a 100644
--- a/datarouter-prov/src/main/java/org/onap/dmaap/datarouter/provisioning/beans/IngressRoute.java
+++ b/datarouter-prov/src/main/java/org/onap/dmaap/datarouter/provisioning/beans/IngressRoute.java
@@ -85,18 +85,18 @@
             DB db = new DB();
             @SuppressWarnings("resource")
             Connection conn = db.getConnection();
-            Statement stmt = conn.createStatement();
-            ResultSet rs = stmt.executeQuery(sql);
-            while (rs.next()) {
-                int seq = rs.getInt("SEQUENCE");
-                int feedid = rs.getInt("FEEDID");
-                String user = rs.getString("USERID");
-                String subnet = rs.getString("SUBNET");
-                int nodeset = rs.getInt("NODESET");
-                set.add(new IngressRoute(seq, feedid, user, subnet, nodeset));
+            try(Statement stmt = conn.createStatement()) {
+                try(ResultSet rs = stmt.executeQuery(sql)) {
+                    while (rs.next()) {
+                        int seq = rs.getInt("SEQUENCE");
+                        int feedid = rs.getInt("FEEDID");
+                        String user = rs.getString("USERID");
+                        String subnet = rs.getString("SUBNET");
+                        int nodeset = rs.getInt("NODESET");
+                        set.add(new IngressRoute(seq, feedid, user, subnet, nodeset));
+                    }
+                }
             }
-            rs.close();
-            stmt.close();
             db.release(conn);
         } catch (SQLException e) {
             e.printStackTrace();
@@ -128,13 +128,13 @@
             DB db = new DB();
             @SuppressWarnings("resource")
             Connection conn = db.getConnection();
-            Statement stmt = conn.createStatement();
-            ResultSet rs = stmt.executeQuery(sql);
-            if (rs.next()) {
-                rv = rs.getInt("MAX");
+            try(Statement stmt = conn.createStatement()) {
+               try(ResultSet rs = stmt.executeQuery(sql)) {
+                   if (rs.next()) {
+                       rv = rs.getInt("MAX");
+                   }
+               }
             }
-            rs.close();
-            stmt.close();
             db.release(conn);
         } catch (SQLException e) {
             e.printStackTrace();
@@ -162,20 +162,22 @@
             ps.setInt(1, feedid);
             ps.setString(2, user);
             ps.setString(3, subnet);
-            ResultSet rs = ps.executeQuery();
-            if (rs.next()) {
-                int seq = rs.getInt("SEQUENCE");
-                int nodeset = rs.getInt("NODESET");
-                v = new IngressRoute(seq, feedid, user, subnet, nodeset);
+            try(ResultSet rs = ps.executeQuery()) {
+                if (rs.next()) {
+                    int seq = rs.getInt("SEQUENCE");
+                    int nodeset = rs.getInt("NODESET");
+                    v = new IngressRoute(seq, feedid, user, subnet, nodeset);
+                }
             }
-            rs.close();
             ps.close();
             db.release(conn);
         } catch (SQLException e) {
             e.printStackTrace();
         } finally {
             try {
-                ps.close();
+                if(ps!=null) {
+                    ps.close();
+                }
             } catch (SQLException e) {
                 e.printStackTrace();
             }
@@ -191,33 +193,26 @@
      */
     public static Collection<IngressRoute> getIngressRoute(int seq) {
         Collection<IngressRoute> rv = new ArrayList<IngressRoute>();
-        PreparedStatement ps = null;
         try {
             DB db = new DB();
             @SuppressWarnings("resource")
             Connection conn = db.getConnection();
             String sql = "select FEEDID, USERID, SUBNET, NODESET from INGRESS_ROUTES where SEQUENCE = ?";
-            ps = conn.prepareStatement(sql);
-            ps.setInt(1, seq);
-            ResultSet rs = ps.executeQuery();
-            while (rs.next()) {
-                int feedid = rs.getInt("FEEDID");
-                String user = rs.getString("USERID");
-                String subnet = rs.getString("SUBNET");
-                int nodeset = rs.getInt("NODESET");
-                rv.add(new IngressRoute(seq, feedid, user, subnet, nodeset));
+            try(PreparedStatement ps = conn.prepareStatement(sql)) {
+                ps.setInt(1, seq);
+                try(ResultSet rs = ps.executeQuery()) {
+                    while (rs.next()) {
+                        int feedid = rs.getInt("FEEDID");
+                        String user = rs.getString("USERID");
+                        String subnet = rs.getString("SUBNET");
+                        int nodeset = rs.getInt("NODESET");
+                        rv.add(new IngressRoute(seq, feedid, user, subnet, nodeset));
+                    }
+                }
             }
-            rs.close();
-            ps.close();
             db.release(conn);
         } catch (SQLException e) {
             e.printStackTrace();
-        } finally {
-            try {
-                ps.close();
-            } catch (SQLException e) {
-                e.printStackTrace();
-            }
         }
         return rv;
     }
@@ -386,31 +381,23 @@
 
     private Collection<String> readNodes() {
         Collection<String> set = new TreeSet<String>();
-        PreparedStatement ps = null;
         try {
             DB db = new DB();
             @SuppressWarnings("resource")
             Connection conn = db.getConnection();
-            Statement stmt = conn.createStatement();
             String sql = "select NODEID from NODESETS where SETID = ?";
-            ps = conn.prepareStatement(sql);
-            ps.setInt(1, nodelist);
-            ResultSet rs = ps.executeQuery();
-            while (rs.next()) {
-                int id = rs.getInt("NODEID");
-                set.add(lookupNodeID(id));
+            try(PreparedStatement ps = conn.prepareStatement(sql)) {
+                ps.setInt(1, nodelist);
+                try(ResultSet rs = ps.executeQuery()) {
+                    while (rs.next()) {
+                        int id = rs.getInt("NODEID");
+                        set.add(lookupNodeID(id));
+                    }
+                }
             }
-            rs.close();
-            stmt.close();
             db.release(conn);
         } catch (SQLException e) {
             e.printStackTrace();
-        } finally {
-            try {
-                ps.close();
-            } catch (SQLException e) {
-                e.printStackTrace();
-            }
         }
         return set;
     }
@@ -441,7 +428,9 @@
             e.printStackTrace();
         } finally {
             try {
-                ps.close();
+                if(ps!=null) {
+                    ps.close();
+                }
             } catch (SQLException e) {
                 e.printStackTrace();
             }
@@ -482,7 +471,9 @@
             e.printStackTrace();
         } finally {
             try {
-                ps.close();
+                if(ps!=null) {
+                    ps.close();
+                }
             } catch (SQLException e) {
                 e.printStackTrace();
             }
diff --git a/datarouter-prov/src/main/java/org/onap/dmaap/datarouter/provisioning/beans/NetworkRoute.java b/datarouter-prov/src/main/java/org/onap/dmaap/datarouter/provisioning/beans/NetworkRoute.java
index f50043a..00eb6a2 100644
--- a/datarouter-prov/src/main/java/org/onap/dmaap/datarouter/provisioning/beans/NetworkRoute.java
+++ b/datarouter-prov/src/main/java/org/onap/dmaap/datarouter/provisioning/beans/NetworkRoute.java
@@ -29,6 +29,7 @@
 import java.sql.ResultSet;
 import java.sql.SQLException;
 import java.sql.Statement;
+import java.util.Objects;
 import java.util.SortedSet;
 import java.util.TreeSet;
 
@@ -60,16 +61,16 @@
             DB db = new DB();
             @SuppressWarnings("resource")
             Connection conn = db.getConnection();
-            Statement stmt = conn.createStatement();
-            ResultSet rs = stmt.executeQuery("select FROMNODE, TONODE, VIANODE from NETWORK_ROUTES");
-            while (rs.next()) {
-                int fromnode = rs.getInt("FROMNODE");
-                int tonode = rs.getInt("TONODE");
-                int vianode = rs.getInt("VIANODE");
-                set.add(new NetworkRoute(fromnode, tonode, vianode));
+            try(Statement stmt = conn.createStatement()) {
+                try(ResultSet rs = stmt.executeQuery("select FROMNODE, TONODE, VIANODE from NETWORK_ROUTES")) {
+                    while (rs.next()) {
+                        int fromnode = rs.getInt("FROMNODE");
+                        int tonode = rs.getInt("TONODE");
+                        int vianode = rs.getInt("VIANODE");
+                        set.add(new NetworkRoute(fromnode, tonode, vianode));
+                    }
+                }
             }
-            rs.close();
-            stmt.close();
             db.release(conn);
         } catch (SQLException e) {
             e.printStackTrace();
@@ -129,7 +130,9 @@
             e.printStackTrace();
         } finally {
             try {
-                ps.close();
+                if(ps!=null) {
+                    ps.close();
+                }
             } catch (SQLException e) {
                 e.printStackTrace();
             }
@@ -157,7 +160,9 @@
                 e.printStackTrace();
             } finally {
                 try {
-                    ps.close();
+                    if(ps!=null) {
+                        ps.close();
+                    }
                 } catch (SQLException e) {
                     e.printStackTrace();
                 }
@@ -183,7 +188,9 @@
             e.printStackTrace();
         } finally {
             try {
-                ps.close();
+                if(ps!=null) {
+                    ps.close();
+                }
             } catch (SQLException e) {
                 e.printStackTrace();
             }
@@ -214,6 +221,11 @@
     }
 
     @Override
+    public int hashCode() {
+        return Objects.hash(fromnode, tonode, vianode);
+    }
+
+    @Override
     public int compareTo(NetworkRoute o) {
         if (this.fromnode == o.fromnode) {
             if (this.tonode == o.tonode)
diff --git a/datarouter-prov/src/main/java/org/onap/dmaap/datarouter/provisioning/beans/Parameters.java b/datarouter-prov/src/main/java/org/onap/dmaap/datarouter/provisioning/beans/Parameters.java
index 8e9d5bf..3e8c90b 100644
--- a/datarouter-prov/src/main/java/org/onap/dmaap/datarouter/provisioning/beans/Parameters.java
+++ b/datarouter-prov/src/main/java/org/onap/dmaap/datarouter/provisioning/beans/Parameters.java
@@ -28,10 +28,7 @@
 import java.sql.ResultSet;
 import java.sql.SQLException;
 import java.sql.Statement;
-import java.util.ArrayList;
-import java.util.Collection;
-import java.util.HashMap;
-import java.util.Map;
+import java.util.*;
 
 import org.apache.log4j.Logger;
 import org.json.JSONObject;
@@ -93,15 +90,15 @@
             DB db = new DB();
             @SuppressWarnings("resource")
             Connection conn = db.getConnection();
-            Statement stmt = conn.createStatement();
-            String sql = "select * from PARAMETERS";
-            ResultSet rs = stmt.executeQuery(sql);
-            while (rs.next()) {
-                Parameters p = new Parameters(rs);
-                coll.add(p);
+            try(Statement stmt = conn.createStatement()) {
+                String sql = "select * from PARAMETERS";
+                try(ResultSet rs = stmt.executeQuery(sql)) {
+                    while (rs.next()) {
+                        Parameters p = new Parameters(rs);
+                        coll.add(p);
+                    }
+                }
             }
-            rs.close();
-            stmt.close();
             db.release(conn);
         } catch (SQLException e) {
             e.printStackTrace();
@@ -121,14 +118,14 @@
             DB db = new DB();
             @SuppressWarnings("resource")
             Connection conn = db.getConnection();
-            Statement stmt = conn.createStatement();
-            String sql = "select KEYNAME, VALUE from PARAMETERS where KEYNAME = '" + k + "'";
-            ResultSet rs = stmt.executeQuery(sql);
-            if (rs.next()) {
-                v = new Parameters(rs);
+            try(Statement stmt = conn.createStatement()) {
+                String sql = "select KEYNAME, VALUE from PARAMETERS where KEYNAME = '" + k + "'";
+                try(ResultSet rs = stmt.executeQuery(sql)) {
+                    if (rs.next()) {
+                        v = new Parameters(rs);
+                    }
+                }
             }
-            rs.close();
-            stmt.close();
             db.release(conn);
         } catch (SQLException e) {
             e.printStackTrace();
@@ -191,7 +188,9 @@
             e.printStackTrace();
         } finally {
             try {
-                ps.close();
+                if(ps!=null) {
+                    ps.close();
+                }
             } catch (SQLException e) {
                 e.printStackTrace();
             }
@@ -216,7 +215,9 @@
             e.printStackTrace();
         } finally {
             try {
-                ps.close();
+                if(ps!=null) {
+                    ps.close();
+                }
             } catch (SQLException e) {
                 e.printStackTrace();
             }
@@ -240,7 +241,9 @@
             e.printStackTrace();
         } finally {
             try {
-                ps.close();
+                if(ps!=null) {
+                    ps.close();
+                }
             } catch (SQLException e) {
                 e.printStackTrace();
             }
@@ -266,6 +269,11 @@
     }
 
     @Override
+    public int hashCode() {
+        return Objects.hash(keyname, value);
+    }
+
+    @Override
     public String toString() {
         return "PARAM: keyname=" + keyname + ", value=" + value;
     }
diff --git a/datarouter-prov/src/test/java/org/onap/dmaap/datarouter/provisioning/InternalServletTest.java b/datarouter-prov/src/test/java/org/onap/dmaap/datarouter/provisioning/InternalServletTest.java
index 5f6b7ae..591dcc3 100644
--- a/datarouter-prov/src/test/java/org/onap/dmaap/datarouter/provisioning/InternalServletTest.java
+++ b/datarouter-prov/src/test/java/org/onap/dmaap/datarouter/provisioning/InternalServletTest.java
@@ -33,43 +33,35 @@
 
 import java.io.File;
 import java.net.InetAddress;
-import java.util.HashMap;
-import java.util.Map;
+import javax.persistence.EntityManager;
+import javax.persistence.EntityManagerFactory;
+import javax.persistence.Persistence;
 import javax.servlet.ServletInputStream;
 import javax.servlet.ServletOutputStream;
 import javax.servlet.http.HttpServletRequest;
 import javax.servlet.http.HttpServletResponse;
+
 import org.apache.commons.lang3.reflect.FieldUtils;
 import org.junit.Before;
 import org.junit.Test;
 import org.junit.runner.RunWith;
+import org.junit.BeforeClass;
+import org.junit.AfterClass;
 import org.mockito.Mock;
-import org.onap.dmaap.datarouter.authz.AuthorizationResponse;
-import org.onap.dmaap.datarouter.authz.Authorizer;
+
 import org.onap.dmaap.datarouter.provisioning.beans.Deleteable;
-import org.onap.dmaap.datarouter.provisioning.beans.Feed;
 import org.onap.dmaap.datarouter.provisioning.beans.Insertable;
 import org.onap.dmaap.datarouter.provisioning.beans.LogRecord;
-import org.onap.dmaap.datarouter.provisioning.beans.NodeClass;
-import org.onap.dmaap.datarouter.provisioning.beans.Parameters;
-import org.onap.dmaap.datarouter.provisioning.beans.Subscription;
 import org.onap.dmaap.datarouter.provisioning.beans.Updateable;
-import org.onap.dmaap.datarouter.provisioning.utils.LogfileLoader;
-import org.onap.dmaap.datarouter.provisioning.utils.RLEBitSet;
 import org.powermock.api.mockito.PowerMockito;
 import org.powermock.core.classloader.annotations.PrepareForTest;
-import org.powermock.core.classloader.annotations.SuppressStaticInitializationFor;
 import org.powermock.modules.junit4.PowerMockRunner;
 
 @RunWith(PowerMockRunner.class)
 @PrepareForTest(LogRecord.class)
-@SuppressStaticInitializationFor({"org.onap.dmaap.datarouter.provisioning.beans.Feed",
-    "org.onap.dmaap.datarouter.provisioning.beans.Parameters",
-    "org.onap.dmaap.datarouter.provisioning.beans.NodeClass",
-    "org.onap.dmaap.datarouter.provisioning.beans.Subscription",
-    "org.onap.dmaap.datarouter.provisioning.utils.LogfileLoader"})
 public class InternalServletTest extends DrServletTestBase {
-
+  private static EntityManagerFactory emf;
+  private static EntityManager em;
   private InternalServlet internalServlet;
 
   @Mock
@@ -78,11 +70,25 @@
   @Mock
   private HttpServletResponse response;
 
+  @BeforeClass
+  public static void init() {
+    emf = Persistence.createEntityManagerFactory("dr-unit-tests");
+    em = emf.createEntityManager();
+    System.setProperty(
+            "org.onap.dmaap.datarouter.provserver.properties",
+            "src/test/resources/h2Database.properties");
+  }
+
+  @AfterClass
+  public static void tearDownClass() {
+    em.clear();
+    em.close();
+    emf.close();
+  }
+
   @Before
   public void setUp() throws Exception {
-    super.setUp();
     internalServlet = new InternalServlet();
-    setAuthoriserToReturnRequestIsAuthorized();
     setUpValidAuthorisedRequest();
   }
 
@@ -90,8 +96,6 @@
   public void Given_Request_Is_HTTP_GET_And_Address_Not_Authorized_When_HTTPS_Is_Required_Then_Forbidden_Response_Is_Generated()
       throws Exception {
     when(request.getRemoteAddr()).thenReturn("127.100.0.3");
-    FieldUtils.writeDeclaredStaticField(BaseServlet.class, "isAddressAuthEnabled", "true", true);
-
     internalServlet.doGet(request, response);
     verify(response)
         .sendError(eq(HttpServletResponse.SC_FORBIDDEN), argThat(notNullValue(String.class)));
@@ -108,7 +112,7 @@
   }
 
   @Test
-  public void Given_Request_Is_HTTP_GET_With_Halt_In_Endpoint_Request_Succeeds() throws Exception {
+  public void Given_Request_Is_HTTP_GET_With_Halt_In_Endpoint_Then_Request_Succeeds() throws Exception {
     when(request.getPathInfo()).thenReturn("/halt");
     when(request.isSecure()).thenReturn(false);
     when(request.getRemoteAddr()).thenReturn("127.0.0.1");
@@ -117,7 +121,7 @@
   }
 
   @Test
-  public void Given_Request_Is_HTTP_GET_With_FetchProv_In_Endpoint_Request_Succeeds()
+  public void Given_Request_Is_HTTP_GET_With_FetchProv_In_Endpoint_Then_Request_Succeeds()
       throws Exception {
     when(request.getPathInfo()).thenReturn("/fetchProv");
     when(request.isSecure()).thenReturn(false);
@@ -126,7 +130,7 @@
   }
 
   @Test
-  public void Given_Request_Is_HTTP_GET_With_Prov_In_Endpoint_Request_Succeeds() throws Exception {
+  public void Given_Request_Is_HTTP_GET_With_Prov_In_Endpoint_Then_Request_Succeeds() throws Exception {
     when(request.getPathInfo()).thenReturn("/prov");
     when(request.getQueryString()).thenReturn(null);
     setPokerToNotCreateTimers();
@@ -137,7 +141,7 @@
   }
 
   @Test
-  public void Given_Request_Is_HTTP_GET_With_Logs_In_Endpoint_Request_Succeeds() throws Exception {
+  public void Given_Request_Is_HTTP_GET_With_Logs_In_Endpoint_Then_Request_Succeeds() throws Exception {
     when(request.getPathInfo()).thenReturn("/logs/");
     ServletOutputStream outStream = mock(ServletOutputStream.class);
     when(response.getOutputStream()).thenReturn(outStream);
@@ -146,7 +150,7 @@
   }
 
   @Test
-  public void Given_Request_Is_HTTP_GET_Starts_With_Logs_In_Endpoint_Request_Succeeds()
+  public void Given_Request_Is_HTTP_GET_Starts_With_Logs_In_Endpoint_Then_Request_Succeeds()
       throws Exception {
     when(request.getPathInfo()).thenReturn("/logs/TestFile");
     internalServlet.doGet(request, response);
@@ -168,9 +172,8 @@
   }
 
   @Test
-  public void Given_Request_Is_HTTP_GET_With_Api_In_Endpoint_Request_Succeeds() throws Exception {
-    when(request.getPathInfo()).thenReturn("/api/Key");
-    setParametersToNotContactDb(false);
+  public void Given_Request_Is_HTTP_GET_With_Api_In_Endpoint_Then_Request_Succeeds() throws Exception {
+    when(request.getPathInfo()).thenReturn("/api/DELIVERY_MAX_RETRY_INTERVAL");
     ServletOutputStream outStream = mock(ServletOutputStream.class);
     when(response.getOutputStream()).thenReturn(outStream);
     internalServlet.doGet(request, response);
@@ -178,10 +181,9 @@
   }
 
   @Test
-  public void Given_Request_Is_HTTP_GET_With_Drlogs_In_Endpoint_Request_Succeeds()
+  public void Given_Request_Is_HTTP_GET_With_Drlogs_In_Endpoint_Then_Request_Succeeds()
       throws Exception {
     when(request.getPathInfo()).thenReturn("/drlogs/");
-    mockLogfileLoader();
     ServletOutputStream outStream = mock(ServletOutputStream.class);
     when(response.getOutputStream()).thenReturn(outStream);
     internalServlet.doGet(request, response);
@@ -189,7 +191,7 @@
   }
 
   @Test
-  public void Given_Request_Is_HTTP_GET_Incorrect_Endpoint_Then_No_Content_Response_Is_Generated()
+  public void Given_Request_Is_HTTP_GET_With_Incorrect_Endpoint_Then_No_Content_Response_Is_Generated()
       throws Exception {
     when(request.getPathInfo()).thenReturn("/incorrect/");
     internalServlet.doGet(request, response);
@@ -209,13 +211,11 @@
 
   @Test
   public void Given_Request_Is_HTTP_PUT_With_Api_In_Endpoint_Request_Succeeds() throws Exception {
-    when(request.getPathInfo()).thenReturn("/api/Key");
-    setParametersToNotContactDb(false);
+    when(request.getPathInfo()).thenReturn("/api/NODES");
     String[] values = {"V", "a", "l", "u", "e", "s"};
     when(request.getParameterValues(anyString())).thenReturn(values);
     internalServlet = internalServerSuccess();
     setPokerToNotCreateTimers();
-    mockProvisioningParametersChanged();
     internalServlet.doPut(request, response);
     verify(response).setStatus(eq(HttpServletResponse.SC_OK));
   }
@@ -223,8 +223,7 @@
   @Test
   public void Given_Request_Is_HTTP_PUT_With_Api_In_Endpoint_And_Update_Fails_Then_Internal_Server_Error_Is_Generated()
       throws Exception {
-    when(request.getPathInfo()).thenReturn("/api/Key");
-    setParametersToNotContactDb(false);
+    when(request.getPathInfo()).thenReturn("/api/NODES");
     String[] values = {"V", "a", "l", "u", "e", "s"};
     when(request.getParameterValues(anyString())).thenReturn(values);
     internalServlet = internalServerFailure();
@@ -255,13 +254,11 @@
   @Test
   public void Given_Request_Is_HTTP_DELETE_With_Api_In_Endpoint_Request_Succeeds()
       throws Exception {
-    when(request.getPathInfo()).thenReturn("/api/Key");
-    setParametersToNotContactDb(false);
+    when(request.getPathInfo()).thenReturn("/api/NODES");
     String[] values = {"V", "a", "l", "u", "e", "s"};
     when(request.getParameterValues(anyString())).thenReturn(values);
     internalServlet = internalServerSuccess();
     setPokerToNotCreateTimers();
-    mockProvisioningParametersChanged();
     internalServlet.doDelete(request, response);
     verify(response).setStatus(eq(HttpServletResponse.SC_OK));
   }
@@ -269,8 +266,7 @@
   @Test
   public void Given_Request_Is_HTTP_DELETE_With_Api_In_Endpoint_And_Delete_Fails_Then_Internal_Server_Error_Is_Generated()
       throws Exception {
-    when(request.getPathInfo()).thenReturn("/api/Key");
-    setParametersToNotContactDb(false);
+    when(request.getPathInfo()).thenReturn("/api/NODES");
     String[] values = {"V", "a", "l", "u", "e", "s"};
     when(request.getParameterValues(anyString())).thenReturn(values);
     internalServlet = internalServerFailure();
@@ -293,20 +289,17 @@
       throws Exception {
     when(request.getRemoteAddr()).thenReturn("127.100.0.3");
     internalServlet.doPost(request, response);
-    FieldUtils.writeDeclaredStaticField(BaseServlet.class, "isAddressAuthEnabled", "true", true);
     verify(response)
         .sendError(eq(HttpServletResponse.SC_FORBIDDEN), argThat(notNullValue(String.class)));
   }
 
   @Test
   public void Given_Request_Is_HTTP_POST_With_Api_In_Endpoint_Request_Succeeds() throws Exception {
-    when(request.getPathInfo()).thenReturn("/api/Key");
-    setParametersToNotContactDb(true);
+    when(request.getPathInfo()).thenReturn("/api/key");
     String[] values = {"V", "a", "l", "u", "e", "s"};
     when(request.getParameterValues(anyString())).thenReturn(values);
     internalServlet = internalServerSuccess();
     setPokerToNotCreateTimers();
-    mockProvisioningParametersChanged();
     internalServlet.doPost(request, response);
     verify(response).setStatus(eq(HttpServletResponse.SC_OK));
   }
@@ -315,7 +308,6 @@
   public void Given_Request_Is_HTTP_POST_With_Api_In_Endpoint_And_Insert_Fails_Then_Internal_Server_Error_Is_Generated()
       throws Exception {
     when(request.getPathInfo()).thenReturn("/api/Key");
-    setParametersToNotContactDb(true);
     String[] values = {"V", "a", "l", "u", "e", "s"};
     when(request.getParameterValues(anyString())).thenReturn(values);
     internalServlet = internalServerFailure();
@@ -352,7 +344,6 @@
     File testDir = new File("unit-test-logs/spool");
     testDir.mkdirs();
     testDir.deleteOnExit();
-    mockLogfileLoader();
     internalServlet.doPost(request, response);
     verify(response).setStatus(eq(HttpServletResponse.SC_CREATED));
   }
@@ -386,14 +377,6 @@
         .sendError(eq(HttpServletResponse.SC_NOT_FOUND), argThat(notNullValue(String.class)));
   }
 
-  private void setAuthoriserToReturnRequestIsAuthorized() throws IllegalAccessException {
-    AuthorizationResponse authResponse = mock(AuthorizationResponse.class);
-    Authorizer authorizer = mock(Authorizer.class);
-    FieldUtils.writeDeclaredStaticField(BaseServlet.class, "authz", authorizer, true);
-    when(authorizer.decide(request)).thenReturn(authResponse);
-    when(authResponse.isAuthorized()).thenReturn(true);
-  }
-
   private void setUpValidAuthorisedRequest() throws Exception {
     setUpValidSecurityOnHttpRequest();
     setBehalfHeader("Stub_Value");
@@ -424,16 +407,6 @@
     FieldUtils.writeDeclaredStaticField(Poker.class, "poker", poker, true);
   }
 
-  private void setParametersToNotContactDb(boolean isPost) {
-    PowerMockito.mockStatic(Parameters.class);
-    Parameters parameters = mock(Parameters.class);
-    if (isPost) {
-      PowerMockito.when(Parameters.getParameter(anyString())).thenReturn(null);
-    } else {
-      PowerMockito.when(Parameters.getParameter(anyString())).thenReturn(parameters);
-    }
-  }
-
   private InternalServlet internalServerSuccess() {
     InternalServlet internalServlet = new InternalServlet() {
 
@@ -469,20 +442,4 @@
     };
     return internalServlet;
   }
-
-  private void mockProvisioningParametersChanged() throws IllegalAccessException {
-    PowerMockito.mockStatic(Feed.class);
-    PowerMockito.mockStatic(Subscription.class);
-    PowerMockito.when(Feed.countActiveFeeds()).thenReturn(0);
-    PowerMockito.when(Subscription.countActiveSubscriptions()).thenReturn(0);
-    Map<String, Integer> map = new HashMap<>();
-    FieldUtils.writeDeclaredStaticField(NodeClass.class, "map", map, true);
-  }
-
-  private void mockLogfileLoader() {
-    PowerMockito.mockStatic(LogfileLoader.class);
-    LogfileLoader logfileLoader = mock(LogfileLoader.class);
-    when(logfileLoader.getBitSet()).thenReturn(new RLEBitSet());
-    PowerMockito.when(LogfileLoader.getLoader()).thenReturn(logfileLoader);
-  }
 }
diff --git a/datarouter-prov/src/test/resources/h2Database.properties b/datarouter-prov/src/test/resources/h2Database.properties
index 11f1381..336af0e 100755
--- a/datarouter-prov/src/test/resources/h2Database.properties
+++ b/datarouter-prov/src/test/resources/h2Database.properties
@@ -25,4 +25,6 @@
 org.onap.dmaap.datarouter.db.driver                        = org.h2.Driver
 org.onap.dmaap.datarouter.db.url                           = jdbc:h2:mem:test;DB_CLOSE_DELAY=-1
 org.onap.dmaap.datarouter.provserver.isaddressauthenabled  = true
-org.onap.dmaap.datarouter.provserver.https.relaxation      = false
\ No newline at end of file
+org.onap.dmaap.datarouter.provserver.https.relaxation      = false
+org.onap.dmaap.datarouter.provserver.accesslog.dir         = unit-test-logs
+org.onap.dmaap.datarouter.provserver.spooldir              = unit-test-logs/spool
\ No newline at end of file
