Hi,

I just wrote a simple WPS client with geotools for GeoServer. I used
the same code in the geotools website:
http://docs.geotools.org/latest/userguide/unsupported/wps.html

I got the following error in WPSFactory():
Exception in thread "main" java.lang.NullPointerException
        at 
org.geotools.data.wps.WPSUtils.getLiteralTypeFromReference(WPSUtils.java:296)
        at org.geotools.data.wps.WPSUtils.createInputParamMap(WPSUtils.java:183)
        at 
org.geotools.data.wps.WPSFactory.buildValuesFromProcessDescriptionType(WPSFactory.java:81)
        at org.geotools.data.wps.WPSFactory.<init>(WPSFactory.java:68)
        at au.org.aurin.wps.WPSClient.getCapabilities(WPSClient.java:108)
        at au.org.aurin.wps.WPSClient.main(WPSClient.java:42)

After looking into WPSUtiles class I found out that problem is here:
if (literalData != null) {
                String reference = literalData.getDataType().getReference();
                type = getLiteralTypeFromReference(reference);
}

reference is null, so getLiteralTypeFromReference gives
java.lang.NullPointerException.

I checked the same code with 52N WPS and Deegree WPS, which works fine!
So, I believe that there is a bug in  XML of DescribeProcess in
GeoServer as listed below as well:

These are part of XML of Describe process (SimpleBufferAlgorithm in
52N WPS and JTS:buffer in Geoserver WPS)

-------------- in 52N
<LiteralData>
       <ns1:DataType ns1:reference="xs:double"
xmlns:ns1="http://www.opengis.net/ows/1.1"/>
       <ns1:AnyValue xmlns:ns1="http://www.opengis.net/ows/1.1"/>
     </LiteralData>

-------------- in GeoSrrver
<wps:LiteralData>
<ows:DataType>xs:double</ows:DataType>
<ows:AnyValue/>
</wps:LiteralData>


Regards,
Bahman

------------------------------------------------------------------------------
Get a FREE DOWNLOAD! and learn more about uberSVN rich system, 
user administration capabilities and model configuration. Take 
the hassle out of deploying and managing Subversion and the 
tools developers use with it. http://p.sf.net/sfu/wandisco-d2d-2
_______________________________________________
Geoserver-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/geoserver-users

Reply via email to