The performance of mappingwidgets is (partly) determined by the amount of html/javascript code that is transferred from server to client. At present only serverside caching is done by smarty.
An improvement seems to be possible in 2 parts:
1) introduce client side caching by putting the javascript code in separated files (per language!) and using <script src=file.js>.
2) compress the javascript code
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
A first implementation doesn't yet take language codes in the javascript files in account.
The difference of the generated page (one with most buttons, a simplemap, a simplelegend and an overview) is large: with code included the size of the page is 73.4 kB, with the javascript as src files it is only 10.8 kB.
Note that client caching also requests less capacity from the server.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
The performance of mappingwidgets is (partly) determined by the amount of html/javascript code that is transferred from server to client. At present only serverside caching is done by smarty.
An improvement seems to be possible in 2 parts:
1) introduce client side caching by putting the javascript code in separated files (per language!) and using <script src=file.js>.
2) compress the javascript code
A first implementation doesn't yet take language codes in the javascript files in account.
The difference of the generated page (one with most buttons, a simplemap, a simplelegend and an overview) is large: with code included the size of the page is 73.4 kB, with the javascript as src files it is only 10.8 kB.
Note that client caching also requests less capacity from the server.
A suitable compression has not been found yet, but an approximation is that e.g. SimpleMap.js can be compressed from 45 kB to about 24 kB.
A working compressor is found at http://dojotoolkit.org/docs/compressor_system.html
It compresses SimpleMap.js from 45.2 kB to 23.5 kB (a 48% reduction).