Skip to content

Commit

Permalink
fix dependency issues and upgrade to gt 23 to make geoscript work
Browse files Browse the repository at this point in the history
  • Loading branch information
moovida committed Apr 26, 2020
1 parent b50234a commit 238ee18
Show file tree
Hide file tree
Showing 10 changed files with 43 additions and 54 deletions.
8 changes: 8 additions & 0 deletions apps/src/main/java/org/hortonmachine/nww/SimpleNwwViewer.java
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,8 @@
import org.hortonmachine.nww.gui.NwwPanel;
import org.hortonmachine.nww.gui.ToolsPanelController;
import org.hortonmachine.nww.gui.ViewControlsLayer;
import org.hortonmachine.nww.layers.defaults.raster.OepnvkarteLayer;
import org.hortonmachine.nww.layers.defaults.raster.OpenTopoLayer;

import gov.nasa.worldwind.Configuration;
import gov.nasa.worldwind.avlist.AVKey;
Expand Down Expand Up @@ -63,6 +65,12 @@ public static ToolsPanelController openNww( String appName, int onCloseAction )
wwjPanel = (NwwPanel) nwwComponent;
((Component) wwjPanel.getWwd()).setPreferredSize(new Dimension(500, 500));
wwjPanel.addOsmLayer();
OpenTopoLayer openTopoLayer = new OpenTopoLayer();
openTopoLayer.setEnabled(false);
wwjPanel.addLayer(openTopoLayer);
OepnvkarteLayer oepnvLayer = new OepnvkarteLayer();
oepnvLayer.setEnabled(false);
wwjPanel.addLayer(oepnvLayer);
ViewControlsLayer viewControls = wwjPanel.addViewControls();
viewControls.setScale(1.5);

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -214,7 +214,7 @@ protected void downloadTexture( final MercatorTextureTile tile ) {

Retriever retriever;

if ("http".equalsIgnoreCase(url.getProtocol())) {
if (url.getProtocol().toLowerCase().startsWith("http")) {
retriever = new HTTPRetriever(url, new DownloadPostProcessor(tile, this));
retriever.setValue(URLRetriever.EXTRACT_ZIP_ENTRY, "true"); // supports legacy layers
} else if ("file".equalsIgnoreCase(url.getProtocol())) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ private static LevelSet makeLevels() {

params.setValue(AVKey.TILE_WIDTH, 256);
params.setValue(AVKey.TILE_HEIGHT, 256);
params.setValue(AVKey.DATA_CACHE_NAME, "Earth/OSM-Mercator/OpenStreetMap Mapnik");
params.setValue(AVKey.DATA_CACHE_NAME, "Earth/OSM-Mercator/OpenStreetMap OpentopoMap");
params.setValue(AVKey.SERVICE, "https://tile.openstreetmap.org/");
params.setValue(AVKey.DATASET_NAME, "h");
params.setValue(AVKey.FORMAT_SUFFIX, ".png");
Expand Down
2 changes: 1 addition & 1 deletion extras/deploy/quiet-logging.properties
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
handlers=java.util.logging.ConsoleHandler
.level=OFF
.level=SEVERE
7 changes: 0 additions & 7 deletions gears/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -47,12 +47,6 @@
</exclusion>
</exclusions>
</dependency>
<dependency>
<groupId>org.javassist</groupId>
<artifactId>javassist</artifactId>
<version>3.20.0-GA</version>
</dependency>

<dependency>
<groupId>com.github.mreutegg</groupId>
<artifactId>laszip4j</artifactId>
Expand All @@ -62,7 +56,6 @@
<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<version>4.5</version>
<scope>test</scope>
</dependency>

Expand Down
1 change: 0 additions & 1 deletion hmachine/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,6 @@
<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<version>4.5</version>
<scope>test</scope>
</dependency>
</dependencies>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,8 @@
import org.geotools.coverage.grid.GridCoverage2D;
import org.geotools.data.simple.SimpleFeatureCollection;
import org.geotools.feature.DefaultFeatureCollection;
import org.hortonmachine.gears.io.rasterreader.OmsRasterReader;
import org.hortonmachine.gears.io.vectorreader.OmsVectorReader;
import org.hortonmachine.gears.libs.exceptions.ModelsIllegalargumentException;
import org.hortonmachine.gears.libs.modules.HMModel;
import org.hortonmachine.gears.utils.features.FeatureUtilities;
Expand Down Expand Up @@ -182,13 +184,21 @@ public void process() throws Exception {
*/
junctionElevatioAttributeName = FeatureUtilities.findAttributeName(inJunctions.getSchema(),
Junctions.ELEVATION.getAttributeName());
if (junctionElevatioAttributeName == null) {
throw new ModelsIllegalargumentException(
"The junctions layer is missing the " + Junctions.ELEVATION.getAttributeName() + " attribute.", this);
}
String junctionIDAttributeName = FeatureUtilities.findAttributeName(inJunctions.getSchema(),
Junctions.ID.getAttributeName());
pipesStartNodeAttributeName = FeatureUtilities.findAttributeName(inPipes.getSchema(),
Pipes.START_NODE.getAttributeName());
pipesEndNodeAttributeName = FeatureUtilities.findAttributeName(inPipes.getSchema(), Pipes.END_NODE.getAttributeName());
pipesIdAttributeName = FeatureUtilities.findAttributeName(inPipes.getSchema(), Pipes.ID.getAttributeName());
lengthAttributeName = FeatureUtilities.findAttributeName(inPipes.getSchema(), Pipes.LENGTH.getAttributeName());
if (lengthAttributeName == null) {
throw new ModelsIllegalargumentException(
"The pipes layer is missing the " + Pipes.LENGTH.getAttributeName() + " attribute.", this);
}

String tanksIDAttributeName = null;
if (inTanks != null) {
Expand Down Expand Up @@ -462,5 +472,4 @@ private void appendWarning( String... msgs ) {
}
warningBuilder.append("\n");
}

}
7 changes: 0 additions & 7 deletions lesto/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -21,13 +21,6 @@
<version>0.9.11</version>
</dependency>

<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<version>4.5</version>
<scope>test</scope>
</dependency>

</dependencies>

</project>
8 changes: 0 additions & 8 deletions modules/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -25,14 +25,6 @@
<groupId>com.github.docker-java</groupId>
<artifactId>docker-java</artifactId>
</dependency>



<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<version>3.8.1</version>
<scope>test</scope>
</dependency>
</dependencies>
</project>
49 changes: 22 additions & 27 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -22,18 +22,18 @@
</modules>

<properties>
<gt.version>22.3</gt.version>
<groovy.version>3.0.0-rc-3</groovy.version>
<gt.version>23.0</gt.version>
<groovy.version>3.0.1</groovy.version>
<geoscript.version>1.14.0</geoscript.version>

<c3p0.version>0.9.5.5</c3p0.version>
<h2gis.version>1.5.0</h2gis.version>
<sqlitejdbc.version>3.30.1</sqlitejdbc.version>
<jt.version>1.5.0</jt.version>

<imageio.ext.version>1.1.25</imageio.ext.version>
<imageio.ext.version>1.3.2</imageio.ext.version>
<jts.version>1.16.1</jts.version>
<jaiext.version>1.1.1</jaiext.version>
<jaiext.version>1.1.14</jaiext.version>
<jackson.version>2.9.8</jackson.version>

<jdk.version>8</jdk.version>
Expand Down Expand Up @@ -680,6 +680,14 @@

<dependency><groupId>com.miglayout</groupId><artifactId>miglayout</artifactId><version>3.7.4</version></dependency>



<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<version>4.10</version>
<scope>test</scope>
</dependency>

</dependencies>
</dependencyManagement>
Expand Down Expand Up @@ -709,14 +717,16 @@
</snapshots>
</repository>

<repository>
<snapshots>
<enabled>false</enabled>
</snapshots>
<id>osgeo</id>
<name>Open Source Geospatial Foundation Repository</name>
<url>http://download.osgeo.org/webdav/geotools/</url>
</repository>
<repository>
<id>osgeo</id>
<name>OSGeo Nexus Release Repository</name>
<url>https://repo.osgeo.org/repository/release/</url>
<!-- contains release (including third-party-dependences) -->
<!-- ucar (https://artifacts.unidata.ucar.edu/content/repositories/unidata-releases) -->
<!-- geosolutions (http://maven.geo-solutions.it/) -->
<snapshots><enabled>false</enabled></snapshots>
<releases><enabled>true</enabled></releases>
</repository>

<repository>
<snapshots>
Expand All @@ -736,21 +746,6 @@
<url>http://oss.sonatype.org/content/repositories/snapshots</url>
</repository>

<repository>
<!-- contains snapshot and release (including third-party-dependences) -->
<!-- Restlet maven Repository (http://maven.restlet.org) -->
<!-- ucar (https://artifacts.unidata.ucar.edu/content/repositories/unidata-releases) -->
<!-- geosolutions (http://maven.geo-solutions.it/) -->
<snapshots>
<enabled>true</enabled>
</snapshots>
<releases>
<enabled>true</enabled>
</releases>
<id>boundless</id>
<name>Boundless Maven Repository</name>
<url>https://repo.boundlessgeo.com/main/</url>
</repository>

<repository>
<id>jzy3d-releases</id>
Expand Down

0 comments on commit 238ee18

Please sign in to comment.