blob: a7ed6c2e87dbe89ff14b5d3f1085620793810553 [file] [log] [blame]
/*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* License); you may not use this file except in compliance
* with the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an AS IS BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
plugins { id 'org.apache.beam.module' }
applyJavaNature(
automaticModuleName: 'org.apache.beam.sdk',
shadowClosure: {
dependencies {
include(dependency(library.java.protobuf_java))
include(dependency("org.apache.commons:.*"))
include(dependency(library.java.antlr_runtime))
}
relocate "com.google.thirdparty", getJavaRelocatedPath("com.google.thirdparty")
relocate "com.google.protobuf", getJavaRelocatedPath("com.google.protobuf")
relocate "org.apache.commons", getJavaRelocatedPath("org.apache.commons")
relocate "org.antlr.v4", getJavaRelocatedPath("org.antlr.v4")
}
)
applyAvroNature()
applyAntlrNature()
generateGrammarSource {
arguments += ["-visitor"]
}
description = "Apache Beam :: SDKs :: Java :: Core"
ext.summary = """Beam SDK Java All provides a simple, Java-based
interface for processing virtually any size data. This
artifact includes entire Apache Beam Java SDK."""
processResources {
filter org.apache.tools.ant.filters.ReplaceTokens, tokens: [
'pom.version': version,
'timestamp': new Date().format("yyyy-MM-dd HH:mm")
]
}
// Exclude tests that need a runner
test {
systemProperty "beamUseDummyRunner", "true"
useJUnit {
excludeCategories "org.apache.beam.sdk.testing.NeedsRunner"
}
}
dependencies {
antlr library.java.antlr
// Required to load constants from the model, e.g. max timestamp for global window
shadow project(path: ":model:pipeline", configuration: "shadow")
shadow project(path: ":model:job-management", configuration: "shadow")
shadow library.java.vendored_bytebuddy_1_9_3
shadow library.java.vendored_guava_26_0_jre
compile library.java.antlr_runtime
compile library.java.protobuf_java
compile library.java.commons_compress
compile library.java.commons_lang3
shadow library.java.jackson_core
shadow library.java.jackson_annotations
shadow library.java.jackson_databind
shadow library.java.slf4j_api
shadow library.java.avro
shadow library.java.snappy_java
shadow library.java.joda_time
shadow "org.tukaani:xz:1.8"
provided library.java.junit
provided library.java.hamcrest_core
provided library.java.hamcrest_library
shadowTest library.java.jackson_dataformat_yaml
shadowTest library.java.guava_testlib
shadowTest library.java.mockito_core
shadowTest library.java.hamcrest_core
shadowTest library.java.hamcrest_library
shadowTest "com.esotericsoftware.kryo:kryo:2.21"
shadowTest library.java.quickcheck_core
shadowTest library.java.avro_tests
shadowTest library.java.zstd_jni
testRuntimeOnly library.java.slf4j_jdk14
}