Repository: mahout
Updated Branches:
  refs/heads/master cc361cb7b -> 6cf991c60


MAHOUT-1563: Eliminated warnings about multiple scala versions


Project: http://git-wip-us.apache.org/repos/asf/mahout/repo
Commit: http://git-wip-us.apache.org/repos/asf/mahout/commit/6cf991c6
Tree: http://git-wip-us.apache.org/repos/asf/mahout/tree/6cf991c6
Diff: http://git-wip-us.apache.org/repos/asf/mahout/diff/6cf991c6

Branch: refs/heads/master
Commit: 6cf991c60ac73dbd32b26d8ea0b773ac07d16193
Parents: cc361cb
Author: Stevo Slavic <[email protected]>
Authored: Sun Mar 29 22:17:25 2015 +0200
Committer: Stevo Slavic <[email protected]>
Committed: Sun Mar 29 22:17:25 2015 +0200

----------------------------------------------------------------------
 CHANGELOG           |   2 +
 h2o/pom.xml         | 144 +++++++++++------------------------------------
 math-scala/pom.xml  | 103 +++++++++------------------------
 math/pom.xml        |   2 -
 pom.xml             |  48 +++++++++++++---
 spark-shell/pom.xml | 115 +++++++++----------------------------
 spark/pom.xml       | 114 +++++++++----------------------------
 7 files changed, 158 insertions(+), 370 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/mahout/blob/6cf991c6/CHANGELOG
----------------------------------------------------------------------
diff --git a/CHANGELOG b/CHANGELOG
index 600ed9b..6e15846 100644
--- a/CHANGELOG
+++ b/CHANGELOG
@@ -38,6 +38,8 @@ Release 0.10.0 - unreleased
 
   MAHOUT-1583: cbind() operator for Scala DRMs (dlyubimov)
 
+  MAHOUT-1563: Eliminated warnings about multiple scala versions (sslavic)
+
   MAHOUT-1541, MAHOUT-1568, MAHOUT-1569: Created text-delimited file I/O 
traits and classes on spark, a MahoutDriver for a CLI and a 
ItemSimilairtyDriver using the CLI
 
   MAHOUT-1573: More explicit parallelism adjustments in math-scala DRM apis; 
elements of automatic parallelism management (dlyubimov)

http://git-wip-us.apache.org/repos/asf/mahout/blob/6cf991c6/h2o/pom.xml
----------------------------------------------------------------------
diff --git a/h2o/pom.xml b/h2o/pom.xml
index aa333e1..be76185 100644
--- a/h2o/pom.xml
+++ b/h2o/pom.xml
@@ -36,83 +36,12 @@
 
   <packaging>jar</packaging>
 
-  <repositories>
-    <repository>
-      <id>oss.sonatype.org-releases</id>
-      <url>http://oss.sonatype.org/content/repositories/releases</url>
-      <releases>
-        <enabled>true</enabled>
-      </releases>
-      <snapshots>
-        <enabled>true</enabled>
-      </snapshots>
-    </repository>
-  </repositories>
-
-  <!-- this is needed for scalatest plugin until they publish it to central -->
-  <pluginRepositories>
-    <pluginRepository>
-      <id>sonatype</id>
-      <url>https://oss.sonatype.org/content/groups/public</url>
-      <releases>
-        <enabled>true</enabled>
-      </releases>
-    </pluginRepository>
-  </pluginRepositories>
-
   <build>
-    <defaultGoal>install</defaultGoal>
-
     <plugins>
 
       <plugin>
