Merge branch 'stable-3.4' into stable-3.5

* stable-3.4:
  Fetch change version from refdb on Git protocol v2
  Do not cache negative results from open changes / timestamp lookups
  follow-up to "Exclude repo from ChangeCacheKey..."
  Exclude repo from ChangeCacheKey equals/hash code calculation

Change-Id: I7be400b2c2584504e3b7f750387bafb946025616
diff --git a/src/main/java/com/googlesource/gerrit/modules/gitrefsfilter/ForProjectWrapper.java b/src/main/java/com/googlesource/gerrit/modules/gitrefsfilter/ForProjectWrapper.java
index 3b5725b..2186b97 100644
--- a/src/main/java/com/googlesource/gerrit/modules/gitrefsfilter/ForProjectWrapper.java
+++ b/src/main/java/com/googlesource/gerrit/modules/gitrefsfilter/ForProjectWrapper.java
@@ -138,7 +138,7 @@
       return Optional.ofNullable(refDb.exactRef(RefNames.changeMetaRef(changeId)));
     } catch (IOException e) {
       logger.atWarning().withCause(e).log(
-          "Error looking up change '%d' meta-ref from refs db.", changeId);
+          "Error looking up change '%d' meta-ref from refs db.", changeId.get());
       return Optional.empty();
     }
   }
@@ -153,7 +153,7 @@
     } catch (ExecutionException e) {
       logger.atWarning().withCause(e).log(
           "Error getting change '%d' from the cache. Do not hide from the advertised refs",
-          changeId);
+          changeId.get());
       return true;
     }
   }
@@ -171,7 +171,7 @@
     } catch (ExecutionException e) {
       logger.atWarning().withCause(e).log(
           "Error getting change '%d' from the cache. Do not hide from the advertised refs",
-          changeId);
+          changeId.get());
       return true;
     }
   }