Load balance and the apache+tomcat of cluster

Source: Internet
Author: User

After reading a book, it should be harvested, summed up, the recent "large-scale Web site technology architecture" a book to read, give people the impression is really profound, plus before the book on the reverse agent and load balance and session independent storage and caching, so the book seems to be quite easy to understand, And the author Li Zhihui the Impression (book) is also very profound, I also learned a lot from this book, understand a lot, but understanding or more abstract, write is the real understanding, so ready to write a series of blog to introduce and deepen understanding of large-scale web site technology architecture.

Speaking of large web sites, the first to say the characteristics of large sites: high concurrency, large flow, high availability, massive data . Let's talk about the architecture evolution of a large web site. 1, the initial stage of the site architecture

The initial stage is relatively simple, usually a server can handle a website, look at the picture.

2. Application Service and Data service separation

With the development of the website business, a server is gradually unable to meet the demand, this time will need to separate applications and data, such as figure.

3, use the cache to improve the performance of the site

There is no doubt that today's web sites will basically use caching, that is, 80% of business access will be concentrated on 20% of the data.

4, use the application server cluster to improve the concurrent processing capacity of the Web site

Because a single application server can handle a limited number of request connections, the application server becomes the bottleneck of the entire site during peak visit times. Therefore, the use of load balancing processor potential in the inevitable. The load Balancing dispatch server distributes the access requests from the browser to any server in the application cluster.

5, database reading and writing separation

When the user reaches a certain scale, the database becomes the bottleneck of the website because the load pressure is too high. The current mainstream database provides master-slave hot standby function, through the configuration of two database master-slave relationship, can be a database of data updates synchronized to another server. The website uses the database function to realize the database reading and writing separation, thus improves the database load pressure.

6, the use of reverse proxy and CDN plus the site corresponding

Improve the speed of Web site access, the main means of using CDN and reverse proxy.

the basic principles of CDN and reverse proxy are caching , the difference is that CDN is deployed in the network provider's room, and the reverse proxy is deployed in the center of the website, when the user requests to the center room, the first access to the reverse proxy, if the reverse proxy cache the user requested resources, is returned directly to the user.

7. Using Distributed File system and distributed database system

Any powerful single server will not meet the growing business needs of large web sites.

The last means of splitting a Web site database when distributed database is used only when the data of single table is very large. Less than the last resort, the Web site more commonly used to split the method is the business split, the different business data deployed on different physical servers .

8, the use of NoSQL and search engines

The search engine has also basically formed the function that the big website must provide now, the website needs to adopt some non relational database technology such as NoSQL and non database query technology such as search engine.

9, Business split

To cope with increasingly complex business scenarios, large Web sites split the entire site into different product lines by using divide-and-conquer practices.

specific to the technical, will also be based on product line charges, a site split into many different applications, each application of independent deployment maintenance. Applications can be managed through hyperlinks, or through Message Queuing, or, of course, by accessing the same data storage system to form an associated complete system.

10. Distributed Service

Since each application system needs to perform many of the same business operations, such as user management, session management, you can extract these common services and deploy them independently.

 

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.