This is an automated email from the ASF dual-hosted git repository.
heejong pushed a commit to branch release-2.30.0
in repository https://gitbox.apache.org/repos/asf/beam.git
The following commit(s) were added to refs/heads/release-2.30.0 by this push:
new 8a945c5 [BEAM-11055] Don't add log4j to library (#14777)
new 0a9bec6 Merge pull request #14809 from boyuanzz/cherry-pick
8a945c5 is described below
commit 8a945c57cb97cf1607cb7fe4fb6c37f76016a133
Author: Brian Hulette <[email protected]>
AuthorDate: Tue May 11 12:18:24 2021 -0700
[BEAM-11055] Don't add log4j to library (#14777)
(cherry picked from commit 436b7bf584d8d525cc390dcd195659b189904337)
---
.../main/groovy/org/apache/beam/gradle/BeamModulePlugin.groovy | 3 ---
.../io/elasticsearch-tests/elasticsearch-tests-2/build.gradle | 5 +++--
.../io/elasticsearch-tests/elasticsearch-tests-5/build.gradle | 9 +++++----
.../io/elasticsearch-tests/elasticsearch-tests-6/build.gradle | 9 +++++----
.../io/elasticsearch-tests/elasticsearch-tests-7/build.gradle | 9 +++++----
.../elasticsearch-tests/elasticsearch-tests-common/build.gradle | 9 +++++----
sdks/java/io/hadoop-format/build.gradle | 1 -
7 files changed, 23 insertions(+), 22 deletions(-)
diff --git
a/buildSrc/src/main/groovy/org/apache/beam/gradle/BeamModulePlugin.groovy
b/buildSrc/src/main/groovy/org/apache/beam/gradle/BeamModulePlugin.groovy
index f601908..17dcaf5 100644
--- a/buildSrc/src/main/groovy/org/apache/beam/gradle/BeamModulePlugin.groovy
+++ b/buildSrc/src/main/groovy/org/apache/beam/gradle/BeamModulePlugin.groovy
@@ -441,7 +441,6 @@ class BeamModulePlugin implements Plugin<Project> {
def jaxb_api_version = "2.3.3"
def jsr305_version = "3.0.2"
def kafka_version = "2.4.1"
- def log4j_version = "2.14.1"
def nemo_version = "0.1"
def netty_version = "4.1.52.Final"
def postgres_version = "42.2.16"
@@ -596,8 +595,6 @@ class BeamModulePlugin implements Plugin<Project> {
junit : "junit:junit:4.13.1",
kafka :
"org.apache.kafka:kafka_2.11:$kafka_version",
kafka_clients :
"org.apache.kafka:kafka-clients:$kafka_version",
- log4j_api :
"org.apache.logging.log4j:log4j-api:$log4j_version",
- log4j_core :
"org.apache.logging.log4j:log4j-core:$log4j_version",
mockito_core :
"org.mockito:mockito-core:3.7.7",
mongo_java_driver :
"org.mongodb:mongo-java-driver:3.12.7",
nemo_compiler_frontend_beam :
"org.apache.nemo:nemo-compiler-frontend-beam:$nemo_version",
diff --git
a/sdks/java/io/elasticsearch-tests/elasticsearch-tests-2/build.gradle
b/sdks/java/io/elasticsearch-tests/elasticsearch-tests-2/build.gradle
index 179c341..dd281bb 100644
--- a/sdks/java/io/elasticsearch-tests/elasticsearch-tests-2/build.gradle
+++ b/sdks/java/io/elasticsearch-tests/elasticsearch-tests-2/build.gradle
@@ -27,6 +27,7 @@ enableJavaPerformanceTesting()
description = "Apache Beam :: SDKs :: Java :: IO :: Elasticsearch-Tests :: 2.x"
ext.summary = "Tests of ElasticsearchIO on Elasticsearch 2.x"
+def log4j_version = "2.14.1"
def elastic_search_version = "2.4.1"
dependencies {
@@ -40,8 +41,8 @@ dependencies {
testCompile library.java.junit
testCompile "org.elasticsearch.client:elasticsearch-rest-client:7.9.2"
testCompile "org.elasticsearch:elasticsearch:$elastic_search_version"
- testRuntimeOnly library.java.log4j_api
- testRuntimeOnly library.java.log4j_core
+ testRuntimeOnly "org.apache.logging.log4j:log4j-api:$log4j_version"
+ testRuntimeOnly "org.apache.logging.log4j:log4j-core:$log4j_version"
testRuntimeOnly library.java.slf4j_jdk14
testRuntimeOnly project(path: ":runners:direct-java", configuration:
"shadow")
}
diff --git
a/sdks/java/io/elasticsearch-tests/elasticsearch-tests-5/build.gradle
b/sdks/java/io/elasticsearch-tests/elasticsearch-tests-5/build.gradle
index e5090ef..718b903 100644
--- a/sdks/java/io/elasticsearch-tests/elasticsearch-tests-5/build.gradle
+++ b/sdks/java/io/elasticsearch-tests/elasticsearch-tests-5/build.gradle
@@ -32,14 +32,15 @@ test {
systemProperty "tests.security.manager", "false"
}
+def log4j_version = "2.14.1"
def elastic_search_version = "5.6.3"
configurations.all {
resolutionStrategy {
// Make sure the log4j versions for api and core match instead of taking
the default
// Gradle rule of using the latest.
- force library.java.log4j_api
- force library.java.log4j_core
+ force "org.apache.logging.log4j:log4j-core:$log4j_version"
+ force "org.apache.logging.log4j:log4j-api:$log4j_version"
}
}
@@ -58,8 +59,8 @@ dependencies {
testCompile library.java.hamcrest_library
testCompile library.java.junit
testCompile
"org.elasticsearch.client:elasticsearch-rest-client:$elastic_search_version"
- testRuntimeOnly library.java.log4j_api
- testRuntimeOnly library.java.log4j_core
+ testRuntimeOnly "org.apache.logging.log4j:log4j-api:$log4j_version"
+ testRuntimeOnly "org.apache.logging.log4j:log4j-core:$log4j_version"
testRuntimeOnly library.java.slf4j_jdk14
testRuntimeOnly project(path: ":runners:direct-java", configuration:
"shadow")
}
diff --git
a/sdks/java/io/elasticsearch-tests/elasticsearch-tests-6/build.gradle
b/sdks/java/io/elasticsearch-tests/elasticsearch-tests-6/build.gradle
index 71cbe00..6eee3a0 100644
--- a/sdks/java/io/elasticsearch-tests/elasticsearch-tests-6/build.gradle
+++ b/sdks/java/io/elasticsearch-tests/elasticsearch-tests-6/build.gradle
@@ -32,14 +32,15 @@ test {
systemProperty "tests.security.manager", "false"
}
+def log4j_version = "2.14.1"
def elastic_search_version = "6.4.0"
configurations.all {
resolutionStrategy {
// Make sure the log4j versions for api and core match instead of taking
the default
// Gradle rule of using the latest.
- force library.java.log4j_api
- force library.java.log4j_core
+ force "org.apache.logging.log4j:log4j-core:$log4j_version"
+ force "org.apache.logging.log4j:log4j-api:$log4j_version"
}
}
@@ -58,8 +59,8 @@ dependencies {
testCompile library.java.hamcrest_library
testCompile library.java.junit
testCompile
"org.elasticsearch.client:elasticsearch-rest-client:$elastic_search_version"
- testRuntimeOnly library.java.log4j_api
- testRuntimeOnly library.java.log4j_core
+ testRuntimeOnly "org.apache.logging.log4j:log4j-api:$log4j_version"
+ testRuntimeOnly "org.apache.logging.log4j:log4j-core:$log4j_version"
testRuntimeOnly library.java.slf4j_jdk14
testRuntimeOnly project(path: ":runners:direct-java", configuration:
"shadow")
}
diff --git
a/sdks/java/io/elasticsearch-tests/elasticsearch-tests-7/build.gradle
b/sdks/java/io/elasticsearch-tests/elasticsearch-tests-7/build.gradle
index 127408a..ead50d7 100644
--- a/sdks/java/io/elasticsearch-tests/elasticsearch-tests-7/build.gradle
+++ b/sdks/java/io/elasticsearch-tests/elasticsearch-tests-7/build.gradle
@@ -32,14 +32,15 @@ test {
systemProperty "tests.security.manager", "false"
}
+def log4j_version = "2.14.1"
def elastic_search_version = "7.9.2"
configurations.all {
resolutionStrategy {
// Make sure the log4j versions for api and core match instead of taking
the default
// Gradle rule of using the latest.
- force library.java.log4j_api
- force library.java.log4j_core
+ force "org.apache.logging.log4j:log4j-core:$log4j_version"
+ force "org.apache.logging.log4j:log4j-api:$log4j_version"
}
}
@@ -58,8 +59,8 @@ dependencies {
testCompile library.java.hamcrest_library
testCompile library.java.junit
testCompile
"org.elasticsearch.client:elasticsearch-rest-client:$elastic_search_version"
- testRuntimeOnly library.java.log4j_api
- testRuntimeOnly library.java.log4j_core
+ testRuntimeOnly "org.apache.logging.log4j:log4j-api:$log4j_version"
+ testRuntimeOnly "org.apache.logging.log4j:log4j-core:$log4j_version"
testRuntimeOnly library.java.slf4j_jdk14
testRuntimeOnly project(path: ":runners:direct-java", configuration:
"shadow")
}
diff --git
a/sdks/java/io/elasticsearch-tests/elasticsearch-tests-common/build.gradle
b/sdks/java/io/elasticsearch-tests/elasticsearch-tests-common/build.gradle
index 6a86075..396d3a1 100644
--- a/sdks/java/io/elasticsearch-tests/elasticsearch-tests-common/build.gradle
+++ b/sdks/java/io/elasticsearch-tests/elasticsearch-tests-common/build.gradle
@@ -25,14 +25,15 @@ applyJavaNature(
description = "Apache Beam :: SDKs :: Java :: IO :: Elasticsearch-Tests ::
Common"
ext.summary = "Common test classes for ElasticsearchIO"
+def log4j_version = "2.14.1"
def elastic_search_version = "7.9.2"
configurations.all {
resolutionStrategy {
// Make sure the log4j versions for api and core match instead of taking
the default
// Gradle rule of using the latest.
- force library.java.log4j_api
- force library.java.log4j_core
+ force "org.apache.logging.log4j:log4j-core:$log4j_version"
+ force "org.apache.logging.log4j:log4j-api:$log4j_version"
}
}
@@ -46,8 +47,8 @@ dependencies {
testCompile library.java.hamcrest_library
testCompile library.java.junit
testCompile
"org.elasticsearch.client:elasticsearch-rest-client:$elastic_search_version"
- testRuntimeOnly library.java.log4j_api
- testRuntimeOnly library.java.log4j_core
+ testRuntimeOnly "org.apache.logging.log4j:log4j-api:$log4j_version"
+ testRuntimeOnly "org.apache.logging.log4j:log4j-core:$log4j_version"
testRuntimeOnly library.java.slf4j_jdk14
testRuntimeOnly project(path: ":runners:direct-java", configuration:
"shadow")
}
diff --git a/sdks/java/io/hadoop-format/build.gradle
b/sdks/java/io/hadoop-format/build.gradle
index 16787e5..d5075fe 100644
--- a/sdks/java/io/hadoop-format/build.gradle
+++ b/sdks/java/io/hadoop-format/build.gradle
@@ -96,7 +96,6 @@ dependencies {
testCompile library.java.hamcrest_library
testCompile library.java.testcontainers_postgresql
testCompile library.java.netty_all
- testRuntimeOnly library.java.log4j_core
testRuntimeOnly library.java.slf4j_jdk14
testRuntimeOnly project(path: ":runners:direct-java", configuration:
"shadow")