Merge branch 'stable-3.6' into stable-3.7

* stable-3.6:
  Move to the standard Gerrit plugins verifier

Change-Id: Ic371f4302b835494bedd015a58b0c93aa2448b82
diff --git a/pom.xml b/pom.xml
index 546d78f..a7c7c02 100644
--- a/pom.xml
+++ b/pom.xml
@@ -4,7 +4,7 @@
 
     <groupId>com.gerritforge</groupId>
     <artifactId>global-refdb</artifactId>
-    <version>3.6.3.4</version>
+    <version>3.7.4</version>
     <packaging>jar</packaging>
 
     <name>global-refdb</name>
@@ -38,7 +38,7 @@
 
     <properties>
         <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
-        <gerrit.version>3.6.3</gerrit.version>
+        <gerrit.version>3.7.4</gerrit.version>
     </properties>
 
     <dependencies>
diff --git a/src/main/java/com/gerritforge/gerrit/globalrefdb/validation/RefUpdateValidator.java b/src/main/java/com/gerritforge/gerrit/globalrefdb/validation/RefUpdateValidator.java
index c86a346..40e168c 100644
--- a/src/main/java/com/gerritforge/gerrit/globalrefdb/validation/RefUpdateValidator.java
+++ b/src/main/java/com/gerritforge/gerrit/globalrefdb/validation/RefUpdateValidator.java
@@ -160,7 +160,7 @@
   private Boolean isRefToBeIgnored(String refName) {
     Boolean isRefToBeIgnored =
         ignoredRefs.stream().anyMatch(ignoredRefPrefix -> refName.startsWith(ignoredRefPrefix));
-    logger.atFine().log("Is project version update? %s", isRefToBeIgnored);
+    logger.atFine().log("Is project version update? %b", isRefToBeIgnored);
     return isRefToBeIgnored;
   }
 
@@ -176,7 +176,7 @@
 
   protected Boolean isGlobalProject(String projectName) {
     Boolean isGlobalProject = projectsFilter.matches(projectName);
-    logger.atFine().log("Is global project? %s", isGlobalProject);
+    logger.atFine().log("Is global project? %b", isGlobalProject);
     return isGlobalProject;
   }
 
@@ -217,12 +217,6 @@
         refEnforcement.getPolicy(projectName, refPair.getName());
     if (refEnforcementPolicy == EnforcePolicy.IGNORED) return;
 
-    String errorMessage =
-        String.format(
-            "Not able to persist the data in Zookeeper for project '%s' and ref '%s',"
-                + "the cluster is now in Split Brain since the commit has been "
-                + "persisted locally but not in SharedRef the value %s",
-            projectName, refPair.getName(), refPair.putValue);
     boolean succeeded;
     try {
       succeeded =
@@ -236,6 +230,12 @@
     }
 
     if (!succeeded) {
+      String errorMessage =
+          String.format(
+              "Not able to persist the data in Zookeeper for project '%s' and ref '%s',"
+                  + "the cluster is now in Split Brain since the commit has been "
+                  + "persisted locally but not in SharedRef the value %s",
+              projectName, refPair.getName(), refPair.putValue);
       throw new SharedDbSplitBrainException(errorMessage);
     }
   }