-        <groupId>org.codehaus.mojo</groupId>
-        <artifactId>build-helper-maven-plugin</artifactId>
-        <executions>
-          <execution>
-            <id>add-source</id>
-            <phase>generate-sources</phase>
-            <goals>
-              <goal>add-source</goal>
-            </goals>
-            <configuration>
-              <sources>
-                
<source>${project.build.directory}/generated-sources/mahout</source>
-              </sources>
-            </configuration>
-          </execution>
-          <execution>
-            <id>add-test-source</id>
-            <phase>generate-sources</phase>
-            <goals>
-              <goal>add-test-source</goal>
-            </goals>
-            <configuration>
-              <sources>
-                
<source>${project.build.directory}/generated-test-sources/mahout</source>
-              </sources>
-            </configuration>
-          </execution>
-        </executions>
-      </plugin>
-
-      <!-- create test jar so other modules can reuse the math test utility 
classes. -->
-      <plugin>
-        <groupId>org.apache.maven.plugins</groupId>
-        <artifactId>maven-jar-plugin</artifactId>
-        <executions>
-          <execution>
-            <goals>
-              <goal>test-jar</goal>
-            </goals>
-            <phase>package</phase>
-          </execution>
-        </executions>
-      </plugin>
-
-      <plugin>
-       <artifactId>maven-assembly-plugin</artifactId>
-       <configuration>
+        <artifactId>maven-assembly-plugin</artifactId>
+        <configuration>
           <descriptorRefs>
             <descriptorRef>jar-with-dependencies</descriptorRef>
           </descriptorRefs>
@@ -121,15 +50,15 @@
               <mainClass>water.H2O</mainClass>
             </manifest>
           </archive>
-       </configuration>
-       <executions>
+        </configuration>
+        <executions>
           <execution>
             <phase>package</phase>
             <goals>
               <goal>single</goal>
             </goals>
           </execution>
-       </executions>
+        </executions>
       </plugin>
 
       <plugin>
@@ -141,54 +70,47 @@
       </plugin>
 
       <plugin>
-        <groupId>org.scala-tools</groupId>
-        <artifactId>maven-scala-plugin</artifactId>
+        <groupId>net.alchim31.maven</groupId>
+        <artifactId>scala-maven-plugin</artifactId>
         <executions>
-         <execution>
-           <id>scala-compile-first</id>
-           <phase>process-resources</phase>
-           <goals>
-             <goal>add-source</goal>
-             <goal>compile</goal>
-           </goals>
-         </execution>
           <execution>
+            <id>add-scala-sources</id>
+            <phase>initialize</phase>
+            <goals>
+              <goal>add-source</goal>
+            </goals>
+          </execution>
+          <execution>
+            <id>scala-compile</id>
+            <phase>process-resources</phase>
             <goals>
               <goal>compile</goal>
+            </goals>
+          </execution>
+          <execution>
+            <id>scala-test-compile</id>
+            <phase>process-test-resources</phase>
+            <goals>
               <goal>testCompile</goal>
             </goals>
           </execution>
         </executions>
-        <configuration>
-          <sourceDir>src/main/scala</sourceDir>
-          <jvmArgs>
-            <jvmArg>-Xms64m</jvmArg>
-            <jvmArg>-Xmx1024m</jvmArg>
-          </jvmArgs>
-        </configuration>
       </plugin>
 
       <!--this is what scalatest recommends to do to enable scala tests -->
 
       <!-- disable surefire -->
-      <!--<plugin>-->
-      <!--<groupId>org.apache.maven.plugins</groupId>-->
-      <!--<artifactId>maven-surefire-plugin</artifactId>-->
-      <!--<version>2.7</version>-->
-      <!--<configuration>-->
-      <!--<skipTests>true</skipTests>-->
-      <!--</configuration>-->
-      <!--</plugin>-->
+      <plugin>
+        <groupId>org.apache.maven.plugins</groupId>
+        <artifactId>maven-surefire-plugin</artifactId>
+        <configuration>
+          <skipTests>true</skipTests>
+        </configuration>
+      </plugin>
       <!-- enable scalatest -->
       <plugin>
         <groupId>org.scalatest</groupId>
         <artifactId>scalatest-maven-plugin</artifactId>
