Merge "Remove now-redundant KeyUtil#setEncoderImpl call"

* submodules:
* Update plugins/replication from branch 'master'
  to 534b041232a196d244b041f35225d6f569e5e084
  - Remove now-redundant KeyUtil#setEncoderImpl call
    
    Change-Id: If4e6b18d2513a6a21fe096c5b9b70e2140d7e0aa
    
diff --git a/.gitmodules b/.gitmodules
index 8d75bcc..4ce7b5f 100644
--- a/.gitmodules
+++ b/.gitmodules
@@ -8,6 +8,11 @@
 	url = ../plugins/commit-message-length-validator
 	branch = .
 
+[submodule "plugins/delete-project"]
+	path = plugins/delete-project
+	url = ../plugins/delete-project
+	branch = .
+
 [submodule "plugins/download-commands"]
 	path = plugins/download-commands
 	url = ../plugins/download-commands
@@ -32,3 +37,8 @@
 	path = plugins/singleusergroup
 	url = ../plugins/singleusergroup
 	branch = .
+
+[submodule "plugins/webhooks"]
+	path = plugins/webhooks
+	url = ../plugins/webhooks
+	branch = .
diff --git a/Documentation/config-plugins.txt b/Documentation/config-plugins.txt
index a138b14..35f44c0 100644
--- a/Documentation/config-plugins.txt
+++ b/Documentation/config-plugins.txt
@@ -61,6 +61,18 @@
 link:https://gerrit.googlesource.com/plugins/commit-message-length-validator/+doc/master/src/main/resources/Documentation/config.md[
 Configuration]
 
+[[delete-project]]
+=== delete-project
+
+Provides the ability to delete a project.
+
+link:https://gerrit-review.googlesource.com/admin/repos/plugins/delete-project[
+Project] |
+link:https://gerrit.googlesource.com/plugins/delete-project/+doc/master/src/main/resources/Documentation/about.md[
+Documentation] |
+link:https://gerrit.googlesource.com/plugins/delete-project/+doc/master/src/main/resources/Documentation/config.md[
+Configuration]
+
 [[download-commands]]
 === download-commands
 
@@ -220,16 +232,6 @@
 link:https://gerrit.googlesource.com/plugins/changemessage/+doc/master/src/main/resources/Documentation/config.md[
 Configuration]
 
-[[delete-project]]
-=== delete-project
-
-Provides the ability to delete a project.
-
-link:https://gerrit-review.googlesource.com/admin/repos/plugins/delete-project[
-Project] |
-link:https://gerrit.googlesource.com/plugins/delete-project/+doc/master/src/main/resources/Documentation/about.md[
-Documentation]
-
 [[egit]]
 === egit
 
diff --git a/WORKSPACE b/WORKSPACE
index fe1f341c..58bde27 100644
--- a/WORKSPACE
+++ b/WORKSPACE
@@ -1072,6 +1072,32 @@
     sha1 = "485de3a253e23f645037828c07f1d7f1af40763a",
 )
 
+maven_jar(
+    name = "mockito",
+    artifact = "org.mockito:mockito-core:2.23.4",
+    sha1 = "a35b6f8ffcfa786771eac7d7d903429e790fdf3f",
+)
+
+BYTE_BUDDY_VERSION = "1.9.3"
+
+maven_jar(
+    name = "byte-buddy",
+    artifact = "net.bytebuddy:byte-buddy:" + BYTE_BUDDY_VERSION,
+    sha1 = "f32e510b239620852fc9a2387fac41fd053d6a4d",
+)
+
+maven_jar(
+    name = "byte-buddy-agent",
+    artifact = "net.bytebuddy:byte-buddy-agent:" + BYTE_BUDDY_VERSION,
+    sha1 = "f5b78c16cf4060664d80b6ca32d80dca4bd3d264",
+)
+
+maven_jar(
+    name = "objenesis",
+    artifact = "org.objenesis:objenesis:2.6",
+    sha1 = "639033469776fd37c08358c6b92a4761feb2af4b",
+)
+
 load("//tools/bzl:js.bzl", "bower_archive", "npm_binary")
 
 # NPM binaries bundled along with their dependencies.
diff --git a/java/com/google/gerrit/acceptance/BUILD b/java/com/google/gerrit/acceptance/BUILD
index 7becf99..f74246f 100644
--- a/java/com/google/gerrit/acceptance/BUILD
+++ b/java/com/google/gerrit/acceptance/BUILD
@@ -50,6 +50,7 @@
         "//lib/guice:guice-servlet",
         "//lib/jgit/org.eclipse.jgit:jgit",
         "//lib/mina:sshd",
