Hi,

When it comes to the time it takes to get all the features instead of just the 
bounding box, I would do some measurements and collect some facts before saying 
if it is faster to receive some extra data ot to launch some extra service for 
ripping off the unnecessary feature geometries.

Do your getFeature by including a parameter &propertyname=the_geom (or whatever 
you geometry is named).  Then WFS server will send only the geometries and you 
have avoided to download the attributes which are unnecessary for you.  
GetFeature will contain the boundedBy element in the beginning or the GML 
response and that is what you want to get,

Try this with 10 returned features
http://demo.opengeo.org/geoserver/ows?service=WFS&version=1.1.0&request=getfeature&typename=topp:states&maxfeatures=10&propertyname=the_geom

You will receive also the geometries of the features which you do not want but 
with a bunch of feature IDs that is not necessarily so huge a amount of bytes 
to download even the will be discarded immediately.


-Jukka Rahkonen-

Andrea Aime  wrote:
On Thu, Feb 9, 2012 at 9:50 AM, Gottfrid Linge 
<[email protected]<mailto:[email protected]>> wrote:
Hi there!

Is it possible to get the bounding box for a featurecollection using WFS in 
GeoServer? I have a bunch of feature ids and would like to know the bounding 
box so that I can make a WMS request for a map image containing all the 
features. I don't want to get all the features in WFS since that will take more 
time.

I think there should be a way using WFS Getfeature with resultType = hits and 
somehow enabling feature bounding in GeoServer? I only want bounds for the 
entire feature collection and not for every feature in the result.

WFS does not support getting just the feature bounds (as far as I know).
There is, however, a GeoServer WPS process that does just that

Cheers
Andrea


--
-------------------------------------------------------
Ing. Andrea Aime
GeoSolutions S.A.S.
Tech lead

Via Poggio alle Viti 1187
55054  Massarosa (LU)
Italy

phone: +39 0584 962313
fax:      +39 0584 962313
mob:    +39 339 8844549

http://www.geo-solutions.it
http://geo-solutions.blogspot.com/
http://www.youtube.com/user/GeoSolutionsIT
http://www.linkedin.com/in/andreaaime
http://twitter.com/geowolf

-------------------------------------------------------
------------------------------------------------------------------------------
Virtualization & Cloud Management Using Capacity Planning
Cloud computing makes use of virtualization - but cloud computing 
also focuses on allowing computing to be delivered as a service.
http://www.accelacomm.com/jaw/sfnl/114/51521223/
_______________________________________________
Geoserver-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/geoserver-users

Reply via email to