Friday, February 19, 2010

Componets Contributing to the performance of Page load

Network time represents how long a user is waiting while data is transmitted between their computer and your server. We can't completely control network time since some users are on slower connections than others, but we can reduce the number of bytes required to load a page; fewer bytes means less network time. The 5 main contributors to network time are bytes of cookies, HTML, CSS, JavaScript, and images.

Generation time captures how long it takes from when your webserver receives a request from the user to the time it sends back a response. This metric measures the efficiency of our code itself and also the webserver, caching, database, and network hardware. Reducing generation time is totally under our control and is accomplished through cleaner, faster code and constantly improving the backend architectures.

Render time measures how much time the user's web browser needs to process a response from the web server and display the resultant web page. Like network time, it is somewhat constrained here by the performance and behavior of the various browsers. The less we send back to the user, the faster the browser can display results, so minimizing bytes of HTML, CSS, JavaScript, and images also helps with render time. Another simple way to reduce render time is to execute as little JavaScript as possible before showing the page to the user.