-        <version>1.0-M2</version>
-        <configuration>
-          
<reportsDirectory>${project.build.directory}/scalatest-reports</reportsDirectory>
-          <junitxml>.</junitxml>
-          <filereports>WDF TestSuite.txt</filereports>
-        </configuration>
         <executions>
           <execution>
             <id>test</id>
@@ -206,7 +128,7 @@
 
     <dependency>
       <groupId>org.apache.mahout</groupId>
-      <artifactId>mahout-math-scala_2.10</artifactId>
+      <artifactId>mahout-math-scala_${scala.compat.version}</artifactId>
       <version>${project.version}</version>
     </dependency>
 
@@ -219,7 +141,7 @@
 
    <dependency>
       <groupId>org.apache.mahout</groupId>
-      <artifactId>mahout-math-scala_2.10</artifactId>
+      <artifactId>mahout-math-scala_${scala.compat.version}</artifactId>
       <classifier>tests</classifier>
       <scope>test</scope>
    </dependency>
@@ -249,9 +171,7 @@
     <!-- scala stuff -->
     <dependency>
       <groupId>org.scalatest</groupId>
-      <artifactId>scalatest_2.10</artifactId>
-      <version>2.0</version>
-      <scope>test</scope>
+      <artifactId>scalatest_${scala.compat.version}</artifactId>
     </dependency>
 
   </dependencies>

http://git-wip-us.apache.org/repos/asf/mahout/blob/6cf991c6/math-scala/pom.xml
----------------------------------------------------------------------
diff --git a/math-scala/pom.xml b/math-scala/pom.xml
index 50cea7a..bb524fb 100644
--- a/math-scala/pom.xml
+++ b/math-scala/pom.xml
@@ -36,54 +36,9 @@
 
   <packaging>jar</packaging>
 
-  <!-- this is needed for scalatest plugin until they publish it to central -->
-  <pluginRepositories>
-    <pluginRepository>
-      <id>sonatype</id>
-      <url>https://oss.sonatype.org/content/groups/public</url>
-      <releases>
-        <enabled>true</enabled>
-      </releases>
-    </pluginRepository>
-  </pluginRepositories>
-
   <build>
-    <defaultGoal>install</defaultGoal>
-
     <plugins>
-
-      <plugin>
-        <groupId>org.codehaus.mojo</groupId>
-        <artifactId>build-helper-maven-plugin</artifactId>
-        <executions>
-          <execution>
-            <id>add-source</id>
-            <phase>generate-sources</phase>
-            <goals>
-              <goal>add-source</goal>
-            </goals>
-            <configuration>
-              <sources>
-                
<source>${project.build.directory}/generated-sources/mahout</source>
-              </sources>
-            </configuration>
-          </execution>
-          <execution>
-            <id>add-test-source</id>
-            <phase>generate-sources</phase>
-            <goals>
-              <goal>add-test-source</goal>
-            </goals>
-            <configuration>
-              <sources>
-                
<source>${project.build.directory}/generated-test-sources/mahout</source>
-              </sources>
-            </configuration>
-          </execution>
-        </executions>
-      </plugin>
-
-      <!-- create test jar so other modules can reuse the math test utility 
classes. -->
+      <!-- create test jar so other modules can reuse the math-scala test 
utility classes. -->
       <plugin>
         <groupId>org.apache.maven.plugins</groupId>
         <artifactId>maven-jar-plugin</artifactId>
@@ -106,47 +61,47 @@
       </plugin>
 
       <plugin>
-        <groupId>org.scala-tools</groupId>
-        <artifactId>maven-scala-plugin</artifactId>
-        <version>2.15.2</version>
+        <groupId>net.alchim31.maven</groupId>
+        <artifactId>scala-maven-plugin</artifactId>
         <executions>
           <execution>
+            <id>add-scala-sources</id>
+            <phase>initialize</phase>
+            <goals>
+              <goal>add-source</goal>
+            </goals>
+          </execution>
+          <execution>
+            <id>scala-compile</id>
+            <phase>process-resources</phase>
             <goals>
               <goal>compile</goal>
