ppyordanov / Dynamic-Noise-and-Pollution-Map

A dynamically generated University of Glasgow noise and pollution campus map via the innovative Smart Citizen Kit developed in Barcelona, Spain by FabLab.
0 stars 0 forks source link

Assess Performance #70

Closed ppyordanov closed 9 years ago

ppyordanov commented 9 years ago

The performance of the server and the client needs to be assessed. This will involve:

ppyordanov commented 9 years ago

The performance assessment function for page loading time has the following implementation:

function logPageLoadingTime() {

var loadingComplete = Date.now();
var userLoadTime = loadingComplete - performance.timing.navigationStart;
console.log("Page Loading Time: " + userLoadTime + " ms");
console.log(locationARR);

}

What this function calculates essentially is the time passed between the point a user navigates to a specific page and the point when all or most of the page assets have finished loading. The expected page loading time without caching that would be considered within the norm is 0-2 seconds.

Below can be seen uncached and cached page loading times as well as page loading time after code optimization to improve the speed:

Uncached page loading:

loading_time_mozilla

Cached page loading:

loading_time_chrome

Here is the test after improvements:

loading_time_imp

ppyordanov commented 9 years ago

A speed improvement can be noticed from the screenshots above. More refactoring procedures are going to be executed which is likely to improve the speed more. However, at this stage, the page loading time without caching is far less than the specified 2 seconds norm.

This issue can be closed.