Skip to content

Commit

Permalink
Remove antlr from dependency from java-core pom (#33030)
Browse files Browse the repository at this point in the history
* Remove antlr from dependency of jaca-core pom

* Fix to use java-core shadowjar as source to build direct-runner-java
  • Loading branch information
Abacn authored Nov 7, 2024
1 parent 81f35ab commit e598df7
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 11 deletions.
22 changes: 12 additions & 10 deletions runners/direct-java/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -22,12 +22,12 @@ plugins { id 'org.apache.beam.module' }
// Shade away runner execution utilities till because this causes ServiceLoader conflicts with
// TransformPayloadTranslatorRegistrar amongst other runners. This only happens in the DirectRunner
// because it is likely to appear on the classpath of another runner.
def dependOnProjects = [
":runners:core-java",
":runners:local-java",
":runners:java-fn-execution",
":sdks:java:core",
]
def dependOnProjectsAndConfigs = [
":runners:core-java":null,
":runners:local-java":null,
":runners:java-fn-execution":null,
":sdks:java:core":"shadow",
]

applyJavaNature(
automaticModuleName: 'org.apache.beam.runners.direct',
Expand All @@ -36,8 +36,8 @@ applyJavaNature(
],
shadowClosure: {
dependencies {
dependOnProjects.each {
include(project(path: it, configuration: "shadow"))
dependOnProjectsAndConfigs.each {
include(project(path: it.key, configuration: "shadow"))
}
}
},
Expand All @@ -63,8 +63,10 @@ configurations {
dependencies {
shadow library.java.vendored_guava_32_1_2_jre
shadow project(path: ":model:pipeline", configuration: "shadow")
dependOnProjects.each {
implementation project(it)
dependOnProjectsAndConfigs.each {
// For projects producing shadowjar, use the packaged jar as dependency to
// handle redirected packages from it
implementation project(path: it.key, configuration: it.value)
}
shadow library.java.vendored_grpc_1_60_1
shadow library.java.joda_time
Expand Down
1 change: 0 additions & 1 deletion sdks/java/core/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,6 @@ dependencies {
shadow library.java.vendored_grpc_1_60_1
shadow library.java.vendored_guava_32_1_2_jre
shadow library.java.byte_buddy
shadow library.java.antlr_runtime
shadow library.java.commons_compress
shadow library.java.commons_lang3
testImplementation library.java.mockito_inline
Expand Down

0 comments on commit e598df7

Please sign in to comment.