+        "//lib/mockito",
         "//prolog:gerrit-prolog-common",
     ],
 )
diff --git a/java/com/google/gerrit/server/git/receive/ReceiveCommits.java b/java/com/google/gerrit/server/git/receive/ReceiveCommits.java
index ba11985..65b4f73 100644
--- a/java/com/google/gerrit/server/git/receive/ReceiveCommits.java
+++ b/java/com/google/gerrit/server/git/receive/ReceiveCommits.java
@@ -18,6 +18,7 @@
 import static com.google.common.base.Preconditions.checkArgument;
 import static com.google.common.base.Preconditions.checkState;
 import static com.google.common.collect.ImmutableSet.toImmutableSet;
+import static com.google.common.flogger.LazyArgs.lazy;
 import static com.google.gerrit.common.FooterConstants.CHANGE_ID;
 import static com.google.gerrit.reviewdb.client.RefNames.REFS_CHANGES;
 import static com.google.gerrit.reviewdb.client.RefNames.isConfigRef;
@@ -611,6 +612,10 @@
       replaceProgress.end();
       queueSuccessMessages(newChanges);
       refsPublishDeprecationWarning();
+
+      logger.atFine().log(
+          "Command results: %s",
+          lazy(() -> commands.stream().map(ReceiveCommits::commandToString).collect(joining(","))));
     }
   }
 
@@ -3277,4 +3282,15 @@
   private static boolean isConfig(ReceiveCommand cmd) {
     return cmd.getRefName().equals(RefNames.REFS_CONFIG);
   }
+
+  private static String commandToString(ReceiveCommand cmd) {
+    StringBuilder b = new StringBuilder();
+    b.append(cmd);
+    b.append("  (").append(cmd.getResult());
+    if (cmd.getMessage() != null) {
+      b.append(": ").append(cmd.getMessage());
+    }
+    b.append(")\n");
+    return b.toString();
+  }
 }
diff --git a/lib/mockito/BUILD b/lib/mockito/BUILD
new file mode 100644
index 0000000..7448462
--- /dev/null
+++ b/lib/mockito/BUILD
@@ -0,0 +1,35 @@
+package(
+    default_testonly = 1,
+    default_visibility = ["//visibility:private"],
+)
+
+java_library(
+    name = "mockito",
+    data = ["//lib:LICENSE-Apache2.0"],
+    # Only exposed for plugin tests; core tests should use Easymock
+    visibility = ["//java/com/google/gerrit/acceptance:__pkg__"],
+    exports = ["@mockito//jar"],
+    runtime_deps = [
+        ":byte-buddy",
+        ":byte-buddy-agent",
+        ":objenesis",
+    ],
+)
+
+java_library(
+    name = "byte-buddy",
+    data = ["//lib:LICENSE-Apache2.0"],
+    exports = ["@byte-buddy//jar"],
+)
+
+java_library(
+    name = "byte-buddy-agent",
+    data = ["//lib:LICENSE-Apache2.0"],
+    exports = ["@byte-buddy-agent//jar"],
+)
+
+java_library(
+    name = "objenesis",
+    data = ["//lib:LICENSE-Apache2.0"],
+    exports = ["@objenesis//jar"],
+)
diff --git a/plugins/delete-project b/plugins/delete-project
new file mode 160000
index 0000000..6d5deba
--- /dev/null
+++ b/plugins/delete-project
@@ -0,0 +1 @@
+Subproject commit 6d5deba11e57ae3c2b6b41a66b0dbabcd09ad378
diff --git a/plugins/replication b/plugins/replication
index 05b0999..534b041 160000
--- a/plugins/replication
+++ b/plugins/replication
@@ -1 +1 @@
-Subproject commit 05b0999845151b230d8fe0c38d43cd39bcba8093
+Subproject commit 534b041232a196d244b041f35225d6f569e5e084
diff --git a/plugins/webhooks b/plugins/webhooks
new file mode 160000
index 0000000..37b062e
--- /dev/null
+++ b/plugins/webhooks
@@ -0,0 +1 @@
+Subproject commit 37b062e08c5a83c4a939777cfddc9b6f97c44cdf
diff --git a/tools/bzl/plugins.bzl b/tools/bzl/plugins.bzl
index 7fd7625..4b4065f 100644
--- a/tools/bzl/plugins.bzl
+++ b/tools/bzl/plugins.bzl
@@ -1,11 +1,13 @@
 CORE_PLUGINS = [
     "codemirror-editor",
     "commit-message-length-validator",
+    "delete-project",
     "download-commands",
     "hooks",
     "replication",
     "reviewnotes",
     "singleusergroup",
+    "webhooks",
 ]
 
 CUSTOM_PLUGINS = [