+            </goals>
+          </execution>
+          <execution>
+            <id>scala-test-compile</id>
+            <phase>process-test-resources</phase>
+            <goals>
               <goal>testCompile</goal>
             </goals>
           </execution>
         </executions>
-        <configuration>
-          <sourceDir>src/main/scala</sourceDir>
-          <jvmArgs>
-            <jvmArg>-Xms64m</jvmArg>
-            <jvmArg>-Xmx1024m</jvmArg>
-          </jvmArgs>
-        </configuration>
       </plugin>
 
       <!--this is what scalatest recommends to do to enable scala tests -->
 
       <!-- disable surefire -->
-      <!--<plugin>-->
-        <!--<groupId>org.apache.maven.plugins</groupId>-->
-        <!--<artifactId>maven-surefire-plugin</artifactId>-->
-        <!--<version>2.7</version>-->
-        <!--<configuration>-->
-          <!--<skipTests>true</skipTests>-->
-        <!--</configuration>-->
-      <!--</plugin>-->
+      <plugin>
+        <groupId>org.apache.maven.plugins</groupId>
+        <artifactId>maven-surefire-plugin</artifactId>
+        <configuration>
+          <skipTests>true</skipTests>
+        </configuration>
+      </plugin>
       <!-- enable scalatest -->
       <plugin>
         <groupId>org.scalatest</groupId>
         <artifactId>scalatest-maven-plugin</artifactId>
-        <version>1.0-M2</version>
-        <configuration>
-          
<reportsDirectory>${project.build.directory}/scalatest-reports</reportsDirectory>
-          <junitxml>.</junitxml>
-          <filereports>WDF TestSuite.txt</filereports>
-        </configuration>
         <executions>
           <execution>
             <id>test</id>
@@ -172,10 +127,10 @@
       <groupId>log4j</groupId>
       <artifactId>log4j</artifactId>
     </dependency>
-      
+
     <dependency>
       <groupId>com.github.scopt</groupId>
-      <artifactId>scopt_${scala.major}</artifactId>
+      <artifactId>scopt_${scala.compat.version}</artifactId>
       <version>3.3.0</version>
     </dependency>
 
@@ -207,9 +162,7 @@
     </dependency>
     <dependency>
       <groupId>org.scalatest</groupId>
-      <artifactId>scalatest_${scala.major}</artifactId>
-      <version>2.0</version>
-      <scope>test</scope>
+      <artifactId>scalatest_${scala.compat.version}</artifactId>
     </dependency>
 
   </dependencies>

http://git-wip-us.apache.org/repos/asf/mahout/blob/6cf991c6/math/pom.xml
----------------------------------------------------------------------
diff --git a/math/pom.xml b/math/pom.xml
index 624f843..c0edb34 100644
--- a/math/pom.xml
+++ b/math/pom.xml
@@ -37,8 +37,6 @@
   <packaging>jar</packaging>
 
   <build>
-    <defaultGoal>install</defaultGoal>
-
     <plugins>
       <plugin>
         <groupId>org.apache.mahout</groupId>

http://git-wip-us.apache.org/repos/asf/mahout/blob/6cf991c6/pom.xml
----------------------------------------------------------------------
diff --git a/pom.xml b/pom.xml
index ee1dbba..47b080a 100644
--- a/pom.xml
+++ b/pom.xml
@@ -109,7 +109,7 @@
     <hbase.version>1.0.0</hbase.version>
     <lucene.version>4.6.1</lucene.version>
     <slf4j.version>1.7.10</slf4j.version>
-    <scala.major>2.10</scala.major>
+    <scala.compat.version>2.10</scala.compat.version>
     <scala.version>2.10.4</scala.version>
     <spark.version>1.1.1</spark.version>
     <h2o.version>0.1.25</h2o.version>
