aboutsummaryrefslogtreecommitdiff
path: root/pom.xml
diff options
context:
space:
mode:
authorJosh Rosen <joshrosen@databricks.com>2016-04-21 09:57:26 -0700
committerReynold Xin <rxin@databricks.com>2016-04-21 09:57:26 -0700
commit649335d6c1dd0884bf6f6618cd56fb480fe40886 (patch)
tree3af2f4a7234b7693b6ef37b1c7498ea64d3870be /pom.xml
parent6fdd0e32a6c3fdce1f3f7e1f8d252af05c419f7b (diff)
downloadspark-649335d6c1dd0884bf6f6618cd56fb480fe40886.tar.gz
spark-649335d6c1dd0884bf6f6618cd56fb480fe40886.tar.bz2
spark-649335d6c1dd0884bf6f6618cd56fb480fe40886.zip
[SPARK-14797][BUILD] Spark SQL POM should not hardcode spark-sketch_2.11 dep.
Spark SQL's POM hardcodes a dependency on `spark-sketch_2.11`, which causes Scala 2.10 builds to include the `_2.11` dependency. This is harmless since `spark-sketch` is a pure-Java module (see #12334 for a discussion of dropping the Scala version suffixes from these modules' artifactIds), but it's confusing to people looking at the published POMs. This patch fixes this by using `${scala.binary.version}` to substitute the correct suffix, and also adds a set of Maven Enforcer rules to ensure that `_2.11` artifacts are not used in 2.10 builds (and vice-versa). /cc ahirreddy, who spotted this issue. Author: Josh Rosen <joshrosen@databricks.com> Closes #12563 from JoshRosen/fix-sketch-scala-version.
Diffstat (limited to 'pom.xml')
-rw-r--r--pom.xml50
1 files changed, 50 insertions, 0 deletions
diff --git a/pom.xml b/pom.xml
index a8e752c7d5..dfee5d7834 100644
--- a/pom.xml
+++ b/pom.xml
@@ -2487,6 +2487,31 @@
</dependency>
</dependencies>
</dependencyManagement>
+ <build>
+ <plugins>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-enforcer-plugin</artifactId>
+ <executions>
+ <execution>
+ <id>enforce-versions</id>
+ <goals>
+ <goal>enforce</goal>
+ </goals>
+ <configuration>
+ <rules>
+ <bannedDependencies>
+ <excludes combine.children="append">
+ <exclude>*:*_2.11</exclude>
+ </excludes>
+ </bannedDependencies>
+ </rules>
+ </configuration>
+ </execution>
+ </executions>
+ </plugin>
+ </plugins>
+ </build>
</profile>
<profile>
@@ -2508,6 +2533,31 @@
<scala.version>2.11.8</scala.version>
<scala.binary.version>2.11</scala.binary.version>
</properties>
+ <build>
+ <plugins>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-enforcer-plugin</artifactId>
+ <executions>
+ <execution>
+ <id>enforce-versions</id>
+ <goals>
+ <goal>enforce</goal>
+ </goals>
+ <configuration>
+ <rules>
+ <bannedDependencies>
+ <excludes combine.children="append">
+ <exclude>*:*_2.10</exclude>
+ </excludes>
+ </bannedDependencies>
+ </rules>
+ </configuration>
+ </execution>
+ </executions>
+ </plugin>
+ </plugins>
+ </build>
</profile>
<!--