[Geoserver-devel] [JIRA] (GEOS-9964) Expected log messages not appearing when activating netcdf4 support with the netcdf-out plugin

2021-03-08 Thread Benjamin Root (JIRA)
Benjamin Root ( 
https://osgeo-org.atlassian.net/secure/ViewProfile.jspa?accountId=60469b9c58aa8d0072fec081
 ) *created* an issue

GeoServer ( 
https://osgeo-org.atlassian.net/browse/GEOS?atlOrigin=eyJpIjoiOTlkMjljY2ViMDE0NGM5N2I1ZjdkODRkMDE0N2Q4MTYiLCJwIjoiaiJ9
 ) / Bug ( 
https://osgeo-org.atlassian.net/browse/GEOS-9964?atlOrigin=eyJpIjoiOTlkMjljY2ViMDE0NGM5N2I1ZjdkODRkMDE0N2Q4MTYiLCJwIjoiaiJ9
 ) GEOS-9964 ( 
https://osgeo-org.atlassian.net/browse/GEOS-9964?atlOrigin=eyJpIjoiOTlkMjljY2ViMDE0NGM5N2I1ZjdkODRkMDE0N2Q4MTYiLCJwIjoiaiJ9
 ) Expected log messages not appearing when activating netcdf4 support with the 
netcdf-out plugin ( 
https://osgeo-org.atlassian.net/browse/GEOS-9964?atlOrigin=eyJpIjoiOTlkMjljY2ViMDE0NGM5N2I1ZjdkODRkMDE0N2Q4MTYiLCJwIjoiaiJ9
 )

Issue Type: Bug Affects Versions: 2.17.2 Assignee: Unassigned Components: 
Documentation, NetCDF Created: 08/Mar/21 11:00 PM Environment:

Amazon Linux 2 (CentOS-based)

Priority: Low Reporter: Benjamin Root ( 
https://osgeo-org.atlassian.net/secure/ViewProfile.jspa?accountId=60469b9c58aa8d0072fec081
 )

This is either a documentation bug, or some sort of logging bug, but it did 
cause me to chase ghosts for a few hours.

According to 
https://docs.geoserver.org/maintain/en/user/extensions/netcdf-out/nc4.html#geoserver-startup-checks
 , there is supposed to be an indication in a log (which?!) that the loading of 
the native netcdf4 library was successful or failed. As far as I can tell, 
neither message appears in any log that I could find as of v2.17.2 (the only 
version I have tried). Spent a bunch of time trying to figure out what went 
wrong before finally deciding to actually try a WCS call with 
`application/x-netcdf4` as an output format, and it worked.

Possibly related, the WCS Capabilities document also doesn't advertise that it 
supports `application/x-netcdf4`, only `application/x-netcdf`, which 
corresponds to NetCDF-3. Maybe that is tied in with the lack of any logging 
message, I don't know...

( 
https://osgeo-org.atlassian.net/browse/GEOS-9964#add-comment?atlOrigin=eyJpIjoiOTlkMjljY2ViMDE0NGM5N2I1ZjdkODRkMDE0N2Q4MTYiLCJwIjoiaiJ9
 ) Add Comment ( 
https://osgeo-org.atlassian.net/browse/GEOS-9964#add-comment?atlOrigin=eyJpIjoiOTlkMjljY2ViMDE0NGM5N2I1ZjdkODRkMDE0N2Q4MTYiLCJwIjoiaiJ9
 )

Get Jira notifications on your phone! Download the Jira Cloud app for Android ( 
https://play.google.com/store/apps/details?id=com.atlassian.android.jira.core=utm_source%3DNotificationLink%26utm_medium%3DEmail
 ) or iOS ( 
https://itunes.apple.com/app/apple-store/id1006972087?pt=696495=EmailNotificationLink=8
 ) This message was sent by Atlassian Jira (v1001.0.0-SNAPSHOT#100154- 
sha1:d382120 )___
Geoserver-devel mailing list
Geoserver-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/geoserver-devel


[Geoserver-devel] powermock for unit tests in app-schema

2021-03-08 Thread Niels Charlier via Geoserver-devel

Hello,

