Several questions about using EF site optimization

Source: Internet
Author: User

1. Cache common data.

2. Avoid unnecessary layering when writing programs, and unreasonable layering can also affect performance.

3. You post to the outside of the Internet, and then tell us the address, we come to see, haha.

4. Write JS into a common, and put it in a separate JS file.

If it is not necessary to load the execution of JS, it is recommended to place JS at the end of the page.

5. Reduce unnecessary comments on the ASPX design page and remove unused controls.

Use HTML control as much as possible and use less server controls.

6. Using Ajax in a reasonable combination can improve the user experience.

7. Optimize the database and index the frequently used tables.

8. I still cache, in fact, I said above, here again to emphasize.

9. Common query statements are best done as stored procedures, and EF can call stored procedures. There are also views that can be made, and EF also supports the processing of the view.

10. For complex business, such as 5 tables above the associated query, the proposed SQL to implement, EF in the Multi-table association, will generate very complex SQL statements, although the generated statements are not bad, but compared to my own writing, I think I write better. (Emphasizing that I mean when the very many tables are associated)

Several questions about using EF site optimization

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.