@@ -194,19 +194,19 @@
       </dependency>
 
       <dependency>
-        <artifactId>mahout-math-scala_${scala.major}</artifactId>
+        <artifactId>mahout-math-scala_${scala.compat.version}</artifactId>
         <groupId>${project.groupId}</groupId>
         <version>${project.version}</version>
       </dependency>
       <dependency>
         <groupId>${project.groupId}</groupId>
         <version>${project.version}</version>
-        <artifactId>mahout-math-scala_${scala.major}</artifactId>
+        <artifactId>mahout-math-scala_${scala.compat.version}</artifactId>
         <classifier>tests</classifier>
       </dependency>
 
       <dependency>
-        <artifactId>mahout-spark_${scala.major}</artifactId>
+        <artifactId>mahout-spark_${scala.compat.version}</artifactId>
         <groupId>${project.groupId}</groupId>
         <version>${project.version}</version>
       </dependency>
@@ -341,6 +341,12 @@
         <version>${lucene.version}</version>
         <scope>test</scope>
       </dependency>
+      <dependency>
+        <groupId>org.scalatest</groupId>
+        <artifactId>scalatest_${scala.compat.version}</artifactId>
+        <version>2.2.4</version>
+        <scope>test</scope>
+      </dependency>
 
       <dependency>
         <groupId>org.codehaus.jackson</groupId>
@@ -666,9 +672,36 @@
           <version>1.8</version>
         </plugin>
         <plugin>
-          <groupId>org.scala-tools</groupId>
-          <artifactId>maven-scala-plugin</artifactId>
-          <version>2.15.2</version>
+          <groupId>net.alchim31.maven</groupId>
+          <artifactId>scala-maven-plugin</artifactId>
+          <version>3.2.0</version>
+          <configuration>
+            <jvmArgs>
+              <jvmArg>-Xms64m</jvmArg>
+              <jvmArg>-Xmx1024m</jvmArg>
+            </jvmArgs>
+            <args>
+              <arg>-target:jvm-${maven.compiler.target}</arg>
+              <arg>-deprecation</arg>
+              <arg>-feature</arg>
+              <arg>-language:existentials</arg>
+              <arg>-language:implicitConversions</arg>
+              <arg>-language:postfixOps</arg>
+            </args>
+            <sourceDir>src/main/scala</sourceDir>
+            <testSourceDir>src/test/scala</testSourceDir>
+          </configuration>
+        </plugin>
+        <plugin>
+          <groupId>org.scalatest</groupId>
+          <artifactId>scalatest-maven-plugin</artifactId>
+          <version>1.0</version>
+          <configuration>
+            
<reportsDirectory>${project.build.directory}/scalatest-reports</reportsDirectory>
+            <junitxml>.</junitxml>
+            <filereports>WDF TestSuite.txt</filereports>
+            <argLine>-Xmx1024m</argLine>
+          </configuration>
         </plugin>
       </plugins>
     </pluginManagement>
@@ -830,6 +863,7 @@
       <id>hadoop1</id>
       <properties>
         <hadoop.classifier>hadoop1</hadoop.classifier>
+        <hadoop.version>2.6.0</hadoop.version>
       </properties>
     </profile>
     <profile>

http://git-wip-us.apache.org/repos/asf/mahout/blob/6cf991c6/spark-shell/pom.xml
----------------------------------------------------------------------
diff --git a/spark-shell/pom.xml b/spark-shell/pom.xml
index 65df401..3297152 100644
--- a/spark-shell/pom.xml
+++ b/spark-shell/pom.xml
@@ -36,116 +36,59 @@
 
   <packaging>jar</packaging>
 
-  <!-- this is needed for scalatest plugin until they publish it to central -->
-  <pluginRepositories>
-    <pluginRepository>
-      <id>sonatype</id>
-      <url>https://oss.sonatype.org/content/groups/public</url>
-      <releases>
-        <enabled>true</enabled>
-      </releases>
-    </pluginRepository>
-  </pluginRepositories>
-
   <build>
