You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@camel.apache.org by bv...@apache.org on 2018/04/17 19:47:31 UTC

[camel] 03/05: polish

This is an automated email from the ASF dual-hosted git repository.

bvahdat pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/camel.git

commit 5a0e1aadf1949c0e729f085d42831e6731bc1c3e
Author: Babak Vahdat <bv...@apache.org>
AuthorDate: Tue Apr 17 21:45:38 2018 +0200

    polish
---
 .../camel/component/facebook/FacebookComponent.java    |  2 +-
 .../camel/component/facebook/FacebookConsumer.java     |  6 +++---
 .../camel/component/facebook/FacebookEndpoint.java     |  4 ++--
 .../camel/component/facebook/FacebookProducer.java     |  2 +-
 .../component/facebook/data/FacebookMethodsType.java   |  4 ++--
 .../facebook/data/FacebookMethodsTypeHelper.java       | 18 +++++++++---------
 .../facebook/data/FacebookPropertiesHelper.java        |  6 +++---
 .../camel/component/facebook/data/ReadingBuilder.java  |  2 +-
 .../component/facebook/CamelFacebookTestSupport.java   |  2 +-
 .../facebook/FacebookComponentConsumerTest.java        |  2 +-
 .../facebook/FacebookComponentProducerTest.java        |  6 +++---
 .../camel/component/facebook/TestUserMethodsTest.java  |  2 +-
 .../config/FacebookEndpointConfigurationTest.java      |  2 --
 .../facebook/data/FacebookMethodsTypeHelperTest.java   |  4 ++--
 .../component/facebook/data/ReadingBuilderTest.java    |  2 +-
 .../camel/component/fastjson/FastjsonDataFormat.java   |  4 +---
 .../camel/component/fastjson/FastjsonMarshalTest.java  |  2 +-
 .../camel/component/flatpack/FlatpackConverter.java    |  6 +++---
 .../flatpack/FlatpackDelimitedDataFormatTest.java      | 12 ++++++------
 .../flatpack/FlatpackFixedLengthDataFormatTest.java    |  4 ++--
 .../camel/component/flink/DataStreamFlinkProducer.java |  2 --
 .../freemarker/FreemarkerContentCacheTest.java         |  2 +-
 .../camel/component/freemarker/FreemarkerTest.java     |  4 ++--
 .../camel/component/file/remote/FtpComponent.java      |  2 +-
 .../camel/component/file/remote/FtpConsumer.java       |  4 ++--
 .../camel/component/file/remote/FtpEndpoint.java       |  8 ++++----
 .../camel/component/file/remote/FtpOperations.java     |  4 ++--
 .../camel/component/file/remote/FtpsEndpoint.java      |  4 ++--
 .../component/file/remote/RemoteFileEndpoint.java      |  1 -
 .../camel/component/file/remote/SftpConsumer.java      |  6 ++----
 .../camel/component/file/remote/SftpEndpoint.java      |  2 +-
 .../camel/component/file/remote/SftpOperations.java    |  2 +-
 .../remote/strategy/FtpProcessStrategyFactory.java     | 18 +++++++++---------
 .../remote/strategy/SftpProcessStrategyFactory.java    | 18 +++++++++---------
 .../file/remote/FromFtpClientSoTimeout3Test.java       |  2 +-
 .../camel/component/file/remote/FromFtpFilterTest.java |  2 +-
 .../remote/FromFtpRemoteFileFilterDirectoryTest.java   |  2 +-
 .../file/remote/FromFtpRemoteFileFilterTest.java       |  2 +-
 .../file/remote/FtpBadLoginConnectionLeakTest.java     |  2 +-
 .../FtpBadLoginInProducerConnectionLeakTest.java       |  2 +-
 .../remote/FtpBadLoginMockNoopConnectionLeakTest.java  |  2 +-
 .../remote/RecipientListErrorHandlingIssueTest.java    |  4 ++--
 .../remote/RemoteFileProduceOverruleOnlyOnceTest.java  |  2 +-
 .../camel/component/git/consumer/GitConsumerTest.java  |  1 -
 .../component/git/producer/GitRemoteProducerTest.java  |  2 +-
 .../component/github/consumer/CommitConsumer.java      |  4 ++--
 .../github/consumer/PullRequestCommentConsumer.java    |  6 +++---
 .../component/github/consumer/PullRequestConsumer.java |  2 +-
 .../camel/component/github/consumer/TagConsumer.java   |  4 ++--
 .../github/producer/PullRequestFilesProducerTest.java  |  2 +-
 .../component/github/services/MockCommitService.java   |  4 ++--
 .../component/github/services/MockIssueService.java    |  2 +-
 .../github/services/MockPullRequestService.java        | 12 ++++++------
 .../github/services/MockRepositoryService.java         |  2 +-
 .../google/bigquery/GoogleBigQueryProducer.java        |  2 --
 .../google/bigquery/integration/InsertIdTest.java      |  2 --
 .../calendar/AbstractGoogleCalendarTestSupport.java    |  2 +-
 .../calendar/CalendarCalendarsIntegrationTest.java     |  2 +-
 .../google/calendar/CalendarEventsIntegrationTest.java | 10 +++++-----
 .../calendar/CalendarFreebusyIntegrationTest.java      |  2 +-
 .../google/drive/AbstractGoogleDriveTestSupport.java   |  6 +++---
 .../google/drive/DriveChildrenIntegrationTest.java     |  4 ++--
 .../google/drive/DriveCommentsIntegrationTest.java     |  8 ++++----
 .../google/drive/DriveFilesIntegrationTest.java        | 14 +++++++-------
 .../google/drive/DriveRepliesIntegrationTest.java      |  6 +++---
 .../google/mail/AbstractGoogleMailTestSupport.java     |  2 +-
 .../google/mail/GmailUsersLabelsIntegrationTest.java   |  4 ++--
 .../google/mail/GmailUsersMessagesIntegrationTest.java | 16 ++++++++--------
 .../google/mail/GmailUsersThreadsIntegrationTest.java  |  6 +++---
 .../apache/camel/language/groovy/GroovyExpression.java |  2 +-
 .../apache/camel/language/groovy/GroovyLanguage.java   |  2 +-
 .../camel/language/groovy/GroovyListMapTest.java       |  4 ++--
 .../camel/language/groovy/GroovySetHeaderTest.java     |  2 +-
 .../org/apache/camel/component/grpc/GrpcUtils.java     |  7 +------
 .../client/GrpcResponseAggregationStreamObserver.java  |  2 +-
 .../camel/component/grpc/server/GrpcMethodHandler.java |  2 +-
 .../camel/component/gson/GsonMarshalListTest.java      |  2 +-
 .../apache/camel/component/gson/GsonMarshalTest.java   |  2 +-
 .../apache/camel/guice/CamelModuleWithRouteTypes.java  |  2 +-
 .../camel/guice/ComponentFoundInRegistryTest.java      |  2 +-
 .../camel/guice/FileEndpointReferenceRouteTest.java    |  4 ++--
 .../apache/camel/guice/testing/InjectorManager.java    |  2 +-
 82 files changed, 166 insertions(+), 185 deletions(-)

