Closes #94 - Update pom to use new Fluo parent 96/head
authorMike Walch <mwalch@gmail.com>
Tue, 26 Jul 2016 13:54:42 +0000 (09:54 -0400)
committerMike Walch <mwalch@gmail.com>
Tue, 26 Jul 2016 19:22:19 +0000 (15:22 -0400)
* Converted a do-while statemnt to while to avoid checkstyle error
* Fix properties in POM used to start MiniAccumulo instance
* Updated snapshots repo to Apache server

modules/spark/src/main/java/org/apache/fluo/recipes/spark/FluoSparkHelper.java
pom.xml

index a24aa48..ae57e91 100644 (file)
@@ -275,13 +275,18 @@ public class FluoSparkHelper {
     }
   }
 
+  private Path getPossibleTempDir() {
+    return new Path(tempBaseDir.toString() + "/" + tempDirCounter.getAndIncrement());
+  }
+
   private Path getTempDir(BulkImportOptions opts) {
     Path tempDir;
     if (opts.tempDir == null) {
       try {
-        do {
-          tempDir = new Path(tempBaseDir.toString() + "/" + tempDirCounter.getAndIncrement());
-        } while (hdfs.exists(tempDir));
+        tempDir = getPossibleTempDir();
+        while (hdfs.exists(tempDir)) {
+          tempDir = getPossibleTempDir();
+        }
       } catch (IOException e) {
         throw new IllegalStateException(e);
       }
diff --git a/pom.xml b/pom.xml
index 9a90a1d..430e67f 100644 (file)
--- a/pom.xml
+++ b/pom.xml
@@ -16,9 +16,9 @@
 <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
   <modelVersion>4.0.0</modelVersion>
   <parent>
-    <groupId>io.fluo</groupId>
-    <artifactId>fluo-io-parent</artifactId>
-    <version>2</version>
+    <groupId>org.apache.fluo</groupId>
+    <artifactId>fluo-parent</artifactId>
+    <version>1-SNAPSHOT</version>
   </parent>
   <groupId>org.apache.fluo</groupId>
   <artifactId>fluo-recipes-parent</artifactId>
       </dependency>
     </dependencies>
   </dependencyManagement>
-  <repositories>
-    <repository>
-      <releases>
-        <enabled>false</enabled>
-        <updatePolicy>never</updatePolicy>
-        <checksumPolicy>fail</checksumPolicy>
-      </releases>
-      <snapshots>
-        <enabled>true</enabled>
-        <updatePolicy>daily</updatePolicy>
-        <checksumPolicy>fail</checksumPolicy>
-      </snapshots>
-      <id>sonatype-nexus-snapshots</id>
-      <url>https://oss.sonatype.org/content/repositories/snapshots</url>
-    </repository>
-  </repositories>
   <build>
     <pluginManagement>
       <plugins>
           <artifactId>maven-failsafe-plugin</artifactId>
           <configuration>
             <systemPropertyVariables>
-              <org.apache.fluo.it.instance.name>it-instance-maven</org.apache.fluo.it.instance.name>
-              <org.apache.fluo.it.instance.clear>false</org.apache.fluo.it.instance.clear>
+              <fluo.it.instance.name>it-instance-maven</fluo.it.instance.name>
+              <fluo.it.instance.clear>false</fluo.it.instance.clear>
             </systemPropertyVariables>
           </configuration>
         </plugin>
       <plugin>
         <groupId>org.apache.maven.plugins</groupId>
         <artifactId>maven-dependency-plugin</artifactId>
-        <version>2.10</version>
         <executions>
           <execution>
             <id>analyze</id>