-    <defaultGoal>install</defaultGoal>
-
     <plugins>
 
       <plugin>
-        <groupId>org.codehaus.mojo</groupId>
-        <artifactId>build-helper-maven-plugin</artifactId>
+        <artifactId>maven-javadoc-plugin</artifactId>
+      </plugin>
+
+      <plugin>
+        <artifactId>maven-source-plugin</artifactId>
+      </plugin>
+
+      <plugin>
+        <groupId>net.alchim31.maven</groupId>
+        <artifactId>scala-maven-plugin</artifactId>
         <executions>
           <execution>
-            <id>add-source</id>
-            <phase>generate-sources</phase>
+            <id>add-scala-sources</id>
+            <phase>initialize</phase>
             <goals>
               <goal>add-source</goal>
             </goals>
-            <configuration>
-              <sources>
-                
<source>${project.build.directory}/generated-sources/mahout</source>
-              </sources>
-            </configuration>
           </execution>
           <execution>
-            <id>add-test-source</id>
-            <phase>generate-sources</phase>
+            <id>scala-compile</id>
+            <phase>process-resources</phase>
             <goals>
-              <goal>add-test-source</goal>
+              <goal>compile</goal>
             </goals>
-            <configuration>
-              <sources>
-                
<source>${project.build.directory}/generated-test-sources/mahout</source>
-              </sources>
-            </configuration>
           </execution>
-        </executions>
-      </plugin>
-
-      <!-- create test jar so other modules can reuse the math test utility 
classes. -->
-      <plugin>
-        <groupId>org.apache.maven.plugins</groupId>
-        <artifactId>maven-jar-plugin</artifactId>
-        <executions>
           <execution>
+            <id>scala-test-compile</id>
+            <phase>process-test-resources</phase>
             <goals>
-              <goal>test-jar</goal>
+              <goal>testCompile</goal>
             </goals>
-            <phase>package</phase>
           </execution>
         </executions>
       </plugin>
 
-      <plugin>
-        <artifactId>maven-javadoc-plugin</artifactId>
-      </plugin>
-
-      <plugin>
-        <artifactId>maven-source-plugin</artifactId>
-      </plugin>
+      <!--this is what scalatest recommends to do to enable scala tests -->
 
+      <!-- disable surefire -->
       <plugin>
-        <groupId>org.scala-tools</groupId>
-        <artifactId>maven-scala-plugin</artifactId>
-        <executions>
-          <execution>
-            <goals>
-              <goal>compile</goal>
-              <goal>testCompile</goal>
-            </goals>
-          </execution>
-        </executions>
+        <groupId>org.apache.maven.plugins</groupId>
+        <artifactId>maven-surefire-plugin</artifactId>
         <configuration>
-          <sourceDir>src/main/scala</sourceDir>
-          <jvmArgs>
-            <jvmArg>-Xms64m</jvmArg>
-            <jvmArg>-Xmx1024m</jvmArg>
-          </jvmArgs>
+          <skipTests>true</skipTests>
         </configuration>
       </plugin>
-
-      <!--this is what scalatest recommends to do to enable scala tests -->
-
-      <!-- disable surefire -->
-      <!--<plugin>-->
-      <!--<groupId>org.apache.maven.plugins</groupId>-->
-      <!--<artifactId>maven-surefire-plugin</artifactId>-->
-      <!--<version>2.7</version>-->
-      <!--<configuration>-->
-      <!--<skipTests>true</skipTests>-->
-      <!--</configuration>-->
-      <!--</plugin>-->
       <!-- enable scalatest -->
       <plugin>
         <groupId>org.scalatest</groupId>
         <artifactId>scalatest-maven-plugin</artifactId>
