Uploaded image for project: 'GeoServer'
  1. GEOS-8668

2.14 WPS DownloadMap fails with more than one layer input

    Details

      Description

      This issue appears to be only in the 2.14.x (the release 2.13.0 works correctly)

      To reproduce:

      • Download the platform independent binary for 2.14.x
      • Add WPS plugin
      • Add WPS Download community module
      • Issue the following WPS request:
      <?xml version="1.0" encoding="UTF-8"?>
      <wps:Execute version="1.0.0" service="WPS"
                   xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://www.opengis.net/wps/1.0.0"
                   xmlns:wfs="http://www.opengis.net/wfs" xmlns:wps="http://www.opengis.net/wps/1.0.0"
                   xmlns:ows="http://www.opengis.net/ows/1.1" xmlns:gml="http://www.opengis.net/gml"
                   xmlns:ogc="http://www.opengis.net/ogc" xmlns:wcs="http://www.opengis.net/wcs/1.1.1"
                   xmlns:xlink="http://www.w3.org/1999/xlink"
                   xsi:schemaLocation="http://www.opengis.net/wps/1.0.0 http://schemas.opengis.net/wps/1.0.0/wpsAll.xsd">
        <ows:Identifier>gs:DownloadMap</ows:Identifier>
        <wps:DataInputs>
          <wps:Input>
            <ows:Identifier>bbox</ows:Identifier>
            <wps:Data>
              <wps:BoundingBoxData crs="EPSG:4326">
                <ows:LowerCorner>-55.11469223386748 -1.175069167133131</ows:LowerCorner>
                <ows:UpperCorner>67.14116714113253 72.65305583286687</ows:UpperCorner>
              </wps:BoundingBoxData>
            </wps:Data>
          </wps:Input>
          <wps:Input>
            <ows:Identifier>width</ows:Identifier>
            <wps:Data>
              <wps:LiteralData>1024</wps:LiteralData>
            </wps:Data>
          </wps:Input>
          <wps:Input>
            <ows:Identifier>height</ows:Identifier>
            <wps:Data>
              <wps:LiteralData>618</wps:LiteralData>
            </wps:Data>
          </wps:Input>
          
          <wps:Input>
            <ows:Identifier>layer</ows:Identifier>
            <wps:Data>
              <wps:ComplexData xmlns:dwn="http://geoserver.org/wps/download">
                <dwn:Layer>
                  <dwn:Name>tiger:poi</dwn:Name>
                </dwn:Layer>
              </wps:ComplexData>
            </wps:Data>
          </wps:Input>
      
          <wps:Input>
            <ows:Identifier>layer</ows:Identifier>
            <wps:Data>
              <wps:ComplexData xmlns:dwn="http://geoserver.org/wps/download">
                <dwn:Layer>
                  <dwn:Name>tiger:giant_polygon</dwn:Name>
                </dwn:Layer>
              </wps:ComplexData>
            </wps:Data>
          </wps:Input>
      
         </wps:DataInputs>
        <wps:ResponseForm>
          <wps:RawDataOutput mimeType="image/jpeg">
            <ows:Identifier>result</ows:Identifier>
          </wps:RawDataOutput>
        </wps:ResponseForm>
      </wps:Execute>
      

      The request will fail with the following error:

      <wps:ProcessFailed>
                  <ows:ExceptionReport version="1.1.0">
                      <ows:Exception exceptionCode="NoApplicableCode">
                          <ows:ExceptionText>Failed to retrieve value for input layerIl prefisso &amp;quot;dwn&amp;quot; per l&amp;apos;elemento &amp;quot;dwn:Layer&amp;quot; non è associato.</ows:ExceptionText>
                      </ows:Exception>
                  </ows:ExceptionReport>
              </wps:ProcessFailed>
      

      In the console there is the following log:

      2018-03-30 10:54:08,138 ERROR [wps.executor] - Process execution failed
      org.geoserver.wps.WPSException: Failed to retrieve value for input layer
      	at org.geoserver.wps.executor.LazyInputMap.parseInputs(LazyInputMap.java:94)
      	at org.geoserver.wps.executor.LazyInputMap.get(LazyInputMap.java:50)
      	at org.geotools.process.factory.AnnotationDrivenProcessFactory$InvokeMethodProcess.buildProcessArguments(AnnotationDrivenProcessFactory.java:659)
      	at org.geotools.process.factory.AnnotationDrivenProcessFactory$InvokeMethodProcess.execute(AnnotationDrivenProcessFactory.java:544)
      	at org.geoserver.wps.executor.ProcessStartupFilter$ProcessStartupWrapper.execute(ProcessStartupFilter.java:51)
      	at org.geoserver.wps.executor.DefaultProcessManager$ProcessCallable.call(DefaultProcessManager.java:201)
      	at org.geoserver.wps.executor.DefaultProcessManager$ProcessCallable.call(DefaultProcessManager.java:169)
      	at java.util.concurrent.FutureTask.run(FutureTask.java:266)
      	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
      	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
      	at java.lang.Thread.run(Thread.java:748)
      Caused by: javax.xml.bind.UnmarshalException
       - with linked exception:
      [org.xml.sax.SAXParseException; lineNumber: 1; columnNumber: 12; Il prefisso "dwn" per l'elemento "dwn:Layer" non è associato.]
      	at javax.xml.bind.helpers.AbstractUnmarshallerImpl.createUnmarshalException(AbstractUnmarshallerImpl.java:335)
      	at com.sun.xml.internal.bind.v2.runtime.unmarshaller.UnmarshallerImpl.createUnmarshalException(UnmarshallerImpl.java:563)
      	at com.sun.xml.internal.bind.v2.runtime.unmarshaller.UnmarshallerImpl.unmarshal0(UnmarshallerImpl.java:249)
      	at com.sun.xml.internal.bind.v2.runtime.unmarshaller.UnmarshallerImpl.unmarshal(UnmarshallerImpl.java:214)
      	at javax.xml.bind.helpers.AbstractUnmarshallerImpl.unmarshal(AbstractUnmarshallerImpl.java:140)
      	at javax.xml.bind.helpers.AbstractUnmarshallerImpl.unmarshal(AbstractUnmarshallerImpl.java:123)
      	at org.geoserver.wps.gs.download.JaxbPPIO.decode(JaxbPPIO.java:57)
      	at org.geoserver.wps.gs.download.JaxbPPIO.decode(JaxbPPIO.java:37)
      	at org.geoserver.wps.executor.SimpleInputProvider.getValueInternal(SimpleInputProvider.java:84)
      	at org.geoserver.wps.executor.AbstractInputProvider.getValue(AbstractInputProvider.java:97)
      	at org.geoserver.wps.executor.ListInputProvider.getValue(ListInputProvider.java:61)
      	at org.geoserver.wps.executor.LazyInputMap.parseInputs(LazyInputMap.java:86)
      	... 10 more
      Caused by: org.xml.sax.SAXParseException; lineNumber: 1; columnNumber: 12; Il prefisso "dwn" per l'elemento "dwn:Layer" non è associato.
      	at com.sun.org.apache.xerces.internal.util.ErrorHandlerWrapper.createSAXParseException(ErrorHandlerWrapper.java:203)
      	at com.sun.org.apache.xerces.internal.util.ErrorHandlerWrapper.fatalError(ErrorHandlerWrapper.java:177)
      	at com.sun.org.apache.xerces.internal.impl.XMLErrorReporter.reportError(XMLErrorReporter.java:400)
      	at com.sun.org.apache.xerces.internal.impl.XMLErrorReporter.reportError(XMLErrorReporter.java:327)
      	at com.sun.org.apache.xerces.internal.impl.XMLErrorReporter.reportError(XMLErrorReporter.java:284)
      	at com.sun.org.apache.xerces.internal.impl.XMLNSDocumentScannerImpl.scanStartElement(XMLNSDocumentScannerImpl.java:284)
      	at com.sun.org.apache.xerces.internal.impl.XMLNSDocumentScannerImpl$NSContentDriver.scanRootElementHook(XMLNSDocumentScannerImpl.java:613)
      	at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl$FragmentContentDriver.next(XMLDocumentFragmentScannerImpl.java:3132)
      	at com.sun.org.apache.xerces.internal.impl.XMLDocumentScannerImpl$PrologDriver.next(XMLDocumentScannerImpl.java:852)
      	at com.sun.org.apache.xerces.internal.impl.XMLDocumentScannerImpl.next(XMLDocumentScannerImpl.java:602)
      	at com.sun.org.apache.xerces.internal.impl.XMLNSDocumentScannerImpl.next(XMLNSDocumentScannerImpl.java:112)
      	at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanDocument(XMLDocumentFragmentScannerImpl.java:505)
      	at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:842)
      	at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:771)
      	at com.sun.org.apache.xerces.internal.parsers.XMLParser.parse(XMLParser.java:141)
      	at com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.parse(AbstractSAXParser.java:1213)
      	at com.sun.org.apache.xerces.internal.jaxp.SAXParserImpl$JAXPSAXParser.parse(SAXParserImpl.java:643)
      	at com.sun.xml.internal.bind.v2.runtime.unmarshaller.UnmarshallerImpl.unmarshal0(UnmarshallerImpl.java:243)
      	... 19 more
      

      Removing one of the "Input" layers will make it work

        Attachments

          Issue links

            Activity

              People

              • Assignee:
                dany111 Daniele Romagnoli
                Reporter:
                Gnafu Gnafu
              • Votes:
                0 Vote for this issue
                Watchers:
                1 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: