[Geoserver-devel] [jira] Created: (GEOS-387) Feature count in WFS getFeature requests

Feature count in WFS getFeature requests
----------------------------------------

         Key: GEOS-387
         URL: http://jira.codehaus.org/browse/GEOS-387
     Project: GeoServer
        Type: Improvement
  Components: WFS
    Versions: 1.3-rc2
Environment: Win2000
Reporter: brock anderson
Assigned to: dblasby
Attachments: FeatureResponse.patch

In servicing WFS getFeature requests, GeoServer tries to get a count of the features that are returned. I don't believe this is strictly necessary for forming a getFeature response, and it would be nice if we could eliminate the getCount call because it is sometimes expensive. (I have encountered an ArcSDE query that takes 20 seconds to get a count).

Looking at the code, FeatureResponse.execute() calls getCount once for each query that it executes. It needs the count when there are multiple queries in the request (to properly respect maxFeatures), but I don't believe the count is required for requests with just one query.

I have attached a simple patch which changes FeatureResponse.execute() to call getCount only when a request has mulitple queries.

I tested the patch with requests that have different combinations of one query/multiple queries, maxfeatures specified/not specified.

--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira