From c17768f14f5a57bcc2d83613818101f3b21e7260 Mon Sep 17 00:00:00 2001 From: Kenneth Knowles Date: Thu, 7 Jul 2016 19:41:45 -0700 Subject: [PATCH] Move example dependency on runners into a profile Even an optional runtime dependency, such as from the examples to a runner, does get pulled in for testing. This meant that all the dependencies for all runners had to be resolvable in an integration testing context. It is quite inconvient. Explicitly excluding runners via flags such as `-pl !runners/spark` does not work since it causes errors in dependency resolution. This change adds a profile, active by default, that can be explicitly disabled to avoid pulling in dependencies. --- examples/java8/pom.xml | 63 +++++++++++++++++++++++++++++++----------- 1 file changed, 47 insertions(+), 16 deletions(-) diff --git a/examples/java8/pom.xml b/examples/java8/pom.xml index 61b8cb4f8d79..3cd1787757d1 100644 --- a/examples/java8/pom.xml +++ b/examples/java8/pom.xml @@ -35,6 +35,53 @@ jar + + + + + include-runners + true + + + org.apache.beam + beam-runners-direct-java + ${project.version} + runtime + true + + + + org.apache.beam + beam-runners-flink_2.10 + ${project.version} + runtime + true + + + + org.apache.beam + beam-runners-spark + ${project.version} + runtime + true + + + + + @@ -164,21 +211,5 @@ com.google.api-client google-api-client - - - org.apache.beam - beam-runners-direct-java - ${project.version} - runtime - true - - - - org.apache.beam - beam-runners-flink_2.10 - ${project.version} - runtime - true -