[gdal-dev] Can OGR WFS driver take advantage of WFS Server streaming?

Even Rouault even.rouault at mines-paris.org
Thu May 17 12:47:45 EDT 2012


> > 2. Does the GML driver take url pointing to a GML?
> 
> It can work with /vsicurl/http://something, provided that the server allows
> partial downloading of arbitrary ranges of bytes within the file, which is
> rarely the case with GetFeature() requests.
> 
> In theory the WFS driver could be improved to use the capability of the GML
> driver to read chunk by chunk, but there is some work to make that happen.
> This would probably require a /vsicurl_streaming/ virtual file system where
> basically only Read() requests would be available, thus not requiring the
> server to have download range capabilities.

Before considering the effort of implementing /vsicurl_streaming/ , I've 
improved a few things in the GML driver in trunk that allows to parse a GML 
stream that is a WFS GetFeature response document.

So you can now try the following command on Linux :

wget -O - "http://testing.deegree.org/deegree-
wfs/services?SERVICE=WFS&VERSION=1.1.0&REQUEST=GetFeature&TYPENAME=app:Springs" 
| ogrinfo -ro -al -q /vsistdin/

or

wget -O - "http://testing.deegree.org/deegree-
wfs/services?SERVICE=WFS&VERSION=1.1.0&REQUEST=GetFeature&TYPENAME=app:Springs" 
| ogr2ogr springs.shp /vsistdin/

(or instead of "wget -O -", you can use "curl" depending on what is installed 
on your machine)


More information about the gdal-dev mailing list