REST: listing granules in a structured coverage view fails with exception

Description

Trying to get to the list of granules of a coverage view, e.g.:

http://localhost:8080/geoserver/rest/workspaces/s2/coveragestores/S2_MSI_L1C_FULL/coverages/S2_MSI_L1C_FULL/index/granules.xml

results in the following:

java.lang.NullPointerException org.geoserver.rest.catalog.StructuredCoverageController.forceNonNullNamespace(StructuredCoverageController.java:294) org.geoserver.rest.catalog.StructuredCoverageController.granulesGet(StructuredCoverageController.java:132) sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) java.lang.reflect.Method.invoke(Method.java:498) org.springframework.web.method.support.InvocableHandlerMethod.doInvoke(InvocableHandlerMethod.java:205) org.springframework.web.method.support.InvocableHandlerMethod.invokeForRequest(InvocableHandlerMethod.java:133) org.springframework.web.servlet.mvc.method.annotation.ServletInvocableHandlerMethod.invokeAndHandle(ServletInvocableHandlerMethod.java:116) org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerAdapter.invokeHandlerMethod(RequestMappingHandlerAdapter.java:827) org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerAdapter.handleInternal(RequestMappingHandlerAdapter.java:738) org.springframework.web.servlet.mvc.method.AbstractHandlerMethodAdapter.handle(AbstractHandlerMethodAdapter.java:85) org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:963) org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:897)

Environment

None

Activity

Andrea Aime
June 5, 2018 at 3:10 PM

Backporting on 2.12.x has proved to be challenging, the patches build on code that does not exist in that branch

Fixed

Details

Assignee

Reporter

Fix versions

Components

Priority

Created June 5, 2018 at 8:42 AM
Updated November 15, 2021 at 10:09 AM
Resolved June 5, 2018 at 3:10 PM