Hi,

 

I am using WMS to display data in an OpenLayers map.

 

When I use the built in preview map inside Geoserver the map launches
quickly (about 5 seconds):

 

http://185.38.105.91:8080/geoserver/SCXBC/wms?service=WMS
<http://185.38.105.91:8080/geoserver/SCXBC/wms?service=WMS&version=1.1.0&req
uest=GetMap&layers=SCXBC:view5th&styles=&bbox=5513.0,530249.0,470332.0,12203
01.5&width=517&height=768&srs=EPSG:27700&format=application/openlayers>
&version=1.1.0&request=GetMap&layers=SCXBC:view5th&styles=&bbox=5513.0,53024
9.0,470332.0,1220301.5&width=517&height=768&srs=EPSG:27700&format=applicatio
n/openlayers

When I do the same in my own OpenLayer map it takes much longer (about 45
seconds):

 

     var geoserverWMS = 'http://185.38.105.91:8080/geoserver/SCXBC/wms?';

 

      var layers = [

        new ol.layer.Tile({

          source: new ol.source.OSM()

        }),

        new ol.layer.Tile({

                source: new ol.source.TileWMS({

            url: geoserverWMS,

            params: {'LAYERS': 'SCXBC:view5th', 'TILED': true},

            serverType: 'geoserver',

            transition: 0

          })

        })

      ];

 

      var map = new ol.Map({

        target: 'mapOpenLayers',

        layers: layers,

        view: new ol.View({

          center: ol.proj.fromLonLat([dLong, dLat]),

          zoom: dZoom

        })

      });

 

Do you know why my version is much slower?

 

I would like to use caching. Does the built in example use a cached example
somehow?

 

Many thanks,

 

Mike

_______________________________________________
Geoserver-users mailing list

Please make sure you read the following two resources before posting to this 
list:
- Earning your support instead of buying it, but Ian Turton: 
http://www.ianturton.com/talks/foss4g.html#/
- The GeoServer user list posting guidelines: 
http://geoserver.org/comm/userlist-guidelines.html

If you want to request a feature or an improvement, also see this: 
https://github.com/geoserver/geoserver/wiki/Successfully-requesting-and-integrating-new-features-and-improvements-in-GeoServer


[email protected]
https://lists.sourceforge.net/lists/listinfo/geoserver-users

Reply via email to