Like many here I was really excited to see OGC support improved in ArcGIS Online with the addition of Web Feature Service support, including identify on WFS.
In trying the functionality out with some services though I'm struggling, as from trying out the viewer it doesn't implement a spatial operator in the query to the service. Only limiting the getFeature query to the layer, coordinate system and number of features:
<GetFeature xmlns:xsi='http://www.w3.org/2001/XMLSchema-instance' xmlns:gml='http://www.opengis.net/gml' xmlns:ogc='http://www.opengis.net/ogc' xmlns:wfs='http://www.opengis.net/wfs' xmlns='http://www.opengis.net/wfs/2.0' xmlns:fife='http://arcgisweb.fife.gov.uk/geoserver' version='2.0.0' service='WFS' count='100'> <Query typeNames='fife:LISTED_BUILDINGS' srsName='EPSG:27700'> </Query> </GetFeature>
So ArcGIS Online will only ask the service for all features up to the maximum feature count defined in the WFS OGC Options. This is regardless of the extent of the map, so where a service contains more features than the limit it may well return features outside the current map extent. Most services will implement their own limit on the number of features in a response similar to ArcGIS Server Feature Services.
You can see the behaviour in this example map which includes a WFS from one of our neighbouring authorties, the WFS contains 6,147 buildings but will only ever return 100 as requested by the AGOL viewer. It would be impractical and slow to always set the map to request every feature in the service. I know not all WFS servers support Spatial Filters on a WFS getFeature request, but can this be implemented in AGOL for servers that do support it?