tomee-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From dblev...@apache.org
Subject [08/12] tomee git commit: Added diamond operator usage to the OpenEJB Container Core project, where appropriate
Date Tue, 04 Dec 2018 04:54:39 GMT
http://git-wip-us.apache.org/repos/asf/tomee/blob/bfb1ed40/container/openejb-core/src/main/java/org/apache/openejb/config/LinkBuiltInTypes.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/main/java/org/apache/openejb/config/LinkBuiltInTypes.java b/container/openejb-core/src/main/java/org/apache/openejb/config/LinkBuiltInTypes.java
index ec26495..cf24239 100644
--- a/container/openejb-core/src/main/java/org/apache/openejb/config/LinkBuiltInTypes.java
+++ b/container/openejb-core/src/main/java/org/apache/openejb/config/LinkBuiltInTypes.java
@@ -84,7 +84,7 @@ public class LinkBuiltInTypes implements DynamicDeployer {
     private void link(final JndiConsumer consumer) {
 
 
-        final Map<String, String> links = new HashMap<String, String>();
+        final Map<String, String> links = new HashMap<>();
 
         add(links, BeanManager.class);
         add(links, Validator.class);
@@ -96,7 +96,7 @@ public class LinkBuiltInTypes implements DynamicDeployer {
         add(links, TimerService.class);
         add(links, WebServiceContext.class);
 
-        final List<JndiReference> refs = new ArrayList<JndiReference>();
+        final List<JndiReference> refs = new ArrayList<>();
         refs.addAll(consumer.getResourceRef());
         refs.addAll(consumer.getResourceEnvRef());
 

http://git-wip-us.apache.org/repos/asf/tomee/blob/bfb1ed40/container/openejb-core/src/main/java/org/apache/openejb/config/MBeanDeployer.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/main/java/org/apache/openejb/config/MBeanDeployer.java b/container/openejb-core/src/main/java/org/apache/openejb/config/MBeanDeployer.java
index c656d0d..6d08a0e 100644
--- a/container/openejb-core/src/main/java/org/apache/openejb/config/MBeanDeployer.java
+++ b/container/openejb-core/src/main/java/org/apache/openejb/config/MBeanDeployer.java
@@ -41,7 +41,7 @@ public class MBeanDeployer implements DynamicDeployer {
     @Override
     public AppModule deploy(final AppModule appModule) throws OpenEJBException {
         logger.debug("looking for annotated MBeans in " + appModule.getModuleId());
-        final List<String> done = new ArrayList<String>();
+        final List<String> done = new ArrayList<>();
 
         ClassLoader cl = appModule.getClassLoader();
         if (cl == null) {
@@ -51,7 +51,7 @@ public class MBeanDeployer implements DynamicDeployer {
             }
         }
 
-        final Collection<Class<? extends Annotation>> mbeanClasses = new ArrayList<Class<? extends Annotation>>(2);
+        final Collection<Class<? extends Annotation>> mbeanClasses = new ArrayList<>(2);
         mbeanClasses.add(MBean.class);
 
         try { // for OSGi environment, javax.management is imported by the JRE

http://git-wip-us.apache.org/repos/asf/tomee/blob/bfb1ed40/container/openejb-core/src/main/java/org/apache/openejb/config/Module.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/main/java/org/apache/openejb/config/Module.java b/container/openejb-core/src/main/java/org/apache/openejb/config/Module.java
index 3b1bd5b..f260ad9 100644
--- a/container/openejb-core/src/main/java/org/apache/openejb/config/Module.java
+++ b/container/openejb-core/src/main/java/org/apache/openejb/config/Module.java
@@ -36,11 +36,11 @@ public class Module {
     private ClassLoader classLoader;
 
     private ValidationConfigType validationConfig;
-    private final Map<String, Object> altDDs = new HashMap<String, Object>();
+    private final Map<String, Object> altDDs = new HashMap<>();
     private String uniqueId;
     private AppModule appModule;
     private Resources resources;
-    private final Set<String> mbeans = new HashSet<String>();
+    private final Set<String> mbeans = new HashSet<>();
     private final Properties properties = new SuperProperties().caseInsensitive(true);
 
     public Module(final boolean needId) {

http://git-wip-us.apache.org/repos/asf/tomee/blob/bfb1ed40/container/openejb-core/src/main/java/org/apache/openejb/config/NewLoaderLogic.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/main/java/org/apache/openejb/config/NewLoaderLogic.java b/container/openejb-core/src/main/java/org/apache/openejb/config/NewLoaderLogic.java
index 0067e72..845fc94 100644
--- a/container/openejb-core/src/main/java/org/apache/openejb/config/NewLoaderLogic.java
+++ b/container/openejb-core/src/main/java/org/apache/openejb/config/NewLoaderLogic.java
@@ -92,9 +92,9 @@ public class NewLoaderLogic {
 
     public static Set<String> callers(final Filter start) {
 
-        final Set<String> callers = new LinkedHashSet<String>();
+        final Set<String> callers = new LinkedHashSet<>();
 
-        final List<StackTraceElement> elements = new ArrayList<StackTraceElement>(Arrays.asList(new Exception().fillInStackTrace().getStackTrace()));
+        final List<StackTraceElement> elements = new ArrayList<>(Arrays.asList(new Exception().fillInStackTrace().getStackTrace()));
 
         // Yank out everything until we find a known ENTRY point
         // if we don't find one, so be it, this is only a convenience
@@ -323,7 +323,7 @@ public class NewLoaderLogic {
             exclusions = readDefaultExclusions();
         }
 
-        final List<String> excludes = new ArrayList<String>(exclusions.length + 5);
+        final List<String> excludes = new ArrayList<>(exclusions.length + 5);
         excludes.addAll(Arrays.asList(exclusions));
 
         if (ADDITIONAL_EXCLUDES != null) {
@@ -390,7 +390,7 @@ public class NewLoaderLogic {
 
     public static String[] readInputStreamList(final InputStream is) {
 
-        final List<String> list = new ArrayList<String>();
+        final List<String> list = new ArrayList<>();
         BufferedReader reader = null;
         String line;
 
@@ -452,7 +452,7 @@ public class NewLoaderLogic {
 
             callers.size();
 
-            final Set<String> packages = new HashSet<String>();
+            final Set<String> packages = new HashSet<>();
             for (final String caller : callers) {
                 String[] parts = caller.split("\\.");
                 if (parts.length > 2) {
@@ -573,7 +573,7 @@ public class NewLoaderLogic {
                     "='" +
                     include +
                     "'");
-                final List<String> list = new ArrayList<String>();
+                final List<String> list = new ArrayList<>();
                 for (final URL url : urls) {
                     list.add(url.toExternalForm());
                 }

http://git-wip-us.apache.org/repos/asf/tomee/blob/bfb1ed40/container/openejb-core/src/main/java/org/apache/openejb/config/OpenEJBDeploymentManager.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/main/java/org/apache/openejb/config/OpenEJBDeploymentManager.java b/container/openejb-core/src/main/java/org/apache/openejb/config/OpenEJBDeploymentManager.java
index 7706b2e..47d2075 100644
--- a/container/openejb-core/src/main/java/org/apache/openejb/config/OpenEJBDeploymentManager.java
+++ b/container/openejb-core/src/main/java/org/apache/openejb/config/OpenEJBDeploymentManager.java
@@ -94,7 +94,7 @@ public class OpenEJBDeploymentManager implements DeploymentManager {
 
         // target.* - known targets available on the server
         // target.*.description - known targets available on the server
-        final SortedMap<String, Target> targets = new TreeMap<String, Target>();
+        final SortedMap<String, Target> targets = new TreeMap<>();
         for (final Iterator<Map.Entry<Object, Object>> iterator = properties.entrySet().iterator(); iterator.hasNext(); ) {
             final Map.Entry entry = iterator.next();
             final String key = (String) entry.getKey();
@@ -118,7 +118,7 @@ public class OpenEJBDeploymentManager implements DeploymentManager {
 
         this.targets = Collections.unmodifiableSortedMap(targets);
 
-        targetPaths = new ArrayList<String>();
+        targetPaths = new ArrayList<>();
         for (final String targetName : targets.keySet()) {
             targetPaths.add(targetName + "/");
         }
@@ -329,7 +329,7 @@ public class OpenEJBDeploymentManager implements DeploymentManager {
     }
 
     private Set<TargetModuleID> toTargetModuleIds(final Set<String> modules) {
-        final Set<TargetModuleID> targetModuleIds = new HashSet<TargetModuleID>();
+        final Set<TargetModuleID> targetModuleIds = new HashSet<>();
         for (final String module : modules) {
             String moduleId;
             final String webUrl;
@@ -366,7 +366,7 @@ public class OpenEJBDeploymentManager implements DeploymentManager {
             return Collections.emptySet();
         }
 
-        final TreeSet<String> targetSet = new TreeSet<String>();
+        final TreeSet<String> targetSet = new TreeSet<>();
         for (final Target target : targets) {
             targetSet.add(target.getName());
         }
@@ -378,7 +378,7 @@ public class OpenEJBDeploymentManager implements DeploymentManager {
             return Collections.emptySet();
         }
 
-        final TreeSet<String> moduleSet = new TreeSet<String>();
+        final TreeSet<String> moduleSet = new TreeSet<>();
         for (final TargetModuleID module : moduleIDList) {
             moduleSet.add(module.getTarget().getName() + "/" + module.getModuleID());
         }
@@ -458,7 +458,7 @@ public class OpenEJBDeploymentManager implements DeploymentManager {
         private final String moduleId;
         private final String webUrl;
         private TargetModuleID parentTargetModuleId;
-        private final Set<TargetModuleID> children = new TreeSet<TargetModuleID>();
+        private final Set<TargetModuleID> children = new TreeSet<>();
 
         public TargetModuleIDImpl(final Target target, final String moduleId) {
             this(target, moduleId, null);

http://git-wip-us.apache.org/repos/asf/tomee/blob/bfb1ed40/container/openejb-core/src/main/java/org/apache/openejb/config/OpenEjb2Conversion.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/main/java/org/apache/openejb/config/OpenEjb2Conversion.java b/container/openejb-core/src/main/java/org/apache/openejb/config/OpenEjb2Conversion.java
index c530780..6a755ce 100644
--- a/container/openejb-core/src/main/java/org/apache/openejb/config/OpenEjb2Conversion.java
+++ b/container/openejb-core/src/main/java/org/apache/openejb/config/OpenEjb2Conversion.java
@@ -185,7 +185,7 @@ public class OpenEjb2Conversion implements DynamicDeployer {
                 deployment.getJndi().add(new org.apache.openejb.jee.oejb3.Jndi(jndi.getName(), jndi.getInterface()));
             }
 
-            final Set<String> ejbLinks = new TreeSet<String>();
+            final Set<String> ejbLinks = new TreeSet<>();
             for (final EjbLink ejbLink : deployment.getEjbLink()) {
                 ejbLinks.add(ejbLink.getEjbRefName());
             }
@@ -246,7 +246,7 @@ public class OpenEjb2Conversion implements DynamicDeployer {
     }
 
     public final void convertMdbConfigs(final EjbJar ejbJar, final OpenejbJarType openejbJarType) {
-        final Map<String, MessageDrivenBean> mdbs = new TreeMap<String, MessageDrivenBean>();
+        final Map<String, MessageDrivenBean> mdbs = new TreeMap<>();
         for (final EnterpriseBean enterpriseBean : ejbJar.getEnterpriseBeans()) {
             if (!(enterpriseBean instanceof MessageDrivenBean)) {
                 continue;
@@ -281,7 +281,7 @@ public class OpenEjb2Conversion implements DynamicDeployer {
     }
 
     public final void mergeEntityMappings(final String moduleId, final EntityMappings entityMappings, final OpenejbJar openejbJar, final OpenejbJarType openejbJarType) {
-        final Map<String, EntityData> entities = new TreeMap<String, EntityData>();
+        final Map<String, EntityData> entities = new TreeMap<>();
         if (entityMappings != null) {
             for (final Entity entity : entityMappings.getEntity()) {
                 try {
@@ -537,8 +537,8 @@ public class OpenEjb2Conversion implements DynamicDeployer {
     private static class EntityData {
 
         private final Entity entity;
-        private final Map<String, Field> fields = new TreeMap<String, Field>();
-        private final Map<String, RelationField> relations = new TreeMap<String, RelationField>();
+        private final Map<String, Field> fields = new TreeMap<>();
+        private final Map<String, RelationField> relations = new TreeMap<>();
 
         public EntityData(final Entity e) {
 

http://git-wip-us.apache.org/repos/asf/tomee/blob/bfb1ed40/container/openejb-core/src/main/java/org/apache/openejb/config/PersistenceContextAnnFactory.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/main/java/org/apache/openejb/config/PersistenceContextAnnFactory.java b/container/openejb-core/src/main/java/org/apache/openejb/config/PersistenceContextAnnFactory.java
index 5671df4..f15f4ab 100644
--- a/container/openejb-core/src/main/java/org/apache/openejb/config/PersistenceContextAnnFactory.java
+++ b/container/openejb-core/src/main/java/org/apache/openejb/config/PersistenceContextAnnFactory.java
@@ -55,8 +55,8 @@ public class PersistenceContextAnnFactory {
         useAsm = !isPersistenceContextAnnotationValid;
     }
 
-    public Map<String, AsmPersistenceContext> contexts = new HashMap<String, AsmPersistenceContext>();
-    private final Set<String> processed = new HashSet<String>();
+    public Map<String, AsmPersistenceContext> contexts = new HashMap<>();
+    private final Set<String> processed = new HashSet<>();
 
     public void addAnnotations(final Class c) throws OpenEJBException {
         if (!useAsm) {
@@ -130,7 +130,7 @@ public class PersistenceContextAnnFactory {
         }
 
         public Map<String, String> properties() {
-            final Map<String, String> properties = new LinkedHashMap<String, String>();
+            final Map<String, String> properties = new LinkedHashMap<>();
             for (final PersistenceProperty property : persistenceContext.properties()) {
                 properties.put(property.name(), property.value());
             }
@@ -147,7 +147,7 @@ public class PersistenceContextAnnFactory {
         public String unitName;
         public String type;
         public String synchronization = SynchronizationType.SYNCHRONIZED.name(); // default
-        public final Map<String, String> properties = new LinkedHashMap<String, String>();
+        public final Map<String, String> properties = new LinkedHashMap<>();
 
         public String name() {
             return name;

http://git-wip-us.apache.org/repos/asf/tomee/blob/bfb1ed40/container/openejb-core/src/main/java/org/apache/openejb/config/PersistenceModule.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/main/java/org/apache/openejb/config/PersistenceModule.java b/container/openejb-core/src/main/java/org/apache/openejb/config/PersistenceModule.java
index 9ab7339..1c67400 100644
--- a/container/openejb-core/src/main/java/org/apache/openejb/config/PersistenceModule.java
+++ b/container/openejb-core/src/main/java/org/apache/openejb/config/PersistenceModule.java
@@ -30,7 +30,7 @@ import java.util.TreeSet;
 public class PersistenceModule implements DeploymentModule {
     private String rootUrl;
     private Persistence persistence;
-    private final Set<String> watchedResources = new TreeSet<String>();
+    private final Set<String> watchedResources = new TreeSet<>();
     private URI uri;
     private final AppModule appModule;
 

http://git-wip-us.apache.org/repos/asf/tomee/blob/bfb1ed40/container/openejb-core/src/main/java/org/apache/openejb/config/PersistenceUnitLinkResolver.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/main/java/org/apache/openejb/config/PersistenceUnitLinkResolver.java b/container/openejb-core/src/main/java/org/apache/openejb/config/PersistenceUnitLinkResolver.java
index 3a28e87..52d41a4 100644
--- a/container/openejb-core/src/main/java/org/apache/openejb/config/PersistenceUnitLinkResolver.java
+++ b/container/openejb-core/src/main/java/org/apache/openejb/config/PersistenceUnitLinkResolver.java
@@ -79,7 +79,7 @@ public class PersistenceUnitLinkResolver extends UniqueDefaultLinkResolver<Persi
             return false;
         }
 
-        final Collection<String> strUrls = new ArrayList<String>();
+        final Collection<String> strUrls = new ArrayList<>();
         for (final URL url : urls) {
             strUrls.add(URLs.toFilePath(url));
         }

http://git-wip-us.apache.org/repos/asf/tomee/blob/bfb1ed40/container/openejb-core/src/main/java/org/apache/openejb/config/QuickServerXmlParser.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/main/java/org/apache/openejb/config/QuickServerXmlParser.java b/container/openejb-core/src/main/java/org/apache/openejb/config/QuickServerXmlParser.java
index 3184721..df68658 100644
--- a/container/openejb-core/src/main/java/org/apache/openejb/config/QuickServerXmlParser.java
+++ b/container/openejb-core/src/main/java/org/apache/openejb/config/QuickServerXmlParser.java
@@ -52,7 +52,7 @@ public class QuickServerXmlParser extends DefaultHandler {
     public static final String DEFAULT_APP_BASE = "webapps";
     public static final String DEFAULT_KEYSTORE = new File(JavaSecurityManagers.getSystemProperty("user.home"), ".keystore").getAbsolutePath();
 
-    private final Map<String, String> values = new TreeMap<String, String>(String.CASE_INSENSITIVE_ORDER);
+    private final Map<String, String> values = new TreeMap<>(String.CASE_INSENSITIVE_ORDER);
 
     public QuickServerXmlParser() { // ensure defaults are present
         values.put(STOP_KEY, DEFAULT_STOP_PORT);

http://git-wip-us.apache.org/repos/asf/tomee/blob/bfb1ed40/container/openejb-core/src/main/java/org/apache/openejb/config/RemoteServer.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/main/java/org/apache/openejb/config/RemoteServer.java b/container/openejb-core/src/main/java/org/apache/openejb/config/RemoteServer.java
index a42ae71..4953f20 100644
--- a/container/openejb-core/src/main/java/org/apache/openejb/config/RemoteServer.java
+++ b/container/openejb-core/src/main/java/org/apache/openejb/config/RemoteServer.java
@@ -74,7 +74,7 @@ public class RemoteServer {
     private boolean serverHasAlreadyBeenStarted = true;
 
     private Properties properties;
-    private final AtomicReference<Process> server = new AtomicReference<Process>();
+    private final AtomicReference<Process> server = new AtomicReference<>();
     private final int tries;
     private final boolean verbose;
     private final int portShutdown;
@@ -223,7 +223,7 @@ public class RemoteServer {
                     java = new File(JavaSecurityManagers.getSystemProperty("java.home"), "bin/java").getAbsolutePath();
                 }
 
-                final List<String> argsList = new ArrayList<String>(20);
+                final List<String> argsList = new ArrayList<>(20);
                 argsList.add(java);
                 argsList.add("-XX:+HeapDumpOnOutOfMemoryError");
 
@@ -247,7 +247,7 @@ public class RemoteServer {
                     argsList.addAll(parse(javaOpts.replace("${openejb.base}", home.getAbsolutePath())));
                 }
 
-                final Map<String, String> addedArgs = new HashMap<String, String>();
+                final Map<String, String> addedArgs = new HashMap<>();
                 if (additionalArgs != null) {
                     for (final String arg : additionalArgs) {
                         final int equal = arg.indexOf('=');

http://git-wip-us.apache.org/repos/asf/tomee/blob/bfb1ed40/container/openejb-core/src/main/java/org/apache/openejb/config/RemoveWebServices.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/main/java/org/apache/openejb/config/RemoveWebServices.java b/container/openejb-core/src/main/java/org/apache/openejb/config/RemoveWebServices.java
index 8467726..42a8083 100644
--- a/container/openejb-core/src/main/java/org/apache/openejb/config/RemoveWebServices.java
+++ b/container/openejb-core/src/main/java/org/apache/openejb/config/RemoveWebServices.java
@@ -130,6 +130,6 @@ class RemoveWebServices implements DynamicDeployer {
     }
 
     public <T> List<T> copy(final Collection<T> list) {
-        return new ArrayList<T>(list);
+        return new ArrayList<>(list);
     }
 }

http://git-wip-us.apache.org/repos/asf/tomee/blob/bfb1ed40/container/openejb-core/src/main/java/org/apache/openejb/config/ScanUtil.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/main/java/org/apache/openejb/config/ScanUtil.java b/container/openejb-core/src/main/java/org/apache/openejb/config/ScanUtil.java
index 244f09d..0bf4168 100644
--- a/container/openejb-core/src/main/java/org/apache/openejb/config/ScanUtil.java
+++ b/container/openejb-core/src/main/java/org/apache/openejb/config/ScanUtil.java
@@ -46,8 +46,8 @@ public final class ScanUtil {
     }
 
     public static final class ScanHandler extends DefaultHandler {
-        private final Set<String> classes = new HashSet<String>();
-        private final Set<String> packages = new HashSet<String>();
+        private final Set<String> classes = new HashSet<>();
+        private final Set<String> packages = new HashSet<>();
         private Set<String> current;
         private boolean optimized = true;
 

http://git-wip-us.apache.org/repos/asf/tomee/blob/bfb1ed40/container/openejb-core/src/main/java/org/apache/openejb/config/ServiceUtils.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/main/java/org/apache/openejb/config/ServiceUtils.java b/container/openejb-core/src/main/java/org/apache/openejb/config/ServiceUtils.java
index a3ac1ba..45eb971 100644
--- a/container/openejb-core/src/main/java/org/apache/openejb/config/ServiceUtils.java
+++ b/container/openejb-core/src/main/java/org/apache/openejb/config/ServiceUtils.java
@@ -134,7 +134,7 @@ public class ServiceUtils {
 
 
     public static List<ServiceProvider> getServiceProvidersByServiceType(final String type) throws OpenEJBException {
-        final ArrayList<ServiceProvider> providers = new ArrayList<ServiceProvider>();
+        final ArrayList<ServiceProvider> providers = new ArrayList<>();
         if (type == null) {
             return providers;
         }

http://git-wip-us.apache.org/repos/asf/tomee/blob/bfb1ed40/container/openejb-core/src/main/java/org/apache/openejb/config/SunConversion.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/main/java/org/apache/openejb/config/SunConversion.java b/container/openejb-core/src/main/java/org/apache/openejb/config/SunConversion.java
index 3f987b0..2511d2b 100644
--- a/container/openejb-core/src/main/java/org/apache/openejb/config/SunConversion.java
+++ b/container/openejb-core/src/main/java/org/apache/openejb/config/SunConversion.java
@@ -149,7 +149,7 @@ public class SunConversion implements DynamicDeployer {
                 }
 
                 // map resource-env-refs and message-destination-refs
-                final Map<String, JndiReference> resEnvMap = new TreeMap<String, JndiReference>();
+                final Map<String, JndiReference> resEnvMap = new TreeMap<>();
                 resEnvMap.putAll(applicationClient.getResourceEnvRefMap());
                 resEnvMap.putAll(applicationClient.getMessageDestinationRefMap());
 
@@ -200,7 +200,7 @@ public class SunConversion implements DynamicDeployer {
                     refName = normalize(refName);
                     final ServiceRef serviceRef = serviceRefMap.get(refName);
                     if (serviceRef != null) {
-                        final Map<String, PortComponentRef> ports = new TreeMap<String, PortComponentRef>();
+                        final Map<String, PortComponentRef> ports = new TreeMap<>();
                         for (final PortComponentRef portComponentRef : serviceRef.getPortComponentRef()) {
                             ports.put(portComponentRef.getServiceEndpointInterface(), portComponentRef);
                         }
@@ -390,7 +390,7 @@ public class SunConversion implements DynamicDeployer {
         }
 
         // map resource-env-refs and message-destination-refs
-        final Map<String, JndiReference> resEnvMap = new TreeMap<String, JndiReference>();
+        final Map<String, JndiReference> resEnvMap = new TreeMap<>();
         resEnvMap.putAll(applicationClient.getResourceEnvRefMap());
         resEnvMap.putAll(applicationClient.getMessageDestinationRefMap());
 
@@ -431,7 +431,7 @@ public class SunConversion implements DynamicDeployer {
             refName = normalize(refName);
             final ServiceRef serviceRef = serviceRefMap.get(refName);
             if (serviceRef != null) {
-                final Map<String, PortComponentRef> ports = new TreeMap<String, PortComponentRef>();
+                final Map<String, PortComponentRef> ports = new TreeMap<>();
                 for (final PortComponentRef portComponentRef : serviceRef.getPortComponentRef()) {
                     ports.put(portComponentRef.getServiceEndpointInterface(), portComponentRef);
                 }
@@ -487,7 +487,7 @@ public class SunConversion implements DynamicDeployer {
         }
 
         // map ejb-refs
-        final Map<String, JndiReference> refMap = new TreeMap<String, JndiReference>();
+        final Map<String, JndiReference> refMap = new TreeMap<>();
         refMap.putAll(webApp.getEjbRefMap());
         refMap.putAll(webApp.getEjbLocalRefMap());
 
@@ -507,7 +507,7 @@ public class SunConversion implements DynamicDeployer {
         }
 
         // map resource-env-refs and message-destination-refs
-        final Map<String, JndiReference> resEnvMap = new TreeMap<String, JndiReference>();
+        final Map<String, JndiReference> resEnvMap = new TreeMap<>();
         resEnvMap.putAll(webApp.getResourceRefMap());
         resEnvMap.putAll(webApp.getResourceEnvRefMap());
         resEnvMap.putAll(webApp.getMessageDestinationRefMap());
@@ -549,7 +549,7 @@ public class SunConversion implements DynamicDeployer {
             refName = normalize(refName);
             final ServiceRef serviceRef = serviceRefMap.get(refName);
             if (serviceRef != null) {
-                final Map<String, PortComponentRef> ports = new TreeMap<String, PortComponentRef>();
+                final Map<String, PortComponentRef> ports = new TreeMap<>();
                 for (final PortComponentRef portComponentRef : serviceRef.getPortComponentRef()) {
                     ports.put(portComponentRef.getServiceEndpointInterface(), portComponentRef);
                 }
@@ -629,7 +629,7 @@ public class SunConversion implements DynamicDeployer {
     }
 
     public void convertModule(final EjbModule ejbModule, final EntityMappings entityMappings) {
-        final Map<String, EntityData> entities = new TreeMap<String, EntityData>();
+        final Map<String, EntityData> entities = new TreeMap<>();
         if (entityMappings != null) {
             for (final Entity entity : entityMappings.getEntity()) {
                 entities.put(entity.getDescription(), new EntityData(entity));
@@ -664,7 +664,7 @@ public class SunConversion implements DynamicDeployer {
             return;
         }
 
-        final Map<String, Map<String, WebserviceEndpoint>> endpointMap = new HashMap<String, Map<String, WebserviceEndpoint>>();
+        final Map<String, Map<String, WebserviceEndpoint>> endpointMap = new HashMap<>();
         for (final Ejb ejb : sunEjbJar.getEnterpriseBeans().getEjb()) {
             final EjbDeployment deployment = openejbJar.getDeploymentsByEjbName().get(ejb.getEjbName());
             if (deployment == null) {
@@ -748,7 +748,7 @@ public class SunConversion implements DynamicDeployer {
                     refName = normalize(refName);
                     final ServiceRef serviceRef = serviceRefMap.get(refName);
                     if (serviceRef != null) {
-                        final Map<String, PortComponentRef> ports = new TreeMap<String, PortComponentRef>();
+                        final Map<String, PortComponentRef> ports = new TreeMap<>();
                         for (final PortComponentRef portComponentRef : serviceRef.getPortComponentRef()) {
                             ports.put(portComponentRef.getServiceEndpointInterface(), portComponentRef);
                         }
@@ -850,7 +850,7 @@ public class SunConversion implements DynamicDeployer {
                 continue;
             }
 
-            final Collection<String> cmpFields = new ArrayList<String>(bean.getCmpField().size());
+            final Collection<String> cmpFields = new ArrayList<>(bean.getCmpField().size());
             for (final CmpField cmpField : bean.getCmpField()) {
                 cmpFields.add(cmpField.getFieldName());
             }
@@ -1091,7 +1091,7 @@ public class SunConversion implements DynamicDeployer {
         }
 
         final List bits = Collections.list(new StringTokenizer(queryParams, " \t\n\r\f,", false));
-        final List<List<String>> params = new ArrayList<List<String>>(bits.size() / 2);
+        final List<List<String>> params = new ArrayList<>(bits.size() / 2);
         for (int i = 0; i < bits.size(); i++) {
             final String type = resolveType((String) bits.get(i));
             final String param = (String) bits.get(++i);
@@ -1122,7 +1122,7 @@ public class SunConversion implements DynamicDeployer {
             return null;
         }
 
-        final Map<String, String> variableMap = new TreeMap<String, String>();
+        final Map<String, String> variableMap = new TreeMap<>();
         for (final String cmpField : cmpFields) {
             variableMap.put(cmpField, "o." + cmpField);
         }
@@ -1131,7 +1131,7 @@ public class SunConversion implements DynamicDeployer {
             variableMap.put(param.get(1), "?" + (i + 1));
         }
 
-        final Map<String, String> symbolMap = new TreeMap<String, String>();
+        final Map<String, String> symbolMap = new TreeMap<>();
         symbolMap.put("&&", "and");
         symbolMap.put("||", "or");
         symbolMap.put("!", "not");
@@ -1166,7 +1166,7 @@ public class SunConversion implements DynamicDeployer {
     }
 
     private List<String> tokenize(final String queryFilter) {
-        final LinkedList<String> tokens = new LinkedList<String>();
+        final LinkedList<String> tokens = new LinkedList<>();
         final List bits = Collections.list(new StringTokenizer(queryFilter, " \t\n\r\f()&|<>=!~+-/*", true));
 
         boolean inWitespace = false;
@@ -1247,9 +1247,9 @@ public class SunConversion implements DynamicDeployer {
 
     private class EntityData {
         private final Entity entity;
-        private final Map<String, Id> ids = new TreeMap<String, Id>();
-        private final Map<String, Field> fields = new TreeMap<String, Field>();
-        private final Map<String, RelationField> relations = new TreeMap<String, RelationField>();
+        private final Map<String, Id> ids = new TreeMap<>();
+        private final Map<String, Field> fields = new TreeMap<>();
+        private final Map<String, RelationField> relations = new TreeMap<>();
 
         public EntityData(final Entity entity) {
             if (entity == null) {

http://git-wip-us.apache.org/repos/asf/tomee/blob/bfb1ed40/container/openejb-core/src/main/java/org/apache/openejb/config/TldScanner.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/main/java/org/apache/openejb/config/TldScanner.java b/container/openejb-core/src/main/java/org/apache/openejb/config/TldScanner.java
index 31652ad..9223333 100644
--- a/container/openejb-core/src/main/java/org/apache/openejb/config/TldScanner.java
+++ b/container/openejb-core/src/main/java/org/apache/openejb/config/TldScanner.java
@@ -101,7 +101,7 @@ public class TldScanner {
             return Collections.emptySet();
         }
 
-        final Set<URL> tldUrls = new HashSet<URL>();
+        final Set<URL> tldUrls = new HashSet<>();
 
         if (classLoader == null) {
             return tldUrls;
@@ -125,7 +125,7 @@ public class TldScanner {
                     Math.min(urls.size(), 2 * Runtime.getRuntime().availableProcessors() + 1),
                     new DaemonThreadFactory("OpenEJB-tld-server-scanning"));
 
-            final Collection<Future<Set<URL>>> futures = new ArrayList<Future<Set<URL>>>(urls.size());
+            final Collection<Future<Set<URL>>> futures = new ArrayList<>(urls.size());
             for (URL url : urls) {
                 if (url.getProtocol().equals("jar")) {
                     try {
@@ -177,7 +177,7 @@ public class TldScanner {
     }
 
     static Set<URL> scanWarForTagLibs(final File war) {
-        final Set<URL> urls = new HashSet<URL>();
+        final Set<URL> urls = new HashSet<>();
 
         final File webInfDir = new File(war, "WEB-INF");
         if (!webInfDir.isDirectory()) {
@@ -186,7 +186,7 @@ public class TldScanner {
 
 
         // skip the lib and classes dir in WEB-INF
-        final LinkedList<File> files = new LinkedList<File>();
+        final LinkedList<File> files = new LinkedList<>();
         final File[] list = webInfDir.listFiles();
         if (list != null) {
             for (final File file : list) {
@@ -233,7 +233,7 @@ public class TldScanner {
     }
 
     static Set<URL> scanForTagLibs(final File file) {
-        final Set<URL> tldLocations = new HashSet<URL>();
+        final Set<URL> tldLocations = new HashSet<>();
         try {
             final String location = file.toURI().toURL().toExternalForm();
 
@@ -252,7 +252,7 @@ public class TldScanner {
     }
 
     static Set<URL> scanJarForTagLibs(final File file) {
-        final Set<URL> urls = new HashSet<URL>();
+        final Set<URL> urls = new HashSet<>();
 
         if (!file.isFile()) {
             return urls;

http://git-wip-us.apache.org/repos/asf/tomee/blob/bfb1ed40/container/openejb-core/src/main/java/org/apache/openejb/config/ValidationContext.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/main/java/org/apache/openejb/config/ValidationContext.java b/container/openejb-core/src/main/java/org/apache/openejb/config/ValidationContext.java
index 754b0f5..33f0d2b 100644
--- a/container/openejb-core/src/main/java/org/apache/openejb/config/ValidationContext.java
+++ b/container/openejb-core/src/main/java/org/apache/openejb/config/ValidationContext.java
@@ -24,9 +24,9 @@ import java.util.List;
  * @version $Rev$ $Date$
  */
 public class ValidationContext implements ValidationResults {
-    private final List<ValidationFailure> failures = new ArrayList<ValidationFailure>();
-    private final List<ValidationWarning> warnings = new ArrayList<ValidationWarning>();
-    private final List<ValidationError> errors = new ArrayList<ValidationError>();
+    private final List<ValidationFailure> failures = new ArrayList<>();
+    private final List<ValidationWarning> warnings = new ArrayList<>();
+    private final List<ValidationError> errors = new ArrayList<>();
 
     private final String moduleType;
     private final String name;

http://git-wip-us.apache.org/repos/asf/tomee/blob/bfb1ed40/container/openejb-core/src/main/java/org/apache/openejb/config/VmDeploymentManager.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/main/java/org/apache/openejb/config/VmDeploymentManager.java b/container/openejb-core/src/main/java/org/apache/openejb/config/VmDeploymentManager.java
index 337ac8a..1fef1ec 100644
--- a/container/openejb-core/src/main/java/org/apache/openejb/config/VmDeploymentManager.java
+++ b/container/openejb-core/src/main/java/org/apache/openejb/config/VmDeploymentManager.java
@@ -161,7 +161,7 @@ public class VmDeploymentManager implements DeploymentManager {
     }
 
     private static Set<TargetModuleID> toTargetModuleIds(final Collection<AppInfo> deployedApps, final ModuleType allowedModuleType) {
-        final Set<TargetModuleID> targetModuleIds = new HashSet<TargetModuleID>(deployedApps.size());
+        final Set<TargetModuleID> targetModuleIds = new HashSet<>(deployedApps.size());
         for (final AppInfo deployedApp : deployedApps) {
             final TargetModuleID moduleId = toTargetModuleId(deployedApp, allowedModuleType);
             // moduleID will be null if the module was filtered
@@ -173,7 +173,7 @@ public class VmDeploymentManager implements DeploymentManager {
     }
 
     private static TargetModuleID toTargetModuleId(final AppInfo appInfo, final ModuleType allowedModuleType) {
-        final List<InfoObject> infos = new ArrayList<InfoObject>();
+        final List<InfoObject> infos = new ArrayList<>();
         infos.addAll(appInfo.clients);
         infos.addAll(appInfo.ejbJars);
         infos.addAll(appInfo.webApps);
@@ -403,7 +403,7 @@ public class VmDeploymentManager implements DeploymentManager {
         }
 
         final Set<TargetModuleID> deployedModules = toTargetModuleIds(getDeployer().getDeployedApps(), null);
-        final Set<TargetModuleID> targetModuleIds = new HashSet<TargetModuleID>(Arrays.asList(moduleIdList));
+        final Set<TargetModuleID> targetModuleIds = new HashSet<>(Arrays.asList(moduleIdList));
         targetModuleIds.retainAll(deployedModules);
 
         return new ProgressObjectImpl(CommandType.START, targetModuleIds);
@@ -425,7 +425,7 @@ public class VmDeploymentManager implements DeploymentManager {
         }
 
         UndeployException undeployException = null;
-        final Set<TargetModuleID> results = new TreeSet<TargetModuleID>();
+        final Set<TargetModuleID> results = new TreeSet<>();
         for (final TargetModuleID targetModuleId : moduleIdList) {
             try {
                 getDeployer().undeploy(targetModuleId.getModuleID());
@@ -580,7 +580,7 @@ public class VmDeploymentManager implements DeploymentManager {
         private final String moduleId;
         private final String webUrl;
         private TargetModuleID parentTargetModuleId;
-        private final Set<TargetModuleID> children = new TreeSet<TargetModuleID>();
+        private final Set<TargetModuleID> children = new TreeSet<>();
 
         public TargetModuleIDImpl(final Target target, final String moduleId) {
             this(target, moduleId, null);

http://git-wip-us.apache.org/repos/asf/tomee/blob/bfb1ed40/container/openejb-core/src/main/java/org/apache/openejb/config/WebModule.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/main/java/org/apache/openejb/config/WebModule.java b/container/openejb-core/src/main/java/org/apache/openejb/config/WebModule.java
index e760cb2..3df658c 100644
--- a/container/openejb-core/src/main/java/org/apache/openejb/config/WebModule.java
+++ b/container/openejb-core/src/main/java/org/apache/openejb/config/WebModule.java
@@ -46,18 +46,18 @@ public class WebModule extends Module implements WsModule, RESTModule {
     private Webservices webservices;
     private String host;
     private String contextRoot;
-    private final List<TldTaglib> taglibs = new ArrayList<TldTaglib>();
-    private final Set<String> watchedResources = new TreeSet<String>();
+    private final List<TldTaglib> taglibs = new ArrayList<>();
+    private final Set<String> watchedResources = new TreeSet<>();
     // List of all faces configuration files found in this web module
-    private final List<FacesConfig> facesConfigs = new ArrayList<FacesConfig>();
+    private final List<FacesConfig> facesConfigs = new ArrayList<>();
     private IAnnotationFinder finder;
-    private final Set<String> restClasses = new TreeSet<String>();
-    private final Set<String> ejbWebServices = new TreeSet<String>();
-    private final Set<String> ejbRestServices = new TreeSet<String>();
-    private final Set<String> jaxrsProviders = new TreeSet<String>();
-    private final Set<String> restApplications = new TreeSet<String>();
-    private final Map<String, Set<String>> jsfAnnotatedClasses = new HashMap<String, Set<String>>();
-    private final Map<String, Set<String>> webAnnotatedClasses = new HashMap<String, Set<String>>();
+    private final Set<String> restClasses = new TreeSet<>();
+    private final Set<String> ejbWebServices = new TreeSet<>();
+    private final Set<String> ejbRestServices = new TreeSet<>();
+    private final Set<String> jaxrsProviders = new TreeSet<>();
+    private final Set<String> restApplications = new TreeSet<>();
+    private final Map<String, Set<String>> jsfAnnotatedClasses = new HashMap<>();
+    private final Map<String, Set<String>> webAnnotatedClasses = new HashMap<>();
 
     private final ID id;
 

http://git-wip-us.apache.org/repos/asf/tomee/blob/bfb1ed40/container/openejb-core/src/main/java/org/apache/openejb/config/WebappAggregatedArchive.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/main/java/org/apache/openejb/config/WebappAggregatedArchive.java b/container/openejb-core/src/main/java/org/apache/openejb/config/WebappAggregatedArchive.java
index 58f7743..2e0a90b 100644
--- a/container/openejb-core/src/main/java/org/apache/openejb/config/WebappAggregatedArchive.java
+++ b/container/openejb-core/src/main/java/org/apache/openejb/config/WebappAggregatedArchive.java
@@ -95,7 +95,7 @@ public class WebappAggregatedArchive implements Archive, ScanConstants {
     // for internal usage mainly like faked modules
     public WebappAggregatedArchive(final Archive delegate, final Iterable<URL> urls) {
         final List<Archive> archives = doScan(Thread.currentThread().getContextClassLoader(), urls, null);
-        final List<String> classes = new ArrayList<String>();
+        final List<String> classes = new ArrayList<>();
         final Archive archive = new FilteredArchive(delegate, new ScanXmlSaverFilter(scanXmlExists, handler, classes, null));
         try {
             this.map.put(new URL("jar:file://!/META-INF/beans.xml"), classes);

http://git-wip-us.apache.org/repos/asf/tomee/blob/bfb1ed40/container/openejb-core/src/main/java/org/apache/openejb/config/WsDeployer.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/main/java/org/apache/openejb/config/WsDeployer.java b/container/openejb-core/src/main/java/org/apache/openejb/config/WsDeployer.java
index f0c517f..cc9dc75 100644
--- a/container/openejb-core/src/main/java/org/apache/openejb/config/WsDeployer.java
+++ b/container/openejb-core/src/main/java/org/apache/openejb/config/WsDeployer.java
@@ -115,7 +115,7 @@ public class WsDeployer implements DynamicDeployer {
     private void processPorts(final WebModule webModule) throws OpenEJBException {
         // map existing webservice port declarations by servlet link
         Webservices webservices = webModule.getWebservices();
-        final Map<String, PortComponent> portMap = new TreeMap<String, PortComponent>();
+        final Map<String, PortComponent> portMap = new TreeMap<>();
         if (webservices != null) {
             for (final WebserviceDescription webserviceDescription : webservices.getWebserviceDescription()) {
                 for (final PortComponent portComponent : webserviceDescription.getPortComponent()) {
@@ -130,7 +130,7 @@ public class WsDeployer implements DynamicDeployer {
 
         // map existing servlet-mapping declarations
         final WebApp webApp = webModule.getWebApp();
-        final Map<String, ServletMapping> servletMappings = new TreeMap<String, ServletMapping>();
+        final Map<String, ServletMapping> servletMappings = new TreeMap<>();
         for (final ServletMapping servletMapping : webApp.getServletMapping()) {
             servletMappings.put(servletMapping.getServletName(), servletMapping);
         }
@@ -251,7 +251,7 @@ public class WsDeployer implements DynamicDeployer {
     private void processPorts(final EjbModule ejbModule) throws OpenEJBException {
         // map existing webservice port declarations by servlet link
         Webservices webservices = ejbModule.getWebservices();
-        final Map<String, PortComponent> portMap = new TreeMap<String, PortComponent>();
+        final Map<String, PortComponent> portMap = new TreeMap<>();
         if (webservices != null) {
             for (final WebserviceDescription webserviceDescription : webservices.getWebserviceDescription()) {
                 for (final PortComponent portComponent : webserviceDescription.getPortComponent()) {

http://git-wip-us.apache.org/repos/asf/tomee/blob/bfb1ed40/container/openejb-core/src/main/java/org/apache/openejb/config/provider/ProviderManager.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/main/java/org/apache/openejb/config/provider/ProviderManager.java b/container/openejb-core/src/main/java/org/apache/openejb/config/provider/ProviderManager.java
index 2aaa3eb..5142b93 100644
--- a/container/openejb-core/src/main/java/org/apache/openejb/config/provider/ProviderManager.java
+++ b/container/openejb-core/src/main/java/org/apache/openejb/config/provider/ProviderManager.java
@@ -43,8 +43,8 @@ import java.util.Set;
  */
 public class ProviderManager {
 
-    private final List<String> namespaces = new LinkedList<String>();
-    private final Map<ID, ServiceProvider> providers = new LinkedHashMap<ID, ServiceProvider>();
+    private final List<String> namespaces = new LinkedList<>();
+    private final Map<ID, ServiceProvider> providers = new LinkedHashMap<>();
     private final ProviderLoader loader;
 
     public ProviderManager(final ProviderLoader loader) {
@@ -53,11 +53,11 @@ public class ProviderManager {
 
     public ServiceProvider get(final String namespace, final String name) {
         final ID id = new ID(namespace, name);
-        return getProvider(id, new LinkedHashSet<ID>());
+        return getProvider(id, new LinkedHashSet<>());
     }
 
     public List<ServiceProvider> getAll() {
-        return new ArrayList<ServiceProvider>(providers.values());
+        return new ArrayList<>(providers.values());
     }
 
     public void register(final String namespace, final ServiceProvider provider) {
@@ -67,7 +67,7 @@ public class ProviderManager {
 
         final ID id = new ID(namespace, provider.getId());
 
-        register(id, provider, new LinkedHashSet<ID>());
+        register(id, provider, new LinkedHashSet<>());
     }
 
     public List<ServiceProvider> load(String namespace) {
@@ -81,14 +81,14 @@ public class ProviderManager {
             namespaces.add(namespace);
 
             { // load
-                final ArrayList<ServiceProvider> list = new ArrayList<ServiceProvider>(loader.load(namespace));
+                final ArrayList<ServiceProvider> list = new ArrayList<>(loader.load(namespace));
                 for (final ServiceProvider provider : list) {
                     register(namespace, provider);
                 }
             }
         }
 
-        final List<ServiceProvider> providers = new ArrayList<ServiceProvider>();
+        final List<ServiceProvider> providers = new ArrayList<>();
         for (final Map.Entry<ID, ServiceProvider> entry : this.providers.entrySet()) {
             if (entry.getKey().getNamespace().equals(namespace)) {
                 providers.add(entry.getValue());
@@ -144,7 +144,7 @@ public class ProviderManager {
         }
 
         { // types
-            final Set<String> types = new HashSet<String>();
+            final Set<String> types = new HashSet<>();
             types.addAll(parent.getTypes());
             types.addAll(child.getTypes());
 

http://git-wip-us.apache.org/repos/asf/tomee/blob/bfb1ed40/container/openejb-core/src/main/java/org/apache/openejb/config/provider/ServiceJarXmlLoader.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/main/java/org/apache/openejb/config/provider/ServiceJarXmlLoader.java b/container/openejb-core/src/main/java/org/apache/openejb/config/provider/ServiceJarXmlLoader.java
index e0a9613..99a4440 100644
--- a/container/openejb-core/src/main/java/org/apache/openejb/config/provider/ServiceJarXmlLoader.java
+++ b/container/openejb-core/src/main/java/org/apache/openejb/config/provider/ServiceJarXmlLoader.java
@@ -33,8 +33,8 @@ import java.util.Map;
  */
 public class ServiceJarXmlLoader implements ProviderLoader {
 
-    private final Map<ID, ServiceProvider> loaded = new LinkedHashMap<ID, ServiceProvider>();
-    private final List<String> namespaces = new LinkedList<String>();
+    private final Map<ID, ServiceProvider> loaded = new LinkedHashMap<>();
+    private final List<String> namespaces = new LinkedList<>();
 
     @Override
     public ServiceProvider load(final ID id) {
@@ -81,7 +81,7 @@ public class ServiceJarXmlLoader implements ProviderLoader {
             parse(namespace);
         }
 
-        final List<ServiceProvider> list = new ArrayList<ServiceProvider>();
+        final List<ServiceProvider> list = new ArrayList<>();
         for (final Map.Entry<ID, ServiceProvider> entry : loaded.entrySet()) {
             if (entry.getKey().getNamespace().equals(namespace)) {
                 list.add(entry.getValue());

http://git-wip-us.apache.org/repos/asf/tomee/blob/bfb1ed40/container/openejb-core/src/main/java/org/apache/openejb/config/rules/CheckAssemblyBindings.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/main/java/org/apache/openejb/config/rules/CheckAssemblyBindings.java b/container/openejb-core/src/main/java/org/apache/openejb/config/rules/CheckAssemblyBindings.java
index b210423..82a235f 100644
--- a/container/openejb-core/src/main/java/org/apache/openejb/config/rules/CheckAssemblyBindings.java
+++ b/container/openejb-core/src/main/java/org/apache/openejb/config/rules/CheckAssemblyBindings.java
@@ -94,16 +94,16 @@ public class CheckAssemblyBindings extends ValidationBase {
         final AssemblyDescriptor assembly = ejbModule.getEjbJar().getAssemblyDescriptor();
         final Interceptor[] interceptorsArray = ejbModule.getEjbJar().getInterceptors();
         final List<Interceptor> interceptors = Arrays.asList(interceptorsArray);
-        final Set<String> interceptorClassNames = new HashSet<String>(interceptors.size());
+        final Set<String> interceptorClassNames = new HashSet<>(interceptors.size());
         for (final Interceptor interceptor : interceptors) {
             interceptorClassNames.add(interceptor.getInterceptorClass());
         }
-        final Set<String> interceptorClassNamesUsedInBindings = new HashSet<String>();
+        final Set<String> interceptorClassNamesUsedInBindings = new HashSet<>();
         for (final InterceptorBinding binding : assembly.getInterceptorBinding()) {
             final List<String> interceptorClass = binding.getInterceptorClass();
             interceptorClassNamesUsedInBindings.addAll(interceptorClass);
         }
-        final Set<String> unusedInterceptors = new HashSet<String>();
+        final Set<String> unusedInterceptors = new HashSet<>();
         for (final String clazz : interceptorClassNames) {
             if (!interceptorClassNamesUsedInBindings.contains(clazz)) {
                 unusedInterceptors.add(clazz);

http://git-wip-us.apache.org/repos/asf/tomee/blob/bfb1ed40/container/openejb-core/src/main/java/org/apache/openejb/config/rules/CheckAsynchronous.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/main/java/org/apache/openejb/config/rules/CheckAsynchronous.java b/container/openejb-core/src/main/java/org/apache/openejb/config/rules/CheckAsynchronous.java
index 229181a..c274ec9 100644
--- a/container/openejb-core/src/main/java/org/apache/openejb/config/rules/CheckAsynchronous.java
+++ b/container/openejb-core/src/main/java/org/apache/openejb/config/rules/CheckAsynchronous.java
@@ -40,7 +40,7 @@ import java.util.concurrent.Future;
 public class CheckAsynchronous extends ValidationBase {
 
     public void validate(final EjbModule module) {
-        final Set<String> applicationExceptions = new HashSet<String>();
+        final Set<String> applicationExceptions = new HashSet<>();
         for (final ApplicationException applicationException : module.getEjbJar().getAssemblyDescriptor().getApplicationException()) {
             applicationExceptions.add(applicationException.getExceptionClass());
         }

http://git-wip-us.apache.org/repos/asf/tomee/blob/bfb1ed40/container/openejb-core/src/main/java/org/apache/openejb/config/rules/CheckCallbacks.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/main/java/org/apache/openejb/config/rules/CheckCallbacks.java b/container/openejb-core/src/main/java/org/apache/openejb/config/rules/CheckCallbacks.java
index 0c81c34..0e854e2 100644
--- a/container/openejb-core/src/main/java/org/apache/openejb/config/rules/CheckCallbacks.java
+++ b/container/openejb-core/src/main/java/org/apache/openejb/config/rules/CheckCallbacks.java
@@ -432,7 +432,7 @@ public class CheckCallbacks extends ValidationBase {
     }
 
     private List<Method> getMethods(Class clazz, final String methodName) {
-        final List<Method> methods = new ArrayList<Method>();
+        final List<Method> methods = new ArrayList<>();
         while (clazz != null) {
             for (final Method method : clazz.getDeclaredMethods()) {
                 if (method.getName().equals(methodName)) {

http://git-wip-us.apache.org/repos/asf/tomee/blob/bfb1ed40/container/openejb-core/src/main/java/org/apache/openejb/config/rules/CheckClassLoading.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/main/java/org/apache/openejb/config/rules/CheckClassLoading.java b/container/openejb-core/src/main/java/org/apache/openejb/config/rules/CheckClassLoading.java
index dd3d8ae..f5ba718 100644
--- a/container/openejb-core/src/main/java/org/apache/openejb/config/rules/CheckClassLoading.java
+++ b/container/openejb-core/src/main/java/org/apache/openejb/config/rules/CheckClassLoading.java
@@ -100,7 +100,7 @@ public class CheckClassLoading extends ValidationBase {
     public static class Classes {
         private static final String[] CLASS_EXTENSION = new String[]{".class"};
 
-        private final Map<String, Collection<String>> fileByArchive = new TreeMap<String, Collection<String>>();
+        private final Map<String, Collection<String>> fileByArchive = new TreeMap<>();
 
         public Classes(final URL[] urls) {
             list(urls);
@@ -125,7 +125,7 @@ public class CheckClassLoading extends ValidationBase {
     }
 
     public static Collection<DiffItem> intersection(final Classes cl1, final Classes cl2) {
-        final List<DiffItem> diff = new ArrayList<DiffItem>();
+        final List<DiffItem> diff = new ArrayList<>();
         for (final Map.Entry<String, Collection<String>> entry1 : cl1.fileByArchive.entrySet()) {
             for (final Map.Entry<String, Collection<String>> entry2 : cl2.fileByArchive.entrySet()) {
                 final Collection<String> v1 = entry1.getValue();
@@ -165,7 +165,7 @@ public class CheckClassLoading extends ValidationBase {
                 throw new IllegalArgumentException(archive.getPath() + " is not a file");
             }
 
-            final List<String> files = new ArrayList<String>();
+            final List<String> files = new ArrayList<>();
 
             try (JarFile file = new JarFile(archive)) {
                 final Enumeration<JarEntry> entries = file.entries();
@@ -190,7 +190,7 @@ public class CheckClassLoading extends ValidationBase {
     }
 
     public static class DiffItem {
-        private Collection<String> files = new ArrayList<String>();
+        private Collection<String> files = new ArrayList<>();
         private final String file1;
         private final String file2;
 

http://git-wip-us.apache.org/repos/asf/tomee/blob/bfb1ed40/container/openejb-core/src/main/java/org/apache/openejb/config/rules/CheckDependsOn.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/main/java/org/apache/openejb/config/rules/CheckDependsOn.java b/container/openejb-core/src/main/java/org/apache/openejb/config/rules/CheckDependsOn.java
index 41273ca..3ccae7c 100644
--- a/container/openejb-core/src/main/java/org/apache/openejb/config/rules/CheckDependsOn.java
+++ b/container/openejb-core/src/main/java/org/apache/openejb/config/rules/CheckDependsOn.java
@@ -41,7 +41,7 @@ public class CheckDependsOn extends ValidationBase {
     public void validate(final AppModule appModule) {
         module = appModule;
 
-        final LinkResolver<Bean> app = new LinkResolver<Bean>();
+        final LinkResolver<Bean> app = new LinkResolver<>();
 
         for (final EjbModule ejbModule : appModule.getEjbModules()) {
 
@@ -88,7 +88,7 @@ public class CheckDependsOn extends ValidationBase {
                 }
 
                 public Set<String> getReferences(final Bean t) {
-                    final LinkedHashSet<String> refs = new LinkedHashSet<String>();
+                    final LinkedHashSet<String> refs = new LinkedHashSet<>();
                     for (final Bean bean : t.dependsOn) {
                         refs.add(bean.getId());
                     }
@@ -97,7 +97,7 @@ public class CheckDependsOn extends ValidationBase {
             });
         } catch (final CircularReferencesException e) {
             for (final List<Bean> circuit : e.getCircuits()) {
-                final List<String> ejbNames = new ArrayList<String>(circuit.size());
+                final List<String> ejbNames = new ArrayList<>(circuit.size());
                 for (final Bean bean : circuit) {
                     ejbNames.add(bean.bean.getEjbName());
                 }
@@ -129,7 +129,7 @@ public class CheckDependsOn extends ValidationBase {
     public static class Bean {
         private final URI moduleUri;
         private final EnterpriseBean bean;
-        private final ArrayList<Bean> dependsOn = new ArrayList<Bean>();
+        private final ArrayList<Bean> dependsOn = new ArrayList<>();
         private final EjbModule module;
         private final Resolver<Bean> resolver;
 

http://git-wip-us.apache.org/repos/asf/tomee/blob/bfb1ed40/container/openejb-core/src/main/java/org/apache/openejb/config/rules/CheckDescriptorLocation.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/main/java/org/apache/openejb/config/rules/CheckDescriptorLocation.java b/container/openejb-core/src/main/java/org/apache/openejb/config/rules/CheckDescriptorLocation.java
index ba50966..e8a8685 100644
--- a/container/openejb-core/src/main/java/org/apache/openejb/config/rules/CheckDescriptorLocation.java
+++ b/container/openejb-core/src/main/java/org/apache/openejb/config/rules/CheckDescriptorLocation.java
@@ -40,7 +40,7 @@ public class CheckDescriptorLocation extends ValidationBase {
     @Override
     public void validate(final AppModule appModule) {
 
-        final List<String> validated = new ArrayList<String>();
+        final List<String> validated = new ArrayList<>();
 
         for (final WebModule webModule : safe(appModule.getWebModules())) {
             validated.add(webModule.getModuleId());
@@ -91,7 +91,7 @@ public class CheckDescriptorLocation extends ValidationBase {
     }
 
     private static Map<String, URL> retrieveDescriptors(final List<String> descriptorsToSearch, final URL... locationsToSearch) {
-        final Map<String, URL> descriptorAndWrongLocation = new HashMap<String, URL>();
+        final Map<String, URL> descriptorAndWrongLocation = new HashMap<>();
         final ResourceFinder finder = new ResourceFinder(locationsToSearch);
         for (final String descriptor : descriptorsToSearch) {
             final URL resource = finder.getResource(descriptor);

http://git-wip-us.apache.org/repos/asf/tomee/blob/bfb1ed40/container/openejb-core/src/main/java/org/apache/openejb/config/rules/CheckInjectionTargets.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/main/java/org/apache/openejb/config/rules/CheckInjectionTargets.java b/container/openejb-core/src/main/java/org/apache/openejb/config/rules/CheckInjectionTargets.java
index 01f9837..6fd3d1a 100644
--- a/container/openejb-core/src/main/java/org/apache/openejb/config/rules/CheckInjectionTargets.java
+++ b/container/openejb-core/src/main/java/org/apache/openejb/config/rules/CheckInjectionTargets.java
@@ -32,7 +32,7 @@ public class CheckInjectionTargets extends ValidationBase {
     public void validate(final EjbModule ejbModule) {
 
         for (final EnterpriseBean bean : ejbModule.getEjbJar().getEnterpriseBeans()) {
-            final List<JndiReference> entries = new ArrayList<JndiReference>();
+            final List<JndiReference> entries = new ArrayList<>();
             entries.addAll(bean.getEjbLocalRef());
             entries.addAll(bean.getEjbRef());
             entries.addAll(bean.getEnvEntry());

http://git-wip-us.apache.org/repos/asf/tomee/blob/bfb1ed40/container/openejb-core/src/main/java/org/apache/openejb/config/rules/CheckMethods.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/main/java/org/apache/openejb/config/rules/CheckMethods.java b/container/openejb-core/src/main/java/org/apache/openejb/config/rules/CheckMethods.java
index a37dd66..eb541ea 100644
--- a/container/openejb-core/src/main/java/org/apache/openejb/config/rules/CheckMethods.java
+++ b/container/openejb-core/src/main/java/org/apache/openejb/config/rules/CheckMethods.java
@@ -103,8 +103,8 @@ public class CheckMethods extends ValidationBase {
                 final Class[] params = interfaceMethods[i].getParameterTypes();
                 beanClass.getMethod(name, params);
             } catch (final NoSuchMethodException nsme) {
-                final List<Method> differentArgs = new ArrayList<Method>();
-                final List<Method> differentCase = new ArrayList<Method>();
+                final List<Method> differentArgs = new ArrayList<>();
+                final List<Method> differentCase = new ArrayList<>();
 
                 for (final Method method : beanClass.getMethods()) {
                     if (method.getName().equals(name)) {
@@ -154,8 +154,8 @@ public class CheckMethods extends ValidationBase {
                 final Class[] params = interfaceMethods[i].getParameterTypes();
                 beanClass.getMethod(name, params);
             } catch (final NoSuchMethodException nsme) {
-                final List<Method> differentArgs = new ArrayList<Method>();
-                final List<Method> differentCase = new ArrayList<Method>();
+                final List<Method> differentArgs = new ArrayList<>();
+                final List<Method> differentCase = new ArrayList<>();
 
                 for (final Method method : beanClass.getMethods()) {
                     if (method.getName().equals(name)) {

http://git-wip-us.apache.org/repos/asf/tomee/blob/bfb1ed40/container/openejb-core/src/main/java/org/apache/openejb/config/rules/CheckRestMethodArePublic.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/main/java/org/apache/openejb/config/rules/CheckRestMethodArePublic.java b/container/openejb-core/src/main/java/org/apache/openejb/config/rules/CheckRestMethodArePublic.java
index 0682974..6751143 100644
--- a/container/openejb-core/src/main/java/org/apache/openejb/config/rules/CheckRestMethodArePublic.java
+++ b/container/openejb-core/src/main/java/org/apache/openejb/config/rules/CheckRestMethodArePublic.java
@@ -37,7 +37,7 @@ public class CheckRestMethodArePublic implements ValidationRule {
     @Override
     public void validate(final AppModule appModule) {
         // valid standalone classes
-        final Collection<String> standAloneClasses = new ArrayList<String>();
+        final Collection<String> standAloneClasses = new ArrayList<>();
 
         final ClassLoader loader = Thread.currentThread().getContextClassLoader();
         try {
@@ -56,7 +56,7 @@ public class CheckRestMethodArePublic implements ValidationRule {
                 Thread.currentThread().setContextClassLoader(web.getClassLoader());
 
                 // build the list of classes to validate
-                final Collection<String> classes = new ArrayList<String>();
+                final Collection<String> classes = new ArrayList<>();
                 classes.addAll(web.getRestClasses());
                 classes.addAll(web.getEjbRestServices());
 

http://git-wip-us.apache.org/repos/asf/tomee/blob/bfb1ed40/container/openejb-core/src/main/java/org/apache/openejb/config/sys/JaxbOpenejb.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/main/java/org/apache/openejb/config/sys/JaxbOpenejb.java b/container/openejb-core/src/main/java/org/apache/openejb/config/sys/JaxbOpenejb.java
index 6562b67..4e3072b 100644
--- a/container/openejb-core/src/main/java/org/apache/openejb/config/sys/JaxbOpenejb.java
+++ b/container/openejb-core/src/main/java/org/apache/openejb/config/sys/JaxbOpenejb.java
@@ -141,7 +141,7 @@ public abstract class JaxbOpenejb {
 
         final ClassLoader loader = Thread.currentThread().getContextClassLoader();
 
-        final List<URL> sources = new ArrayList<URL>();
+        final List<URL> sources = new ArrayList<>();
 
         { // Find URLs in the classpath
             final String path1 = "META-INF/" + providerPath + "/service-jar.xml";

http://git-wip-us.apache.org/repos/asf/tomee/blob/bfb1ed40/container/openejb-core/src/main/java/org/apache/openejb/config/sys/ListAdapter.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/main/java/org/apache/openejb/config/sys/ListAdapter.java b/container/openejb-core/src/main/java/org/apache/openejb/config/sys/ListAdapter.java
index cae9fb4..056aadd 100644
--- a/container/openejb-core/src/main/java/org/apache/openejb/config/sys/ListAdapter.java
+++ b/container/openejb-core/src/main/java/org/apache/openejb/config/sys/ListAdapter.java
@@ -30,7 +30,7 @@ import java.util.List;
 public class ListAdapter extends XmlAdapter<String, List<String>> {
     public List<String> unmarshal(final String s) {
         final String[] strings = s.split(", *");
-        return new ArrayList<String>(Arrays.asList(strings));
+        return new ArrayList<>(Arrays.asList(strings));
     }
 
     public String marshal(final List<String> list) {

http://git-wip-us.apache.org/repos/asf/tomee/blob/bfb1ed40/container/openejb-core/src/main/java/org/apache/openejb/config/sys/Openejb.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/main/java/org/apache/openejb/config/sys/Openejb.java b/container/openejb-core/src/main/java/org/apache/openejb/config/sys/Openejb.java
index 85b8775..eb3f51d 100644
--- a/container/openejb-core/src/main/java/org/apache/openejb/config/sys/Openejb.java
+++ b/container/openejb-core/src/main/java/org/apache/openejb/config/sys/Openejb.java
@@ -132,7 +132,7 @@ public class Openejb {
      */
     public List<JndiProvider> getJndiProvider() {
         if (jndiProvider == null) {
-            jndiProvider = new ArrayList<JndiProvider>();
+            jndiProvider = new ArrayList<>();
         }
         return this.jndiProvider;
     }

http://git-wip-us.apache.org/repos/asf/tomee/blob/bfb1ed40/container/openejb-core/src/main/java/org/apache/openejb/config/sys/Resources.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/main/java/org/apache/openejb/config/sys/Resources.java b/container/openejb-core/src/main/java/org/apache/openejb/config/sys/Resources.java
index 81ecf8a..54abeb4 100644
--- a/container/openejb-core/src/main/java/org/apache/openejb/config/sys/Resources.java
+++ b/container/openejb-core/src/main/java/org/apache/openejb/config/sys/Resources.java
@@ -67,7 +67,7 @@ public class Resources {
 
     public List<Resource> getResource() {
         if (resource == null) {
-            resource = new ArrayList<Resource>();
+            resource = new ArrayList<>();
         }
 
         return this.resource;
@@ -75,7 +75,7 @@ public class Resources {
 
     public List<Container> getContainer() {
         if (container == null) {
-            container = new ArrayList<Container>();
+            container = new ArrayList<>();
         }
 
         return this.container;
@@ -83,21 +83,21 @@ public class Resources {
 
     public List<Service> getService() {
         if (service == null) {
-            service = new ArrayList<Service>();
+            service = new ArrayList<>();
         }
         return service;
     }
 
     public List<Connector> getConnector() {
         if (connector == null) {
-            connector = new ArrayList<Connector>();
+            connector = new ArrayList<>();
         }
         return this.connector;
     }
 
     public List<JndiProvider> getJndiProvider() {
         if (jndiProvider == null) {
-            jndiProvider = new ArrayList<JndiProvider>();
+            jndiProvider = new ArrayList<>();
         }
         return this.jndiProvider;
     }

http://git-wip-us.apache.org/repos/asf/tomee/blob/bfb1ed40/container/openejb-core/src/main/java/org/apache/openejb/config/sys/SaxAppCtxConfig.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/main/java/org/apache/openejb/config/sys/SaxAppCtxConfig.java b/container/openejb-core/src/main/java/org/apache/openejb/config/sys/SaxAppCtxConfig.java
index b0b9ecf..0164794 100644
--- a/container/openejb-core/src/main/java/org/apache/openejb/config/sys/SaxAppCtxConfig.java
+++ b/container/openejb-core/src/main/java/org/apache/openejb/config/sys/SaxAppCtxConfig.java
@@ -222,7 +222,7 @@ public class SaxAppCtxConfig {
         }
 
         private class Pojos extends DefaultHandler {
-            protected final List<PojoConfig> genericConfigs = new ArrayList<PojoConfig>();
+            protected final List<PojoConfig> genericConfigs = new ArrayList<>();
 
             protected final Collection<String> aliases;
 
@@ -292,7 +292,7 @@ public class SaxAppCtxConfig {
             }
 
             protected Collection<Properties> propertiesForModule(final String id) {
-                final Collection<Properties> props = new ArrayList<Properties>();
+                final Collection<Properties> props = new ArrayList<>();
                 for (final DeploymentModule m : module.getDeploymentModule()) {
                     if (acceptModule(id, m)) {
                         props.add(m.getProperties());
@@ -309,7 +309,7 @@ public class SaxAppCtxConfig {
 
             @Override
             protected Collection<Properties> propertiesForModule(final String id) {
-                final Collection<Properties> props = new ArrayList<Properties>();
+                final Collection<Properties> props = new ArrayList<>();
                 for (final WebModule m : module.getWebModules()) {
                     if (acceptModule(id, m)) {
                         props.add(m.getProperties());

http://git-wip-us.apache.org/repos/asf/tomee/blob/bfb1ed40/container/openejb-core/src/main/java/org/apache/openejb/config/sys/SaxOpenejb.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/main/java/org/apache/openejb/config/sys/SaxOpenejb.java b/container/openejb-core/src/main/java/org/apache/openejb/config/sys/SaxOpenejb.java
index 88944f4..0debad4 100644
--- a/container/openejb-core/src/main/java/org/apache/openejb/config/sys/SaxOpenejb.java
+++ b/container/openejb-core/src/main/java/org/apache/openejb/config/sys/SaxOpenejb.java
@@ -170,7 +170,7 @@ class SaxOpenejb extends StackHandler {
 
         @Override
         protected List<String> getAttributes() {
-            final List<String> attributes = new ArrayList<String>(super.getAttributes());
+            final List<String> attributes = new ArrayList<>(super.getAttributes());
             attributes.add("ctype");
             return attributes;
         }

http://git-wip-us.apache.org/repos/asf/tomee/blob/bfb1ed40/container/openejb-core/src/main/java/org/apache/openejb/config/sys/ServiceProvider.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/main/java/org/apache/openejb/config/sys/ServiceProvider.java b/container/openejb-core/src/main/java/org/apache/openejb/config/sys/ServiceProvider.java
index 215ef12..ec8d506 100644
--- a/container/openejb-core/src/main/java/org/apache/openejb/config/sys/ServiceProvider.java
+++ b/container/openejb-core/src/main/java/org/apache/openejb/config/sys/ServiceProvider.java
@@ -265,7 +265,7 @@ public class ServiceProvider {
     @SuppressWarnings({"unchecked"})
     public List<String> getTypes() {
         if (types == null) {
-            types = new ArrayList<String>();
+            types = new ArrayList<>();
         }
         return (List<String>) types;
     }

http://git-wip-us.apache.org/repos/asf/tomee/blob/bfb1ed40/container/openejb-core/src/main/java/org/apache/openejb/config/sys/ServicesJar.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/main/java/org/apache/openejb/config/sys/ServicesJar.java b/container/openejb-core/src/main/java/org/apache/openejb/config/sys/ServicesJar.java
index a916bc9..c1f7d44 100644
--- a/container/openejb-core/src/main/java/org/apache/openejb/config/sys/ServicesJar.java
+++ b/container/openejb-core/src/main/java/org/apache/openejb/config/sys/ServicesJar.java
@@ -73,7 +73,7 @@ public class ServicesJar {
      */
     public List<ServiceProvider> getServiceProvider() {
         if (serviceProvider == null) {
-            serviceProvider = new ArrayList<ServiceProvider>();
+            serviceProvider = new ArrayList<>();
         }
         return this.serviceProvider;
     }

http://git-wip-us.apache.org/repos/asf/tomee/blob/bfb1ed40/container/openejb-core/src/main/java/org/apache/openejb/config/sys/WikiGenerator.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/main/java/org/apache/openejb/config/sys/WikiGenerator.java b/container/openejb-core/src/main/java/org/apache/openejb/config/sys/WikiGenerator.java
index 40881d3..deb4d64 100644
--- a/container/openejb-core/src/main/java/org/apache/openejb/config/sys/WikiGenerator.java
+++ b/container/openejb-core/src/main/java/org/apache/openejb/config/sys/WikiGenerator.java
@@ -94,7 +94,7 @@ public class WikiGenerator {
         }
         out.println();
 
-        final ArrayList<String> seen = new ArrayList<String>();
+        final ArrayList<String> seen = new ArrayList<>();
         for (final ServiceProvider provider : servicesJar.getServiceProvider()) {
             if ("Resource".equals(provider.getService())) {
 
@@ -126,7 +126,7 @@ public class WikiGenerator {
         out.println();
         final SuperProperties properties = (SuperProperties) provider.getProperties();
 
-        final Map<String, String> defaults = new LinkedHashMap<String, String>();
+        final Map<String, String> defaults = new LinkedHashMap<>();
 
         if (properties.size() > 0) {
             out.println("## Properties");

http://git-wip-us.apache.org/repos/asf/tomee/blob/bfb1ed40/container/openejb-core/src/main/java/org/apache/openejb/config/typed/util/ObjectMap.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/main/java/org/apache/openejb/config/typed/util/ObjectMap.java b/container/openejb-core/src/main/java/org/apache/openejb/config/typed/util/ObjectMap.java
index 33a0a99..89e9d0b 100644
--- a/container/openejb-core/src/main/java/org/apache/openejb/config/typed/util/ObjectMap.java
+++ b/container/openejb-core/src/main/java/org/apache/openejb/config/typed/util/ObjectMap.java
@@ -47,7 +47,7 @@ public class ObjectMap extends AbstractMap<String, Object> {
     public ObjectMap(final Class<?> clazz, final Object object) {
         this.object = object;
 
-        attributes = new HashMap<String, Entry<String, Object>>();
+        attributes = new HashMap<>();
 
         for (final Field field : clazz.getDeclaredFields()) {
             field.setAccessible(true);
@@ -76,7 +76,7 @@ public class ObjectMap extends AbstractMap<String, Object> {
             }
         }
 
-        entries = Collections.unmodifiableSet(new HashSet<Entry<String, Object>>(attributes.values()));
+        entries = Collections.unmodifiableSet(new HashSet<>(attributes.values()));
     }
 
     @Override

http://git-wip-us.apache.org/repos/asf/tomee/blob/bfb1ed40/container/openejb-core/src/main/java/org/apache/openejb/config/typed/util/ProviderGenerator.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/main/java/org/apache/openejb/config/typed/util/ProviderGenerator.java b/container/openejb-core/src/main/java/org/apache/openejb/config/typed/util/ProviderGenerator.java
index c927cc6..b4408b9 100644
--- a/container/openejb-core/src/main/java/org/apache/openejb/config/typed/util/ProviderGenerator.java
+++ b/container/openejb-core/src/main/java/org/apache/openejb/config/typed/util/ProviderGenerator.java
@@ -48,7 +48,7 @@ public class ProviderGenerator extends Resource {
     public static void main(final String[] args) throws Exception {
         final ProviderManager manager = new ProviderManager(new ServiceJarXmlLoader());
 
-        final Set<String> seen = new HashSet<String>();
+        final Set<String> seen = new HashSet<>();
 
         final List<ServiceProvider> providers = manager.load("org.apache.tomee");
         for (final ServiceProvider provider : providers) {
@@ -443,7 +443,7 @@ public class ProviderGenerator extends Resource {
 
 
         public String apply(final String... args) {
-            final Map<String, String> map = new HashMap<String, String>();
+            final Map<String, String> map = new HashMap<>();
 
             for (int i = 0; i < args.length; i += 2) {
                 final String key = args[i];

http://git-wip-us.apache.org/repos/asf/tomee/blob/bfb1ed40/container/openejb-core/src/main/java/org/apache/openejb/core/BaseSessionContext.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/main/java/org/apache/openejb/core/BaseSessionContext.java b/container/openejb-core/src/main/java/org/apache/openejb/core/BaseSessionContext.java
index 02f333f..8a3edb7 100644
--- a/container/openejb-core/src/main/java/org/apache/openejb/core/BaseSessionContext.java
+++ b/container/openejb-core/src/main/java/org/apache/openejb/core/BaseSessionContext.java
@@ -126,19 +126,19 @@ public abstract class BaseSessionContext extends BaseContext implements SessionC
             final EjbObjectProxyHandler handler;
             switch (di.getComponentType()) {
                 case STATEFUL: {
-                    handler = new StatefulEjbObjectHandler(di, threadContext.getPrimaryKey(), interfaceType, new ArrayList<Class>(), interfce);
+                    handler = new StatefulEjbObjectHandler(di, threadContext.getPrimaryKey(), interfaceType, new ArrayList<>(), interfce);
                     break;
                 }
                 case STATELESS: {
-                    handler = new StatelessEjbObjectHandler(di, threadContext.getPrimaryKey(), interfaceType, new ArrayList<Class>(), interfce);
+                    handler = new StatelessEjbObjectHandler(di, threadContext.getPrimaryKey(), interfaceType, new ArrayList<>(), interfce);
                     break;
                 }
                 case SINGLETON: {
-                    handler = new SingletonEjbObjectHandler(di, threadContext.getPrimaryKey(), interfaceType, new ArrayList<Class>(), interfce);
+                    handler = new SingletonEjbObjectHandler(di, threadContext.getPrimaryKey(), interfaceType, new ArrayList<>(), interfce);
                     break;
                 }
                 case MANAGED: {
-                    handler = new ManagedObjectHandler(di, threadContext.getPrimaryKey(), interfaceType, new ArrayList<Class>(), interfce);
+                    handler = new ManagedObjectHandler(di, threadContext.getPrimaryKey(), interfaceType, new ArrayList<>(), interfce);
                     break;
                 }
                 default:
@@ -148,7 +148,7 @@ public abstract class BaseSessionContext extends BaseContext implements SessionC
             if (InterfaceType.LOCALBEAN.equals(interfaceType)) {
                 return LocalBeanProxyFactory.constructProxy(di.get(BeanContext.ProxyClass.class).getProxy(), handler);
             } else {
-                final List<Class> interfaces = new ArrayList<Class>();
+                final List<Class> interfaces = new ArrayList<>();
                 interfaces.addAll(di.getInterfaces(interfaceType));
                 interfaces.add(Serializable.class);
                 interfaces.add(IntraVmProxy.class);

http://git-wip-us.apache.org/repos/asf/tomee/blob/bfb1ed40/container/openejb-core/src/main/java/org/apache/openejb/core/CoreContainerSystem.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/main/java/org/apache/openejb/core/CoreContainerSystem.java b/container/openejb-core/src/main/java/org/apache/openejb/core/CoreContainerSystem.java
index 7995791..cdde447 100644
--- a/container/openejb-core/src/main/java/org/apache/openejb/core/CoreContainerSystem.java
+++ b/container/openejb-core/src/main/java/org/apache/openejb/core/CoreContainerSystem.java
@@ -38,10 +38,10 @@ import java.util.concurrent.ConcurrentHashMap;
  */
 public class CoreContainerSystem implements ContainerSystem {
 
-    private final Map<Object, AppContext> apps = new ConcurrentHashMap<Object, AppContext>();
-    private final Map<Object, BeanContext> deployments = new ConcurrentHashMap<Object, BeanContext>();
-    private final Map<Object, Container> containers = new ConcurrentHashMap<Object, Container>();
-    private final Map<String, List<WebContext>> webDeployments = new ConcurrentHashMap<String, List<WebContext>>();
+    private final Map<Object, AppContext> apps = new ConcurrentHashMap<>();
+    private final Map<Object, BeanContext> deployments = new ConcurrentHashMap<>();
+    private final Map<Object, Container> containers = new ConcurrentHashMap<>();
+    private final Map<String, List<WebContext>> webDeployments = new ConcurrentHashMap<>();
     private final Context jndiContext;
 
     /**
@@ -152,7 +152,7 @@ public class CoreContainerSystem implements ContainerSystem {
         final String id = webDeployment.getId();
         List<WebContext> list = this.webDeployments.get(id);
         if (list == null) {
-            list = new ArrayList<WebContext>();
+            list = new ArrayList<>();
             this.webDeployments.put(id, list);
         }
         list.add(webDeployment);
@@ -169,7 +169,7 @@ public class CoreContainerSystem implements ContainerSystem {
 
     @Override
     public List<AppContext> getAppContexts() {
-        return new ArrayList<AppContext>(apps.values());
+        return new ArrayList<>(apps.values());
     }
 
     @Override

http://git-wip-us.apache.org/repos/asf/tomee/blob/bfb1ed40/container/openejb-core/src/main/java/org/apache/openejb/core/SimpleTransactionSynchronizationRegistry.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/main/java/org/apache/openejb/core/SimpleTransactionSynchronizationRegistry.java b/container/openejb-core/src/main/java/org/apache/openejb/core/SimpleTransactionSynchronizationRegistry.java
index 541684b..760241f 100644
--- a/container/openejb-core/src/main/java/org/apache/openejb/core/SimpleTransactionSynchronizationRegistry.java
+++ b/container/openejb-core/src/main/java/org/apache/openejb/core/SimpleTransactionSynchronizationRegistry.java
@@ -28,7 +28,7 @@ import java.util.Map;
 
 public class SimpleTransactionSynchronizationRegistry implements TransactionSynchronizationRegistry {
     private final TransactionManager transactionManager;
-    private final Map<Transaction, Map<Object, Object>> transactionResources = new HashMap<Transaction, Map<Object, Object>>();
+    private final Map<Transaction, Map<Object, Object>> transactionResources = new HashMap<>();
 
     public SimpleTransactionSynchronizationRegistry(final TransactionManager transactionManager) {
         this.transactionManager = transactionManager;
@@ -62,7 +62,7 @@ public class SimpleTransactionSynchronizationRegistry implements TransactionSync
             } catch (final Exception e) {
                 throw new IllegalStateException("No transaction active", e);
             }
-            resources = new HashMap<Object, Object>();
+            resources = new HashMap<>();
             transactionResources.put(transaction, resources);
         }
 

http://git-wip-us.apache.org/repos/asf/tomee/blob/bfb1ed40/container/openejb-core/src/main/java/org/apache/openejb/core/ThreadContext.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/main/java/org/apache/openejb/core/ThreadContext.java b/container/openejb-core/src/main/java/org/apache/openejb/core/ThreadContext.java
index b8a596f..ef7d9cf 100644
--- a/container/openejb-core/src/main/java/org/apache/openejb/core/ThreadContext.java
+++ b/container/openejb-core/src/main/java/org/apache/openejb/core/ThreadContext.java
@@ -112,7 +112,7 @@ public class ThreadContext {
 
     private final BeanContext beanContext;
     private final Object primaryKey;
-    private final Map<Class, Object> data = Collections.synchronizedMap(new HashMap<Class, Object>());
+    private final Map<Class, Object> data = Collections.synchronizedMap(new HashMap<>());
     private ClassLoader oldClassLoader;
     private Operation currentOperation;
     private Class invokedInterface;

http://git-wip-us.apache.org/repos/asf/tomee/blob/bfb1ed40/container/openejb-core/src/main/java/org/apache/openejb/core/WebContext.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/main/java/org/apache/openejb/core/WebContext.java b/container/openejb-core/src/main/java/org/apache/openejb/core/WebContext.java
index 075559a..aa277d6 100644
--- a/container/openejb-core/src/main/java/org/apache/openejb/core/WebContext.java
+++ b/container/openejb-core/src/main/java/org/apache/openejb/core/WebContext.java
@@ -56,7 +56,7 @@ import java.util.concurrent.ConcurrentMap;
 public class WebContext {
     private String id;
     private ClassLoader classLoader;
-    private final Collection<Injection> injections = new ArrayList<Injection>();
+    private final Collection<Injection> injections = new ArrayList<>();
     private Context jndiEnc;
     private final AppContext appContext;
     private Map<String, Object> bindings;
@@ -66,7 +66,7 @@ public class WebContext {
     private String host;
     private Context initialContext;
     private ServletContext servletContext;
-    private final Map<Class<?>, ConstructorInjectionBean<Object>> constructorInjectionBeanCache = new ConcurrentHashMap<Class<?>, ConstructorInjectionBean<Object>>();
+    private final Map<Class<?>, ConstructorInjectionBean<Object>> constructorInjectionBeanCache = new ConcurrentHashMap<>();
 
     public Context getInitialContext() {
         if (initialContext != null) {


Mime
View raw message