From b9be6bb1c8b0e9a53963d19689de82aff2fc0fcc Mon Sep 17 00:00:00 2001 From: Yueyang Qiu Date: Tue, 10 Sep 2019 17:30:32 -0700 Subject: [PATCH 1/2] Exclude AvroSchemaTest for Apex and Flink runner for now because they are failing --- runners/apex/build.gradle | 3 +++ runners/flink/flink_runner.gradle | 3 +++ 2 files changed, 6 insertions(+) diff --git a/runners/apex/build.gradle b/runners/apex/build.gradle index e76b9a3eba9c..f3f842932976 100644 --- a/runners/apex/build.gradle +++ b/runners/apex/build.gradle @@ -98,6 +98,9 @@ task validatesRunnerBatch(type: Test) { excludeCategories 'org.apache.beam.sdk.testing.UsesMetricsPusher' excludeCategories 'org.apache.beam.sdk.testing.UsesUnboundedSplittableParDo' excludeCategories 'org.apache.beam.sdk.testing.UsesUnboundedPCollections' + // TODO[BEAM-8204]: figure out if we can make the test work on Apex runner, or maybe create a + // new category tag and change the following line to: excludeCategories ''. + exclude '**/AvroSchemaTest.class' } // apex runner is run in embedded mode. Increase default HeapSize diff --git a/runners/flink/flink_runner.gradle b/runners/flink/flink_runner.gradle index 40e58b3d4186..9b3d9674a26f 100644 --- a/runners/flink/flink_runner.gradle +++ b/runners/flink/flink_runner.gradle @@ -173,6 +173,9 @@ def createValidatesRunnerTask(Map m) { excludeCategories 'org.apache.beam.sdk.testing.UsesUnboundedSplittableParDo' excludeCategories 'org.apache.beam.sdk.testing.UsesTestStream' } + // TODO[BEAM-8205]: figure out if we can make the test work on Flink runner, or maybe create a + // new category tag and change the following line to: excludeCategories ''. + exclude '**/AvroSchemaTest.class' } } } From 3fc26cd430c2bdfd8a22144b039091ca33c2bd20 Mon Sep 17 00:00:00 2001 From: Yueyang Qiu Date: Tue, 10 Sep 2019 17:52:05 -0700 Subject: [PATCH 2/2] Exclude ParDoTest.testSideInputAnnotationWithMultipleSideInputs --- runners/apex/build.gradle | 3 +++ .../UsesSideInputsWithDifferentCoders.java | 21 +++++++++++++++++++ .../apache/beam/sdk/transforms/ParDoTest.java | 7 ++++++- 3 files changed, 30 insertions(+), 1 deletion(-) create mode 100644 sdks/java/core/src/main/java/org/apache/beam/sdk/testing/UsesSideInputsWithDifferentCoders.java diff --git a/runners/apex/build.gradle b/runners/apex/build.gradle index f3f842932976..ce7b1cfb7e16 100644 --- a/runners/apex/build.gradle +++ b/runners/apex/build.gradle @@ -99,6 +99,9 @@ task validatesRunnerBatch(type: Test) { excludeCategories 'org.apache.beam.sdk.testing.UsesUnboundedSplittableParDo' excludeCategories 'org.apache.beam.sdk.testing.UsesUnboundedPCollections' // TODO[BEAM-8204]: figure out if we can make the test work on Apex runner, or maybe create a + // more meaningful category tag. + excludeCategories 'org.apache.beam.sdk.testing.UsesSideInputsWithDifferentCoders' + // TODO[BEAM-8204]: figure out if we can make the test work on Apex runner, or maybe create a // new category tag and change the following line to: excludeCategories ''. exclude '**/AvroSchemaTest.class' } diff --git a/sdks/java/core/src/main/java/org/apache/beam/sdk/testing/UsesSideInputsWithDifferentCoders.java b/sdks/java/core/src/main/java/org/apache/beam/sdk/testing/UsesSideInputsWithDifferentCoders.java new file mode 100644 index 000000000000..ab5031324ff9 --- /dev/null +++ b/sdks/java/core/src/main/java/org/apache/beam/sdk/testing/UsesSideInputsWithDifferentCoders.java @@ -0,0 +1,21 @@ +/* + * 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. + */ +package org.apache.beam.sdk.testing; + +/** Category tag for validation tests which use multiple side inputs with different coders. */ +public interface UsesSideInputsWithDifferentCoders {} diff --git a/sdks/java/core/src/test/java/org/apache/beam/sdk/transforms/ParDoTest.java b/sdks/java/core/src/test/java/org/apache/beam/sdk/transforms/ParDoTest.java index b6df00fd0344..cb968553a698 100644 --- a/sdks/java/core/src/test/java/org/apache/beam/sdk/transforms/ParDoTest.java +++ b/sdks/java/core/src/test/java/org/apache/beam/sdk/transforms/ParDoTest.java @@ -82,6 +82,7 @@ import org.apache.beam.sdk.testing.UsesMapState; import org.apache.beam.sdk.testing.UsesSetState; import org.apache.beam.sdk.testing.UsesSideInputs; +import org.apache.beam.sdk.testing.UsesSideInputsWithDifferentCoders; import org.apache.beam.sdk.testing.UsesStatefulParDo; import org.apache.beam.sdk.testing.UsesTestStream; import org.apache.beam.sdk.testing.UsesTestStreamWithProcessingTime; @@ -919,7 +920,11 @@ public void processElement( } @Test - @Category({ValidatesRunner.class, UsesSideInputs.class}) + @Category({ + ValidatesRunner.class, + UsesSideInputs.class, + UsesSideInputsWithDifferentCoders.class + }) public void testSideInputAnnotationWithMultipleSideInputs() { final List side1Data = ImmutableList.of(2, 0);