IN-CORE / incore-services

IN-CORE Web Services is a component of IN-CORE. IN-CORE uses a service oriented architecture with a REST API for communicating with the different services.
Mozilla Public License 2.0
5 stars 1 forks source link

283 uploaded joined shapefile to geoserver has missing values #284

Closed navarroc closed 7 months ago

navarroc commented 7 months ago

I switched the call from outToShapefile to outToGpkgFile and fixed the issue with using the gpkg file. I have not tested upload to the geoserver, but I did test the join on my local and it looks to be working correctly.

navarroc commented 7 months ago

I deployed to incore-dev and tested. Got a 500 Internal Error. Data service pod logs are not very helpful

at java.base/java.lang.Thread.run(Unknown Source)
Mar 13, 2024 3:10:42 AM org.geotools.jdbc.JDBCDataStore getSQLTypeNames
WARNING: Fetching fields from Database
Mar 13, 2024 3:13:15 AM org.geotools.jdbc.JDBCDataStore getSQLTypeNames
WARNING: Fetching fields from Database

One interesting thing I found is YWK might revert back to shapefile because geopackage is posting this layer with the store name as the dataset id but layer name as something completely different image

Apart from the wrong layer name (and 500 error), the layer seems to be correct image

So it uploads OK (besides the name issue), but still throws an error? I'm guessing the internal error comes from the GeoserverUtils.uploadGpkgToGeoserver(dataset.getId(), geoPkgFile) not getting the return type it expects. Any thoughts on how to address this? Is there a way to test this locally to push to our geoserver so we can put in some debug statements? I see that it automatically sets "renameLayer=True". I'm really not sure since this code is not very familiar to me.