I am developing an application, part of which uses OpenLayers (calling the WMS service maintained by Geoserver), displaying some frequently updated data (the track of the ship, or, more specifically, a number of points).
I would like this ship track to be updated at a given interval - OpenLayers.Strategy.Refresh seems to be the most appropriate way to do this. I slightly modified the wms.html example (OpenLayers 2.11) to try this, for example:
underway = new OpenLayers.Layer.WMS("Underway Data", "http://ubuntu-geospatial-server:8080/geoserver/underway/wms", {'layers': 'underway:ss2011_v03', transparent: true, format: 'image/gif'}, {isBaseLayer: false}, {strategies : [new OpenLayers.Strategy.Refresh({interval: 6000})]} ); map.addLayers([layer, underway]);
From what I can say, this should work as it is (i.e. update the current layer every 6 seconds), but nothing happens. Updated basic WMS is updated - if I update the map manually, updated data will appear.
I am sure that I am missing something fairly obvious, any help would be greatly appreciated. I don't get any errors in Firebug or anything else, it just does nothing.
Caligari
source share