<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=us-ascii">
<meta name="Generator" content="Microsoft Word 15 (filtered medium)">
<!--[if !mso]><style>v\:* {behavior:url(#default#VML);}
o\:* {behavior:url(#default#VML);}
w\:* {behavior:url(#default#VML);}
.shape {behavior:url(#default#VML);}
</style><![endif]--><style><!--
/* Font Definitions */
@font-face
        {font-family:Wingdings;
        panose-1:5 0 0 0 0 0 0 0 0 0;}
@font-face
        {font-family:"Cambria Math";
        panose-1:2 4 5 3 5 4 6 3 2 4;}
@font-face
        {font-family:Calibri;
        panose-1:2 15 5 2 2 2 4 3 2 4;}
@font-face
        {font-family:Tahoma;
        panose-1:2 11 6 4 3 5 4 4 2 4;}
@font-face
        {font-family:Webdings;
        panose-1:5 3 1 2 1 5 9 6 7 3;}
@font-face
        {font-family:"Comic Sans MS";
        panose-1:3 15 7 2 3 3 2 2 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0cm;
        margin-bottom:.0001pt;
        font-size:11.0pt;
        font-family:"Calibri","sans-serif";}
a:link, span.MsoHyperlink
        {mso-style-priority:99;
        color:#0563C1;
        text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
        {mso-style-priority:99;
        color:#954F72;
        text-decoration:underline;}
p.MsoListParagraph, li.MsoListParagraph, div.MsoListParagraph
        {mso-style-priority:34;
        margin-top:0cm;
        margin-right:0cm;
        margin-bottom:0cm;
        margin-left:36.0pt;
        margin-bottom:.0001pt;
        font-size:11.0pt;
        font-family:"Calibri","sans-serif";}
span.E-mailStijl18
        {mso-style-type:personal;
        font-family:"Arial","sans-serif";
        color:windowtext;}
span.E-mailStijl19
        {mso-style-type:personal;
        font-family:"Comic Sans MS";
        color:windowtext;
        font-weight:normal;
        font-style:normal;}
span.E-mailStijl20
        {mso-style-type:personal-reply;
        font-family:"Arial","sans-serif";
        color:windowtext;}
.MsoChpDefault
        {mso-style-type:export-only;
        font-size:10.0pt;}
@page WordSection1
        {size:612.0pt 792.0pt;
        margin:70.85pt 70.85pt 70.85pt 70.85pt;}
div.WordSection1
        {page:WordSection1;}
--></style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]-->
</head>
<body lang="NL-BE" link="#0563C1" vlink="#954F72">
<div class="WordSection1">
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:"Arial","sans-serif";mso-fareast-language:EN-US">Hi Bob,<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:"Arial","sans-serif";mso-fareast-language:EN-US"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:"Arial","sans-serif";mso-fareast-language:EN-US">For our WMS data we have created 1 layer which combines all required feature types to reduce the number of network requests. This works very well.
 Also one of the changes we already made to improve performance. Another one was replacing the database views with tables (which are rebuilt every night).<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:"Arial","sans-serif";mso-fareast-language:EN-US"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:"Arial","sans-serif";mso-fareast-language:EN-US">Today I tried to do something similar for the WFS data: just 1 layer with all required (visible) feature types. But the request itself takes 6-7
 seconds, 750KB of WFS data (gzipped) is returned. I saved such a response into a text file, it was almost 7MB. So it takes 10-15 seconds until the user can proceed (request is completely finished with all wfs being processed and wms tiles are loaded). This
 probably won’t be fast enough. <o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:"Arial","sans-serif";mso-fareast-language:EN-US"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:"Arial","sans-serif";mso-fareast-language:EN-US">But maybe you are referring to something else which I’m not aware of.<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:"Arial","sans-serif";mso-fareast-language:EN-US"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:"Arial","sans-serif";mso-fareast-language:EN-US">Kind regards,<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:"Arial","sans-serif";mso-fareast-language:EN-US">Roel<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:"Arial","sans-serif";mso-fareast-language:EN-US"><o:p> </o:p></span></p>
<div>
<div style="border:none;border-top:solid #E1E1E1 1.0pt;padding:3.0pt 0cm 0cm 0cm">
<p class="MsoNormal"><b><span lang="NL">Van:</span></b><span lang="NL"> Basques, Bob (CI-StPaul) [mailto:bob.basques@ci.stpaul.mn.us]
<br>
<b>Verzonden:</b> dinsdag 4 november 2014 17:48<br>
<b>Aan:</b> Roel De Nijs; openlayers-users@lists.osgeo.org<br>
<b>Onderwerp:</b> RE: Alternatives to get rid of WFS layers<o:p></o:p></span></p>
</div>
</div>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:8.0pt;font-family:"Comic Sans MS"">Have you thought about combining all the WFS services into a single call and then managing the filtering on the client side.  This would also work for the hover control,
 in that you could pull multiples based on a hover action and still use some sort of buffer to handle things that are clustered as well as multiple selects.  This could reduce the amount of data being pulled on demand to an acceptable level, performance wise. 
 It also allows you to do global searches since all data is handled by a single service.<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:8.0pt;font-family:"Comic Sans MS""><o:p> </o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:8.0pt;font-family:"Comic Sans MS"">bobb<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:8.0pt;font-family:"Comic Sans MS""><o:p> </o:p></span></p>
<div>
<div style="border:none;border-top:solid #B5C4DF 1.0pt;padding:3.0pt 0cm 0cm 0cm">
<p class="MsoNormal" style="margin-left:36.0pt"><b><span lang="EN-US" style="font-size:10.0pt;font-family:"Tahoma","sans-serif"">From:</span></b><span lang="EN-US" style="font-size:10.0pt;font-family:"Tahoma","sans-serif"">
<a href="mailto:openlayers-users-bounces@lists.osgeo.org">openlayers-users-bounces@lists.osgeo.org</a> [<a href="mailto:openlayers-users-bounces@lists.osgeo.org">mailto:openlayers-users-bounces@lists.osgeo.org</a>]
<b>On Behalf Of </b>Roel De Nijs<br>
<b>Sent:</b> Tuesday, November 04, 2014 10:32 AM<br>
<b>To:</b> <a href="mailto:openlayers-users@lists.osgeo.org">openlayers-users@lists.osgeo.org</a><br>
<b>Subject:</b> [OpenLayers-Users] Alternatives to get rid of WFS layers<o:p></o:p></span></p>
</div>
</div>
<p class="MsoNormal" style="margin-left:36.0pt"><span lang="EN-US"><o:p> </o:p></span></p>
<p class="MsoNormal" style="margin-left:36.0pt"><span style="font-size:10.0pt;font-family:"Arial","sans-serif"">Hi list,<o:p></o:p></span></p>
<p class="MsoNormal" style="margin-left:36.0pt"><span style="font-size:10.0pt;font-family:"Arial","sans-serif""><o:p> </o:p></span></p>
<p class="MsoNormal" style="margin-left:36.0pt"><span style="font-size:10.0pt;font-family:"Arial","sans-serif"">We have a web application displaying some geographical data (about the sewerage system) and using OpenLayers 2.13.1 as front-end library (geoserver
 as back-end). Currently we have +- 30 object (feature) types. Every object type has a WMS and WFS layer in the map. The visibility of each object type is dependent on a minimum/maximum zoom level and/or can be turned off by the user. The user can perform a
 set of standard functions on the map (zoom, pan,…) and each feature (hover, select, double click,…).<o:p></o:p></span></p>
<p class="MsoNormal" style="margin-left:36.0pt"><span style="font-size:10.0pt;font-family:"Arial","sans-serif"">Everything works fine, but the main criticism about this application is (very) poor performance, being (very) slow and making the browser freeze.
 Sometimes the only option is to close the browser and start again. Not the most user-friendly approach.<o:p></o:p></span></p>
<p class="MsoNormal" style="margin-left:36.0pt"><span style="font-size:10.0pt;font-family:"Arial","sans-serif""><o:p> </o:p></span></p>
<p class="MsoNormal" style="margin-left:36.0pt"><span style="font-size:10.0pt;font-family:"Arial","sans-serif"">We did some testing related to the performance. One of the things we noticed, WFS data has a huge impact on performance. From a certain zoom level,
 the WFS data (for all layers) retrieved the server is 750KB – 1MB (and that’s the gzipped version). It takes some time to load all this data (certainly if the user is on the road) and also to process the data. If you zoom and pan a few times, you’ll probably
 have to close your browser (mostly IE) and start over again. Users sometimes have to wait 15-20 seconds before a pan or zoom request has finished, which is inacceptable from a user’s point of view.<o:p></o:p></span></p>
<p class="MsoNormal" style="margin-left:36.0pt"><span style="font-size:10.0pt;font-family:"Arial","sans-serif""><o:p> </o:p></span></p>
<p class="MsoNormal" style="margin-left:36.0pt"><span style="font-size:10.0pt;font-family:"Arial","sans-serif"">I can’t imagine this application is the only one having to deal with so much WFS data, so I was wondering how other developers managed big amounts
 of WFS data and keeping their web application responsive while loding/processing the WFS data.
<o:p></o:p></span></p>
<p class="MsoNormal" style="margin-left:36.0pt"><span style="font-size:10.0pt;font-family:"Arial","sans-serif""><o:p> </o:p></span></p>
<p class="MsoNormal" style="margin-left:36.0pt"><span style="font-size:10.0pt;font-family:"Arial","sans-serif"">Or maybe some alternative/work-around exists to get rid of the WFS layers/data, but still keep the feature functions (like hovering, (multiple) selection,
 box selection, double click,…)?<o:p></o:p></span></p>
<p class="MsoNormal" style="margin-left:36.0pt"><span style="font-size:10.0pt;font-family:"Arial","sans-serif""><o:p> </o:p></span></p>
<p class="MsoNormal" style="margin-left:36.0pt"><span style="font-size:10.0pt;font-family:"Arial","sans-serif"">Another path I have already experimented with is loading the WFS data on-demand, because the user is probably not interested in all features but
 only in some of them. Using the GetFeature control I’m able to get the features underneath the mouse cursor. But I’m wondering how I can incorporate all other feature functions. Because e.g. the Select control uses a wfs layer, but the layers doesn’t contain
 features anymore. <o:p></o:p></span></p>
<p class="MsoNormal" style="margin-left:36.0pt"><span style="font-size:10.0pt;font-family:"Arial","sans-serif""><o:p> </o:p></span></p>
<p class="MsoNormal" style="margin-left:36.0pt"><span style="font-size:10.0pt;font-family:"Arial","sans-serif"">I’m really desperate, so I appreciate all insights, suggestions, pointers, hints, a lot!
</span><span style="font-size:10.0pt;font-family:Wingdings">J</span><span style="font-size:10.0pt;font-family:"Arial","sans-serif""><o:p></o:p></span></p>
<p class="MsoNormal" style="margin-left:36.0pt"><span style="font-size:10.0pt;font-family:"Arial","sans-serif""><o:p> </o:p></span></p>
<p class="MsoNormal" style="margin-left:36.0pt"><span style="font-size:10.0pt;font-family:"Arial","sans-serif"">Kind regards,<o:p></o:p></span></p>
<p class="MsoNormal" style="margin-left:36.0pt"><span style="font-size:10.0pt;font-family:"Arial","sans-serif"">Roel De Nijs<o:p></o:p></span></p>
<p class="MsoNormal" style="margin-left:36.0pt"><span style="font-size:10.0pt;font-family:"Arial","sans-serif"">Senior Java Developer<o:p></o:p></span></p>
<div style="margin-left:36.0pt">
<div class="MsoNormal" align="center" style="text-align:center"><span style="font-size:12.0pt;font-family:"Times New Roman","serif"">
<hr size="1" width="100%" noshade="" style="color:#00ADEE" align="center">
</span></div>
</div>
<p class="MsoNormal" style="margin-left:36.0pt"><span style="font-size:12.0pt;font-family:"Times New Roman","serif""><br>
</span><i><span style="font-size:7.5pt;font-family:"Arial","sans-serif";color:#00ADEE">Volg Aquafin op
<a href="https://www.facebook.com/AquafinNV"><span style="color:#00ADEE">Facebook</span></a> |
<a href="https://twitter.com/aquafinnv"><span style="color:#00ADEE">Twitter</span></a> |
<a href="http://www.youtube.com/channel/UCk_4P5BJ-MtEEDCkCsR_KqQ?feature=mhee"><span style="color:#00ADEE">YouTube</span></a> |
<a href="http://www.linkedin.com/company/aquafin/products"><span style="color:#00ADEE">LinkedIN</span></a>
</span></i><span style="font-size:7.5pt;font-family:"Arial","sans-serif";color:#00ADEE"><br>
<br>
</span><span style="font-size:7.5pt;font-family:"Arial","sans-serif";color:gray">Disclaimer: zie
<a href="http://www.aquafin.be"><span style="color:gray">www.aquafin.be</span></a></span><span style="font-size:7.5pt;font-family:"Arial","sans-serif";color:#00ADEE">  
</span><span style="font-size:10.0pt;font-family:Webdings;color:#00CC00">P</span><span style="font-size:7.5pt;font-family:"Arial","sans-serif";color:#00ADEE">
</span><span style="font-size:7.5pt;font-family:"Arial","sans-serif";color:black">Denk aan het milieu. Druk deze mail niet onnodig af.</span><span style="font-size:7.5pt;font-family:"Arial","sans-serif";color:#00ADEE">
</span><span style="font-size:12.0pt;font-family:"Times New Roman","serif""><o:p></o:p></span></p>
</div>
</body>
</html>