[Geoserver-devel] [jira] (GEOS-5013) WFS request containing viewparams parameter causes an IllegalArgumentException

Martin Davis created GEOS-5013:
----------------------------------

             Summary: WFS request containing viewparams parameter causes an IllegalArgumentException
                 Key: GEOS-5013
                 URL: https://jira.codehaus.org/browse/GEOS-5013
             Project: GeoServer
          Issue Type: Bug
          Components: WFS
    Affects Versions: 2.2.x
            Reporter: Martin Davis
            Assignee: Andrea Aime
         Attachments: wfs.diff

A WFS request with a viewParams parameter generates an IllegalArgumentException.

Sample request:
http://localhost:8080/geoserver/wfs?request=GetFeature&typename=globe_temp_dailies&version=1.1&viewparams=strField:minimum_temp;strDate:2010-07-01

Error msg:

java.lang.IllegalArgumentException: [{STRFIELD=minimum_temp, STRDATE=2010-07-01}] incompatible with VIRTUAL_TABLE_PARAMETERS [{STRFIELD=minimum_temp, STRDATE=2010-07-01}] incompatible with VIRTUAL_TABLE_PARAMETERS

Stack trace:

Thread [btpool0-1] (Suspended)
  Hints(RenderingHints).put(Object, Object) line: 1056
  GetFeature.toDataQuery(Query, Filter, int, int, FeatureSource<FeatureType,Feature>, GetFeatureRequest, List<PropertyName>, Map<String,String>, List<Join>) line: 981
  GetFeature.run(GetFeatureRequest) line: 464
  DefaultWebFeatureService.getFeature(GetFeatureType) line: 121
  NativeMethodAccessorImpl.invoke0(Method, Object, Object) line: not available [native method]

This was caused by a erroneous duplicate assignment to the Hints.VIRTUAL_TABLE_PARAMETERS in GetFeature.java. Patch attached.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://jira.codehaus.org/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira