From 5f0ee3a725509ffc9eb9c920edc43dc14c84b312 Mon Sep 17 00:00:00 2001 From: Eric Anderson Date: Fri, 23 Mar 2018 15:45:05 -0700 Subject: [PATCH] Bump to Guava 20 Fixes #4176 --- build.gradle | 4 ++-- core/build.gradle | 4 ++++ protobuf/build.gradle | 8 ++++++-- repositories.bzl | 4 ++-- services/build.gradle | 2 ++ 5 files changed, 16 insertions(+), 6 deletions(-) diff --git a/build.gradle b/build.gradle index 08728492e0..689e230fa8 100644 --- a/build.gradle +++ b/build.gradle @@ -100,7 +100,7 @@ subprojects { javaPluginPath = "$rootDir/compiler/build/exe/java_plugin/$protocPluginBaseName$exeSuffix" nettyVersion = '4.1.22.Final' - guavaVersion = '19.0' + guavaVersion = '20.0' protobufVersion = '3.5.1' protocVersion = '3.5.1-1' protobufNanoVersion = '3.0.0-alpha-5' @@ -222,7 +222,7 @@ subprojects { junit: 'junit:junit:4.12', mockito: 'org.mockito:mockito-core:1.9.5', truth: 'com.google.truth:truth:0.36', - guava_testlib: 'com.google.guava:guava-testlib:19.0', + guava_testlib: 'com.google.guava:guava-testlib:20.0', // Benchmark dependencies hdrhistogram: 'org.hdrhistogram:HdrHistogram:2.1.10', diff --git a/core/build.gradle b/core/build.gradle index 4b3a88ff0e..8a3622bc94 100644 --- a/core/build.gradle +++ b/core/build.gradle @@ -11,6 +11,8 @@ dependencies { exclude group: 'com.google.code.findbugs', module: 'jsr305' // prefer 2.1.2 from libraries instead of 2.2.0 exclude group: 'com.google.errorprone', module: 'error_prone_annotations' + // prefer 20.0 from libraries instead of 19.0 + exclude group: 'com.google.guava', module: 'guava' // we'll always be more up-to-date exclude group: 'io.grpc', module: 'grpc-context' } @@ -21,6 +23,8 @@ dependencies { exclude group: 'io.grpc', module: 'grpc-context' // prefer 2.1.2 from libraries instead of 2.2.0 exclude group: 'com.google.errorprone', module: 'error_prone_annotations' + // prefer 20.0 from libraries instead of 19.0 + exclude group: 'com.google.guava', module: 'guava' } testCompile project(':grpc-context').sourceSets.test.output, diff --git a/protobuf/build.gradle b/protobuf/build.gradle index 2d4a8a8c59..74bea7fb34 100644 --- a/protobuf/build.gradle +++ b/protobuf/build.gradle @@ -15,8 +15,12 @@ buildscript { dependencies { compile project(':grpc-core'), libraries.protobuf, - libraries.guava, - libraries.protobuf_util + libraries.guava + + compile (libraries.protobuf_util) { + // prefer 20.0 from libraries instead of 19.0 + exclude group: 'com.google.guava', module: 'guava' + } compile (libraries.google_api_protos) { // 'com.google.api:api-common' transitively depends on auto-value, which breaks our diff --git a/repositories.bzl b/repositories.bzl index 6776600570..857063b6ef 100644 --- a/repositories.bzl +++ b/repositories.bzl @@ -131,8 +131,8 @@ def com_google_errorprone_error_prone_annotations(): def com_google_guava(): native.maven_jar( name = "com_google_guava_guava", - artifact = "com.google.guava:guava:19.0", - sha1 = "6ce200f6b23222af3d8abb6b6459e6c44f4bb0e9", + artifact = "com.google.guava:guava:20.0", + sha1 = "89507701249388e1ed5ddcf8c41f4ce1be7831ef", ) def com_google_protobuf(): diff --git a/services/build.gradle b/services/build.gradle index 6f7924863e..f2de92d7f6 100644 --- a/services/build.gradle +++ b/services/build.gradle @@ -19,6 +19,8 @@ dependencies { compile (libraries.instrumentation_api) { // prefer 2.0.19 from libraries instead of 2.0.11 exclude group: 'com.google.errorprone', module: 'error_prone_annotations' + // prefer 20.0 from libraries instead of 19.0 + exclude group: 'com.google.guava', module: 'guava' // we'll always be more up-to-date exclude group: 'io.grpc', module: 'grpc-context' }