github.com/apache/beam/sdks/v2@v2.48.2/java/io/amazon-web-services2/build.gradle (about) 1 import groovy.json.JsonOutput 2 3 /* 4 * Licensed to the Apache Software Foundation (ASF) under one 5 * or more contributor license agreements. See the NOTICE file 6 * distributed with this work for additional information 7 * regarding copyright ownership. The ASF licenses this file 8 * to you under the Apache License, Version 2.0 (the 9 * License); you may not use this file except in compliance 10 * with the License. You may obtain a copy of the License at 11 * 12 * http://www.apache.org/licenses/LICENSE-2.0 13 * 14 * Unless required by applicable law or agreed to in writing, software 15 * distributed under the License is distributed on an AS IS BASIS, 16 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 17 * See the License for the specific language governing permissions and 18 * limitations under the License. 19 */ 20 21 plugins { id 'org.apache.beam.module' } 22 applyJavaNature( 23 automaticModuleName: 'org.apache.beam.sdk.io.aws2', 24 ) 25 provideIntegrationTestingDependencies() 26 enableJavaPerformanceTesting() 27 28 description = "Apache Beam :: SDKs :: Java :: IO :: Amazon Web Services 2" 29 ext.summary = "IO library to read and write Amazon Web Services services from Beam." 30 31 def excludeNetty = { 32 exclude group: "io.netty", module: "*" // exclude more recent Netty version 33 } 34 35 dependencies { 36 implementation library.java.vendored_guava_26_0_jre 37 implementation library.java.error_prone_annotations 38 implementation project(path: ":sdks:java:core", configuration: "shadow") 39 implementation library.java.aws_java_sdk2_cloudwatch, excludeNetty 40 implementation library.java.aws_java_sdk2_dynamodb, excludeNetty 41 implementation library.java.aws_java_sdk2_kinesis, excludeNetty 42 implementation library.java.aws_java_sdk2_s3, excludeNetty 43 implementation library.java.aws_java_sdk2_sns, excludeNetty 44 implementation library.java.aws_java_sdk2_sqs, excludeNetty 45 implementation library.java.aws_java_sdk2_sts, excludeNetty 46 implementation library.java.aws_java_sdk2_aws_core, excludeNetty 47 implementation library.java.aws_java_sdk2_sdk_core, excludeNetty 48 implementation library.java.aws_java_sdk2_auth, excludeNetty 49 implementation library.java.aws_java_sdk2_regions, excludeNetty 50 implementation library.java.aws_java_sdk2_utils, excludeNetty 51 implementation library.java.aws_java_sdk2_profiles, excludeNetty 52 implementation library.java.aws_java_sdk2_http_client_spi, excludeNetty 53 implementation library.java.aws_java_sdk2_apache_client, excludeNetty 54 implementation library.java.aws_java_sdk2_netty_client, excludeNetty 55 implementation("software.amazon.kinesis:amazon-kinesis-client:2.4.8") { 56 // Note: The KCL client isn't used. However, unfortunately, some model classes of KCL leak into the 57 // KinesisIO API (KinesisClientRecord, InitialPositionInStream). Additionally, KinesisIO 58 // internally uses KCL utils to generate aggregated messages and de-aggregate them. 59 60 // Exclude unnecessary runtime dependencies of the client as these cause conflicts. 61 exclude group: "software.amazon.glue", module: "*" 62 exclude group: "software.amazon.awssdk", module: "*" 63 exclude group: "io.reactivex.rxjava3", module: "rxjava" 64 } 65 implementation library.java.netty_all // force version of netty used by Beam 66 implementation library.java.netty_transport 67 permitUnusedDeclared library.java.netty_all 68 implementation library.java.byte_buddy 69 implementation library.java.jackson_core 70 implementation library.java.jackson_annotations 71 implementation library.java.jackson_databind 72 implementation library.java.joda_time 73 implementation library.java.slf4j_api 74 implementation library.java.protobuf_java 75 implementation "commons-lang:commons-lang:2.6" 76 implementation "org.reactivestreams:reactive-streams:1.0.3" 77 implementation library.java.commons_lang3 78 implementation library.java.commons_codec 79 testImplementation project(path: ":sdks:java:core", configuration: "shadowTest") 80 testImplementation project(path: ":sdks:java:extensions:avro", configuration: "testRuntimeMigration") 81 testImplementation project(path: ":sdks:java:io:common", configuration: "testRuntimeMigration") 82 testImplementation "io.findify:s3mock_2.12:0.2.6" 83 testImplementation 'org.elasticmq:elasticmq-rest-sqs_2.12:1.3.5' 84 testImplementation library.java.mockito_core 85 testImplementation library.java.guava_testlib 86 testImplementation library.java.junit 87 testImplementation library.java.hamcrest 88 testImplementation "org.assertj:assertj-core:3.11.1" 89 testImplementation library.java.testcontainers_localstack 90 testRuntimeOnly library.java.slf4j_jdk14 91 testRuntimeOnly project(path: ":runners:direct-java", configuration: "shadow") 92 } 93 94 test { 95 systemProperty "beamTestPipelineOptions", JsonOutput.toJson([ 96 '--awsRegion=us-west-2', 97 '--awsCredentialsProvider={"@type": "StaticCredentialsProvider", "accessKeyId": "key_id_value", "secretAccessKey": "secret_value"}' 98 ]) 99 maxParallelForks 4 100 }