Merge branch 'stable-2.16' into stable-3.0

* stable-2.16:
  GerritSshApi: Consistently use logError method
  GerritSshApi: Make sshHelper and uri members protected

Change-Id: I5ecbadf706c3138a9b501836865d540a18b921b0
diff --git a/src/main/java/com/googlesource/gerrit/plugins/replication/GerritSshApi.java b/src/main/java/com/googlesource/gerrit/plugins/replication/GerritSshApi.java
index 12b6cbe..9a92d4e 100644
--- a/src/main/java/com/googlesource/gerrit/plugins/replication/GerritSshApi.java
+++ b/src/main/java/com/googlesource/gerrit/plugins/replication/GerritSshApi.java
@@ -30,8 +30,8 @@
   static int SSH_COMMAND_FAILED = -1;
   static String GERRIT_ADMIN_PROTOCOL_PREFIX = "gerrit+";
 
-  private final SshHelper sshHelper;
-  private final URIish uri;
+  protected final SshHelper sshHelper;
+  protected final URIish uri;
 
   private final Set<URIish> withoutDeleteProjectPlugin = new HashSet<>();
 
@@ -80,10 +80,7 @@
     try {
       execute(uri, cmd, errStream);
     } catch (IOException e) {
-      logger.atSevere().withCause(e).log(
-          "Error updating HEAD of remote repository at %s to %s:\n"
-              + "  Exception: %s\n  Command: %s\n  Output: %s",
-          uri, newHead, e, cmd, errStream);
+      logError("updating HEAD of", uri, errStream, cmd, e);
     }
   }