beam-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From lc...@apache.org
Subject [1/2] incubator-beam git commit: Exclude guava-testlib from shading relocation
Date Tue, 16 Aug 2016 00:08:46 GMT
Repository: incubator-beam
Updated Branches:
  refs/heads/master ab104a16c -> f1935d5d1


Exclude guava-testlib from shading relocation

Previously, guava-testlib guava-testlib was being relocated as part of
the shading process, but test-scope dependencies aren't bundled in the
uber-jar. As a result, the output JAR was unusable without recreating the
same shading rules in a consuming project.


Project: http://git-wip-us.apache.org/repos/asf/incubator-beam/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-beam/commit/914ae520
Tree: http://git-wip-us.apache.org/repos/asf/incubator-beam/tree/914ae520
Diff: http://git-wip-us.apache.org/repos/asf/incubator-beam/diff/914ae520

Branch: refs/heads/master
Commit: 914ae520b15b8a0ed3304b206adcc802f9cce7fb
Parents: ab104a1
Author: Scott Wegner <swegner@google.com>
Authored: Mon Aug 15 15:39:34 2016 -0700
Committer: Luke Cwik <lcwik@google.com>
Committed: Mon Aug 15 16:52:25 2016 -0700

----------------------------------------------------------------------
 pom.xml                                    | 2 ++
 runners/direct-java/pom.xml                | 6 ++++++
 runners/google-cloud-dataflow-java/pom.xml | 6 ++++++
 sdks/java/core/pom.xml                     | 6 ++++++
 4 files changed, 20 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-beam/blob/914ae520/pom.xml
----------------------------------------------------------------------
diff --git a/pom.xml b/pom.xml
index d5e609b..b5f30c1 100644
--- a/pom.xml
+++ b/pom.xml
@@ -633,6 +633,8 @@
       </dependency>
 
       <dependency>
+        <!-- Note: when relocating guava, ensure guava-testlib is not also relocated by
+             excluding com.google.common.**.testing -->
         <groupId>com.google.guava</groupId>
         <artifactId>guava-testlib</artifactId>
         <version>${guava.version}</version>

http://git-wip-us.apache.org/repos/asf/incubator-beam/blob/914ae520/runners/direct-java/pom.xml
----------------------------------------------------------------------
diff --git a/runners/direct-java/pom.xml b/runners/direct-java/pom.xml
index 0a2b4b9..11481f1 100644
--- a/runners/direct-java/pom.xml
+++ b/runners/direct-java/pom.xml
@@ -192,6 +192,10 @@
                      the second relocation. -->
                 <relocation>
                   <pattern>com.google.common</pattern>
+                  <excludes>
+                    <!-- com.google.common is too generic, need to exclude guava-testlib
-->
+                    <exclude>com.google.common.**.testing</exclude>
+                  </excludes>
                   <shadedPattern>org.apache.beam.runners.direct.repackaged.com.google.common</shadedPattern>
                 </relocation>
                 <relocation>
@@ -264,6 +268,8 @@
     </dependency>
 
     <dependency>
+      <!-- Note: when relocating guava, ensure guava-testlib is not also relocated by
+     excluding com.google.common.**.testing -->
       <groupId>com.google.guava</groupId>
       <artifactId>guava-testlib</artifactId>
       <scope>test</scope>

http://git-wip-us.apache.org/repos/asf/incubator-beam/blob/914ae520/runners/google-cloud-dataflow-java/pom.xml
----------------------------------------------------------------------
diff --git a/runners/google-cloud-dataflow-java/pom.xml b/runners/google-cloud-dataflow-java/pom.xml
index d130281..d5485ef 100644
--- a/runners/google-cloud-dataflow-java/pom.xml
+++ b/runners/google-cloud-dataflow-java/pom.xml
@@ -196,6 +196,10 @@
                      the second relocation. -->
                 <relocation>
                   <pattern>com.google.common</pattern>
+                  <excludes>
+                    <!-- com.google.common is too generic, need to exclude guava-testlib
-->
+                    <exclude>com.google.common.**.testing</exclude>
+                  </excludes>
                   <shadedPattern>org.apache.beam.sdk.repackaged.com.google.common</shadedPattern>
                 </relocation>
                 <relocation>
@@ -310,6 +314,8 @@
     </dependency>
 
     <dependency>
+      <!-- Note: when relocating guava, ensure guava-testlib is not also relocated by
+           excluding com.google.common.**.testing -->
       <groupId>com.google.guava</groupId>
       <artifactId>guava-testlib</artifactId>
       <scope>test</scope>

http://git-wip-us.apache.org/repos/asf/incubator-beam/blob/914ae520/sdks/java/core/pom.xml
----------------------------------------------------------------------
diff --git a/sdks/java/core/pom.xml b/sdks/java/core/pom.xml
index aff4f66..fddccea 100644
--- a/sdks/java/core/pom.xml
+++ b/sdks/java/core/pom.xml
@@ -193,6 +193,10 @@
                   exclude 'org.apache.beam.**', and remove the second relocation. -->
                 <relocation>
                   <pattern>com.google.common</pattern>
+                  <excludes>
+                    <!-- com.google.common is too generic, need to exclude guava-testlib
-->
+                    <exclude>com.google.common.**.testing</exclude>
+                  </excludes>
                   <shadedPattern>org.apache.beam.sdk.repackaged.com.google.common</shadedPattern>
                 </relocation>
                 <relocation>
@@ -421,6 +425,8 @@
     </dependency>
 
     <dependency>
+      <!-- Note: when relocating guava, ensure guava-testlib is not also relocated by
+           excluding com.google.common.**.testing -->
       <groupId>com.google.guava</groupId>
       <artifactId>guava-testlib</artifactId>
       <scope>test</scope>


Mime
View raw message