Skip to content

Commit

Permalink
Merge pull request #247 from ngageoint/GEOWAVE-234
Browse files Browse the repository at this point in the history
Geowave 234
  • Loading branch information
jwomeara committed Feb 26, 2015
2 parents 657f5b4 + 12d2f8e commit d2ae074
Show file tree
Hide file tree
Showing 20 changed files with 216 additions and 26 deletions.
2 changes: 1 addition & 1 deletion docs/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
<artifactId>geowave-parent</artifactId>
<groupId>mil.nga.giat</groupId>
<relativePath>../</relativePath>
<version>0.8.3-SNAPSHOT</version>
<version>0.8.3</version>
</parent>

<artifactId>geowave-docs</artifactId>
Expand Down
2 changes: 1 addition & 1 deletion geowave-accumulo/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<artifactId>geowave-parent</artifactId>
<groupId>mil.nga.giat</groupId>
<relativePath>../</relativePath>
<version>0.8.3-SNAPSHOT</version>
<version>0.8.3</version>
</parent>
<artifactId>geowave-accumulo</artifactId>
<name>geowave-accumulo</name>
Expand Down
2 changes: 1 addition & 1 deletion geowave-analytics/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
<artifactId>geowave-parent</artifactId>
<groupId>mil.nga.giat</groupId>
<relativePath>../</relativePath>
<version>0.8.3-SNAPSHOT</version>
<version>0.8.3</version>
</parent>
<artifactId>geowave-analytics</artifactId>
<dependencies>
Expand Down
2 changes: 1 addition & 1 deletion geowave-benchmark/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
<artifactId>geowave-parent</artifactId>
<groupId>mil.nga.giat</groupId>
<relativePath>../</relativePath>
<version>0.8.3-SNAPSHOT</version>
<version>0.8.3</version>
</parent>
<artifactId>geowave-benchmark</artifactId>
<name>geowave-benchmark</name>
Expand Down
6 changes: 3 additions & 3 deletions geowave-client/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
<artifactId>geowave-parent</artifactId>
<groupId>mil.nga.giat</groupId>
<relativePath>../</relativePath>
<version>0.8.3-SNAPSHOT</version>
<version>0.8.3</version>
</parent>
<artifactId>geowave-client</artifactId>
<name>geowave-client</name>
Expand All @@ -28,7 +28,7 @@
<dependency>
<groupId>org.glassfish.jersey.media</groupId>
<artifactId>jersey-media-multipart</artifactId>
<version>2.13</version>
<version>2.14</version>
</dependency>
<dependency>
<groupId>org.glassfish.jersey.core</groupId>
Expand All @@ -38,7 +38,7 @@
<dependency>
<groupId>org.glassfish.jersey.ext</groupId>
<artifactId>jersey-proxy-client</artifactId>
<version>2.13</version>
<version>2.14</version>
</dependency>
</dependencies>
</project>
7 changes: 6 additions & 1 deletion geowave-deploy/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<artifactId>geowave-parent</artifactId>
<groupId>mil.nga.giat</groupId>
<relativePath>../</relativePath>
<version>0.8.3-SNAPSHOT</version>
<version>0.8.3</version>
</parent>
<artifactId>geowave-deploy</artifactId>
<name>geowave-deploy</name>
Expand All @@ -23,6 +23,11 @@
<artifactId>geowave-raster</artifactId>
<version>${project.version}</version>
</dependency>
<dependency>
<groupId>mil.nga.giat</groupId>
<artifactId>geowave-utils</artifactId>
<version>${project.version}</version>
</dependency>
</dependencies>
<build>
<resources>
Expand Down
2 changes: 1 addition & 1 deletion geowave-examples/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
<parent>
<groupId>mil.nga.giat</groupId>
<artifactId>geowave-parent</artifactId>
<version>0.8.3-SNAPSHOT</version>
<version>0.8.3</version>
</parent>
<artifactId>geowave-examples</artifactId>
<dependencies>
Expand Down
2 changes: 1 addition & 1 deletion geowave-index/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<artifactId>geowave-parent</artifactId>
<groupId>mil.nga.giat</groupId>
<relativePath>../</relativePath>
<version>0.8.3-SNAPSHOT</version>
<version>0.8.3</version>
</parent>
<artifactId>geowave-index</artifactId>
<name>geowave-index</name>
Expand Down
2 changes: 1 addition & 1 deletion geowave-ingest/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
<artifactId>geowave-parent</artifactId>
<groupId>mil.nga.giat</groupId>
<relativePath>../</relativePath>
<version>0.8.3-SNAPSHOT</version>
<version>0.8.3</version>
</parent>
<artifactId>geowave-ingest</artifactId>
<name>geowave-ingest</name>
Expand Down
2 changes: 1 addition & 1 deletion geowave-raster/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
<artifactId>geowave-parent</artifactId>
<groupId>mil.nga.giat</groupId>
<relativePath>../</relativePath>
<version>0.8.3-SNAPSHOT</version>
<version>0.8.3</version>
</parent>
<artifactId>geowave-raster</artifactId>
<name>geowave-raster</name>
Expand Down
6 changes: 3 additions & 3 deletions geowave-services/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
<artifactId>geowave-parent</artifactId>
<groupId>mil.nga.giat</groupId>
<relativePath>../</relativePath>
<version>0.8.3-SNAPSHOT</version>
<version>0.8.3</version>
</parent>
<artifactId>geowave-services</artifactId>
<packaging>war</packaging>
Expand Down Expand Up @@ -39,12 +39,12 @@
<dependency>
<groupId>org.glassfish.jersey.containers</groupId>
<artifactId>jersey-container-servlet</artifactId>
<version>2.13</version>
<version>2.14</version>
</dependency>
<dependency>
<groupId>org.glassfish.jersey.media</groupId>
<artifactId>jersey-media-json-jackson</artifactId>
<version>2.13</version>
<version>2.14</version>
</dependency>
</dependencies>
</project>
2 changes: 1 addition & 1 deletion geowave-store/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<artifactId>geowave-parent</artifactId>
<groupId>mil.nga.giat</groupId>
<relativePath>../</relativePath>
<version>0.8.3-SNAPSHOT</version>
<version>0.8.3</version>
</parent>
<artifactId>geowave-store</artifactId>
<name>geowave-store</name>
Expand Down
2 changes: 1 addition & 1 deletion geowave-test/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
<artifactId>geowave-parent</artifactId>
<groupId>mil.nga.giat</groupId>
<relativePath>../</relativePath>
<version>0.8.3-SNAPSHOT</version>
<version>0.8.3</version>
</parent>
<artifactId>geowave-test</artifactId>
<name>geowave-test</name>
Expand Down
2 changes: 1 addition & 1 deletion geowave-types/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<parent>
<groupId>mil.nga.giat</groupId>
<artifactId>geowave-parent</artifactId>
<version>0.8.3-SNAPSHOT</version>
<version>0.8.3</version>
</parent>
<artifactId>geowave-types</artifactId>
<dependencies>
Expand Down
83 changes: 77 additions & 6 deletions geowave-utils/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
<artifactId>geowave-parent</artifactId>
<groupId>mil.nga.giat</groupId>
<relativePath>../</relativePath>
<version>0.8.3-SNAPSHOT</version>
<version>0.8.3</version>
</parent>
<artifactId>geowave-utils</artifactId>
<name>geowave-utils</name>
Expand All @@ -14,6 +14,12 @@
<groupId>mil.nga.giat</groupId>
<artifactId>geowave-accumulo</artifactId>
<version>${project.version}</version>
<exclusions>
<exclusion>
<artifactId>jersey-core</artifactId>
<groupId>com.sun.jersey</groupId>
</exclusion>
</exclusions>
</dependency>
<dependency>
<groupId>mil.nga.giat</groupId>
Expand All @@ -26,11 +32,76 @@
<version>${project.version}</version>
</dependency>
<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<version>3.8.1</version>
<scope>test</scope>
<groupId>org.apache.accumulo</groupId>
<artifactId>accumulo-minicluster</artifactId>
<version>${accumulo.version}</version>
<exclusions>
<exclusion>
<groupId>org.slf4j</groupId>
<artifactId>*</artifactId>
</exclusion>
<exclusion>
<artifactId>jersey-core</artifactId>
<groupId>com.sun.jersey</groupId>
</exclusion>
</exclusions>
</dependency>
</dependencies>

