<html>
<head>
<meta content="text/html; charset=windows-1252"
http-equiv="Content-Type">
</head>
<body text="#000000" bgcolor="#FFFFFF">
<div class="moz-cite-prefix">Hi Steve, List, <br>
<br>
Hmm, I compiled mapserver from sources (GitHub Master). Actually
that was not that bad, all tough I did not find out how to run the
mapserver from ubuntu packages next to the one I compiled myself.<br>
<br>
The new mapserver is working ... a bit.<br>
The new mapserver doesn't support custom dimensions (yet ?) which
I do use. So, for now I've removed that from the client side
requests and getmap requests are fine .<br>
<br>
Then do a simple query like:<br>
<blockquote><wfs:GetFeature
xmlns:wfs=<a class="moz-txt-link-rfc2396E" href="http://www.opengis.net/wfs">"http://www.opengis.net/wfs"</a> service="WFS"
version="1.1.0" xsi:schemaLocation=<a class="moz-txt-link-rfc2396E" href="http://www.opengis.net/wfshttp://schemas.opengis.net/wfs/1.1.0/wfs.xsd">"http://www.opengis.net/wfs
http://schemas.opengis.net/wfs/1.1.0/wfs.xsd"</a>
xmlns:xsi=<a class="moz-txt-link-rfc2396E" href="http://www.w3.org/2001/XMLSchema-instance">"http://www.w3.org/2001/XMLSchema-instance"</a>><br>
<wfs:Query typeName="hb:jan2014_high"
srsName="EPSG:900913"
xmlns:hb=<a class="moz-txt-link-rfc2396E" href="http://maps.md2.com/schemas/hb_wfs.xsd">"http://maps.md2.com/schemas/hb_wfs.xsd"</a>><br>
<ogc:Filter
xmlns:ogc=<a class="moz-txt-link-rfc2396E" href="http://www.opengis.net/ogc">"http://www.opengis.net/ogc"</a>><br>
<ogc:Intersects><br>
<ogc:PropertyName></ogc:PropertyName><br>
<gml:Polygon
xmlns:gml=<a class="moz-txt-link-rfc2396E" href="http://www.opengis.net/gml">"http://www.opengis.net/gml"</a> srsName="EPSG:900913"><br>
<gml:exterior><br>
<gml:LinearRing><br>
<gml:posList>493014.59839229
6795936.8942158 493014.59839229 6796022.885872601
493102.97870623 6796022.885872601
493102.97870623 6795936.8942158
493014.59839229 6795936.8942158</gml:posList><br>
</gml:LinearRing><br>
</gml:exterior><br>
</gml:Polygon><br>
</ogc:Intersects><br>
</ogc:Filter><br>
</wfs:Query><br>
</wfs:GetFeature><br>
</blockquote>
<br>
Resulting in an error:<br>
msWFSGetFeature(): WFS server error. Invalid or Unsupported FILTER
in GetFeature : <Filter ogc=<a class="moz-txt-link-rfc2396E" href="http://www.opengis.net/ogc">"http://www.opengis.net/ogc"</a>>
<Intersects> <PropertyName /> <Polygon
gml=<a class="moz-txt-link-rfc2396E" href="http://www.opengis.net/gml">"http://www.opengis.net/gml"</a> srsName="EPSG:900913">
<exterior> <LinearRing> <posList>492858.14135005
6795805.518073499 492858.14135005 6796116.0435008 493197.33066301
6796116.0435008 493197.33066301 6795805.518073499 492858.14135005
6795805.518073499</posList> </LinearRing>
</exterior> </Polygon> </Intersects>
</Filter>
<br>
(Mapserver 6.4 accepts this query and returns a result (albeit
taking long)).<br>
<br>
A simple query like this works:<br>
<wfs:GetFeature xmlns:wfs=<a class="moz-txt-link-rfc2396E" href="http://www.opengis.net/wfs">"http://www.opengis.net/wfs"</a>
service="WFS" version="1.1.0"
xsi:schemaLocation=<a class="moz-txt-link-rfc2396E" href="http://www.opengis.net/wfshttp://schemas.opengis.net/wfs/1.1.0/wfs.xsdhttp://maps.md2.com/schemas/hb_wfs.xsdhttp://xxxxx/maps/xxxx/rc1/services/basic/default.map?service=WFS&version=1.1.0&request=DescribeFeatureType&typeName=jan2014_high">"http://www.opengis.net/wfs
http://schemas.opengis.net/wfs/1.1.0/wfs.xsd
http://maps.md2.com/schemas/hb_wfs.xsd
http://xxxxx/maps/xxxx/rc1/services/basic/default.map?service=WFS&version=1.1.0&request=DescribeFeatureType&typeName=jan2014_high"</a>
xmlns:xsi=<a class="moz-txt-link-rfc2396E" href="http://www.w3.org/2001/XMLSchema-instance">"http://www.w3.org/2001/XMLSchema-instance"</a>><br>
<wfs:Query typeName="feature:jan2014_high"
srsName="EPSG:900913"><br>
<ogc:Filter xmlns:ogc=<a class="moz-txt-link-rfc2396E" href="http://www.opengis.net/ogc">"http://www.opengis.net/ogc"</a>><br>
<ogc:And><br>
<ogc:BBOX><br>
<ogc:PropertyName>msGeometry</ogc:PropertyName><br>
<gml:Envelope xmlns:gml=<a class="moz-txt-link-rfc2396E" href="http://www.opengis.net/gml">"http://www.opengis.net/gml"</a>
srsName="EPSG:900913"><br>
<gml:lowerCorner>491667.6470239
6795223.3576443</gml:lowerCorner><br>
<gml:upperCorner>494192.4576141
6796212.2616977</gml:upperCorner><br>
</gml:Envelope><br>
</ogc:BBOX><br>
<ogc:PropertyIsLessThan><br>
<ogc:PropertyName>value</ogc:PropertyName><br>
<ogc:Literal>0</ogc:Literal><br>
</ogc:PropertyIsLessThan><br>
</ogc:And><br>
</ogc:Filter><br>
</wfs:Query><br>
</wfs:GetFeature><br>
<br>
but that one was already reasonably fast.<br>
<br>
Any pointers very much appreciated.<br>
<br>
MArco<br>
<br>
<br>
<br>
On 03-11-14 19:06, Lime, Steve D (MNIT) wrote:<br>
</div>
<blockquote
cite="mid:C549F0496453D842B4DD71AC8188DDC507FAF22E@055-CH1MPN1-041.055d.mgd.msft.net"
type="cite">
<pre wrap="">MapServer 7.0 should fix issues like this. A more general solution to the one presented in #4049 has been added to that version. You might try the development version and see how it goes. I'm surprised simple queries aren't working well though since older versions of MapServer have optimizations specific to PostGIS for those simple cases.
Steve
-----Original Message-----
From: <a class="moz-txt-link-abbreviated" href="mailto:mapserver-users-bounces@lists.osgeo.org">mapserver-users-bounces@lists.osgeo.org</a> [<a class="moz-txt-link-freetext" href="mailto:mapserver-users-bounces@lists.osgeo.org">mailto:mapserver-users-bounces@lists.osgeo.org</a>] On Behalf Of deduikertjes
Sent: Monday, November 03, 2014 9:56 AM
To: <a class="moz-txt-link-abbreviated" href="mailto:mapserver-users@lists.osgeo.org">mapserver-users@lists.osgeo.org</a>
Subject: [mapserver-users] WFS query slow on large postgis table (and small table disappointing as well)
Hi List,
I'm experiencing real slow performance when doing WFS queries on a postgis table with about 1500000 records.
A simple spatial query (which features in a box) takes about 1 to 2 minutes.
In postgis the same query takes less than a second. Same story for attribute queries.
Indeed on a postgis table with some 60000 records things are still very very slow.
WMS on the other hand is flying taking less than a second for rendering most tiles.
By using the debug functions I see that mapserver fetches all features in the map extent (set at map level) and then starts filtering feature by feature which takes a long time.
I found ticket <a class="moz-txt-link-freetext" href="http://trac.osgeo.org/mapserver/ticket/4049">http://trac.osgeo.org/mapserver/ticket/4049</a> which seems to be related.
Is there any way to speed up this kind of WFS queries? Is there any progress on the ticket?
Any help appreciated, MArco
--
View this message in context: <a class="moz-txt-link-freetext" href="http://osgeo-org.1560.x6.nabble.com/WFS-query-slow-on-large-postgis-table-and-small-table-disappointing-as-well-tp5170988.html">http://osgeo-org.1560.x6.nabble.com/WFS-query-slow-on-large-postgis-table-and-small-table-disappointing-as-well-tp5170988.html</a>
Sent from the Mapserver - User mailing list archive at Nabble.com.
_______________________________________________
mapserver-users mailing list
<a class="moz-txt-link-abbreviated" href="mailto:mapserver-users@lists.osgeo.org">mapserver-users@lists.osgeo.org</a>
<a class="moz-txt-link-freetext" href="http://lists.osgeo.org/mailman/listinfo/mapserver-users">http://lists.osgeo.org/mailman/listinfo/mapserver-users</a>
</pre>
</blockquote>
<br>
</body>
</html>