Fix warnings about redundant type arguments

Change-Id: I662b53c105a6b346a91535e85cae2d5675e41a77
diff --git a/src/main/java/com/googlesource/gerrit/plugins/replication/AutoReloadSecureCredentialsFactoryDecorator.java b/src/main/java/com/googlesource/gerrit/plugins/replication/AutoReloadSecureCredentialsFactoryDecorator.java
index 9d6ce69..4017822 100644
--- a/src/main/java/com/googlesource/gerrit/plugins/replication/AutoReloadSecureCredentialsFactoryDecorator.java
+++ b/src/main/java/com/googlesource/gerrit/plugins/replication/AutoReloadSecureCredentialsFactoryDecorator.java
@@ -42,8 +42,7 @@
     this.site = site;
     this.config = config;
     this.secureCredentialsFactory =
-        new AtomicReference<SecureCredentialsFactory>(
-            new SecureCredentialsFactory(site));
+        new AtomicReference<>(new SecureCredentialsFactory(site));
     this.secureCredentialsFactoryLoadTs = getSecureConfigLastEditTs();
   }
 
diff --git a/src/main/java/com/googlesource/gerrit/plugins/replication/Destination.java b/src/main/java/com/googlesource/gerrit/plugins/replication/Destination.java
index 5e843ad..a175285 100644
--- a/src/main/java/com/googlesource/gerrit/plugins/replication/Destination.java
+++ b/src/main/java/com/googlesource/gerrit/plugins/replication/Destination.java
@@ -78,8 +78,8 @@
   private final int retryDelay;
   private final Object stateLock = new Object();
   private final int lockErrorMaxRetries;
-  private final Map<URIish, PushOne> pending = new HashMap<URIish, PushOne>();
-  private final Map<URIish, PushOne> inFlight = new HashMap<URIish, PushOne>();
+  private final Map<URIish, PushOne> pending = new HashMap<>();
+  private final Map<URIish, PushOne> inFlight = new HashMap<>();
   private final PushOne.Factory opFactory;
   private final ProjectControl.Factory projectControlFactory;
   private final GitRepositoryManager gitManager;
diff --git a/src/main/java/com/googlesource/gerrit/plugins/replication/PushOne.java b/src/main/java/com/googlesource/gerrit/plugins/replication/PushOne.java
index e9ce3d4..f861667 100644
--- a/src/main/java/com/googlesource/gerrit/plugins/replication/PushOne.java
+++ b/src/main/java/com/googlesource/gerrit/plugins/replication/PushOne.java
@@ -220,7 +220,7 @@
   }
 
   ReplicationState[] getStatesAsArray() {
-    Set<ReplicationState> statesSet = new HashSet<ReplicationState>();
+    Set<ReplicationState> statesSet = new HashSet<>();
     statesSet.addAll(stateMap.values());
     return statesSet.toArray(new ReplicationState[statesSet.size()]);
   }
@@ -544,12 +544,12 @@
 
   private void updateStates(Collection<RemoteRefUpdate> refUpdates)
       throws LockFailureException {
-    Set<String> doneRefs = new HashSet<String>();
+    Set<String> doneRefs = new HashSet<>();
     boolean anyRefFailed = false;
 
     for (RemoteRefUpdate u : refUpdates) {
       RefPushResult pushStatus = RefPushResult.SUCCEEDED;
-      Set<ReplicationState> logStates = new HashSet<ReplicationState>();
+      Set<ReplicationState> logStates = new HashSet<>();
 
       logStates.addAll(stateMap.get(u.getSrcRef()));
       logStates.addAll(stateMap.get(ALL_REFS));
diff --git a/src/main/java/com/googlesource/gerrit/plugins/replication/PushResultProcessing.java b/src/main/java/com/googlesource/gerrit/plugins/replication/PushResultProcessing.java
index 954a175..b5bed2d 100644
--- a/src/main/java/com/googlesource/gerrit/plugins/replication/PushResultProcessing.java
+++ b/src/main/java/com/googlesource/gerrit/plugins/replication/PushResultProcessing.java
@@ -78,7 +78,7 @@
     private AtomicBoolean hasError = new AtomicBoolean();
 
     CommandProcessing(StartCommand sshCommand) {
-      this.sshCommand = new WeakReference<StartCommand>(sshCommand);
+      this.sshCommand = new WeakReference<>(sshCommand);
     }
 
     @Override
diff --git a/src/main/java/com/googlesource/gerrit/plugins/replication/StartCommand.java b/src/main/java/com/googlesource/gerrit/plugins/replication/StartCommand.java
index 6cd41d6..17a2df9 100644
--- a/src/main/java/com/googlesource/gerrit/plugins/replication/StartCommand.java
+++ b/src/main/java/com/googlesource/gerrit/plugins/replication/StartCommand.java
@@ -48,7 +48,7 @@
   private boolean wait;
 
   @Argument(index = 0, multiValued = true, metaVar = "PATTERN", usage = "project name pattern")
-  private List<String> projectPatterns = new ArrayList<String>(2);
+  private List<String> projectPatterns = new ArrayList<>(2);
 
   @Inject
   private PushAll.Factory pushFactory;