I fixed a bug in geoserver app-schema 
(https://github.com/geotools/geotools/pull/3367 
https://osgeo-org.atlassian.net/browse/GEOT-6801). The change I made was 
very small (one character actually) and in one specific class. To me it 
seemed appropriate to write a unit test. Since it is JDBC an integration 
test would only be run online with db, but still require a lot of amount 
of work to create the right table, mapping etc... Mocking seems useful 
to me.


Anyway, because one of the classes I need is final, I had to use 
PowerMock to write the test. The Reviewer of the patch ask to check with 
the list if it is okay to add the PowerMock library to the test scope. I 
know traditionally we have more integration tests than unit tests, but I 
think it wouldn't be bad to add more unit tests in general.


Kind Regards

Niels



___
Geoserver-devel mailing list
Geoserver-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/geoserver-devel


[Geoserver-devel] [JIRA] (GEOS-9963) Missing JAR in the packaging of WPS GeoPackage Downlod module 2.18.x

2021-03-08 Thread Christian Picone (JIRA)
Christian Picone ( 
https://osgeo-org.atlassian.net/secure/ViewProfile.jspa?accountId=5a5dc530a2f18c448df72dfe
 ) *created* an issue

GeoServer ( 
https://osgeo-org.atlassian.net/browse/GEOS?atlOrigin=eyJpIjoiY2ZmYTBiZWIzYmExNGRmZGJlOTVkOWNkODkxOGZhNjQiLCJwIjoiaiJ9
 ) / Bug ( 
https://osgeo-org.atlassian.net/browse/GEOS-9963?atlOrigin=eyJpIjoiY2ZmYTBiZWIzYmExNGRmZGJlOTVkOWNkODkxOGZhNjQiLCJwIjoiaiJ9
 ) GEOS-9963 ( 
https://osgeo-org.atlassian.net/browse/GEOS-9963?atlOrigin=eyJpIjoiY2ZmYTBiZWIzYmExNGRmZGJlOTVkOWNkODkxOGZhNjQiLCJwIjoiaiJ9
 ) Missing JAR in the packaging of WPS GeoPackage Downlod module 2.18.x ( 
https://osgeo-org.atlassian.net/browse/GEOS-9963?atlOrigin=eyJpIjoiY2ZmYTBiZWIzYmExNGRmZGJlOTVkOWNkODkxOGZhNjQiLCJwIjoiaiJ9
 )

Issue Type: Bug Affects Versions: 2.18.2 Assignee: Unassigned Attachments: 
wps-request.xml Components: Community modules Created: 08/Mar/21 12:11 PM 
Priority: Medium Reporter: Christian Picone ( 
https://osgeo-org.atlassian.net/secure/ViewProfile.jspa?accountId=5a5dc530a2f18c448df72dfe
 )

Executing a WPS request to download data in geopackage format:

curl -u admin:geoserver -H "Content-Type: application/xml" -XPOST -d 
@wps-request.xml http://127.0.0.1:8083/geoserver-2.18.2/wps

we obtain an exception.
Here the stack traces from different GeoServer Log levels:

Stack trace
(DEFAULT LOGGING):
08 mar 11:26:49 ERROR [wps.executor] - Process execution failed
org.geotools.process.ProcessException: java.lang.NoClassDefFoundError: 
com/fasterxml/jackson/databind/ObjectMapper
at 
org.geotools.process.factory.AnnotationDrivenProcessFactory$InvokeMethodProcess.execute(AnnotationDrivenProcessFactory.java:637)
at 
org.geoserver.wps.executor.ProcessStartupFilter$ProcessStartupWrapper.execute(ProcessStartupFilter.java:50)
at 
org.geoserver.wps.executor.DefaultProcessManager$ProcessCallable.call(DefaultProcessManager.java:224)
at 
org.geoserver.wps.executor.DefaultProcessManager$ProcessCallable.call(DefaultProcessManager.java:192)
at java.util.concurrent.FutureTask.run(Unknown Source)
at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
at java.lang.Thread.run(Unknown Source)
Caused by: java.lang.NoClassDefFoundError: 
com/fasterxml/jackson/databind/ObjectMapper
at org.geoserver.geopkg.wps.OWSContextWriter.(OWSContextWriter.java:84)
at 
org.geoserver.geopkg.wps.GeoPackageProcess.execute(GeoPackageProcess.java:165)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at 
org.geotools.process.factory.AnnotationDrivenProcessFactory$InvokeMethodProcess.execute(AnnotationDrivenProcessFactory.java:621)
... 7 more
Caused by: java.lang.ClassNotFoundException: 
com.fasterxml.jackson.databind.ObjectMapper
at 
org.apache.catalina.loader.WebappClassLoaderBase.loadClass(WebappClassLoaderBase.java:1364)
at 
org.apache.catalina.loader.WebappClassLoaderBase.loadClass(WebappClassLoaderBase.java:1187)
... 14 more
08 mar 11:26:49 INFO [geoserver.wps] -
Request: execute
service = WPS
version = 1.0.0
baseUrl = http://127.0.0.1:8083/geoserver-2.18.2-itu/
identifier:
value = gs:GeoPackage
dataInputs:
input [0] :
identifier = net.opengis.ows11.impl.CodeTypeImpl@1a0e5af (value: contents, 
codeSpace: null)
data = net.opengis.wps10.impl.DataTypeImpl@1e7908c
responseForm:
rawDataOutput:
identifier = net.opengis.ows11.impl.CodeTypeImpl@f02ecc (value: geopackage, 
codeSpace: null)
08 mar 11:26:49 ERROR [geotools.jdbc] - There's code using JDBC based datastore 
and not disposing them. This may lead to temporary loss of database 
connections. Please make sure all data access code calls DataStore.dispose() 
before freeing all references to it

(GEOTOOLS DEVELOPER LOGGING):
08 mar 11:30:11 INFO [org.geoserver.wps] -
Request: getServiceInfo
08 mar 11:30:11 DEBUG [org.geotools.xsd.impl] - schemaLocation found: 
http://www.opengis.net/wps/1.0.0 http://schemas.opengis.net/wps/1.0.0/wpsAll.xsd
08 mar 11:30:11 DEBUG [org.geotools.xsd.impl] - Found override for 
http://www.opengis.net/wps/1.0.0: 
http://schemas.opengis.net/wps/1.0.0/wpsAll.xsd ==> jar: 
file:/C:/tools/apache-tomcat-9.0.43/webapps/geoserver-2.18.2-itu/WEB-INF/lib/gt-xsd-wps-24.2.jar!/org/geotools/wps/wpsAll.xsd
08 mar 11:30:11 DEBUG [org.geotools.xsd.impl] - No schemaLocation found, using 
'http://www.opengis.net/gpkg jar: 
file:/C:/tools/apache-tomcat-9.0.43/webapps/geoserver-2.18.2-itu/WEB-INF/lib/gt-geopkg-24.2.jar!/org/geotools/geopkg/wps/xml/gpkg.xsd
08 mar 11:30:11 DEBUG [org.geotools.xsd.impl] - Found override for 
http://www.opengis.net/gpkg: jar: 
file:/C:/tools/apache-tomcat-9.0.43/webapps/geoserver-2.18.2-itu/WEB-INF/lib/gt-geopkg-24.2.jar!/org/geotools/geopkg/wps/xml/gpkg.xsd
 ==> jar: