Your SlideShare is downloading. ×
0
Web Front End Performance
Web Front End Performance
Web Front End Performance
Web Front End Performance
Web Front End Performance
Web Front End Performance
Web Front End Performance
Web Front End Performance
Web Front End Performance
Web Front End Performance
Web Front End Performance
Web Front End Performance
Web Front End Performance
Web Front End Performance
Web Front End Performance
Web Front End Performance
Web Front End Performance
Web Front End Performance
Web Front End Performance
Upcoming SlideShare
Loading in...5
×

Thanks for flagging this SlideShare!

Oops! An error has occurred.

×
Saving this for later? Get the SlideShare app to save on your phone or tablet. Read anywhere, anytime – even offline.
Text the download link to your phone
Standard text messaging rates apply

Web Front End Performance

1,314

Published on

This is an older session,

This is an older session,

0 Comments
2 Likes
Statistics
Notes
  • Be the first to comment

No Downloads
Views
Total Views
1,314
On Slideshare
0
From Embeds
0
Number of Embeds
1
Actions
Shares
0
Downloads
25
Comments
0
Likes
2
Embeds 0
No embeds

Report content
Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

Cancel
No notes for slide
  • Entity Tags (ETags) are commonly used in Web applications to effectively leverage the power of using web farms, which is a non-fancy term for HTTP/S load balancing.  In web farms, a common practice is to set what is called ETags as it helps enhance performance in web farm scenarios.  ETags is controlled in IIS by a metabase property (ETAG_CHANGENUMBER) and this value is sent back to clients via response headers as instructed by the HTTP RFC 2616. 
  • Transcript

    • 1. ASP.NET Performance Tips<br />GettingThings Right on the Client<br />Chris Love<br />http://ProfessionalASPNET.com<br />Copyright Extreme Web Works - http://ProfessionalASPNET.com<br />
    • 2. ASP.NET Performance Tips on the Server I<br />ASP.NET Performance Tips on the Server II<br />ASP.NET Performance Tips on the Client-Side<br />Copyright Extreme Web Works - http://ProfessionalASPNET.com<br />
    • 3. High Performance Web Sites<br />Essential Knowledge for <br />Front-End Engineers<br />Steve Souders<br />http://amzn.to/gwf9pG<br />http://amzn.to/gudayQ<br />http://developer.yahoo.com/performance/rules.html<br />Copyright Extreme Web Works - http://ProfessionalASPNET.com<br />
    • 4. Front-End Performance Tools<br /><ul><li>FireBug and YSlow
    • 5. http://GetFireBug.com
    • 6. http://developer.yahoo.com/yslow/
    • 7. Fiddler
    • 8. http://FiddlerTools.com
    • 9. Web Development Helper
    • 10. http://projects.nikhilk.net/Projects/WebDevHelper.aspx</li></ul>Copyright Extreme Web Works - http://ProfessionalASPNET.com<br />
    • 11. Front-End Performance Rules<br />Make Fewer HTTP Requests<br />Use a Content Delivery Network<br />Add an Expires Header *<br />Compress Content *<br />StyleeSheets On Top *<br />Scripts at Bottom *<br />Avoid CSS Expressions<br />Make JavaScript and CSS External *<br />Reduce DNS Lookups<br />Minify JavaScript *<br />Avoid Redirects *<br />Remove Duplicate Scripts *<br />Configure Etags<br />Make AJAX Cacheable *<br />Copyright Extreme Web Works - http://ProfessionalASPNET.com<br />
    • 12. Make Fewer HTTP Requests<br /><ul><li>Each Request Adds More Overhead
    • 13. Avoid Slicing Images that are not Reused
    • 14. Image Maps
    • 15. CSS Sprites
    • 16. Inline Images
    • 17. Combine Scripts and CSS</li></ul>Copyright Extreme Web Works - http://ProfessionalASPNET.com<br />
    • 18. <ul><li>Use a Content Delivery Network
    • 19. More Geographically Dispersed
    • 20. Not really practical for most sites.
    • 21. Can see drastic response time savings
    • 22. Do not compare tests against in house lab results</li></ul>Copyright Extreme Web Works - http://ProfessionalASPNET.com<br />
    • 23. <ul><li>Configure Etags</li></ul>Mechanism for Servers and Browsers to <br /> Communicate about Cache Validation.<br />Provide a way to know if Browser Cache matches<br /> what is on the server.<br />RFC 2616<br />Sends a 304 Response instead of 200<br />IIS 6.0 &amp; Service Pack 1 (slipstream)<br />IIS 7 can be integrated with IIS 6 Farms<br /> Set ETAG_CHANGENUMBER to 0<br />Best Idea - Just Remove them!<br />Copyright Extreme Web Works - http://ProfessionalASPNET.com<br />
    • 24. Avoid CSS Expressions<br /><ul><li>Specific to IE 5+
    • 25. Constantly being Reevaluated
    • 26. Use JavaScript Functions to change the Style
    • 27. Use One-Time Expressions</li></ul>Copyright Extreme Web Works - http://ProfessionalASPNET.com<br />
    • 28. Reduce DNS Lookups<br /><ul><li>DNS Caching – How does DNS work?
    • 29. Find the Fine Point between Parallel Downloads and DNS lookups</li></ul>Copyright Extreme Web Works - http://ProfessionalASPNET.com<br />
    • 30. Compress Content<br /><ul><li>Reduces Content being sent over the wire
    • 31. Gzip, Deflate
    • 32. Increases Processer Demand on both ends
    • 33. IIS 6 and IIS 7
    • 34. http://technet2.microsoft.com/windowsserver2008/en/library/60f3fa55-f005-496e-9d2f-cc4fc2732fce1033.mspx?mfr=true
    • 35. Blowry
    • 36. Various ISAPI Filters</li></ul>Copyright Extreme Web Works - http://ProfessionalASPNET.com<br />
    • 37. Add an Expires Header<br /><ul><li>Primes the Cache
    • 38. For more than just images</li></ul>&lt;%@ OutputCache Duration=&quot;60&quot; VaryByParam=&quot;None&quot; %&gt;<br />Response.Cache.SetExpires(DateTime.Now.AddSeconds(60)) Response.Cache.SetCacheability(HttpCacheability.Public)<br />&lt;%@ OutputCache Duration=&quot;60&quot; Location=&quot;Downstream&quot; VaryByParam=&quot;None&quot; %&gt;<br />Copyright Extreme Web Works - http://ProfessionalASPNET.com<br />
    • 39. StyleeSheets On Top<br /><ul><li>Progressive Rendering</li></ul>Copyright Extreme Web Works - http://ProfessionalASPNET.com<br />
    • 40. Make JavaScript and CSS External<br />&lt;link rel=&quot;stylesheet&quot; href=“Main.css”&gt;<br />&lt;script src=“Meta.js &quot;&gt;&lt;/script&gt;<br />Copyright Extreme Web Works - http://ProfessionalASPNET.com<br />
    • 41. Scripts at Bottom<br /><ul><li>Yes!!! This Really Works!
    • 42. Defers Loading Client-Side Logic till after HTML
    • 43. Loading JavaScript is a Blocking Call (Everything waits for it to finish)</li></ul> &lt;asp:ScriptManager ID=&quot;ScriptManager1&quot; runat=&quot;server&quot; LoadScriptsBeforeUI=&quot;false&quot;&gt;<br /> &lt;/asp:ScriptManager&gt;<br />Copyright Extreme Web Works - http://ProfessionalASPNET.com<br />
    • 44. Minify JavaScript<br /><ul><li>Remove Unnecessary Characters from JS Files
    • 45. JSMin - http://www.crockford.com/javascript/jsmin.html
    • 46. DoJo Compressor - http://dojotoolkit.org/docs/shrinksafe
    • 47. JavascriptMinimizer - http://devtools.10try.com/
    • 48. CSS Minification does not provide as much gain.</li></ul>Copyright Extreme Web Works - http://ProfessionalASPNET.com<br />
    • 49. Remove Duplicate Scripts<br /><ul><li>They Happen
    • 50. Use the ScriptManager to Register JS Scripts
    • 51. Inherit from a Base Page Class with a checking mechanism
    • 52. Create a httpModule to check final stream</li></ul>Copyright Extreme Web Works - http://ProfessionalASPNET.com<br />
    • 53. Avoid Redirects<br /><ul><li>30X HTTP Status Codes
    • 54. Only use when necessary
    • 55. Reduce Response.Redirect
    • 56. PostBackURL
    • 57. Server.Transfer
    • 58. URL Rewritting</li></ul>Copyright Extreme Web Works - http://ProfessionalASPNET.com<br />
    • 59. Make AJAX Cacheable<br /><ul><li>Optimize AJAX Requests
    • 60. http://www.codeproject.com/KB/aspnet/10ASPNetPerformance.aspx?display=Print</li></ul> &lt;system.web.extensions&gt;<br /> &lt;scripting&gt;<br /> &lt;scriptResourceHandlerenableCaching =&quot;true&quot; enableCompression =&quot;true&quot;/&gt;<br /> &lt;/scripting&gt;<br /> &lt;/system.web.extensions&gt;<br />Copyright Extreme Web Works - http://ProfessionalASPNET.com<br />

    ×