Merge branch 'stable-2.16' into stable-3.0
* stable-2.16:
Bump required Bazel version to 2.1.0
Change-Id: I5acb64db60bf6bc098a45c36495b2ca8991f5107
diff --git a/WORKSPACE b/WORKSPACE
index b671f78..ec0ece7 100644
--- a/WORKSPACE
+++ b/WORKSPACE
@@ -3,7 +3,7 @@
load("//:bazlets.bzl", "load_bazlets")
load_bazlets(
- commit = "1b6fc9b39001806b37a4eedbb0a4816daf1a227d",
+ commit = "96f691ebbf4ef1c46b798e871ed5acd9d844651c",
#local_path = "/home/<user>/projects/bazlets",
)
diff --git a/external_plugin_deps.bzl b/external_plugin_deps.bzl
index 8f9e7d2..b272d6c 100644
--- a/external_plugin_deps.bzl
+++ b/external_plugin_deps.bzl
@@ -1,13 +1,13 @@
load("//tools/bzl:maven_jar.bzl", "GERRIT", "MAVEN_CENTRAL", "MAVEN_LOCAL", "maven_jar")
-JGIT_VERSION = "5.1.12.201910011832-r"
+JGIT_VERSION = "5.3.6.201910020505-r"
REPO = MAVEN_CENTRAL
def external_plugin_deps():
maven_jar(
name = "jgit-http-apache",
artifact = "org.eclipse.jgit:org.eclipse.jgit.http.apache:" + JGIT_VERSION,
- sha1 = "92ad62799dd7eb02cc8805f2e297714cc3bb5149",
+ sha1 = "668c69822b4f54b430dd9880cc2bb13f13aa88d1",
repository = REPO,
unsign = True,
exclude = [
@@ -19,7 +19,7 @@
maven_jar(
name = "jgit-lfs",
artifact = "org.eclipse.jgit:org.eclipse.jgit.lfs:" + JGIT_VERSION,
- sha1 = "bb4972c6e127c615c4b9183f95414ff2a20916cf",
+ sha1 = "153e32275cb0ccfd7f6dba89cf58392d42e16c3a",
repository = REPO,
unsign = True,
exclude = [
@@ -31,7 +31,7 @@
maven_jar(
name = "jgit-lfs-server",
artifact = "org.eclipse.jgit:org.eclipse.jgit.lfs.server:" + JGIT_VERSION,
- sha1 = "b2d1e48f9daddc09e072e422c151384e845c1612",
+ sha1 = "e37339c77dd00d96269e280d582c742c424b908f",
repository = REPO,
unsign = True,
exclude = [
diff --git a/src/main/java/com/googlesource/gerrit/plugins/lfs/LfsApiServlet.java b/src/main/java/com/googlesource/gerrit/plugins/lfs/LfsApiServlet.java
index 8982dbe..992dada 100644
--- a/src/main/java/com/googlesource/gerrit/plugins/lfs/LfsApiServlet.java
+++ b/src/main/java/com/googlesource/gerrit/plugins/lfs/LfsApiServlet.java
@@ -22,9 +22,9 @@
import static com.google.gerrit.server.permissions.ProjectPermission.PUSH_AT_LEAST_ONE_REF;
import com.google.common.flogger.FluentLogger;
-import com.google.gerrit.common.ProjectUtil;
import com.google.gerrit.reviewdb.client.Project;
import com.google.gerrit.server.CurrentUser;
+import com.google.gerrit.server.ProjectUtil;
import com.google.gerrit.server.permissions.PermissionBackend;
import com.google.gerrit.server.project.ProjectCache;
import com.google.gerrit.server.project.ProjectState;
@@ -81,7 +81,7 @@
throw new LfsException("no repository at " + pathInfo);
}
String projName = matcher.group(1);
- Project.NameKey project = Project.NameKey.parse(ProjectUtil.stripGitSuffix(projName));
+ Project.NameKey project = Project.nameKey(ProjectUtil.stripGitSuffix(projName));
ProjectState state = projectCache.get(project);
if (state == null || state.getProject().getState() == HIDDEN) {
throw new LfsRepositoryNotFound(project.get());
diff --git a/src/main/java/com/googlesource/gerrit/plugins/lfs/locks/LfsLocksAction.java b/src/main/java/com/googlesource/gerrit/plugins/lfs/locks/LfsLocksAction.java
index 4b6afb4..32536f7 100644
--- a/src/main/java/com/googlesource/gerrit/plugins/lfs/locks/LfsLocksAction.java
+++ b/src/main/java/com/googlesource/gerrit/plugins/lfs/locks/LfsLocksAction.java
@@ -22,10 +22,10 @@
import static org.eclipse.jgit.util.HttpSupport.HDR_AUTHORIZATION;
import com.google.common.flogger.FluentLogger;
-import com.google.gerrit.common.ProjectUtil;
import com.google.gerrit.extensions.restapi.AuthException;
import com.google.gerrit.reviewdb.client.Project;
import com.google.gerrit.server.CurrentUser;
+import com.google.gerrit.server.ProjectUtil;
import com.google.gerrit.server.permissions.PermissionBackend;
import com.google.gerrit.server.permissions.PermissionBackend.ForProject;
import com.google.gerrit.server.permissions.PermissionBackendException;
@@ -100,7 +100,7 @@
throws LfsException, IOException;
protected ProjectState getProject(String name) throws LfsRepositoryNotFound {
- Project.NameKey project = Project.NameKey.parse(ProjectUtil.stripGitSuffix(name));
+ Project.NameKey project = Project.nameKey(ProjectUtil.stripGitSuffix(name));
ProjectState state = projectCache.get(project);
if (state == null || state.getProject().getState() == HIDDEN) {
throw new LfsRepositoryNotFound(project.get());