-        <version>1.0-M2</version>
-        <configuration>
-          
<reportsDirectory>${project.build.directory}/scalatest-reports</reportsDirectory>
-          <junitxml>.</junitxml>
-          <filereports>WDF TestSuite.txt</filereports>
-        </configuration>
         <executions>
           <execution>
             <id>test</id>
@@ -165,32 +108,30 @@
 
     <dependency>
       <groupId>org.apache.mahout</groupId>
-      <artifactId>mahout-spark_${scala.major}</artifactId>
+      <artifactId>mahout-spark_${scala.compat.version}</artifactId>
     </dependency>
 
     <dependency>
       <groupId>org.apache.mahout</groupId>
-      <artifactId>mahout-math-scala_${scala.major}</artifactId>
+      <artifactId>mahout-math-scala_${scala.compat.version}</artifactId>
       <classifier>tests</classifier>
       <scope>test</scope>
     </dependency>
 
 
     <!--  3rd-party -->
-    
+
     <!-- Spark stuff -->
     <dependency>
       <groupId>org.apache.spark</groupId>
-      <artifactId>spark-repl_${scala.major}</artifactId>
+      <artifactId>spark-repl_${scala.compat.version}</artifactId>
       <version>${spark.version}</version>
     </dependency>
 
     <!-- scala stuff -->
     <dependency>
       <groupId>org.scalatest</groupId>
-      <artifactId>scalatest_2.10</artifactId>
-      <version>2.0</version>
-      <scope>test</scope>
+      <artifactId>scalatest_${scala.compat.version}</artifactId>
     </dependency>
 
   </dependencies>

http://git-wip-us.apache.org/repos/asf/mahout/blob/6cf991c6/spark/pom.xml
----------------------------------------------------------------------
diff --git a/spark/pom.xml b/spark/pom.xml
index 2af2cc8..cf4aaaa 100644
--- a/spark/pom.xml
+++ b/spark/pom.xml
@@ -36,117 +36,59 @@
 
   <packaging>jar</packaging>
 
-  <!-- this is needed for scalatest plugin until they publish it to central -->
-  <pluginRepositories>
-    <pluginRepository>
-      <id>sonatype</id>
-      <url>https://oss.sonatype.org/content/groups/public</url>
-      <releases>
-        <enabled>true</enabled>
-      </releases>
-    </pluginRepository>
-  </pluginRepositories>
-
   <build>
-    <defaultGoal>install</defaultGoal>
-
     <plugins>
 
       <plugin>
-        <groupId>org.codehaus.mojo</groupId>
-        <artifactId>build-helper-maven-plugin</artifactId>
+        <artifactId>maven-javadoc-plugin</artifactId>
+      </plugin>
+
+      <plugin>
+        <artifactId>maven-source-plugin</artifactId>
+      </plugin>
+
+      <plugin>
+        <groupId>net.alchim31.maven</groupId>
+        <artifactId>scala-maven-plugin</artifactId>
         <executions>
           <execution>
-            <id>add-source</id>
-            <phase>generate-sources</phase>
+            <id>add-scala-sources</id>
+            <phase>initialize</phase>
             <goals>
               <goal>add-source</goal>
             </goals>
-            <configuration>
-              <sources>
-                
<source>${project.build.directory}/generated-sources/mahout</source>
-              </sources>
-            </configuration>
           </execution>
           <execution>
-            <id>add-test-source</id>
-            <phase>generate-sources</phase>
+            <id>scala-compile</id>
+            <phase>process-resources</phase>
             <goals>
-              <goal>add-test-source</goal>
+              <goal>compile</goal>
             </goals>
-            <configuration>
-              <sources>
-                
<source>${project.build.directory}/generated-test-sources/mahout</source>
-              </sources>
-            </configuration>
           </execution>
-        </executions>
-      </plugin>
-
-      <!-- create test jar so other modules can reuse the math test utility 
classes. -->
-      <plugin>
-        <groupId>org.apache.maven.plugins</groupId>
-        <artifactId>maven-jar-plugin</artifactId>
-        <executions>
           <execution>