<build>
<plugins>
<plugin>
<groupId>org.sonatype.plugins</groupId>
<artifactId>munge-maven-plugin</artifactId>
<version>1.0</version>
<executions>
<execution>
<id>munge</id>
<phase>generate-sources</phase>
<goals>
<goal>munge</goal>
</goals>
<configuration>
<symbols>ACCUMULO_${accumulo.version}</symbols>
</configuration>
</execution>
</executions>
</plugin>
</plugins>
<pluginManagement>
<plugins>
<!--This plugin's configuration is used to store Eclipse m2e settings
only. It has no influence on the Maven build itself. -->
<plugin>
<groupId>org.eclipse.m2e</groupId>
<artifactId>lifecycle-mapping</artifactId>
<version>1.0.0</version>
<configuration>
<lifecycleMappingMetadata>
<pluginExecutions>
<pluginExecution>
<pluginExecutionFilter>
<groupId>
org.sonatype.plugins
</groupId>
<artifactId>
munge-maven-plugin
</artifactId>
<versionRange>
[1.0,)
</versionRange>
<goals>
<goal>munge</goal>
</goals>
</pluginExecutionFilter>
<action>
<ignore />
</action>
</pluginExecution>
</pluginExecutions>
</lifecycleMappingMetadata>
</configuration>
</plugin>
</plugins>
</pluginManagement>
</build>
</project>
Original file line number Diff line number Diff line change
@@ -0,0 +1,78 @@
package mil.nga.giat.geowave.demo.app;

