SYSK 327: The Cost of RoundedCornersExtender From AjaxControlToolkit


More and more web sites are using rounded corners on spans (labels) and panels.  And since AjaxControlToolkit makes it sinfully easy to do, before I start using it extensively, I decided to do some profiling to see the cost of that extender.


 


Here is what I found:


 


1.     HMTL (download) size in bytes:


 


# of RoundedCornersExtender   Page Size  


Controls   


—————————————————-


0                             2731


1                             3581 (+850)


2                             3770 (+189)


3                             3959 (+189)


4                             4122 (+163)


5                             4299 (+177)      


 


2.    Server-side page request execution time (localhost, Toshiba M5, dual 2 Ghz, 2 Mb):


 


# of RoundedCornersExtender   Time in ms 


Controls   


—————————————————-


0                             4.311721182


1                             5.398800686 (+25%)


2                             7.032737401 (+30%)


3                             7.399823162 (+5%)


4                             8.478870918 (+15%)


5                             9.263607526 (+9%)


 


 


3.    Client-side AJAX controls initialization time (yesterday’s post explained how I timed the added initialization time on the client due to using the extender controls.  Click here to navigate to SYSK 326):


 


# of RoundedCornersExtender   Client init time in ms 


Controls   


—————————————————-


0                             0


1                             10 (+25%)


2                             16 (+30%)


3                             31 (+5%)


4                             31 (+15%)


5                             47 (+9%)   


 


 


4.    Page load time (time to last byte)


 


One can use download speed to calculate the additional page load time, or you can run tests and measure it.  My testing was done using localhost, so I’m not providing any data here as it’s irrelevant.


 


 


Summary:  The first instance of the control adds 850 bytes, and additional instances add approximately 180 bytes.  On my laptop, the additional rendering time per instance is 9.25 ms on the client and 1 ms on the server.


 


 

Comments (4)

  1. Niels Harremoes says:

    Doesn’t browser caching eliminate most of the network and server time affter the first page?

  2. Ryan says:

    I also noticed the speed difference but I never did full testing. I linked to your article here (http://ryantech.spaces.live.com/blog/cns!2497D74A7E644FB3!144.entry) if you are interested.

    Thank you for your great posts!

  3. Swian says:

    Any control you add to a page is going to add more html which will impact the file size.

  4. Matt says:

    When adding the RoundedCorners extender to a panel with a substantial amount of data we noticed an extra load time of up to 5 seconds!

Skip to main content