+            <id>scala-test-compile</id>
+            <phase>process-test-resources</phase>
             <goals>
-              <goal>test-jar</goal>
+              <goal>testCompile</goal>
             </goals>
-            <phase>package</phase>
           </execution>
         </executions>
       </plugin>
 
-      <plugin>
-        <artifactId>maven-javadoc-plugin</artifactId>
-      </plugin>
-
-      <plugin>
-        <artifactId>maven-source-plugin</artifactId>
-      </plugin>
+      <!--this is what scalatest recommends to do to enable scala tests -->
 
+      <!-- disable surefire -->
       <plugin>
-        <groupId>org.scala-tools</groupId>
-        <artifactId>maven-scala-plugin</artifactId>
-        <executions>
-          <execution>
-            <goals>
-              <goal>compile</goal>
-              <goal>testCompile</goal>
-            </goals>
-          </execution>
-        </executions>
+        <groupId>org.apache.maven.plugins</groupId>
+        <artifactId>maven-surefire-plugin</artifactId>
         <configuration>
-          <sourceDir>src/main/scala</sourceDir>
-          <jvmArgs>
-            <jvmArg>-Xms64m</jvmArg>
-            <jvmArg>-Xmx1024m</jvmArg>
-          </jvmArgs>
+          <skipTests>true</skipTests>
         </configuration>
       </plugin>
-
-      <!--this is what scalatest recommends to do to enable scala tests -->
-
-      <!-- disable surefire -->
-      <!--<plugin>-->
-      <!--<groupId>org.apache.maven.plugins</groupId>-->
-      <!--<artifactId>maven-surefire-plugin</artifactId>-->
-      <!--<version>2.7</version>-->
-      <!--<configuration>-->
-      <!--<skipTests>true</skipTests>-->
-      <!--</configuration>-->
-      <!--</plugin>-->
       <!-- enable scalatest -->
       <plugin>
         <groupId>org.scalatest</groupId>
         <artifactId>scalatest-maven-plugin</artifactId>
-        <version>1.0-M2</version>
-        <configuration>
-          
<reportsDirectory>${project.build.directory}/scalatest-reports</reportsDirectory>
-          <junitxml>.</junitxml>
-          <filereports>WDF TestSuite.txt</filereports>
-          <argLine>-Xmx1024m</argLine>
-        </configuration>
         <executions>
           <execution>
             <id>test</id>
@@ -290,13 +232,13 @@
     <!-- spark stuff - need to put this first to use spark's mahout 
dependencies in tests -->
     <dependency>
       <groupId>org.apache.spark</groupId>
-      <artifactId>spark-core_${scala.major}</artifactId>
+      <artifactId>spark-core_${scala.compat.version}</artifactId>
       <version>${spark.version}</version>
     </dependency>
 
     <dependency>
       <groupId>org.apache.mahout</groupId>
-      <artifactId>mahout-math-scala_${scala.major}</artifactId>
+      <artifactId>mahout-math-scala_${scala.compat.version}</artifactId>
     </dependency>
 
     <dependency>
@@ -312,7 +254,7 @@
 
     <dependency>
       <groupId>org.apache.mahout</groupId>
-      <artifactId>mahout-math-scala_${scala.major}</artifactId>
+      <artifactId>mahout-math-scala_${scala.compat.version}</artifactId>
       <classifier>tests</classifier>
       <scope>test</scope>
     </dependency>
@@ -327,9 +269,7 @@
     <!-- scala stuff -->
     <dependency>
       <groupId>org.scalatest</groupId>
-      <artifactId>scalatest_${scala.major}</artifactId>
-      <version>2.0</version>
-      <scope>test</scope>
+      <artifactId>scalatest_${scala.compat.version}</artifactId>
     </dependency>
 
   </dependencies>

Reply via email to