The performance of the site is related to the user access experience, so that the site to support more users, so that each user's waiting time shorter is our goal. Performance is enhanced by database optimization, efficient HTML code rendering, and content caching. Here are some rules for improving Web site performance:
Optimize the design of the database
Rational use of Index, use of efficient SQL statements, reduce database table full table scan, only return the necessary data, these are very effective database optimization methods, database is often a Web site performance bottlenecks, you need to continue to optimize the database, every little bit of performance improvement, The cumulative result will be a qualitative change.
Use Store Procedure to exchange data between database and website business layer
Stored Procedures (store Procedure) perform far more efficiently than dispersed SQL statements. As long as your database supports Store Procedure you should use it as a data interchange channel between the business logic end of the Web site and the database end.
Pagination returns the records in the database without using the business layer's paging
When you return a large number of data records, you should use the paging mechanism to page through the data, you need to page in the database, in the business layer paging will lead to a large number of duplicate data between the data layer and the business layer, resulting in performance bottlenecks.
Using mature optimized Web page rendering techniques
asp.net, PHP, JSP, Ruby, and CGI can act as HTML rendering engines for the site's presentation layer, and you can choose the right platform for your needs. It should be noted that a platform such as ASP.net, in order to meet the vast majority of applications and minimize the amount of user code, uses a number of techniques that may degrade performance, such as View state, which you can turn off to improve page rendering and execution efficiency. In fact, we used the direct Render method in Comsharp CMS, put aside the ASP.net page lifecycle model, rendering HTML code directly to generate Web pages, and achieved very good performance.