Chapter 16. Performance and optimizations

 

This chapter covers

  • Compressing and minifying your markup, CSS, and JavaScript files
  • Using multithreading techniques to boost performance
  • Writing parallel code using ParallelFX
  • Optimizing web.config

This chapter is the last one of our book, and we’re approaching the end of our exploration of ASP.NET. What better way to end our voyage than with performance.

Performance is a driving factor for web applications. You never know how crucial it is until you have a problem. Performance is often confused with scalability, but they aren’t the same thing. You can achieve better performance by scaling, and you can optimize your user experience by following a simple set of rules—and by employing some tricks. Depending on the context, the word performance can assume different meanings: for our purposes, it’s the possibility of performing the same work in less time. Minifying JavaScript, CSS, or markup, for example, can speed up page load on the browser side. Sometimes performance is just a matter of doing little things the right way.

On the other hand, multithreading techniques can boost the performance of your application on the server side by using multiple threads to span the work across them. Modern hardware capabilities let you build a new kind of application because multi-core architecture is well established.

16.1. Increasing download performance by minifying

16.2. Reducing computing time with multithreading

16.3. Optimize your web.config

16.4. Summary