Welcome back, In the last two article we have been discussed about General Checklist and Security Related Checklist for ASP.Net Developers. These checklist are found to be very useful for developers perspective. Now we shall discus something about ASP.Net Performance Improvement Tips. I have listed down some of the Performance Related Tips for ASP.Net Applications

  1. Reduce the size of the HTML document by combining inline images into (cached) style sheets. Use Image Sprites.
  2. Combine all scripts into a single script and all style sheets into a single style sheet.
  3. Load style sheet in the document HEAD. Putting style sheets in the HEAD allows the page to render progressively.
  4. Move all the scripts to the bottom of the document, except scripts which contain ‘document. Write’. This would facilitate the progressive rendering of the page and avoid blocking of parallel downloads.
  5. JavaScript and CSS files should be contained in external files. External files are cached by the browsers.
  6. Minify JavaScript. Remove all the white space, new line, tab and comments from the JavaScript as well as from the .aspx, .ascx files.
  7. Avoid using Redirects: Instead of using http://www.yahoo.com/astrology use http://astrology.yahoo.com . This will reduce the server redirects.
  8. If data is coming from multiple Web services simultaneously then use Asynchronous call to Webservice Methods. This will reduce the total time required to get data from all the Webservices. 
  9. Avoid unnecessary round trips to the server
  10. Use Page.IsPostback to avoid performing unnecessary processing on a round trip.
  11. Use Server controls in appropriate circumstances (If a feature can be attained using HTML control then it’s advisable to use Html Control.)
  12. Save Server control view state only when it is necessary.
  13. Use the SqlDataReader class for a fast forward-only data cursor.
  14. To navigate to a URL without posting form, use hyperlink control.
  15. Keep the JavaScript function name as well as the control names as short as possible
  16. Maintain ASP.NET session state out of process in a SQL Server database or in a state server.
  17. Use Asynchronous mechanism to invoke web services, long running scripts.
  18. Use caching when data is expensive to create or to retrieve.
  19. Call the Dispose or Close method to release expensive resources such as database connection
  20. Minimize calls to DataBinder.Eval.
  21. Set an appropriate expires header for every page
  22. Use Performance Counters to test and measure the performance of the application during testing phase

Conclusion

I guess with these Performance Improvement Tips for ASP.Net Developers, they can able to create a robust ASP.Net application. Please pen down your comments, if you have any. Happy Programming :-)

Related Posts

  1. ASP.Net Developers Checklist – Security Checklist
  2. Checklist/Guidelines for ASP.Net Developers
  3. Handling ASP.Net Controls in JavaScript
  4. Call ASP.net MVC Server side function using Jquery Ajax
  5. ASP.Net Tutorial: Wizard Control

Tags: , , , ,

Leave a Reply

You can use these tags: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>