diff --git a/components/camel-facebook/src/main/java/org/apache/camel/component/facebook/FacebookComponent.java b/components/camel-facebook/src/main/java/org/apache/camel/component/facebook/FacebookComponent.java
index 10af568..c55ed9e 100644
--- a/components/camel-facebook/src/main/java/org/apache/camel/component/facebook/FacebookComponent.java
+++ b/components/camel-facebook/src/main/java/org/apache/camel/component/facebook/FacebookComponent.java
@@ -69,7 +69,7 @@ public class FacebookComponent extends UriEndpointComponent {
     }
 
     private FacebookEndpointConfiguration copyComponentProperties() throws Exception {
-        Map<String, Object> componentProperties = new HashMap<String, Object>();
+        Map<String, Object> componentProperties = new HashMap<>();
         IntrospectionSupport.getProperties(configuration, componentProperties, null, false);
 
         // create endpoint configuration with component properties
diff --git a/components/camel-facebook/src/main/java/org/apache/camel/component/facebook/FacebookConsumer.java b/components/camel-facebook/src/main/java/org/apache/camel/component/facebook/FacebookConsumer.java
index e630754..a1d0020 100644
--- a/components/camel-facebook/src/main/java/org/apache/camel/component/facebook/FacebookConsumer.java
+++ b/components/camel-facebook/src/main/java/org/apache/camel/component/facebook/FacebookConsumer.java
@@ -75,7 +75,7 @@ public class FacebookConsumer extends ScheduledPollConsumer {
         this.method = findMethod();
 
         // get endpoint properties in a map
-        final HashMap<String, Object> properties = new HashMap<String, Object>();
+        final HashMap<String, Object> properties = new HashMap<>();
         FacebookPropertiesHelper.getEndpointProperties(endpoint.getConfiguration(), properties);
 
         // skip since and until fields?
@@ -115,7 +115,7 @@ public class FacebookConsumer extends ScheduledPollConsumer {
 
         FacebookMethodsType result;
         // find one that takes the largest subset of endpoint parameters
-        final Set<String> argNames = new HashSet<String>();
+        final Set<String> argNames = new HashSet<>();
         argNames.addAll(FacebookPropertiesHelper.getEndpointPropertyNames(endpoint.getConfiguration()));
 
         // add reading property for polling, if it doesn't already exist!
@@ -209,7 +209,7 @@ public class FacebookConsumer extends ScheduledPollConsumer {
     private Map<String, Object> getMethodArguments() {
         // start by setting the Reading since and until fields,
         // these are used to avoid reading duplicate results across polls
-        Map<String, Object> arguments = new HashMap<String, Object>();
+        Map<String, Object> arguments = new HashMap<>();
         arguments.putAll(endpointProperties);
 
         Reading reading = (Reading) arguments.remove(READING_PROPERTY);
diff --git a/components/camel-facebook/src/main/java/org/apache/camel/component/facebook/FacebookEndpoint.java b/components/camel-facebook/src/main/java/org/apache/camel/component/facebook/FacebookEndpoint.java
index 50696f6..38d291c 100644
--- a/components/camel-facebook/src/main/java/org/apache/camel/component/facebook/FacebookEndpoint.java
+++ b/components/camel-facebook/src/main/java/org/apache/camel/component/facebook/FacebookEndpoint.java
@@ -124,7 +124,7 @@ public class FacebookEndpoint extends DefaultEndpoint implements FacebookConstan
 
     private void initState() {
         // get endpoint property names
-        final Set<String> arguments = new HashSet<String>();
+        final Set<String> arguments = new HashSet<>();
         arguments.addAll(getEndpointPropertyNames(configuration));
         // add inBody argument for producers
         if (inBody != null) {
@@ -132,7 +132,7 @@ public class FacebookEndpoint extends DefaultEndpoint implements FacebookConstan
         }
         final String[] argNames = arguments.toArray(new String[arguments.size()]);
 
-        candidates = new ArrayList<FacebookMethodsType>();
+        candidates = new ArrayList<>();
         candidates.addAll(getCandidateMethods(method, argNames));
         if (!candidates.isEmpty()) {
             // found an exact name match, allows disambiguation if needed
diff --git a/components/camel-facebook/src/main/java/org/apache/camel/component/facebook/FacebookProducer.java b/components/camel-facebook/src/main/java/org/apache/camel/component/facebook/FacebookProducer.java
index b576d5a..a593baf 100644
--- a/components/camel-facebook/src/main/java/org/apache/camel/component/facebook/FacebookProducer.java
+++ b/components/camel-facebook/src/main/java/org/apache/camel/component/facebook/FacebookProducer.java
@@ -64,7 +64,7 @@ public class FacebookProducer extends DefaultAsyncProducer {
     @Override
     public boolean process(final Exchange exchange, final AsyncCallback callback) {
         // properties for method arguments
-        final Map<String, Object> properties = new HashMap<String, Object>();
+        final Map<String, Object> properties = new HashMap<>();
 
         getExchangeProperties(exchange, properties);
         FacebookPropertiesHelper.configureReadingProperties(endpoint.getConfiguration(), properties);
diff --git a/components/camel-facebook/src/main/java/org/apache/camel/component/facebook/data/FacebookMethodsType.java b/components/camel-facebook/src/main/java/org/apache/camel/component/facebook/data/FacebookMethodsType.java
index eb9817d..c11c8a9 100644
--- a/components/camel-facebook/src/main/java/org/apache/camel/component/facebook/data/FacebookMethodsType.java
+++ b/components/camel-facebook/src/main/java/org/apache/camel/component/facebook/data/FacebookMethodsType.java
@@ -696,8 +696,8 @@ public enum FacebookMethodsType {
                     + "must be of the form 'Class arg1, String arg1Name, Class arg2, String arg2Name...");
         }
         int nArgs = args.length / 2;
-        this.argNames = new ArrayList<String>(nArgs);
-        this.argTypes = new ArrayList<Class<?>>(nArgs);
+        this.argNames = new ArrayList<>(nArgs);
+        this.argTypes = new ArrayList<>(nArgs);
         for (int i = 0; i < nArgs; i++) {
             this.argTypes.add((Class<?>) args[i * 2]);
             this.argNames.add((String) args[i * 2 + 1]);
diff --git a/components/camel-facebook/src/main/java/org/apache/camel/component/facebook/data/FacebookMethodsTypeHelper.java b/components/camel-facebook/src/main/java/org/apache/camel/component/facebook/data/FacebookMethodsTypeHelper.java
index fae95e4..78592d6 100644
--- a/components/camel-facebook/src/main/java/org/apache/camel/component/facebook/data/FacebookMethodsTypeHelper.java
+++ b/components/camel-facebook/src/main/java/org/apache/camel/component/facebook/data/FacebookMethodsTypeHelper.java
@@ -45,15 +45,15 @@ public final class FacebookMethodsTypeHelper {
 
     // maps method name to FacebookMethodsType
     private static final Map<String, List<FacebookMethodsType>> METHOD_MAP =
-        new HashMap<String, List<FacebookMethodsType>>();
+        new HashMap<>();
 
     // maps method name to method arguments of the form Class type1, String name1, Class type2, String name2,...
     private static final Map<String, List<Object>> ARGUMENTS_MAP =
-        new HashMap<String, List<Object>>();
+        new HashMap<>();
 
     // maps argument name to argument type
     private static final Map<String, Class<?>> VALID_ARGUMENTS =
-        new HashMap<String, Class<?>>();
+        new HashMap<>();
 
     static {
         final FacebookMethodsType[] methods = FacebookMethodsType.values();
@@ -64,7 +64,7 @@ public final class FacebookMethodsTypeHelper {
             final String name = method.getName();
             List<FacebookMethodsType> overloads = METHOD_MAP.get(name);
             if (overloads == null) {
-                overloads = new ArrayList<FacebookMethodsType>();
+                overloads = new ArrayList<>();
                 METHOD_MAP.put(method.getName(), overloads);
             }
             overloads.add(method);
@@ -72,7 +72,7 @@ public final class FacebookMethodsTypeHelper {
             // add arguments for this method
             List<Object> arguments = ARGUMENTS_MAP.get(name);
             if (arguments == null) {
-                arguments = new ArrayList<Object>();
+                arguments = new ArrayList<>();
                 ARGUMENTS_MAP.put(name, arguments);
             }
 
@@ -148,8 +148,8 @@ public final class FacebookMethodsTypeHelper {
                                                           String... argNames) {
         List<String> argsList = Arrays.asList(argNames);
         // list of methods that have all args in the given names
-        final List<FacebookMethodsType> result = new ArrayList<FacebookMethodsType>();
-        final List<FacebookMethodsType> extraArgs = new ArrayList<FacebookMethodsType>();
+        final List<FacebookMethodsType> result = new ArrayList<>();
+        final List<FacebookMethodsType> extraArgs = new ArrayList<>();
 
         for (FacebookMethodsType method : methods) {
             final List<String> methodArgs = method.getArgNames();
@@ -217,7 +217,7 @@ public final class FacebookMethodsTypeHelper {
             return getArguments(convertToSearchMethod(name));
         case GET_AND_SEARCH:
         default:
-            final List<Object> arguments = new ArrayList<Object>();
+            final List<Object> arguments = new ArrayList<>();
             arguments.addAll(getArguments(convertToGetMethod(name)));
             arguments.addAll(getArguments(convertToSearchMethod(name)));
             return Collections.unmodifiableList(arguments);
@@ -233,7 +233,7 @@ public final class FacebookMethodsTypeHelper {
      */
     public static Set<String> getMissingProperties(String methodName, FacebookNameStyle nameStyle, Set<String> argNames) {
         final List<Object> argsWithTypes = getArgumentsForNameStyle(methodName, nameStyle);
-        final Set<String> missingArgs = new HashSet<String>();
+        final Set<String> missingArgs = new HashSet<>();
 
         for (int i = 1; i < argsWithTypes.size(); i += 2) {
             final String name = (String) argsWithTypes.get(i);
diff --git a/components/camel-facebook/src/main/java/org/apache/camel/component/facebook/data/FacebookPropertiesHelper.java b/components/camel-facebook/src/main/java/org/apache/camel/component/facebook/data/FacebookPropertiesHelper.java
index d4d0b89..f9be29f 100644
--- a/components/camel-facebook/src/main/java/org/apache/camel/component/facebook/data/FacebookPropertiesHelper.java
+++ b/components/camel-facebook/src/main/java/org/apache/camel/component/facebook/data/FacebookPropertiesHelper.java
@@ -39,11 +39,11 @@ import org.slf4j.LoggerFactory;
 public final class FacebookPropertiesHelper {
 
     // set of field names which are specific to Facebook4J api, to be excluded from method argument considerations
-    private static final Set<String> COMPONENT_CONFIG_FIELDS = new HashSet<String>();
+    private static final Set<String> COMPONENT_CONFIG_FIELDS = new HashSet<>();
 
     private static final Logger LOG = LoggerFactory.getLogger(FacebookPropertiesHelper.class);
 
-    private static final Set<String> ENDPOINT_CONFIG_FIELDS = new HashSet<String>();
+    private static final Set<String> ENDPOINT_CONFIG_FIELDS = new HashSet<>();
 
     static {
         for (Field field : FacebookConfiguration.class.getDeclaredFields()) {
@@ -129,7 +129,7 @@ public final class FacebookPropertiesHelper {
     }
 
     public static Set<String> getEndpointPropertyNames(FacebookEndpointConfiguration configuration) {
-        Map<String, Object> properties = new HashMap<String, Object>();
+        Map<String, Object> properties = new HashMap<>();
         getEndpointProperties(configuration, properties);
         return Collections.unmodifiableSet(properties.keySet());
     }
diff --git a/components/camel-facebook/src/main/java/org/apache/camel/component/facebook/data/ReadingBuilder.java b/components/camel-facebook/src/main/java/org/apache/camel/component/facebook/data/ReadingBuilder.java
index a10f562..796d643 100644
--- a/components/camel-facebook/src/main/java/org/apache/camel/component/facebook/data/ReadingBuilder.java
+++ b/components/camel-facebook/src/main/java/org/apache/camel/component/facebook/data/ReadingBuilder.java
@@ -40,7 +40,7 @@ public final class ReadingBuilder {
         final LinkedHashMap<String, String> source = (LinkedHashMap<String, String>) field.get(reading);
         // create another reading, and add all fields from source
         Reading copy = new Reading();
-        final LinkedHashMap<String, String> copyMap = new LinkedHashMap<String, String>();
+        final LinkedHashMap<String, String> copyMap = new LinkedHashMap<>();
         copyMap.putAll(source);
         if (skipSinceUtil) {
             copyMap.remove("since");
diff --git a/components/camel-facebook/src/test/java/org/apache/camel/component/facebook/CamelFacebookTestSupport.java b/components/camel-facebook/src/test/java/org/apache/camel/component/facebook/CamelFacebookTestSupport.java
index 881202e..bdc9d7b 100644
--- a/components/camel-facebook/src/test/java/org/apache/camel/component/facebook/CamelFacebookTestSupport.java
+++ b/components/camel-facebook/src/test/java/org/apache/camel/component/facebook/CamelFacebookTestSupport.java
@@ -50,7 +50,7 @@ public abstract class CamelFacebookTestSupport extends CamelTestSupport {
             throw new IllegalAccessError("test-options.properties could not be found");
         }
 
-        Map<String, Object> options = new HashMap<String, Object>();
+        Map<String, Object> options = new HashMap<>();
         for (Map.Entry<Object, Object> entry : properties.entrySet()) {
             options.put(entry.getKey().toString(), entry.getValue());
         }
diff --git a/components/camel-facebook/src/test/java/org/apache/camel/component/facebook/FacebookComponentConsumerTest.java b/components/camel-facebook/src/test/java/org/apache/camel/component/facebook/FacebookComponentConsumerTest.java
index fc3dbdc..e8f0350 100644
--- a/components/camel-facebook/src/test/java/org/apache/camel/component/facebook/FacebookComponentConsumerTest.java
+++ b/components/camel-facebook/src/test/java/org/apache/camel/component/facebook/FacebookComponentConsumerTest.java
@@ -40,7 +40,7 @@ import org.junit.Test;
 public class FacebookComponentConsumerTest extends CamelFacebookTestSupport {
     public static final String APACHE_FOUNDATION_PAGE_ID = "6538157161";
 
-    private final Set<String> searchNames = new HashSet<String>();
+    private final Set<String> searchNames = new HashSet<>();
     private List<String> excludedNames;
 
     public FacebookComponentConsumerTest() throws Exception {
diff --git a/components/camel-facebook/src/test/java/org/apache/camel/component/facebook/FacebookComponentProducerTest.java b/components/camel-facebook/src/test/java/org/apache/camel/component/facebook/FacebookComponentProducerTest.java
index dfe219f..bab0d01 100644
--- a/components/camel-facebook/src/test/java/org/apache/camel/component/facebook/FacebookComponentProducerTest.java
+++ b/components/camel-facebook/src/test/java/org/apache/camel/component/facebook/FacebookComponentProducerTest.java
@@ -31,7 +31,7 @@ import org.junit.Test;
 
 public class FacebookComponentProducerTest extends CamelFacebookTestSupport {
 
-    private final Set<String> noArgNames = new HashSet<String>();
+    private final Set<String> noArgNames = new HashSet<>();
 
     private final List<String> idExcludes;
     private final List<String> readingExcludes;
@@ -54,9 +54,9 @@ public class FacebookComponentProducerTest extends CamelFacebookTestSupport {
             }
         }
 
-        idExcludes = new ArrayList<String>();
+        idExcludes = new ArrayList<>();
         idExcludes.addAll(Arrays.asList("me", "home", "searchCheckins", "taggableFriends"));
-        readingExcludes = new ArrayList<String>();
+        readingExcludes = new ArrayList<>();
         readingExcludes.addAll(Arrays.asList("pictureURL", "permissions", "taggableFriends", "sSLPictureURL"));
 
         for (FacebookMethodsType types : FacebookMethodsType.values()) {
diff --git a/components/camel-facebook/src/test/java/org/apache/camel/component/facebook/TestUserMethodsTest.java b/components/camel-facebook/src/test/java/org/apache/camel/component/facebook/TestUserMethodsTest.java
index 2525ade..74b4db71 100644
--- a/components/camel-facebook/src/test/java/org/apache/camel/component/facebook/TestUserMethodsTest.java
+++ b/components/camel-facebook/src/test/java/org/apache/camel/component/facebook/TestUserMethodsTest.java
@@ -51,7 +51,7 @@ public class TestUserMethodsTest extends CamelFacebookTestSupport {
         assertNotNull("Test User2", testUser2);
 
         // make friends, not enemies
-        final Map<String, Object> headers = new HashMap<String, Object>();
+        final Map<String, Object> headers = new HashMap<>();
         headers.put("CamelFacebook.testUser2", testUser2);
         Boolean worked = template().requestBodyAndHeaders("direct:makeFriendTestUser", testUser1, headers, Boolean.class);
         assertTrue("Friends not made", worked);
diff --git a/components/camel-facebook/src/test/java/org/apache/camel/component/facebook/config/FacebookEndpointConfigurationTest.java b/components/camel-facebook/src/test/java/org/apache/camel/component/facebook/config/FacebookEndpointConfigurationTest.java
index a5a54f1..eb7809d 100644
--- a/components/camel-facebook/src/test/java/org/apache/camel/component/facebook/config/FacebookEndpointConfigurationTest.java
+++ b/components/camel-facebook/src/test/java/org/apache/camel/component/facebook/config/FacebookEndpointConfigurationTest.java
@@ -24,8 +24,6 @@ import org.apache.camel.test.junit4.CamelTestSupport;
 
 import org.junit.Test;
 
-import static org.junit.Assert.assertTrue;
-
 public class FacebookEndpointConfigurationTest extends CamelTestSupport {
 
     @Test
diff --git a/components/camel-facebook/src/test/java/org/apache/camel/component/facebook/data/FacebookMethodsTypeHelperTest.java b/components/camel-facebook/src/test/java/org/apache/camel/component/facebook/data/FacebookMethodsTypeHelperTest.java
index 833f87a..553ca70 100644
--- a/components/camel-facebook/src/test/java/org/apache/camel/component/facebook/data/FacebookMethodsTypeHelperTest.java
+++ b/components/camel-facebook/src/test/java/org/apache/camel/component/facebook/data/FacebookMethodsTypeHelperTest.java
@@ -39,7 +39,7 @@ import static org.junit.Assert.assertTrue;
  */
 public class FacebookMethodsTypeHelperTest {
 
-    private Set<String> names = new HashSet<String>();
+    private Set<String> names = new HashSet<>();
     private final List<String> getExcludes;
     private final List<String> searchIncludes;
 
@@ -102,7 +102,7 @@ public class FacebookMethodsTypeHelperTest {
                     // will throw an exception if can't be found
                     final List<Object> arguments = FacebookMethodsTypeHelper.getArguments(method.getName());
                     final int nArgs = arguments.size() / 2;
-                    List<Class<?>> types = new ArrayList<Class<?>>(nArgs);
+                    List<Class<?>> types = new ArrayList<>(nArgs);
                     for (int i = 0; i < nArgs; i++) {
                         types.add((Class<?>) arguments.get(2 * i));
                     }
diff --git a/components/camel-facebook/src/test/java/org/apache/camel/component/facebook/data/ReadingBuilderTest.java b/components/camel-facebook/src/test/java/org/apache/camel/component/facebook/data/ReadingBuilderTest.java
index 7329ca7..9c1026d 100644
--- a/components/camel-facebook/src/test/java/org/apache/camel/component/facebook/data/ReadingBuilderTest.java
+++ b/components/camel-facebook/src/test/java/org/apache/camel/component/facebook/data/ReadingBuilderTest.java
@@ -64,7 +64,7 @@ public class ReadingBuilderTest {
     public void testSetProperties() throws Exception {
         final Reading reading = new Reading();
 
-        Map<String, Object> properties = new HashMap<String, Object>();
+        Map<String, Object> properties = new HashMap<>();
         properties.put("fields", "field1,field2");
         properties.put("filter", "testFilter");
         properties.put("limit", "100");
diff --git a/components/camel-fastjson/src/main/java/org/apache/camel/component/fastjson/FastjsonDataFormat.java b/components/camel-fastjson/src/main/java/org/apache/camel/component/fastjson/FastjsonDataFormat.java
index 9dbe41d..61c935e 100644
--- a/components/camel-fastjson/src/main/java/org/apache/camel/component/fastjson/FastjsonDataFormat.java
+++ b/components/camel-fastjson/src/main/java/org/apache/camel/component/fastjson/FastjsonDataFormat.java
@@ -19,7 +19,6 @@ package org.apache.camel.component.fastjson;
 import java.io.*;
 import java.lang.reflect.Type;
 import java.util.ArrayList;
-import java.util.Arrays;
 import java.util.List;
 
 import com.alibaba.fastjson.JSON;
@@ -30,7 +29,6 @@ import org.apache.camel.Message;
 import org.apache.camel.spi.DataFormat;
 import org.apache.camel.spi.DataFormatName;
 import org.apache.camel.support.ServiceSupport;
-import org.apache.camel.util.IOHelper;
 
 /**
  * A <a href="http://camel.apache.org/data-format.html">data format</a> ({@link DataFormat})
@@ -104,7 +102,7 @@ public class FastjsonDataFormat extends ServiceSupport implements DataFormat, Da
     @Override
     protected void doStart() throws Exception {
         if (config == null) {
-            List<SerializerFeature> serializerFeatureList = new ArrayList<SerializerFeature>();
+            List<SerializerFeature> serializerFeatureList = new ArrayList<>();
             config = new FastJsonConfig();
             if (prettyPrint) {
                 serializerFeatureList.add(SerializerFeature.PrettyFormat);
diff --git a/components/camel-fastjson/src/test/java/org/apache/camel/component/fastjson/FastjsonMarshalTest.java b/components/camel-fastjson/src/test/java/org/apache/camel/component/fastjson/FastjsonMarshalTest.java
index ee52bdd..d2e9412 100644
--- a/components/camel-fastjson/src/test/java/org/apache/camel/component/fastjson/FastjsonMarshalTest.java
+++ b/components/camel-fastjson/src/test/java/org/apache/camel/component/fastjson/FastjsonMarshalTest.java
@@ -28,7 +28,7 @@ public class FastjsonMarshalTest extends CamelTestSupport {
 
     @Test
     public void testMarshalAndUnmarshalMap() throws Exception {
-        Map<String, String> in = new HashMap<String, String>();
+        Map<String, String> in = new HashMap<>();
         in.put("name", "Camel");
 
         MockEndpoint mock = getMockEndpoint("mock:reverse");
diff --git a/components/camel-flatpack/src/main/java/org/apache/camel/component/flatpack/FlatpackConverter.java b/components/camel-flatpack/src/main/java/org/apache/camel/component/flatpack/FlatpackConverter.java
index 9ac397d..e101acd 100644
--- a/components/camel-flatpack/src/main/java/org/apache/camel/component/flatpack/FlatpackConverter.java
+++ b/components/camel-flatpack/src/main/java/org/apache/camel/component/flatpack/FlatpackConverter.java
@@ -42,18 +42,18 @@ public final class FlatpackConverter {
 
     @Converter
     public static Map<String, Object> toMap(DataSet dataSet) {
-        Map<String, Object> map = new HashMap<String, Object>();
+        Map<String, Object> map = new HashMap<>();
         putValues(map, dataSet);
         return map;
     }
 
     @Converter
     public static List<Map<String, Object>> toList(DataSet dataSet) {
-        List<Map<String, Object>> answer = new ArrayList<Map<String, Object>>();
+        List<Map<String, Object>> answer = new ArrayList<>();
         dataSet.goTop();
 
         while (dataSet.next()) {
-            Map<String, Object> map = new HashMap<String, Object>();
+            Map<String, Object> map = new HashMap<>();
             putValues(map, dataSet);
             answer.add(map);
         }
diff --git a/components/camel-flatpack/src/test/java/org/apache/camel/component/flatpack/FlatpackDelimitedDataFormatTest.java b/components/camel-flatpack/src/test/java/org/apache/camel/component/flatpack/FlatpackDelimitedDataFormatTest.java
index e902734..c73f4d6 100644
--- a/components/camel-flatpack/src/test/java/org/apache/camel/component/flatpack/FlatpackDelimitedDataFormatTest.java
+++ b/components/camel-flatpack/src/test/java/org/apache/camel/component/flatpack/FlatpackDelimitedDataFormatTest.java
@@ -58,15 +58,15 @@ public class FlatpackDelimitedDataFormatTest extends CamelTestSupport {
         // by default we get on big message
         mock.expectedMessageCount(1);
 
-        List<Map<String, Object>> data = new ArrayList<Map<String, Object>>();
-        Map<String, Object> row = new LinkedHashMap<String, Object>();
+        List<Map<String, Object>> data = new ArrayList<>();
+        Map<String, Object> row = new LinkedHashMap<>();
         row.put("ITEM_DESC", "SOME VALVE");
         row.put("IN_STOCK", "2");
         row.put("PRICE", "5.00");
         row.put("LAST_RECV_DT", "20050101");
         data.add(row);
 
-        Map<String, Object> row2 = new LinkedHashMap<String, Object>();
+        Map<String, Object> row2 = new LinkedHashMap<>();
         row2.put("ITEM_DESC", "AN ENGINE");
         row2.put("IN_STOCK", "100");
         row2.put("PRICE", "1000.00");
@@ -83,15 +83,15 @@ public class FlatpackDelimitedDataFormatTest extends CamelTestSupport {
         // by default we get on big message
         mock.expectedMessageCount(1);
 
-        List<Map<String, Object>> data = new ArrayList<Map<String, Object>>();
-        Map<String, Object> row = new LinkedHashMap<String, Object>();
+        List<Map<String, Object>> data = new ArrayList<>();
+        Map<String, Object> row = new LinkedHashMap<>();
         row.put("ITEM_DESC", "SOME VALVE");
         row.put("IN_STOCK", "2");
         row.put("PRICE", "5.00");
         row.put("LAST_RECV_DT", "20050101");
         data.add(row);
 
-        Map<String, Object> row2 = new LinkedHashMap<String, Object>();
+        Map<String, Object> row2 = new LinkedHashMap<>();
         row2.put("ITEM_DESC", "AN ENGINE");
         row2.put("IN_STOCK", "100");
         row2.put("PRICE", "1000.00");
diff --git a/components/camel-flatpack/src/test/java/org/apache/camel/component/flatpack/FlatpackFixedLengthDataFormatTest.java b/components/camel-flatpack/src/test/java/org/apache/camel/component/flatpack/FlatpackFixedLengthDataFormatTest.java
index eb83b7b..311ac66 100644
--- a/components/camel-flatpack/src/test/java/org/apache/camel/component/flatpack/FlatpackFixedLengthDataFormatTest.java
+++ b/components/camel-flatpack/src/test/java/org/apache/camel/component/flatpack/FlatpackFixedLengthDataFormatTest.java
@@ -58,8 +58,8 @@ public class FlatpackFixedLengthDataFormatTest extends CamelTestSupport {
         // by default we get on big message
         mock.expectedMessageCount(1);
 
-        List<Map<String, Object>> data = new ArrayList<Map<String, Object>>();
-        Map<String, Object> row = new LinkedHashMap<String, Object>();
+        List<Map<String, Object>> data = new ArrayList<>();
+        Map<String, Object> row = new LinkedHashMap<>();
         row.put("FIRSTNAME", "JOHN");
         row.put("LASTNAME", "DOE");
         row.put("ADDRESS", "1234 CIRCLE CT");
diff --git a/components/camel-flink/src/main/java/org/apache/camel/component/flink/DataStreamFlinkProducer.java b/components/camel-flink/src/main/java/org/apache/camel/component/flink/DataStreamFlinkProducer.java
index bc1aa16..8db244a 100644
--- a/components/camel-flink/src/main/java/org/apache/camel/component/flink/DataStreamFlinkProducer.java
+++ b/components/camel-flink/src/main/java/org/apache/camel/component/flink/DataStreamFlinkProducer.java
@@ -43,8 +43,6 @@ public class DataStreamFlinkProducer extends DefaultProducer {
 
     protected void collectResults(Exchange exchange, Object result) {
         if (result instanceof DataStream) {
-            DataStream dsResults = (DataStream) result;
-
             if (getEndpoint().isCollect()) {
                 throw new IllegalArgumentException("collect mode not supported for Flink DataStreams.");
             } else {
diff --git a/components/camel-freemarker/src/test/java/org/apache/camel/component/freemarker/FreemarkerContentCacheTest.java b/components/camel-freemarker/src/test/java/org/apache/camel/component/freemarker/FreemarkerContentCacheTest.java
index e265549..690581f 100644
--- a/components/camel-freemarker/src/test/java/org/apache/camel/component/freemarker/FreemarkerContentCacheTest.java
+++ b/components/camel-freemarker/src/test/java/org/apache/camel/component/freemarker/FreemarkerContentCacheTest.java
@@ -134,7 +134,7 @@ public class FreemarkerContentCacheTest extends CamelTestSupport {
         // clear the cache via the mbean server
         MBeanServer mbeanServer = context.getManagementStrategy().getManagementAgent().getMBeanServer();
         Set<ObjectName> objNameSet = mbeanServer.queryNames(new ObjectName("org.apache.camel:type=endpoints,name=\"freemarker:*contentCache=true*\",*"), null);
-        ObjectName managedObjName = new ArrayList<ObjectName>(objNameSet).get(0);
+        ObjectName managedObjName = new ArrayList<>(objNameSet).get(0);
         mbeanServer.invoke(managedObjName, "clearContentCache", null, null);
 
         // change content in the file in the classpath and try again
diff --git a/components/camel-freemarker/src/test/java/org/apache/camel/component/freemarker/FreemarkerTest.java b/components/camel-freemarker/src/test/java/org/apache/camel/component/freemarker/FreemarkerTest.java
index a25337b..e44156a 100644
--- a/components/camel-freemarker/src/test/java/org/apache/camel/component/freemarker/FreemarkerTest.java
+++ b/components/camel-freemarker/src/test/java/org/apache/camel/component/freemarker/FreemarkerTest.java
@@ -58,8 +58,8 @@ public class FreemarkerTest extends CamelTestSupport {
             public void process(Exchange exchange) throws Exception {
                 exchange.getIn().setBody("");
                 exchange.getIn().setHeader("name", "Christian");
-                Map<String, Object> variableMap = new HashMap<String, Object>();
-                Map<String, Object> headersMap = new HashMap<String, Object>();
+                Map<String, Object> variableMap = new HashMap<>();
+                Map<String, Object> headersMap = new HashMap<>();
                 headersMap.put("name", "Willem");
                 variableMap.put("headers", headersMap);
                 variableMap.put("body", "Monday");
diff --git a/components/camel-ftp/src/main/java/org/apache/camel/component/file/remote/FtpComponent.java b/components/camel-ftp/src/main/java/org/apache/camel/component/file/remote/FtpComponent.java
index ddba282..326d534 100644
--- a/components/camel-ftp/src/main/java/org/apache/camel/component/file/remote/FtpComponent.java
+++ b/components/camel-ftp/src/main/java/org/apache/camel/component/file/remote/FtpComponent.java
@@ -48,7 +48,7 @@ public class FtpComponent extends RemoteFileComponent<FTPFile> {
 
         FtpUtils.ensureRelativeFtpDirectory(this, config);
 
-        FtpEndpoint<FTPFile> answer = new FtpEndpoint<FTPFile>(uri, this, config);
+        FtpEndpoint<FTPFile> answer = new FtpEndpoint<>(uri, this, config);
         extractAndSetFtpClientConfigParameters(parameters, answer);
         extractAndSetFtpClientParameters(parameters, answer);
 
diff --git a/components/camel-ftp/src/main/java/org/apache/camel/component/file/remote/FtpConsumer.java b/components/camel-ftp/src/main/java/org/apache/camel/component/file/remote/FtpConsumer.java
index 2d120ba..efaab4d 100644
--- a/components/camel-ftp/src/main/java/org/apache/camel/component/file/remote/FtpConsumer.java
+++ b/components/camel-ftp/src/main/java/org/apache/camel/component/file/remote/FtpConsumer.java
@@ -145,7 +145,7 @@ public class FtpConsumer extends RemoteFileConsumer<FTPFile> {
                 fileExpressionResult = evaluateFileExpression();
                 if (fileExpressionResult != null) {
                     file.setName(fileExpressionResult);
-                    files = new ArrayList<FTPFile>(1);
+                    files = new ArrayList<>(1);
                     files.add(file);
                 }
             }
@@ -242,7 +242,7 @@ public class FtpConsumer extends RemoteFileConsumer<FTPFile> {
     }
 
     private RemoteFile<FTPFile> asRemoteFile(String absolutePath, FTPFile file, String charset) {
-        RemoteFile<FTPFile> answer = new RemoteFile<FTPFile>();
+        RemoteFile<FTPFile> answer = new RemoteFile<>();
 
         answer.setCharset(charset);
         answer.setEndpointPath(endpointPath);
diff --git a/components/camel-ftp/src/main/java/org/apache/camel/component/file/remote/FtpEndpoint.java b/components/camel-ftp/src/main/java/org/apache/camel/component/file/remote/FtpEndpoint.java
index 2b85ef9..fd585ad 100644
--- a/components/camel-ftp/src/main/java/org/apache/camel/component/file/remote/FtpEndpoint.java
+++ b/components/camel-ftp/src/main/java/org/apache/camel/component/file/remote/FtpEndpoint.java
@@ -103,7 +103,7 @@ public class FtpEndpoint<T extends FTPFile> extends RemoteFileEndpoint<FTPFile>
 
     protected GenericFileProducer<FTPFile> buildProducer() {
         try {
-            return new RemoteFileProducer<FTPFile>(this, createRemoteFileOperations());
+            return new RemoteFileProducer<>(this, createRemoteFileOperations());
         } catch (Exception e) {
             throw new FailedToCreateProducerException(this, e);
         }
@@ -145,7 +145,7 @@ public class FtpEndpoint<T extends FTPFile> extends RemoteFileEndpoint<FTPFile>
 
         // then lookup ftp client parameters and set those
         if (ftpClientParameters != null) {
-            Map<String, Object> localParameters = new HashMap<String, Object>(ftpClientParameters);
+            Map<String, Object> localParameters = new HashMap<>(ftpClientParameters);
             // setting soTimeout has to be done later on FTPClient (after it has connected)
             Object timeout = localParameters.remove("soTimeout");
             if (timeout != null) {
@@ -164,7 +164,7 @@ public class FtpEndpoint<T extends FTPFile> extends RemoteFileEndpoint<FTPFile>
             if (ftpClientConfig == null) {
                 ftpClientConfig = new FTPClientConfig();
             }
-            Map<String, Object> localConfigParameters = new HashMap<String, Object>(ftpClientConfigParameters);
+            Map<String, Object> localConfigParameters = new HashMap<>(ftpClientConfigParameters);
             setProperties(ftpClientConfig, localConfigParameters);
         }
 
@@ -252,7 +252,7 @@ public class FtpEndpoint<T extends FTPFile> extends RemoteFileEndpoint<FTPFile>
      * Used by FtpComponent to provide additional parameters for the FTPClientConfig
      */
     void setFtpClientConfigParameters(Map<String, Object> ftpClientConfigParameters) {
-        this.ftpClientConfigParameters = new HashMap<String, Object>(ftpClientConfigParameters);
+        this.ftpClientConfigParameters = new HashMap<>(ftpClientConfigParameters);
     }
 
     public int getSoTimeout() {
diff --git a/components/camel-ftp/src/main/java/org/apache/camel/component/file/remote/FtpOperations.java b/components/camel-ftp/src/main/java/org/apache/camel/component/file/remote/FtpOperations.java
index fba2389..646c398 100644
--- a/components/camel-ftp/src/main/java/org/apache/camel/component/file/remote/FtpOperations.java
+++ b/components/camel-ftp/src/main/java/org/apache/camel/component/file/remote/FtpOperations.java
@@ -898,7 +898,7 @@ public class FtpOperations implements RemoteFileOperations<FTPFile> {
         log.trace("listFiles()");
         clientActivityListener.onScanningForFiles(endpoint.remoteServerInformation(), null);
         try {
-            final List<FTPFile> list = new ArrayList<FTPFile>();
+            final List<FTPFile> list = new ArrayList<>();
             FTPFile[] files = client.listFiles();
             // can return either null or an empty list depending on FTP servers
             if (files != null) {
@@ -921,7 +921,7 @@ public class FtpOperations implements RemoteFileOperations<FTPFile> {
         }
 
         try {
-            final List<FTPFile> list = new ArrayList<FTPFile>();
+            final List<FTPFile> list = new ArrayList<>();
             FTPFile[] files = client.listFiles(path);
             // can return either null or an empty list depending on FTP servers
             if (files != null) {
diff --git a/components/camel-ftp/src/main/java/org/apache/camel/component/file/remote/FtpsEndpoint.java b/components/camel-ftp/src/main/java/org/apache/camel/component/file/remote/FtpsEndpoint.java
index cb51dbb..17f0acc 100644
--- a/components/camel-ftp/src/main/java/org/apache/camel/component/file/remote/FtpsEndpoint.java
+++ b/components/camel-ftp/src/main/java/org/apache/camel/component/file/remote/FtpsEndpoint.java
@@ -169,7 +169,7 @@ public class FtpsEndpoint extends FtpEndpoint<FTPFile> {
         dataTimeout = getConfiguration().getTimeout();
 
         if (ftpClientParameters != null) {
-            Map<String, Object> localParameters = new HashMap<String, Object>(ftpClientParameters);
+            Map<String, Object> localParameters = new HashMap<>(ftpClientParameters);
             // setting soTimeout has to be done later on FTPClient (after it has connected)
             Object timeout = localParameters.remove("soTimeout");
             if (timeout != null) {
@@ -188,7 +188,7 @@ public class FtpsEndpoint extends FtpEndpoint<FTPFile> {
             if (ftpClientConfig == null) {
                 ftpClientConfig = new FTPClientConfig();
             }
-            Map<String, Object> localConfigParameters = new HashMap<String, Object>(ftpClientConfigParameters);
+            Map<String, Object> localConfigParameters = new HashMap<>(ftpClientConfigParameters);
             setProperties(ftpClientConfig, localConfigParameters);
         }
 
diff --git a/components/camel-ftp/src/main/java/org/apache/camel/component/file/remote/RemoteFileEndpoint.java b/components/camel-ftp/src/main/java/org/apache/camel/component/file/remote/RemoteFileEndpoint.java
index d59ba41..a037afd 100644
--- a/components/camel-ftp/src/main/java/org/apache/camel/component/file/remote/RemoteFileEndpoint.java
+++ b/components/camel-ftp/src/main/java/org/apache/camel/component/file/remote/RemoteFileEndpoint.java
@@ -19,7 +19,6 @@ package org.apache.camel.component.file.remote;
 import java.util.Map;
 
 import org.apache.camel.Exchange;
-import org.apache.camel.LoggingLevel;
 import org.apache.camel.PollingConsumer;
 import org.apache.camel.Processor;
 import org.apache.camel.component.file.GenericFile;
diff --git a/components/camel-ftp/src/main/java/org/apache/camel/component/file/remote/SftpConsumer.java b/components/camel-ftp/src/main/java/org/apache/camel/component/file/remote/SftpConsumer.java
index 026b37b..77caa3f 100644
--- a/components/camel-ftp/src/main/java/org/apache/camel/component/file/remote/SftpConsumer.java
+++ b/components/camel-ftp/src/main/java/org/apache/camel/component/file/remote/SftpConsumer.java
@@ -19,7 +19,6 @@ package org.apache.camel.component.file.remote;
 import java.util.ArrayList;
 import java.util.Collections;
 import java.util.List;
-import java.util.stream.Collectors;
 
 import com.jcraft.jsch.ChannelSftp;
 import com.jcraft.jsch.SftpException;
@@ -32,7 +31,6 @@ import org.apache.camel.component.file.GenericFileProcessStrategy;
 import org.apache.camel.util.FileUtil;
 import org.apache.camel.util.ObjectHelper;
 import org.apache.camel.util.URISupport;
-import org.apache.commons.net.ftp.FTPFile;
 
 /**
  * Secure FTP consumer
@@ -134,7 +132,7 @@ public class SftpConsumer extends RemoteFileConsumer<SftpRemoteFile> {
                 fileExpressionResult = evaluateFileExpression();
                 if (fileExpressionResult != null) {
                     SftpRemoteFile file = new SftpRemoteFileSingle(fileExpressionResult);
-                    files = new ArrayList<SftpRemoteFile>(1);
+                    files = new ArrayList<>(1);
                     files.add(file);
                 }
             }
@@ -221,7 +219,7 @@ public class SftpConsumer extends RemoteFileConsumer<SftpRemoteFile> {
     }
 
     private RemoteFile<SftpRemoteFile> asRemoteFile(String absolutePath, SftpRemoteFile file, String charset) {
-        RemoteFile<SftpRemoteFile> answer = new RemoteFile<SftpRemoteFile>();
+        RemoteFile<SftpRemoteFile> answer = new RemoteFile<>();
 
         answer.setCharset(charset);
         answer.setEndpointPath(endpointPath);
diff --git a/components/camel-ftp/src/main/java/org/apache/camel/component/file/remote/SftpEndpoint.java b/components/camel-ftp/src/main/java/org/apache/camel/component/file/remote/SftpEndpoint.java
index 62b46fd..5f82b3a 100644
--- a/components/camel-ftp/src/main/java/org/apache/camel/component/file/remote/SftpEndpoint.java
+++ b/components/camel-ftp/src/main/java/org/apache/camel/component/file/remote/SftpEndpoint.java
@@ -65,7 +65,7 @@ public class SftpEndpoint extends RemoteFileEndpoint<SftpRemoteFile> {
     }
 
     protected GenericFileProducer<SftpRemoteFile> buildProducer() {
-        return new RemoteFileProducer<SftpRemoteFile>(this, createRemoteFileOperations());
+        return new RemoteFileProducer<>(this, createRemoteFileOperations());
     }
 
     public RemoteFileOperations<SftpRemoteFile> createRemoteFileOperations() {
diff --git a/components/camel-ftp/src/main/java/org/apache/camel/component/file/remote/SftpOperations.java b/components/camel-ftp/src/main/java/org/apache/camel/component/file/remote/SftpOperations.java
index e6178a9..ff82e72 100644
--- a/components/camel-ftp/src/main/java/org/apache/camel/component/file/remote/SftpOperations.java
+++ b/components/camel-ftp/src/main/java/org/apache/camel/component/file/remote/SftpOperations.java
@@ -190,7 +190,7 @@ public class SftpOperations implements RemoteFileOperations<SftpRemoteFile> {
 
         if (isNotEmpty(sftpConfig.getCiphers())) {
             LOG.debug("Using ciphers: {}", sftpConfig.getCiphers());
-            Hashtable<String, String> ciphers = new Hashtable<String, String>();
+            Hashtable<String, String> ciphers = new Hashtable<>();
             ciphers.put("cipher.s2c", sftpConfig.getCiphers());
             ciphers.put("cipher.c2s", sftpConfig.getCiphers());
             JSch.setConfig(ciphers);
diff --git a/components/camel-ftp/src/main/java/org/apache/camel/component/file/remote/strategy/FtpProcessStrategyFactory.java b/components/camel-ftp/src/main/java/org/apache/camel/component/file/remote/strategy/FtpProcessStrategyFactory.java
index 55ba556..0b245ab 100644
--- a/components/camel-ftp/src/main/java/org/apache/camel/component/file/remote/strategy/FtpProcessStrategyFactory.java
+++ b/components/camel-ftp/src/main/java/org/apache/camel/component/file/remote/strategy/FtpProcessStrategyFactory.java
@@ -46,44 +46,44 @@ public final class FtpProcessStrategyFactory {
         boolean isMove = moveExpression != null || preMoveExpression != null || moveFailedExpression != null;
 
         if (isDelete) {
-            GenericFileDeleteProcessStrategy<FTPFile> strategy = new GenericFileDeleteProcessStrategy<FTPFile>();
+            GenericFileDeleteProcessStrategy<FTPFile> strategy = new GenericFileDeleteProcessStrategy<>();
             strategy.setExclusiveReadLockStrategy(getExclusiveReadLockStrategy(params));
             if (preMoveExpression != null) {
-                GenericFileExpressionRenamer<FTPFile> renamer = new GenericFileExpressionRenamer<FTPFile>();
+                GenericFileExpressionRenamer<FTPFile> renamer = new GenericFileExpressionRenamer<>();
                 renamer.setExpression(preMoveExpression);
                 strategy.setBeginRenamer(renamer);
             }
             if (moveFailedExpression != null) {
-                GenericFileExpressionRenamer<FTPFile> renamer = new GenericFileExpressionRenamer<FTPFile>();
+                GenericFileExpressionRenamer<FTPFile> renamer = new GenericFileExpressionRenamer<>();
                 renamer.setExpression(moveFailedExpression);
                 strategy.setFailureRenamer(renamer);
             }
             return strategy;
         } else if (isMove || isNoop) {
-            GenericFileRenameProcessStrategy<FTPFile> strategy = new GenericFileRenameProcessStrategy<FTPFile>();
+            GenericFileRenameProcessStrategy<FTPFile> strategy = new GenericFileRenameProcessStrategy<>();
             strategy.setExclusiveReadLockStrategy(getExclusiveReadLockStrategy(params));
             if (!isNoop && moveExpression != null) {
                 // move on commit is only possible if not noop
-                GenericFileExpressionRenamer<FTPFile> renamer = new GenericFileExpressionRenamer<FTPFile>();
+                GenericFileExpressionRenamer<FTPFile> renamer = new GenericFileExpressionRenamer<>();
                 renamer.setExpression(moveExpression);
                 strategy.setCommitRenamer(renamer);
             }
             // both move and noop supports pre move
             if (moveFailedExpression != null) {
-                GenericFileExpressionRenamer<FTPFile> renamer = new GenericFileExpressionRenamer<FTPFile>();
+                GenericFileExpressionRenamer<FTPFile> renamer = new GenericFileExpressionRenamer<>();
                 renamer.setExpression(moveFailedExpression);
                 strategy.setFailureRenamer(renamer);
             }
             // both move and noop supports pre move
             if (preMoveExpression != null) {
-                GenericFileExpressionRenamer<FTPFile> renamer = new GenericFileExpressionRenamer<FTPFile>();
+                GenericFileExpressionRenamer<FTPFile> renamer = new GenericFileExpressionRenamer<>();
                 renamer.setExpression(preMoveExpression);
                 strategy.setBeginRenamer(renamer);
             }
             return strategy;
         } else {
             // default strategy will do nothing
-            GenericFileNoOpProcessStrategy<FTPFile> strategy = new GenericFileNoOpProcessStrategy<FTPFile>();
+            GenericFileNoOpProcessStrategy<FTPFile> strategy = new GenericFileNoOpProcessStrategy<>();
             strategy.setExclusiveReadLockStrategy(getExclusiveReadLockStrategy(params));
             return strategy;
         }
@@ -102,7 +102,7 @@ public final class FtpProcessStrategyFactory {
             if ("none".equals(readLock) || "false".equals(readLock)) {
                 return null;
             } else if ("rename".equals(readLock)) {
-                GenericFileRenameExclusiveReadLockStrategy<FTPFile> readLockStrategy = new GenericFileRenameExclusiveReadLockStrategy<FTPFile>();
+                GenericFileRenameExclusiveReadLockStrategy<FTPFile> readLockStrategy = new GenericFileRenameExclusiveReadLockStrategy<>();
                 Long timeout = (Long) params.get("readLockTimeout");
                 if (timeout != null) {
                     readLockStrategy.setTimeout(timeout);
diff --git a/components/camel-ftp/src/main/java/org/apache/camel/component/file/remote/strategy/SftpProcessStrategyFactory.java b/components/camel-ftp/src/main/java/org/apache/camel/component/file/remote/strategy/SftpProcessStrategyFactory.java
index aabccb4..93e5048 100644
--- a/components/camel-ftp/src/main/java/org/apache/camel/component/file/remote/strategy/SftpProcessStrategyFactory.java
+++ b/components/camel-ftp/src/main/java/org/apache/camel/component/file/remote/strategy/SftpProcessStrategyFactory.java
@@ -46,44 +46,44 @@ public final class SftpProcessStrategyFactory {
         boolean isMove = moveExpression != null || preMoveExpression != null || moveFailedExpression != null;
 
         if (isDelete) {
-            GenericFileDeleteProcessStrategy<ChannelSftp.LsEntry> strategy = new GenericFileDeleteProcessStrategy<ChannelSftp.LsEntry>();
+            GenericFileDeleteProcessStrategy<ChannelSftp.LsEntry> strategy = new GenericFileDeleteProcessStrategy<>();
             strategy.setExclusiveReadLockStrategy(getExclusiveReadLockStrategy(params));
             if (preMoveExpression != null) {
-                GenericFileExpressionRenamer<ChannelSftp.LsEntry> renamer = new GenericFileExpressionRenamer<ChannelSftp.LsEntry>();
+                GenericFileExpressionRenamer<ChannelSftp.LsEntry> renamer = new GenericFileExpressionRenamer<>();
                 renamer.setExpression(preMoveExpression);
                 strategy.setBeginRenamer(renamer);
             }
             if (moveFailedExpression != null) {
-                GenericFileExpressionRenamer<ChannelSftp.LsEntry> renamer = new GenericFileExpressionRenamer<ChannelSftp.LsEntry>();
+                GenericFileExpressionRenamer<ChannelSftp.LsEntry> renamer = new GenericFileExpressionRenamer<>();
                 renamer.setExpression(moveFailedExpression);
                 strategy.setFailureRenamer(renamer);
             }
             return strategy;
         } else if (isMove || isNoop) {
-            GenericFileRenameProcessStrategy<ChannelSftp.LsEntry> strategy = new GenericFileRenameProcessStrategy<ChannelSftp.LsEntry>();
+            GenericFileRenameProcessStrategy<ChannelSftp.LsEntry> strategy = new GenericFileRenameProcessStrategy<>();
             strategy.setExclusiveReadLockStrategy(getExclusiveReadLockStrategy(params));
             if (!isNoop && moveExpression != null) {
                 // move on commit is only possible if not noop
-                GenericFileExpressionRenamer<ChannelSftp.LsEntry> renamer = new GenericFileExpressionRenamer<ChannelSftp.LsEntry>();
+                GenericFileExpressionRenamer<ChannelSftp.LsEntry> renamer = new GenericFileExpressionRenamer<>();
                 renamer.setExpression(moveExpression);
                 strategy.setCommitRenamer(renamer);
             }
             // both move and noop supports pre move
             if (moveFailedExpression != null) {
-                GenericFileExpressionRenamer<ChannelSftp.LsEntry> renamer = new GenericFileExpressionRenamer<ChannelSftp.LsEntry>();
+                GenericFileExpressionRenamer<ChannelSftp.LsEntry> renamer = new GenericFileExpressionRenamer<>();
                 renamer.setExpression(moveFailedExpression);
                 strategy.setFailureRenamer(renamer);
             }
             // both move and noop supports pre move
             if (preMoveExpression != null) {
-                GenericFileExpressionRenamer<ChannelSftp.LsEntry> renamer = new GenericFileExpressionRenamer<ChannelSftp.LsEntry>();
+                GenericFileExpressionRenamer<ChannelSftp.LsEntry> renamer = new GenericFileExpressionRenamer<>();
                 renamer.setExpression(preMoveExpression);
                 strategy.setBeginRenamer(renamer);
             }
             return strategy;
         } else {
             // default strategy will do nothing
-            GenericFileNoOpProcessStrategy<ChannelSftp.LsEntry> strategy = new GenericFileNoOpProcessStrategy<ChannelSftp.LsEntry>();
+            GenericFileNoOpProcessStrategy<ChannelSftp.LsEntry> strategy = new GenericFileNoOpProcessStrategy<>();
             strategy.setExclusiveReadLockStrategy(getExclusiveReadLockStrategy(params));
             return strategy;
         }
@@ -102,7 +102,7 @@ public final class SftpProcessStrategyFactory {
             if ("none".equals(readLock) || "false".equals(readLock)) {
                 return null;
             } else if ("rename".equals(readLock)) {
-                GenericFileRenameExclusiveReadLockStrategy<ChannelSftp.LsEntry> readLockStrategy = new GenericFileRenameExclusiveReadLockStrategy<ChannelSftp.LsEntry>();
+                GenericFileRenameExclusiveReadLockStrategy<ChannelSftp.LsEntry> readLockStrategy = new GenericFileRenameExclusiveReadLockStrategy<>();
                 Long timeout = (Long) params.get("readLockTimeout");
                 if (timeout != null) {
                     readLockStrategy.setTimeout(timeout);
diff --git a/components/camel-ftp/src/test/java/org/apache/camel/component/file/remote/FromFtpClientSoTimeout3Test.java b/components/camel-ftp/src/test/java/org/apache/camel/component/file/remote/FromFtpClientSoTimeout3Test.java
index dc83444..0882d77 100644
--- a/components/camel-ftp/src/test/java/org/apache/camel/component/file/remote/FromFtpClientSoTimeout3Test.java
+++ b/components/camel-ftp/src/test/java/org/apache/camel/component/file/remote/FromFtpClientSoTimeout3Test.java
@@ -44,7 +44,7 @@ public class FromFtpClientSoTimeout3Test extends CamelTestSupport {
         FtpEndpoint<FTPFile> ftpEndpoint = context.getEndpoint(getFtpUrl(), FtpEndpoint.class);
 
         // set "ftp://admin@localhost:21/timeout/?ftpClient.soTimeout=10"
-        Map<String, Object> ftpClientParameters = new HashMap<String, Object>();
+        Map<String, Object> ftpClientParameters = new HashMap<>();
         ftpClientParameters.put("soTimeout", "10");
         ftpEndpoint.setFtpClientParameters(ftpClientParameters);
 
diff --git a/components/camel-ftp/src/test/java/org/apache/camel/component/file/remote/FromFtpFilterTest.java b/components/camel-ftp/src/test/java/org/apache/camel/component/file/remote/FromFtpFilterTest.java
index a88bbc9..20af079 100644
--- a/components/camel-ftp/src/test/java/org/apache/camel/component/file/remote/FromFtpFilterTest.java
+++ b/components/camel-ftp/src/test/java/org/apache/camel/component/file/remote/FromFtpFilterTest.java
@@ -35,7 +35,7 @@ public class FromFtpFilterTest extends FtpServerTestSupport {
     @Override
     protected JndiRegistry createRegistry() throws Exception {
         JndiRegistry jndi = super.createRegistry();
-        jndi.bind("myFilter", new MyFileFilter<Object>());
+        jndi.bind("myFilter", new MyFileFilter<>());
         return jndi;
     }
 
diff --git a/components/camel-ftp/src/test/java/org/apache/camel/component/file/remote/FromFtpRemoteFileFilterDirectoryTest.java b/components/camel-ftp/src/test/java/org/apache/camel/component/file/remote/FromFtpRemoteFileFilterDirectoryTest.java
index 754af6c..329f510 100644
--- a/components/camel-ftp/src/test/java/org/apache/camel/component/file/remote/FromFtpRemoteFileFilterDirectoryTest.java
+++ b/components/camel-ftp/src/test/java/org/apache/camel/component/file/remote/FromFtpRemoteFileFilterDirectoryTest.java
@@ -36,7 +36,7 @@ public class FromFtpRemoteFileFilterDirectoryTest extends FtpServerTestSupport {
     @Override
     protected JndiRegistry createRegistry() throws Exception {
         JndiRegistry jndi = super.createRegistry();
-        jndi.bind("myFilter", new MyFileFilter<Object>());
+        jndi.bind("myFilter", new MyFileFilter<>());
         return jndi;
     }
 
diff --git a/components/camel-ftp/src/test/java/org/apache/camel/component/file/remote/FromFtpRemoteFileFilterTest.java b/components/camel-ftp/src/test/java/org/apache/camel/component/file/remote/FromFtpRemoteFileFilterTest.java
index 28e5bd3..3eae220 100644
--- a/components/camel-ftp/src/test/java/org/apache/camel/component/file/remote/FromFtpRemoteFileFilterTest.java
+++ b/components/camel-ftp/src/test/java/org/apache/camel/component/file/remote/FromFtpRemoteFileFilterTest.java
@@ -36,7 +36,7 @@ public class FromFtpRemoteFileFilterTest extends FtpServerTestSupport {
     @Override
     protected JndiRegistry createRegistry() throws Exception {
         JndiRegistry jndi = super.createRegistry();
-        jndi.bind("myFilter", new MyFileFilter<Object>());
+        jndi.bind("myFilter", new MyFileFilter<>());
         return jndi;
     }
 
diff --git a/components/camel-ftp/src/test/java/org/apache/camel/component/file/remote/FtpBadLoginConnectionLeakTest.java b/components/camel-ftp/src/test/java/org/apache/camel/component/file/remote/FtpBadLoginConnectionLeakTest.java
index b62ecaf..8cbd434 100644
--- a/components/camel-ftp/src/test/java/org/apache/camel/component/file/remote/FtpBadLoginConnectionLeakTest.java
+++ b/components/camel-ftp/src/test/java/org/apache/camel/component/file/remote/FtpBadLoginConnectionLeakTest.java
@@ -34,7 +34,7 @@ public class FtpBadLoginConnectionLeakTest extends FtpServerTestSupport {
     /**
      * Mapping of socket hashcode to two element tab ([connect() called, close() called])
      */
-    private Map<Integer, boolean[]> socketAudits = new HashMap<Integer, boolean[]>();
+    private Map<Integer, boolean[]> socketAudits = new HashMap<>();
 
     private String getFtpUrl() {
         return "ftp://dummy@localhost:" + getPort() + "/badlogin?password=cantremeber" 
diff --git a/components/camel-ftp/src/test/java/org/apache/camel/component/file/remote/FtpBadLoginInProducerConnectionLeakTest.java b/components/camel-ftp/src/test/java/org/apache/camel/component/file/remote/FtpBadLoginInProducerConnectionLeakTest.java
index 0d61331..cfea7e0 100644
--- a/components/camel-ftp/src/test/java/org/apache/camel/component/file/remote/FtpBadLoginInProducerConnectionLeakTest.java
+++ b/components/camel-ftp/src/test/java/org/apache/camel/component/file/remote/FtpBadLoginInProducerConnectionLeakTest.java
@@ -32,7 +32,7 @@ public class FtpBadLoginInProducerConnectionLeakTest extends FtpServerTestSuppor
     /**
      * Mapping of socket hashcode to two element tab ([connect() called, close() called])
      */
-    private Map<Integer, boolean[]> socketAudits = new HashMap<Integer, boolean[]>();
+    private Map<Integer, boolean[]> socketAudits = new HashMap<>();
 
     private String getFtpUrl() {
         return "ftp://dummy@localhost:" + getPort() + "/badlogin?password=cantremeber&maximumReconnectAttempts=3"
diff --git a/components/camel-ftp/src/test/java/org/apache/camel/component/file/remote/FtpBadLoginMockNoopConnectionLeakTest.java b/components/camel-ftp/src/test/java/org/apache/camel/component/file/remote/FtpBadLoginMockNoopConnectionLeakTest.java
index 44e3198..6206bfa 100644
--- a/components/camel-ftp/src/test/java/org/apache/camel/component/file/remote/FtpBadLoginMockNoopConnectionLeakTest.java
+++ b/components/camel-ftp/src/test/java/org/apache/camel/component/file/remote/FtpBadLoginMockNoopConnectionLeakTest.java
@@ -37,7 +37,7 @@ public class FtpBadLoginMockNoopConnectionLeakTest extends FtpServerTestSupport
     /**
      * Mapping of socket hashcode to two element tab ([connect() called, close() called])
      */
-    private Map<Integer, boolean[]> socketAudits = new HashMap<Integer, boolean[]>();
+    private Map<Integer, boolean[]> socketAudits = new HashMap<>();
 
     private String getFtpUrl() {
         return "ftp://dummy@localhost:" + getPort() + "/badlogin?password=cantremeber&maximumReconnectAttempts=3"
diff --git a/components/camel-ftp/src/test/java/org/apache/camel/component/file/remote/RecipientListErrorHandlingIssueTest.java b/components/camel-ftp/src/test/java/org/apache/camel/component/file/remote/RecipientListErrorHandlingIssueTest.java
index f4c4aee..6855d10 100644
--- a/components/camel-ftp/src/test/java/org/apache/camel/component/file/remote/RecipientListErrorHandlingIssueTest.java
+++ b/components/camel-ftp/src/test/java/org/apache/camel/component/file/remote/RecipientListErrorHandlingIssueTest.java
@@ -67,7 +67,7 @@ public class RecipientListErrorHandlingIssueTest extends FtpServerTestSupport {
 
         String foo = "direct:foo," + getFtpUrl();
 
-        Map<String, Object> headers = new HashMap<String, Object>();
+        Map<String, Object> headers = new HashMap<>();
         headers.put("foo", foo);
         headers.put(Exchange.FILE_NAME, "hello.txt");
 
@@ -97,7 +97,7 @@ public class RecipientListErrorHandlingIssueTest extends FtpServerTestSupport {
 
         String foo = "direct:foo," + getFtpUrl();
 
-        Map<String, Object> headers = new HashMap<String, Object>();
+        Map<String, Object> headers = new HashMap<>();
         headers.put("foo", foo);
         headers.put(Exchange.FILE_NAME, "hello.txt");
 
diff --git a/components/camel-ftp/src/test/java/org/apache/camel/component/file/remote/RemoteFileProduceOverruleOnlyOnceTest.java b/components/camel-ftp/src/test/java/org/apache/camel/component/file/remote/RemoteFileProduceOverruleOnlyOnceTest.java
index 04fb666..d19a083 100644
--- a/components/camel-ftp/src/test/java/org/apache/camel/component/file/remote/RemoteFileProduceOverruleOnlyOnceTest.java
+++ b/components/camel-ftp/src/test/java/org/apache/camel/component/file/remote/RemoteFileProduceOverruleOnlyOnceTest.java
@@ -31,7 +31,7 @@ public class RemoteFileProduceOverruleOnlyOnceTest extends FtpServerTestSupport
 
     @Test
     public void testFileToFtp() throws Exception {
-        Map<String, Object> headers = new HashMap<String, Object>();
+        Map<String, Object> headers = new HashMap<>();
         headers.put(Exchange.FILE_NAME, "/sub/hello.txt");
         headers.put(Exchange.OVERRULE_FILE_NAME, "/sub/ruled.txt");
         template.sendBodyAndHeaders("direct:input", "Hello World", headers);
diff --git a/components/camel-git/src/test/java/org/apache/camel/component/git/consumer/GitConsumerTest.java b/components/camel-git/src/test/java/org/apache/camel/component/git/consumer/GitConsumerTest.java
index 49d063c..0c7bc72 100644
--- a/components/camel-git/src/test/java/org/apache/camel/component/git/consumer/GitConsumerTest.java
+++ b/components/camel-git/src/test/java/org/apache/camel/component/git/consumer/GitConsumerTest.java
@@ -52,7 +52,6 @@ public class GitConsumerTest extends GitTestSupport {
         status = git.status().call();
         assertTrue(status.getAdded().contains(filenameBranchToAdd));
         git.commit().setMessage("Test test Commit").call();
-        Iterable<RevCommit> logs = git.log().call();
         validateGitLogs(git, "Test test Commit", commitMessage);
         // Test
         mockResultCommit.assertIsSatisfied();
diff --git a/components/camel-git/src/test/java/org/apache/camel/component/git/producer/GitRemoteProducerTest.java b/components/camel-git/src/test/java/org/apache/camel/component/git/producer/GitRemoteProducerTest.java
index 571dcb1..b1fced3 100644
--- a/components/camel-git/src/test/java/org/apache/camel/component/git/producer/GitRemoteProducerTest.java
+++ b/components/camel-git/src/test/java/org/apache/camel/component/git/producer/GitRemoteProducerTest.java
@@ -60,7 +60,7 @@ public class GitRemoteProducerTest extends GitTestSupport {
             }
         });
 
-        Iterable<PushResult> result = template.requestBody("direct:push", "", Iterable.class);
+        template.requestBody("direct:push", "", Iterable.class);
 
         repository.close();
     }
diff --git a/components/camel-github/src/main/java/org/apache/camel/component/github/consumer/CommitConsumer.java b/components/camel-github/src/main/java/org/apache/camel/component/github/consumer/CommitConsumer.java
index 0b04566..a0ee236 100644
--- a/components/camel-github/src/main/java/org/apache/camel/component/github/consumer/CommitConsumer.java
+++ b/components/camel-github/src/main/java/org/apache/camel/component/github/consumer/CommitConsumer.java
@@ -35,7 +35,7 @@ public class CommitConsumer extends AbstractGitHubConsumer {
     
     private CommitService commitService;
     
-    private List<String> commitHashes = new ArrayList<String>();
+    private List<String> commitHashes = new ArrayList<>();
     
     public CommitConsumer(GitHubEndpoint endpoint, Processor processor, String branchName) throws Exception {
         super(endpoint, processor);
@@ -61,7 +61,7 @@ public class CommitConsumer extends AbstractGitHubConsumer {
     protected int poll() throws Exception {
         List<RepositoryCommit> commits = commitService.getCommits(getRepository());
         // In the end, we want tags oldest to newest.
-        Stack<RepositoryCommit> newCommits = new Stack<RepositoryCommit>();
+        Stack<RepositoryCommit> newCommits = new Stack<>();
         for (RepositoryCommit commit : commits) {
             if (!commitHashes.contains(commit.getSha())) {
                 newCommits.push(commit);
diff --git a/components/camel-github/src/main/java/org/apache/camel/component/github/consumer/PullRequestCommentConsumer.java b/components/camel-github/src/main/java/org/apache/camel/component/github/consumer/PullRequestCommentConsumer.java
index 9703d54..3a28823 100644
--- a/components/camel-github/src/main/java/org/apache/camel/component/github/consumer/PullRequestCommentConsumer.java
+++ b/components/camel-github/src/main/java/org/apache/camel/component/github/consumer/PullRequestCommentConsumer.java
@@ -42,7 +42,7 @@ public class PullRequestCommentConsumer extends AbstractGitHubConsumer {
 
     private IssueService issueService;
     
-    private List<Long> commentIds = new ArrayList<Long>();
+    private List<Long> commentIds = new ArrayList<>();
     
     public PullRequestCommentConsumer(GitHubEndpoint endpoint, Processor processor) throws Exception {
         super(endpoint, processor);
@@ -84,11 +84,11 @@ public class PullRequestCommentConsumer extends AbstractGitHubConsumer {
     protected int poll() throws Exception {
         // Do this here, rather than at the class level.  We only care about it for setting the Exchange header, so
         // there's no point growing memory over time.
-        Map<Long, PullRequest> commentIdToPullRequest = new HashMap<Long, PullRequest>();
+        Map<Long, PullRequest> commentIdToPullRequest = new HashMap<>();
         
         List<PullRequest> pullRequests = pullRequestService.getPullRequests(getRepository(), "open");
         // In the end, we want comments oldest to newest.
-        Stack<Comment> newComments = new Stack<Comment>();
+        Stack<Comment> newComments = new Stack<>();
         for (PullRequest pullRequest : pullRequests) {
             List<CommitComment> commitComments = pullRequestService.getComments(getRepository(), pullRequest.getNumber());
             for (Comment comment : commitComments) {
diff --git a/components/camel-github/src/main/java/org/apache/camel/component/github/consumer/PullRequestConsumer.java b/components/camel-github/src/main/java/org/apache/camel/component/github/consumer/PullRequestConsumer.java
index 164acb5..340437c 100644
--- a/components/camel-github/src/main/java/org/apache/camel/component/github/consumer/PullRequestConsumer.java
+++ b/components/camel-github/src/main/java/org/apache/camel/component/github/consumer/PullRequestConsumer.java
@@ -61,7 +61,7 @@ public class PullRequestConsumer extends AbstractGitHubConsumer {
     protected int poll() throws Exception {
         List<PullRequest> openPullRequests = pullRequestService.getPullRequests(getRepository(), "open");
         // In the end, we want PRs oldest to newest.
-        Stack<PullRequest> newPullRequests = new Stack<PullRequest>();
+        Stack<PullRequest> newPullRequests = new Stack<>();
         for (PullRequest pullRequest : openPullRequests) {
             if (pullRequest.getNumber() > lastOpenPullRequest) {
                 newPullRequests.push(pullRequest);
diff --git a/components/camel-github/src/main/java/org/apache/camel/component/github/consumer/TagConsumer.java b/components/camel-github/src/main/java/org/apache/camel/component/github/consumer/TagConsumer.java
index e40bd74..3b223ba 100644
--- a/components/camel-github/src/main/java/org/apache/camel/component/github/consumer/TagConsumer.java
+++ b/components/camel-github/src/main/java/org/apache/camel/component/github/consumer/TagConsumer.java
@@ -30,7 +30,7 @@ import org.slf4j.LoggerFactory;
 public class TagConsumer extends AbstractGitHubConsumer {
     private static final transient Logger LOG = LoggerFactory.getLogger(TagConsumer.class);
 
-    private List<String> tagNames = new ArrayList<String>();
+    private List<String> tagNames = new ArrayList<>();
     
     public TagConsumer(GitHubEndpoint endpoint, Processor processor) throws Exception {
         super(endpoint, processor);
@@ -46,7 +46,7 @@ public class TagConsumer extends AbstractGitHubConsumer {
     protected int poll() throws Exception {
         List<RepositoryTag> tags = getRepositoryService().getTags(getRepository());
         // In the end, we want tags oldest to newest.
-        Stack<RepositoryTag> newTags = new Stack<RepositoryTag>();
+        Stack<RepositoryTag> newTags = new Stack<>();
         for (RepositoryTag tag : tags) {
             if (!tagNames.contains(tag.getName())) {
                 newTags.push(tag);
diff --git a/components/camel-github/src/test/java/org/apache/camel/component/github/producer/PullRequestFilesProducerTest.java b/components/camel-github/src/test/java/org/apache/camel/component/github/producer/PullRequestFilesProducerTest.java
index a312903..25a4f03 100644
--- a/components/camel-github/src/test/java/org/apache/camel/component/github/producer/PullRequestFilesProducerTest.java
+++ b/components/camel-github/src/test/java/org/apache/camel/component/github/producer/PullRequestFilesProducerTest.java
@@ -63,7 +63,7 @@ public class PullRequestFilesProducerTest extends GitHubComponentTestBase {
         CommitFile file = new CommitFile();
         file.setFilename("testfile");
 
-        List<CommitFile> commitFiles = new ArrayList<CommitFile>();
+        List<CommitFile> commitFiles = new ArrayList<>();
         commitFiles.add(file);
         pullRequestService.setFiles(latestPullRequestNumber, commitFiles);
 
diff --git a/components/camel-github/src/test/java/org/apache/camel/component/github/services/MockCommitService.java b/components/camel-github/src/test/java/org/apache/camel/component/github/services/MockCommitService.java
index c3f8f51..03c742f 100644
--- a/components/camel-github/src/test/java/org/apache/camel/component/github/services/MockCommitService.java
+++ b/components/camel-github/src/test/java/org/apache/camel/component/github/services/MockCommitService.java
@@ -34,9 +34,9 @@ import org.slf4j.LoggerFactory;
 public class MockCommitService extends CommitService {
     protected static final Logger LOG = LoggerFactory.getLogger(MockCommitService.class);
 
-    private List<RepositoryCommit> commitsList = new ArrayList<RepositoryCommit>();
+    private List<RepositoryCommit> commitsList = new ArrayList<>();
     private AtomicLong fakeSha = new AtomicLong(System.currentTimeMillis());
-    private Map<String, CommitStatus> commitStatus = new HashMap<String, CommitStatus>();
+    private Map<String, CommitStatus> commitStatus = new HashMap<>();
 
     public synchronized RepositoryCommit addRepositoryCommit() {
         User author = new User();
diff --git a/components/camel-github/src/test/java/org/apache/camel/component/github/services/MockIssueService.java b/components/camel-github/src/test/java/org/apache/camel/component/github/services/MockIssueService.java
index b77f2e8..60009c8 100644
--- a/components/camel-github/src/test/java/org/apache/camel/component/github/services/MockIssueService.java
+++ b/components/camel-github/src/test/java/org/apache/camel/component/github/services/MockIssueService.java
@@ -27,7 +27,7 @@ import org.eclipse.egit.github.core.service.IssueService;
 
 public class MockIssueService extends IssueService {
 
-    private List<Comment> comments = new ArrayList<Comment>();
+    private List<Comment> comments = new ArrayList<>();
     private MockPullRequestService mockPullRequestService;
 
     public MockIssueService(MockPullRequestService mockPullRequestService) {
diff --git a/components/camel-github/src/test/java/org/apache/camel/component/github/services/MockPullRequestService.java b/components/camel-github/src/test/java/org/apache/camel/component/github/services/MockPullRequestService.java
index 09a7d63..85172d3 100644
--- a/components/camel-github/src/test/java/org/apache/camel/component/github/services/MockPullRequestService.java
+++ b/components/camel-github/src/test/java/org/apache/camel/component/github/services/MockPullRequestService.java
@@ -35,12 +35,12 @@ import org.slf4j.LoggerFactory;
 public class MockPullRequestService extends PullRequestService {
     protected static final Logger LOG = LoggerFactory.getLogger(MockPullRequestService.class);
 
-    private Map<Long, PullRequest> pullRequests = new HashMap<Long, PullRequest>();
-    private List<CommitComment> emptyComments = new ArrayList<CommitComment>();
+    private Map<Long, PullRequest> pullRequests = new HashMap<>();
+    private List<CommitComment> emptyComments = new ArrayList<>();
     private AtomicInteger pullRequestNumber = new AtomicInteger(101);
     private AtomicInteger commentId = new AtomicInteger(500);
-    private Map<Long, List<CommitComment>> allComments = new HashMap<Long, List<CommitComment>>();
-    private Map<Integer, List<CommitFile>> files = new HashMap<Integer, List<CommitFile>>();
+    private Map<Long, List<CommitComment>> allComments = new HashMap<>();
+    private Map<Integer, List<CommitFile>> files = new HashMap<>();
 
     public List<CommitComment> getComments(IRepositoryIdProvider repository, int pullRequestId) {
         Long id = new Long(pullRequestId);
@@ -75,7 +75,7 @@ public class MockPullRequestService extends PullRequestService {
         if (allComments.containsKey(pullRequestId)) {
             comments = allComments.get(pullRequestId);
         } else {
-            comments = new ArrayList<CommitComment>();
+            comments = new ArrayList<>();
         }
         comments.add(commitComment);
         allComments.put(pullRequestId, comments);
@@ -113,7 +113,7 @@ public class MockPullRequestService extends PullRequestService {
 
     @Override
     public synchronized List<PullRequest> getPullRequests(IRepositoryIdProvider repository, String state) {
-        List<PullRequest> result = new ArrayList<PullRequest>();
+        List<PullRequest> result = new ArrayList<>();
 
         for (Long id : pullRequests.keySet()) {
             PullRequest pr = pullRequests.get(id);
diff --git a/components/camel-github/src/test/java/org/apache/camel/component/github/services/MockRepositoryService.java b/components/camel-github/src/test/java/org/apache/camel/component/github/services/MockRepositoryService.java
index 9c93273..fca6c5a 100644
--- a/components/camel-github/src/test/java/org/apache/camel/component/github/services/MockRepositoryService.java
+++ b/components/camel-github/src/test/java/org/apache/camel/component/github/services/MockRepositoryService.java
@@ -30,7 +30,7 @@ import org.slf4j.LoggerFactory;
 public class MockRepositoryService extends RepositoryService {
     protected static final Logger LOG = LoggerFactory.getLogger(MockRepositoryService.class);
 
-    private List<RepositoryTag> tags = new ArrayList<RepositoryTag>();
+    private List<RepositoryTag> tags = new ArrayList<>();
 
     public RepositoryTag addTag(String tagName) {
         RepositoryTag tag = new RepositoryTag();
diff --git a/components/camel-google-bigquery/src/main/java/org/apache/camel/component/google/bigquery/GoogleBigQueryProducer.java b/components/camel-google-bigquery/src/main/java/org/apache/camel/component/google/bigquery/GoogleBigQueryProducer.java
index cae2684..8941f1c 100644
--- a/components/camel-google-bigquery/src/main/java/org/apache/camel/component/google/bigquery/GoogleBigQueryProducer.java
+++ b/components/camel-google-bigquery/src/main/java/org/apache/camel/component/google/bigquery/GoogleBigQueryProducer.java
@@ -137,8 +137,6 @@ public class GoogleBigQueryProducer extends DefaultProducer {
             return 0;
         }
 
-        GoogleBigQueryEndpoint endpoint = getEndpoint();
-
         TableDataInsertAllRequest apiRequestData = new TableDataInsertAllRequest().setRows(apiRequestRows);
 
         Bigquery.Tabledata.InsertAll apiRequest = bigquery
diff --git a/components/camel-google-bigquery/src/test/java/org/apache/camel/component/google/bigquery/integration/InsertIdTest.java b/components/camel-google-bigquery/src/test/java/org/apache/camel/component/google/bigquery/integration/InsertIdTest.java
index 9c9949a..7eec298 100644
--- a/components/camel-google-bigquery/src/test/java/org/apache/camel/component/google/bigquery/integration/InsertIdTest.java
+++ b/components/camel-google-bigquery/src/test/java/org/apache/camel/component/google/bigquery/integration/InsertIdTest.java
@@ -99,7 +99,6 @@ public class InsertIdTest extends BigQueryTestSupport {
         Exchange exchange2 = new DefaultExchange(context);
         String uuid2Col2 = UUID.randomUUID().toString();
 
-        Map<String, String> object2 = new HashMap<>();
         object.put("col1", uuidCol1);
         object.put("col2", uuid2Col2);
         exchange2.getIn().setBody(object);
@@ -130,7 +129,6 @@ public class InsertIdTest extends BigQueryTestSupport {
         Exchange exchange2 = new DefaultExchange(context);
         String uuid2Col2 = UUID.randomUUID().toString();
 
-        Map<String, String> object2 = new HashMap<>();
         object.put("col1", uuidCol1);
         object.put("col2", uuid2Col2);
         exchange2.getIn().setBody(object);
diff --git a/components/camel-google-calendar/src/test/java/org/apache/camel/component/google/calendar/AbstractGoogleCalendarTestSupport.java b/components/camel-google-calendar/src/test/java/org/apache/camel/component/google/calendar/AbstractGoogleCalendarTestSupport.java
index 7392776..805f1cd 100644
--- a/components/camel-google-calendar/src/test/java/org/apache/camel/component/google/calendar/AbstractGoogleCalendarTestSupport.java
+++ b/components/camel-google-calendar/src/test/java/org/apache/camel/component/google/calendar/AbstractGoogleCalendarTestSupport.java
@@ -76,7 +76,7 @@ public class AbstractGoogleCalendarTestSupport extends CamelTestSupport {
             throw new IOException(String.format("%s could not be loaded: %s", TEST_OPTIONS_PROPERTIES, e.getMessage()), e);
         }
 
-        Map<String, Object> options = new HashMap<String, Object>();
+        Map<String, Object> options = new HashMap<>();
         for (Map.Entry<Object, Object> entry : properties.entrySet()) {
             options.put(entry.getKey().toString(), entry.getValue());
         }
diff --git a/components/camel-google-calendar/src/test/java/org/apache/camel/component/google/calendar/CalendarCalendarsIntegrationTest.java b/components/camel-google-calendar/src/test/java/org/apache/camel/component/google/calendar/CalendarCalendarsIntegrationTest.java
index baa3a48..0621016 100644
--- a/components/camel-google-calendar/src/test/java/org/apache/camel/component/google/calendar/CalendarCalendarsIntegrationTest.java
+++ b/components/camel-google-calendar/src/test/java/org/apache/camel/component/google/calendar/CalendarCalendarsIntegrationTest.java
@@ -42,7 +42,7 @@ public class CalendarCalendarsIntegrationTest extends AbstractGoogleCalendarTest
         Calendar calendarFromGet = requestBody("direct://GET", calendar.getId());
         assertTrue(calendar.getId().equals(calendarFromGet.getId()));
 
-        final Map<String, Object> headers = new HashMap<String, Object>();
+        final Map<String, Object> headers = new HashMap<>();
         // parameter type is String
         headers.put("CamelGoogleCalendar.calendarId", calendar.getId());
         // parameter type is com.google.api.services.calendar.model.Calendar
diff --git a/components/camel-google-calendar/src/test/java/org/apache/camel/component/google/calendar/CalendarEventsIntegrationTest.java b/components/camel-google-calendar/src/test/java/org/apache/camel/component/google/calendar/CalendarEventsIntegrationTest.java
index 9d15619..bef1ac5 100644
--- a/components/camel-google-calendar/src/test/java/org/apache/camel/component/google/calendar/CalendarEventsIntegrationTest.java
+++ b/components/camel-google-calendar/src/test/java/org/apache/camel/component/google/calendar/CalendarEventsIntegrationTest.java
@@ -49,7 +49,7 @@ public class CalendarEventsIntegrationTest extends AbstractGoogleCalendarTestSup
         event.setSummary("Feed the Camel");
         event.setLocation("Somewhere");
 
-        ArrayList<EventAttendee> attendees = new ArrayList<EventAttendee>();
+        ArrayList<EventAttendee> attendees = new ArrayList<>();
         attendees.add(new EventAttendee().setEmail("camel-google-calendar.janstey@gmail.com"));
         event.setAttendees(attendees);
 
@@ -60,7 +60,7 @@ public class CalendarEventsIntegrationTest extends AbstractGoogleCalendarTestSup
         DateTime end = new DateTime(endDate, TimeZone.getTimeZone("UTC"));
         event.setEnd(new EventDateTime().setDateTime(end));
 
-        final Map<String, Object> headers = new HashMap<String, Object>();
+        final Map<String, Object> headers = new HashMap<>();
         // parameter type is String
         headers.put("CamelGoogleCalendar.calendarId", getCalendar().getId());
         // parameter type is com.google.api.services.calendar.model.Event
@@ -75,7 +75,7 @@ public class CalendarEventsIntegrationTest extends AbstractGoogleCalendarTestSup
     @Test
     public void testManipulatingAnEvent() throws Exception {
         // Add an event
-        Map<String, Object> headers = new HashMap<String, Object>();
+        Map<String, Object> headers = new HashMap<>();
         // parameter type is String
         headers.put("CamelGoogleCalendar.calendarId", getCalendar().getId());
         // parameter type is String
@@ -90,7 +90,7 @@ public class CalendarEventsIntegrationTest extends AbstractGoogleCalendarTestSup
         assertEquals("Feed the Camel", item.getSummary());
 
         // Get the event metadata
-        headers = new HashMap<String, Object>();
+        headers = new HashMap<>();
         // parameter type is String
         headers.put("CamelGoogleCalendar.calendarId", getCalendar().getId());
         // parameter type is String
@@ -106,7 +106,7 @@ public class CalendarEventsIntegrationTest extends AbstractGoogleCalendarTestSup
         assertEquals("Feed the Camel later", newResult.getSummary());
 
         // Delete the event
-        headers = new HashMap<String, Object>();
+        headers = new HashMap<>();
         // parameter type is String
         headers.put("CamelGoogleCalendar.calendarId", getCalendar().getId());
         // parameter type is String
diff --git a/components/camel-google-calendar/src/test/java/org/apache/camel/component/google/calendar/CalendarFreebusyIntegrationTest.java b/components/camel-google-calendar/src/test/java/org/apache/camel/component/google/calendar/CalendarFreebusyIntegrationTest.java
index 9bfc5ea..395cb8d 100644
--- a/components/camel-google-calendar/src/test/java/org/apache/camel/component/google/calendar/CalendarFreebusyIntegrationTest.java
+++ b/components/camel-google-calendar/src/test/java/org/apache/camel/component/google/calendar/CalendarFreebusyIntegrationTest.java
@@ -43,7 +43,7 @@ public class CalendarFreebusyIntegrationTest extends AbstractGoogleCalendarTestS
         // using com.google.api.services.calendar.model.FreeBusyRequest message
         // body for single parameter "content"
         com.google.api.services.calendar.model.FreeBusyRequest request = new FreeBusyRequest();
-        List<FreeBusyRequestItem> items = new ArrayList<FreeBusyRequestItem>();
+        List<FreeBusyRequestItem> items = new ArrayList<>();
         items.add(new FreeBusyRequestItem().setId(getCalendar().getId()));
         request.setItems(items);
 
diff --git a/components/camel-google-drive/src/test/java/org/apache/camel/component/google/drive/AbstractGoogleDriveTestSupport.java b/components/camel-google-drive/src/test/java/org/apache/camel/component/google/drive/AbstractGoogleDriveTestSupport.java
index a3c4e23..b0b4461 100644
--- a/components/camel-google-drive/src/test/java/org/apache/camel/component/google/drive/AbstractGoogleDriveTestSupport.java
+++ b/components/camel-google-drive/src/test/java/org/apache/camel/component/google/drive/AbstractGoogleDriveTestSupport.java
@@ -59,7 +59,7 @@ public abstract class AbstractGoogleDriveTestSupport extends CamelTestSupport {
         fileMetadata.setTitle(UPLOAD_FILE.getName());
         FileContent mediaContent = new FileContent(null, UPLOAD_FILE);
         
-        final Map<String, Object> headers = new HashMap<String, Object>();
+        final Map<String, Object> headers = new HashMap<>();
         // parameter type is com.google.api.services.drive.model.File
         headers.put("CamelGoogleDrive.content", fileMetadata);
         // parameter type is com.google.api.client.http.AbstractInputStreamContent
@@ -108,7 +108,7 @@ public abstract class AbstractGoogleDriveTestSupport extends CamelTestSupport {
 //        testFileId = properties.getProperty("testFileId");
 //        testUserId = properties.getProperty("testUserId");
 //
-        Map<String, Object> options = new HashMap<String, Object>();
+        Map<String, Object> options = new HashMap<>();
         for (Map.Entry<Object, Object> entry : properties.entrySet()) {
             options.put(entry.getKey().toString(), entry.getValue());
         }
@@ -144,7 +144,7 @@ public abstract class AbstractGoogleDriveTestSupport extends CamelTestSupport {
 
     protected <T> T requestBodyAndHeaders(String endpointUri, Object body, Map<String, Object> headers, Class<T> type)
         throws CamelExecutionException {
-        return (T) template().requestBodyAndHeaders(endpointUri, body, headers, type);
+        return template().requestBodyAndHeaders(endpointUri, body, headers, type);
     }
     
     protected <T> T requestBody(String endpoint, Object body) throws CamelExecutionException {
diff --git a/components/camel-google-drive/src/test/java/org/apache/camel/component/google/drive/DriveChildrenIntegrationTest.java b/components/camel-google-drive/src/test/java/org/apache/camel/component/google/drive/DriveChildrenIntegrationTest.java
index 99b7a64..84246e7 100644
--- a/components/camel-google-drive/src/test/java/org/apache/camel/component/google/drive/DriveChildrenIntegrationTest.java
+++ b/components/camel-google-drive/src/test/java/org/apache/camel/component/google/drive/DriveChildrenIntegrationTest.java
@@ -42,7 +42,7 @@ public class DriveChildrenIntegrationTest extends AbstractGoogleDriveTestSupport
         File folder = uploadTestFolder();
         File file = uploadTestFile();
         
-        final Map<String, Object> headers = new HashMap<String, Object>();
+        final Map<String, Object> headers = new HashMap<>();
         // parameter type is String
         headers.put("CamelGoogleDrive.folderId", folder.getId());
         
@@ -73,7 +73,7 @@ public class DriveChildrenIntegrationTest extends AbstractGoogleDriveTestSupport
     public void testUploadFileToRootFolder() throws Exception {
         File file = uploadTestFile();
         
-        final Map<String, Object> headers = new HashMap<String, Object>();
+        final Map<String, Object> headers = new HashMap<>();
         // parameter type is String
         headers.put("CamelGoogleDrive.folderId", ROOT_FOLDER);
         
diff --git a/components/camel-google-drive/src/test/java/org/apache/camel/component/google/drive/DriveCommentsIntegrationTest.java b/components/camel-google-drive/src/test/java/org/apache/camel/component/google/drive/DriveCommentsIntegrationTest.java
index ea983ac..90fa5de 100644
--- a/components/camel-google-drive/src/test/java/org/apache/camel/component/google/drive/DriveCommentsIntegrationTest.java
+++ b/components/camel-google-drive/src/test/java/org/apache/camel/component/google/drive/DriveCommentsIntegrationTest.java
@@ -45,7 +45,7 @@ public class DriveCommentsIntegrationTest extends AbstractGoogleDriveTestSupport
         String fileId = testFile.getId();
         
         // 2. comment on that file
-        Map<String, Object> headers = new HashMap<String, Object>();
+        Map<String, Object> headers = new HashMap<>();
         // parameter type is String
         headers.put("CamelGoogleDrive.fileId", fileId);
         // parameter type is com.google.api.services.drive.model.Comment
@@ -65,7 +65,7 @@ public class DriveCommentsIntegrationTest extends AbstractGoogleDriveTestSupport
         Comment comment2 = result1.getItems().get(0);
         
         // 4. now try and get that comment 
-        headers = new HashMap<String, Object>();
+        headers = new HashMap<>();
         // parameter type is String
         headers.put("CamelGoogleDrive.fileId", fileId);
         // parameter type is String
@@ -77,7 +77,7 @@ public class DriveCommentsIntegrationTest extends AbstractGoogleDriveTestSupport
         
         // 5. delete the comment
         
-        headers = new HashMap<String, Object>();
+        headers = new HashMap<>();
         // parameter type is String
         headers.put("CamelGoogleDrive.fileId", fileId);
         // parameter type is String
@@ -87,7 +87,7 @@ public class DriveCommentsIntegrationTest extends AbstractGoogleDriveTestSupport
 
         // 6. ensure the comment is gone
         
-        headers = new HashMap<String, Object>();
+        headers = new HashMap<>();
         // parameter type is String
         headers.put("CamelGoogleDrive.fileId", fileId);
         // parameter type is String
diff --git a/components/camel-google-drive/src/test/java/org/apache/camel/component/google/drive/DriveFilesIntegrationTest.java b/components/camel-google-drive/src/test/java/org/apache/camel/component/google/drive/DriveFilesIntegrationTest.java
index b9b22e5..5125196 100644
--- a/components/camel-google-drive/src/test/java/org/apache/camel/component/google/drive/DriveFilesIntegrationTest.java
+++ b/components/camel-google-drive/src/test/java/org/apache/camel/component/google/drive/DriveFilesIntegrationTest.java
@@ -50,7 +50,7 @@ public class DriveFilesIntegrationTest extends AbstractGoogleDriveTestSupport {
         File toFile = new File();
         toFile.setTitle(UPLOAD_FILE.getName() + "_copy");
         
-        final Map<String, Object> headers = new HashMap<String, Object>();
+        final Map<String, Object> headers = new HashMap<>();
         // parameter type is String
         headers.put("CamelGoogleDrive.fileId", fromFileId);
         // parameter type is com.google.api.services.drive.model.File
@@ -121,7 +121,7 @@ public class DriveFilesIntegrationTest extends AbstractGoogleDriveTestSupport {
         
         File testFile2 = uploadTestFile();
         
-        Map<String, Object> headers = new HashMap<String, Object>();
+        Map<String, Object> headers = new HashMap<>();
         headers.put("CamelGoogleDrive.maxResults", 1);
         
         result = requestBodyAndHeaders("direct://LIST", null, headers);
@@ -129,7 +129,7 @@ public class DriveFilesIntegrationTest extends AbstractGoogleDriveTestSupport {
         assertTrue(result.getItems().size() == 1);
         
         // test paging the list
-        List<File> resultList = new ArrayList<File>();
+        List<File> resultList = new ArrayList<>();
         String pageToken;
         int i = 0;
         do {
@@ -155,7 +155,7 @@ public class DriveFilesIntegrationTest extends AbstractGoogleDriveTestSupport {
         // lets update the filename
         file.setTitle(UPLOAD_FILE.getName() + "PATCHED");
         
-        final Map<String, Object> headers = new HashMap<String, Object>();
+        final Map<String, Object> headers = new HashMap<>();
         // parameter type is String
         headers.put("CamelGoogleDrive.fileId", file.getId());
         // parameter type is String
@@ -195,7 +195,7 @@ public class DriveFilesIntegrationTest extends AbstractGoogleDriveTestSupport {
     public void testUpdate() throws Exception {
         File theTestFile = uploadTestFile();
         
-        final Map<String, Object> headers = new HashMap<String, Object>();
+        final Map<String, Object> headers = new HashMap<>();
         // parameter type is String
         headers.put("CamelGoogleDrive.fileId", theTestFile.getId());
         // parameter type is com.google.api.services.drive.model.File
@@ -226,7 +226,7 @@ public class DriveFilesIntegrationTest extends AbstractGoogleDriveTestSupport {
 
         // Send the request to the API.
         
-        final Map<String, Object> headers = new HashMap<String, Object>();
+        final Map<String, Object> headers = new HashMap<>();
         // parameter type is String
         headers.put("CamelGoogleDrive.fileId", fileId);
         // parameter type is com.google.api.services.drive.model.File
@@ -244,7 +244,7 @@ public class DriveFilesIntegrationTest extends AbstractGoogleDriveTestSupport {
     @Ignore
     @Test
     public void testWatch() throws Exception {
-        final Map<String, Object> headers = new HashMap<String, Object>();
+        final Map<String, Object> headers = new HashMap<>();
         // parameter type is String
         headers.put("CamelGoogleDrive.fileId", null);
         // parameter type is com.google.api.services.drive.model.Channel
diff --git a/components/camel-google-drive/src/test/java/org/apache/camel/component/google/drive/DriveRepliesIntegrationTest.java b/components/camel-google-drive/src/test/java/org/apache/camel/component/google/drive/DriveRepliesIntegrationTest.java
index c1bbaa2..e72e8b9 100644
--- a/components/camel-google-drive/src/test/java/org/apache/camel/component/google/drive/DriveRepliesIntegrationTest.java
+++ b/components/camel-google-drive/src/test/java/org/apache/camel/component/google/drive/DriveRepliesIntegrationTest.java
@@ -45,7 +45,7 @@ public class DriveRepliesIntegrationTest extends AbstractGoogleDriveTestSupport
         String fileId = testFile.getId();
         
         // 2. comment on that file
-        Map<String, Object> headers = new HashMap<String, Object>();
+        Map<String, Object> headers = new HashMap<>();
         // parameter type is String
         headers.put("CamelGoogleDrive.fileId", fileId);
         // parameter type is com.google.api.services.drive.model.Comment
@@ -66,7 +66,7 @@ public class DriveRepliesIntegrationTest extends AbstractGoogleDriveTestSupport
         String commentId = comment2.getCommentId();
         
         // 4. add reply
-        headers = new HashMap<String, Object>();
+        headers = new HashMap<>();
         // parameter type is String
         headers.put("CamelGoogleDrive.fileId", fileId);
         // parameter type is String
@@ -80,7 +80,7 @@ public class DriveRepliesIntegrationTest extends AbstractGoogleDriveTestSupport
 
         // 5. list replies on comment to file
         
-        headers = new HashMap<String, Object>();
+        headers = new HashMap<>();
         // parameter type is String
         headers.put("CamelGoogleDrive.fileId", fileId);
         // parameter type is String
diff --git a/components/camel-google-mail/src/test/java/org/apache/camel/component/google/mail/AbstractGoogleMailTestSupport.java b/components/camel-google-mail/src/test/java/org/apache/camel/component/google/mail/AbstractGoogleMailTestSupport.java
index 464e60d..e9b3c1a 100644
--- a/components/camel-google-mail/src/test/java/org/apache/camel/component/google/mail/AbstractGoogleMailTestSupport.java
+++ b/components/camel-google-mail/src/test/java/org/apache/camel/component/google/mail/AbstractGoogleMailTestSupport.java
@@ -49,7 +49,7 @@ public class AbstractGoogleMailTestSupport extends CamelTestSupport {
             throw new IOException(String.format("%s could not be loaded: %s", TEST_OPTIONS_PROPERTIES, e.getMessage()), e);
         }
 
-        Map<String, Object> options = new HashMap<String, Object>();
+        Map<String, Object> options = new HashMap<>();
         for (Map.Entry<Object, Object> entry : properties.entrySet()) {
             options.put(entry.getKey().toString(), entry.getValue());
         }
diff --git a/components/camel-google-mail/src/test/java/org/apache/camel/component/google/mail/GmailUsersLabelsIntegrationTest.java b/components/camel-google-mail/src/test/java/org/apache/camel/component/google/mail/GmailUsersLabelsIntegrationTest.java
index 59c859a..7e3e358 100644
--- a/components/camel-google-mail/src/test/java/org/apache/camel/component/google/mail/GmailUsersLabelsIntegrationTest.java
+++ b/components/camel-google-mail/src/test/java/org/apache/camel/component/google/mail/GmailUsersLabelsIntegrationTest.java
@@ -44,7 +44,7 @@ public class GmailUsersLabelsIntegrationTest extends AbstractGoogleMailTestSuppo
 
         String labelId = null;
         if (getTestLabel(labels) == null) {
-            Map<String, Object> headers = new HashMap<String, Object>();
+            Map<String, Object> headers = new HashMap<>();
             // parameter type is String
             headers.put("CamelGoogleMail.userId", CURRENT_USERID);
             Label label = new Label().setName(CAMEL_TEST_LABEL).setMessageListVisibility("show").setLabelListVisibility("labelShow");
@@ -63,7 +63,7 @@ public class GmailUsersLabelsIntegrationTest extends AbstractGoogleMailTestSuppo
         labels = requestBody("direct://LIST", CURRENT_USERID);
         assertTrue(getTestLabel(labels) != null);
 
-        Map<String, Object> headers = new HashMap<String, Object>();
+        Map<String, Object> headers = new HashMap<>();
         // parameter type is String
         headers.put("CamelGoogleMail.userId", CURRENT_USERID);
         // parameter type is String
diff --git a/components/camel-google-mail/src/test/java/org/apache/camel/component/google/mail/GmailUsersMessagesIntegrationTest.java b/components/camel-google-mail/src/test/java/org/apache/camel/component/google/mail/GmailUsersMessagesIntegrationTest.java
index 0953490..2c476e1 100644
--- a/components/camel-google-mail/src/test/java/org/apache/camel/component/google/mail/GmailUsersMessagesIntegrationTest.java
+++ b/components/camel-google-mail/src/test/java/org/apache/camel/component/google/mail/GmailUsersMessagesIntegrationTest.java
@@ -54,7 +54,7 @@ public class GmailUsersMessagesIntegrationTest extends AbstractGoogleMailTestSup
 
         // ==== Send test email ====
         Message testEmail = createTestEmail();
-        Map<String, Object> headers = new HashMap<String, Object>();
+        Map<String, Object> headers = new HashMap<>();
         // parameter type is String
         headers.put("CamelGoogleMail.userId", CURRENT_USERID);
         // parameter type is com.google.api.services.gmail.model.Message
@@ -65,14 +65,14 @@ public class GmailUsersMessagesIntegrationTest extends AbstractGoogleMailTestSup
         String testEmailId = result.getId();
 
         // ==== Search for message we just sent ====
-        headers = new HashMap<String, Object>();
+        headers = new HashMap<>();
         headers.put("CamelGoogleMail.q", "subject:\"Hello from camel-google-mail\"");
         // using String message body for single parameter "userId"
         ListMessagesResponse listOfMessages = requestBody("direct://LIST", CURRENT_USERID);
         assertTrue(idInList(testEmailId, listOfMessages));
 
         // ===== trash it ====
-        headers = new HashMap<String, Object>();
+        headers = new HashMap<>();
         // parameter type is String
         headers.put("CamelGoogleMail.userId", CURRENT_USERID);
         // parameter type is String
@@ -80,14 +80,14 @@ public class GmailUsersMessagesIntegrationTest extends AbstractGoogleMailTestSup
         requestBodyAndHeaders("direct://TRASH", null, headers);
 
         // ==== Search for message we just trashed ====
-        headers = new HashMap<String, Object>();
+        headers = new HashMap<>();
         headers.put("CamelGoogleMail.q", "subject:\"Hello from camel-google-mail\"");
         // using String message body for single parameter "userId"
         listOfMessages = requestBody("direct://LIST", CURRENT_USERID);
         assertFalse(idInList(testEmailId, listOfMessages));
 
         // ===== untrash it ====
-        headers = new HashMap<String, Object>();
+        headers = new HashMap<>();
         // parameter type is String
         headers.put("CamelGoogleMail.userId", CURRENT_USERID);
         // parameter type is String
@@ -95,14 +95,14 @@ public class GmailUsersMessagesIntegrationTest extends AbstractGoogleMailTestSup
         requestBodyAndHeaders("direct://UNTRASH", null, headers);
 
         // ==== Search for message we just trashed ====
-        headers = new HashMap<String, Object>();
+        headers = new HashMap<>();
         headers.put("CamelGoogleMail.q", "subject:\"Hello from camel-google-mail\"");
         // using String message body for single parameter "userId"
         listOfMessages = requestBody("direct://LIST", CURRENT_USERID);
         assertTrue(idInList(testEmailId, listOfMessages));
 
         // ===== permanently delete it ====
-        headers = new HashMap<String, Object>();
+        headers = new HashMap<>();
         // parameter type is String
         headers.put("CamelGoogleMail.userId", CURRENT_USERID);
         // parameter type is String
@@ -110,7 +110,7 @@ public class GmailUsersMessagesIntegrationTest extends AbstractGoogleMailTestSup
         requestBodyAndHeaders("direct://DELETE", null, headers);
 
         // ==== Search for message we just deleted ====
-        headers = new HashMap<String, Object>();
+        headers = new HashMap<>();
         headers.put("CamelGoogleMail.q", "subject:\"Hello from camel-google-mail\"");
         // using String message body for single parameter "userId"
         listOfMessages = requestBody("direct://LIST", CURRENT_USERID);
diff --git a/components/camel-google-mail/src/test/java/org/apache/camel/component/google/mail/GmailUsersThreadsIntegrationTest.java b/components/camel-google-mail/src/test/java/org/apache/camel/component/google/mail/GmailUsersThreadsIntegrationTest.java
index fcd30fd..e108146 100644
--- a/components/camel-google-mail/src/test/java/org/apache/camel/component/google/mail/GmailUsersThreadsIntegrationTest.java
+++ b/components/camel-google-mail/src/test/java/org/apache/camel/component/google/mail/GmailUsersThreadsIntegrationTest.java
@@ -58,7 +58,7 @@ public class GmailUsersThreadsIntegrationTest extends AbstractGoogleMailTestSupp
             createMessageWithEmail.setThreadId(previousThreadId);
         }
 
-        Map<String, Object> headers = new HashMap<String, Object>();
+        Map<String, Object> headers = new HashMap<>();
         // parameter type is String
         headers.put("CamelGoogleMail.userId", CURRENT_USERID);
         // parameter type is com.google.api.services.gmail.model.Message
@@ -81,7 +81,7 @@ public class GmailUsersThreadsIntegrationTest extends AbstractGoogleMailTestSupp
         Message m1 = createThreadedTestEmail(null);
         Message m2 = createThreadedTestEmail(m1.getThreadId());
 
-        Map<String, Object> headers = new HashMap<String, Object>();
+        Map<String, Object> headers = new HashMap<>();
         headers.put("CamelGoogleMail.q", "subject:\"Hello from camel-google-mail\"");
 
         // using String message body for single parameter "userId"
@@ -91,7 +91,7 @@ public class GmailUsersThreadsIntegrationTest extends AbstractGoogleMailTestSupp
         assertTrue(result.getThreads().size() > 0);
         LOG.debug("list: " + result);
 
-        headers = new HashMap<String, Object>();
+        headers = new HashMap<>();
         // parameter type is String
         headers.put("CamelGoogleMail.userId", CURRENT_USERID);
         // parameter type is String
diff --git a/components/camel-groovy/src/main/java/org/apache/camel/language/groovy/GroovyExpression.java b/components/camel-groovy/src/main/java/org/apache/camel/language/groovy/GroovyExpression.java
index fe3a52a..e01cef8 100644
--- a/components/camel-groovy/src/main/java/org/apache/camel/language/groovy/GroovyExpression.java
+++ b/components/camel-groovy/src/main/java/org/apache/camel/language/groovy/GroovyExpression.java
@@ -86,7 +86,7 @@ public class GroovyExpression extends ExpressionSupport {
     }
 
     private Binding createBinding(Exchange exchange) {
-        Map<String, Object> variables = new HashMap<String, Object>();
+        Map<String, Object> variables = new HashMap<>();
         ExchangeHelper.populateVariableMap(exchange, variables);
         return new Binding(variables);
     }
diff --git a/components/camel-groovy/src/main/java/org/apache/camel/language/groovy/GroovyLanguage.java b/components/camel-groovy/src/main/java/org/apache/camel/language/groovy/GroovyLanguage.java
index d9a8226..7566ff3 100644
--- a/components/camel-groovy/src/main/java/org/apache/camel/language/groovy/GroovyLanguage.java
+++ b/components/camel-groovy/src/main/java/org/apache/camel/language/groovy/GroovyLanguage.java
@@ -28,7 +28,7 @@ import org.codehaus.groovy.runtime.InvokerHelper;
 public class GroovyLanguage extends LanguageSupport {
 
     // Cache used to stores the compiled scripts (aka their classes)
-    private final LRUSoftCache<String, GroovyClassService> scriptCache = new LRUSoftCache<String, GroovyClassService>(16, 1000, true);
+    private final LRUSoftCache<String, GroovyClassService> scriptCache = new LRUSoftCache<>(16, 1000, true);
 
     private static final class GroovyClassService implements Service {
 
diff --git a/components/camel-groovy/src/test/java/org/apache/camel/language/groovy/GroovyListMapTest.java b/components/camel-groovy/src/test/java/org/apache/camel/language/groovy/GroovyListMapTest.java
index be46c5c..86ad6cb 100644
--- a/components/camel-groovy/src/test/java/org/apache/camel/language/groovy/GroovyListMapTest.java
+++ b/components/camel-groovy/src/test/java/org/apache/camel/language/groovy/GroovyListMapTest.java
@@ -36,8 +36,8 @@ public class GroovyListMapTest extends CamelTestSupport {
         MockEndpoint mock = getMockEndpoint("mock:result");
         mock.expectedMessageCount(1);
 
-        List<Map<String, Object>> grid = new ArrayList<Map<String, Object>>();
-        Map<String, Object> cells = new LinkedHashMap<String, Object>();
+        List<Map<String, Object>> grid = new ArrayList<>();
+        Map<String, Object> cells = new LinkedHashMap<>();
         cells.put("foo", "bar");
         grid.add(cells);
 
diff --git a/components/camel-groovy/src/test/java/org/apache/camel/language/groovy/GroovySetHeaderTest.java b/components/camel-groovy/src/test/java/org/apache/camel/language/groovy/GroovySetHeaderTest.java
index 8e1aee6..2770144 100644
--- a/components/camel-groovy/src/test/java/org/apache/camel/language/groovy/GroovySetHeaderTest.java
+++ b/components/camel-groovy/src/test/java/org/apache/camel/language/groovy/GroovySetHeaderTest.java
@@ -40,7 +40,7 @@ public class GroovySetHeaderTest extends CamelTestSupport {
         mock.expectedHeaderReceived("drink", "Carlsberg");
         mock.expectedHeaderReceived("camelId", context.getName());
 
-        Map<String, Object> headers = new HashMap<String, Object>();
+        Map<String, Object> headers = new HashMap<>();
         headers.put("one", "einz");
         headers.put("two", "twei");
         headers.put("beer", "Carlsberg");
diff --git a/components/camel-grpc/src/main/java/org/apache/camel/component/grpc/GrpcUtils.java b/components/camel-grpc/src/main/java/org/apache/camel/component/grpc/GrpcUtils.java
index 474625f..668cc2b 100644
--- a/components/camel-grpc/src/main/java/org/apache/camel/component/grpc/GrpcUtils.java
+++ b/components/camel-grpc/src/main/java/org/apache/camel/component/grpc/GrpcUtils.java
@@ -16,16 +16,11 @@
  */
 package org.apache.camel.component.grpc;
 
-import java.io.UnsupportedEncodingException;
 import java.lang.reflect.Method;
 import java.util.ArrayList;
-import java.util.HashMap;
 import java.util.Iterator;
 import java.util.List;
 
-import com.auth0.jwt.JWT;
-import com.auth0.jwt.algorithms.Algorithm;
-import com.auth0.jwt.exceptions.JWTCreationException;
 import io.grpc.CallCredentials;
 import io.grpc.Channel;
 import io.grpc.stub.StreamObserver;
@@ -162,7 +157,7 @@ public final class GrpcUtils {
         }
         if (method.getReturnType().equals(Iterator.class)) {
             Iterator<Object> responseObjects = (Iterator<Object>)ObjectHelper.invokeMethod(method, blockingStubClass, request);
-            List<Object> objectList = new ArrayList<Object>();
+            List<Object> objectList = new ArrayList<>();
             while (responseObjects.hasNext()) {
                 objectList.add(responseObjects.next());
             }
diff --git a/components/camel-grpc/src/main/java/org/apache/camel/component/grpc/client/GrpcResponseAggregationStreamObserver.java b/components/camel-grpc/src/main/java/org/apache/camel/component/grpc/client/GrpcResponseAggregationStreamObserver.java
index d12bcc0..839e04a 100644
--- a/components/camel-grpc/src/main/java/org/apache/camel/component/grpc/client/GrpcResponseAggregationStreamObserver.java
+++ b/components/camel-grpc/src/main/java/org/apache/camel/component/grpc/client/GrpcResponseAggregationStreamObserver.java
@@ -30,7 +30,7 @@ import org.apache.camel.Exchange;
 public class GrpcResponseAggregationStreamObserver implements StreamObserver<Object> {
     private final Exchange exchange;
     private final AsyncCallback callback;
-    private List<Object> responseCollection = new LinkedList<Object>();
+    private List<Object> responseCollection = new LinkedList<>();
     
     public GrpcResponseAggregationStreamObserver(Exchange exchange, AsyncCallback callback) {
         this.exchange = exchange;
diff --git a/components/camel-grpc/src/main/java/org/apache/camel/component/grpc/server/GrpcMethodHandler.java b/components/camel-grpc/src/main/java/org/apache/camel/component/grpc/server/GrpcMethodHandler.java
index 5007846..fb91615 100644
--- a/components/camel-grpc/src/main/java/org/apache/camel/component/grpc/server/GrpcMethodHandler.java
+++ b/components/camel-grpc/src/main/java/org/apache/camel/component/grpc/server/GrpcMethodHandler.java
@@ -46,7 +46,7 @@ public class GrpcMethodHandler implements MethodHandler {
     @Override
     @SuppressWarnings("unchecked")
     public Object invoke(Object self, Method thisMethod, Method proceed, Object[] args) throws Throwable {
-        Map<String, Object> grcpHeaders = new HashMap<String, Object>();
+        Map<String, Object> grcpHeaders = new HashMap<>();
         
         grcpHeaders.put(GrpcHeaderInterceptor.USER_AGENT_CONTEXT_KEY.toString(), GrpcHeaderInterceptor.USER_AGENT_CONTEXT_KEY.get());
         grcpHeaders.put(GrpcHeaderInterceptor.CONTENT_TYPE_CONTEXT_KEY.toString(), GrpcHeaderInterceptor.CONTENT_TYPE_CONTEXT_KEY.get());
diff --git a/components/camel-gson/src/test/java/org/apache/camel/component/gson/GsonMarshalListTest.java b/components/camel-gson/src/test/java/org/apache/camel/component/gson/GsonMarshalListTest.java
index c3425ac..88f4722 100644
--- a/components/camel-gson/src/test/java/org/apache/camel/component/gson/GsonMarshalListTest.java
+++ b/components/camel-gson/src/test/java/org/apache/camel/component/gson/GsonMarshalListTest.java
@@ -34,7 +34,7 @@ public class GsonMarshalListTest extends CamelTestSupport {
     @Test
     public void testMarshalAndUnmarshalPojo() throws Exception {
         
-        List<TestPojo> inList = new ArrayList<TestPojo>();
+        List<TestPojo> inList = new ArrayList<>();
         
         TestPojo in1 = new TestPojo();
         in1.setName("Camel1");
diff --git a/components/camel-gson/src/test/java/org/apache/camel/component/gson/GsonMarshalTest.java b/components/camel-gson/src/test/java/org/apache/camel/component/gson/GsonMarshalTest.java
index 1404b1d..4dd174c 100644
--- a/components/camel-gson/src/test/java/org/apache/camel/component/gson/GsonMarshalTest.java
+++ b/components/camel-gson/src/test/java/org/apache/camel/component/gson/GsonMarshalTest.java
@@ -28,7 +28,7 @@ public class GsonMarshalTest extends CamelTestSupport {
 
     @Test
     public void testMarshalAndUnmarshalMap() throws Exception {
-        Map<String, String> in = new HashMap<String, String>();
+        Map<String, String> in = new HashMap<>();
         in.put("name", "Camel");
 
         MockEndpoint mock = getMockEndpoint("mock:reverse");
diff --git a/components/camel-guice/src/main/java/org/apache/camel/guice/CamelModuleWithRouteTypes.java b/components/camel-guice/src/main/java/org/apache/camel/guice/CamelModuleWithRouteTypes.java
index 90e63b0..29b494a 100644
--- a/components/camel-guice/src/main/java/org/apache/camel/guice/CamelModuleWithRouteTypes.java
+++ b/components/camel-guice/src/main/java/org/apache/camel/guice/CamelModuleWithRouteTypes.java
@@ -47,7 +47,7 @@ public class CamelModuleWithRouteTypes extends CamelModule {
     private Set<Class<? extends RoutesBuilder>> routes;
 
     public CamelModuleWithRouteTypes(Class<? extends RoutesBuilder>... routeTypes) {
-        this.routes = new HashSet<Class<? extends RoutesBuilder>>();
+        this.routes = new HashSet<>();
         for (Class<? extends RoutesBuilder> route : routeTypes) {
             routes.add(route);
         }
diff --git a/components/camel-guice/src/test/java/org/apache/camel/guice/ComponentFoundInRegistryTest.java b/components/camel-guice/src/test/java/org/apache/camel/guice/ComponentFoundInRegistryTest.java
index ba81a7f..3ebb81e 100644
--- a/components/camel-guice/src/test/java/org/apache/camel/guice/ComponentFoundInRegistryTest.java
+++ b/components/camel-guice/src/test/java/org/apache/camel/guice/ComponentFoundInRegistryTest.java
@@ -53,7 +53,7 @@ public class ComponentFoundInRegistryTest extends Assert {
 
     @Test
     public void testGuice() throws Exception {
-        Hashtable<String, Object> env = new Hashtable<String, Object>();
+        Hashtable<String, Object> env = new Hashtable<>();
         env.put(Context.PROVIDER_URL, GuiceInitialContextFactory.class.getName());
         env.put(Injectors.MODULE_CLASS_NAMES, MyModule.class.getName());
 
diff --git a/components/camel-guice/src/test/java/org/apache/camel/guice/FileEndpointReferenceRouteTest.java b/components/camel-guice/src/test/java/org/apache/camel/guice/FileEndpointReferenceRouteTest.java
index f6e9d6c..acee085 100644
--- a/components/camel-guice/src/test/java/org/apache/camel/guice/FileEndpointReferenceRouteTest.java
+++ b/components/camel-guice/src/test/java/org/apache/camel/guice/FileEndpointReferenceRouteTest.java
@@ -63,7 +63,7 @@ public class FileEndpointReferenceRouteTest extends Assert {
         @Provides
         @JndiBind("fileFilter")
         public GenericFileFilter<?> getfileFilter() {
-            return new MyFileFilter<Object>();
+            return new MyFileFilter<>();
         }
         
 
@@ -83,7 +83,7 @@ public class FileEndpointReferenceRouteTest extends Assert {
     
     @Test
     public void runTest() throws Exception {
-        Hashtable<String, Object> env = new Hashtable<String, Object>();
+        Hashtable<String, Object> env = new Hashtable<>();
         env.put(Context.PROVIDER_URL, GuiceInitialContextFactory.class.getName());
         env.put(Injectors.MODULE_CLASS_NAMES, MyModule.class.getName());
 
diff --git a/components/camel-guice/src/test/java/org/apache/camel/guice/testing/InjectorManager.java b/components/camel-guice/src/test/java/org/apache/camel/guice/testing/InjectorManager.java
index f37490a..93490c4 100644
--- a/components/camel-guice/src/test/java/org/apache/camel/guice/testing/InjectorManager.java
+++ b/components/camel-guice/src/test/java/org/apache/camel/guice/testing/InjectorManager.java
@@ -41,7 +41,7 @@ import org.apache.camel.guice.util.CloseableScope;
 public class InjectorManager {
     private static final String NESTED_MODULE_CLASS = "TestModule";
 
-    private Map<Object, Injector> injectors = new ConcurrentHashMap<Object, Injector>();
+    private Map<Object, Injector> injectors = new ConcurrentHashMap<>();
     private AtomicInteger initializeCounter = new AtomicInteger(0);
     private CloseableScope testScope = new CloseableScope(TestScoped.class);
     private CloseableScope classScope = new CloseableScope(ClassScoped.class);

-- 
To stop receiving notification emails like this one, please contact
bvahdat@apache.org.