Questions tagged [java]
An object-oriented cross-platform programming language developed by Sun Microsystems.
902 questions
- Bountied 0
- Unanswered
- Frequent
- Score
- Trending
- Week
- Month
- Unanswered (my tags)
0
votes
0
answers
27
views
Upgrade GeoServer from 2.13 to?
GeoServer 2.13.0 binary/jetty version running on Ubuntu 18.04.
I'd like to upgrade. I've installed OpenJDK 11 but it's not activated. I have GWC. Which version can I safely/easily upgrade to? I see 2....
1
vote
2
answers
64
views
Retrieving complex features from WFS request using org.geotools
I'm currently working on a client application written in Java, using the org.geotools library in version 33.2 (released July 17th 2025) to request Features from a WFS layer.
The code below establishes ...
2
votes
1
answer
57
views
How do I install GDAL for Java on Windows 10 (to use with Eclipse)?
I want to use GDAL in a Java project in Eclipse but I just can't find any new-ish information about how to install it on Windows 10.
This answer (2013) mentions four .so files but I don't know where ...
1
vote
1
answer
34
views
Polygonizing GeoTiIFF with GDAL Java Bindings
I want to translate the following GDAL command line expression into Java code, using the Polygonize() method in the GDAL Java bindings:
gdal_polygonize -b 1 -mask outcome.tif outcome.tif outline....
0
votes
0
answers
41
views
Maxent CSV "Error reading file [file path]: java.lang.ArrayIndexOutOfBoundsException: -1758671516"
I have in the past few months successfully run 10-15 MaxEnt models using the maxent.jar java system. But in the past few days, I have recieved the following error each time I run the modeling software,...
3
votes
1
answer
53
views
Making a GeoTIFF with Java8 and geotools 28 -- longitude should be negative
I'm trying to make a GeoTIFF file with an envelope at longitude -124.1. It works, but when I load the file into QGIS, all of the longitudes are positive. At a point that should have longitude -124.05, ...
2
votes
0
answers
30
views
Java GDAL: how to call GetDataAxisToSRSAxisMapping
The Java GDAL bindings provide the method
public int[] GetDataAxisToSRSAxisMapping(SWIGTYPE_p_int nLen, SWIGTYPE_p_p_int pList)
but the method is not documented: Java Docs for ...
0
votes
0
answers
49
views
PostGIS cache lookup failed after database restore in integration tests
I’m facing an issue with PostGIS when running integration tests in a Quarkus-based application. The application includes geospatial data (e.g., airports with GeoFence geometries) and uses PostGIS for ...
0
votes
0
answers
40
views
GDAL get vsimem file byte array while using Java binding
i have saved a dataset to PNG file.
file = "/vsimem/output.png"; out_drv.CreateCopy(file, dstile, 0, new String[0]);
then I want to get the file's byte array and save the bytes to a ...
1
vote
1
answer
142
views
Get length in meters of a LineString using GeoTools
In another toolset I have used PostgreSQL to get the distance in meters text:
CREATE OR REPLACE FUNCTION length_text(geometry geometry) RETURNS text AS
$$
SELECT CASE
WHEN ST_IsValid(geometry) ...
2
votes
1
answer
206
views
Generating COG with Geotools
I see there are a few test cases to generate a tiled and even a BigTiff GeoTIFF in the GeoTools repository. E.g.
https://github.com/geotools/geotools/blob/d261ee2eec4022cb847d20aa5223e5a6c37992c7/...
3
votes
1
answer
161
views
Not getting INFO-level messages from org.geotools.util.logging.Logging
As a Java beginner, I've inherited a custom Geoserver extension, running in a Windows environment. The plugin contains logging code like this:
import java.util.logging.Logger;
import org.geotools.util....
0
votes
0
answers
186
views
GML to Geometry parsing issue Java
I am converting GML, that includes wrappers, into Geometry objects. Currently I have converting a Point from the GML to Geometry working but the Line strings and polygons are not being parsed ...
3
votes
1
answer
174
views
Cannot compile code against latest stable GeoTools/GeoServer version
I've previously successfully compiled a GeoServer extension against earlier GeoServer/GeoTools versions, but today, I'm getting some dependency issues (Java newbie here).
I am trying to build for ...
1
vote
1
answer
261
views
GeoServer Tomcat 302 redirect loop or 500 error after attempted upgrade
I'm upgrading a dev instance of Geoserver 2.22.2 to 2.25.2 which is running under Tomcat 9. I can only reach the instance via HTTP.
If I leave the default <session-config> in place in my webapp'...