import com.google.common.io.Files;

import org.apache.accumulo.minicluster.MiniAccumuloCluster;
import org.apache.accumulo.minicluster.MiniAccumuloConfig;
import org.apache.log4j.Level;
import org.apache.log4j.Logger;

import java.io.File;
import java.util.concurrent.TimeUnit;

public class GeoWaveDemoApp
{

public static void main(
String[] args )
throws Exception {
Logger.getRootLogger().setLevel(
Level.WARN);

final boolean interactive = (System.getProperty("interactive") != null) ? Boolean.parseBoolean(System.getProperty("interactive")) : true;
final String instanceName = (System.getProperty("instanceName") != null) ? System.getProperty("instanceName") : "geowave";
final String password = (System.getProperty("password") != null) ? System.getProperty("password") : "password";

File tempDir = Files.createTempDir();
// @formatter:off
/*if[ACCUMULO_1.5.1]
final MiniAccumuloCluster accumulo = new MiniAccumuloCluster(
new MiniAccumuloConfig(
tempDir,
password).setNumTservers(
2));
else[ACCUMULO_1.5.1]*/
final MiniAccumuloCluster accumulo = new MiniAccumuloCluster(
new MiniAccumuloConfig(
tempDir,
password).setNumTservers(
2).setInstanceName(
instanceName).setZooKeeperPort(
2181));
/*end[ACCUMULO_1.5.1]*/
// @formatter:on
accumulo.start();
System.out.println("starting up ...");
Thread.sleep(3000);

System.out.println("cluster running with instance name " + accumulo.getInstanceName() + " and zookeepers " + accumulo.getZooKeepers());

if (interactive) {
System.out.println("hit Enter to shutdown ..");
System.in.read();
System.out.println("Shutting down!");
accumulo.stop();
}
else {
Runtime.getRuntime().addShutdownHook(
new Thread() {
@Override
public void run() {
try {
accumulo.stop();
}
catch (Exception e) {
System.out.println("Error shutting down accumulo.");
}
System.out.println("Shutting down!");
}
});

while (true) {
Thread.sleep(TimeUnit.MILLISECONDS.convert(
Long.MAX_VALUE,
TimeUnit.DAYS));
}
}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
package mil.nga.giat.geowave.demo.app;

import org.apache.accumulo.core.util.shell.Shell;
import org.apache.log4j.Level;
import org.apache.log4j.Logger;

import java.io.IOException;

public class GeoWaveDemoAppShell
{

public static void main(
String[] args )
throws IOException {
Logger.getRootLogger().setLevel(
Level.WARN);

final String instanceName = (System.getProperty("instanceName") != null) ? System.getProperty("instanceName") : "geowave";
final String password = (System.getProperty("password") != null) ? System.getProperty("password") : "password";

String[] shellArgs = new String[] {
"-u",
"root",
"-p",
password,
"-z",
instanceName,
"localhost:2181"
};
Shell.main(shellArgs);
}
}
4 changes: 4 additions & 0 deletions geowave-utils/src/test/java/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
# Ignore everything in this directory
*
# Except this file
!.gitignore
Loading

0 comments on commit d2ae074

Please sign in to comment.