Beginner 1, JS CSS library file through CDN referral recommended HTTP://WWW.BOOTCDN.CN/2, picture compression batch image compression recommended caesium_boxed, compressed picture volume can be reduced by about 50%, while not affecting the picture display accuracy, save bandwidth 3, The head reference CSS, the bottom reference js4, compression js CSS reduce the bandwidth occupied 5, multi-image page using pictures lazy loading. JQUERY.LAZYLOAD.JS6, optimize SQL statements, avoid using distinct,in,select * and so on 7, database index, index can greatly improve query efficiency. Intermediate 1, load-balanced Nginx + tomcat cluster, using Haship load Balancing scheme can avoid sesson loss. Because load balancing is used, uploading files should not be uploaded directly to the Tomcat directory and can be uploaded to a separate file server via FTP. 2, static and dynamic separation the server receives requests from the client, and some of them are requests for static resources, such as html,css,js and picture resources, and so on, some of which are dynamic data requests. Because Tomcat handles static resources at a slower rate, we can consider using Nginx's reverse proxy for all static resources, and the requests for static resources are directly nginx, and others are forwarded to Tomcat processing. 3, the SQL cache cache query results, when modified, new data, empty the corresponding cache 4, page static CMS
Web Application Performance Optimization