General High Performance Service Framework parsing

Source: Internet
Author: User

Do many years of back-office services, have been trying to make their own so many years of high-performance service architecture of some superficial understanding of writing, on the one hand on their own this stage of growth to do a summary, on the other hand, I would like to make a communication with you, not hesitate to enlighten.

First, the concept of service architecture

The initial exposure to the service-side program should be 2011, when the concept of service-based architecture was based on such a model



This is the simplest kind of C/S model structure, the client directly connected to the service side, only for the efficiency, concurrency, scalability requirements of the environment, so when the demand is gradually rising, you will find that the system of this architecture, processing has not satisfied the needs of the business, so you derive from the following architecture.


Second, multiple app streaming mode



This is a two-layer framework, the central control layer is the control service only to do the forwarding shunt operation, the shunt algorithm is usually polling, specifically can be based on the actual business situation to develop. The application layer is the specific application service that executes the specific business. The main advantages of this architecture are the following:

1, the central control layer will effectively distribute traffic to the various business services, and the application of the central control layer only do forwarding do not do business, in the processing request volume efficiency is much higher than the direct-connected business services, so the framework relative to the above one in the throughput of a large increase

2, easier to expand, if you find that application services can not support the existing business volume, by increasing the application services to divert.

However, this kind of architecture with the increase in business will gradually not apply, some students may say that more business services diversion is not to get, here to take into account the resource costs, management costs and so on, so this method is not applicable in the large request volume, the problem is how to improve the application services business processing speed, We can introduce caching mechanisms.

Three, the framework of the buffer mechanism


In the ordinary business processing, the query request volume is the most, how to improve query efficiency, it becomes the key, in general, the database or disk IO read can become a bottleneck, so often we will be in the business application and database or disk to add a cache mechanism, business applications first to check the cache, The cache does not check the corresponding database or disk, 90% of the requests can be resolved in the cache, which not only reduces the pressure on the database, but also increases the speed of business processing. Of course you may be based on the needs of the business more than a few cache, but the basic idea is not changed, depending on your business, this kind of architecture can basically solve 80% of the problem.


Iv. Framework for the inclusion of disaster-tolerant mechanisms

The above-mentioned framework is only a basic framework, in practical applications need to consider a lot of factors, such as server downtime, how to smooth the transition, do not affect the business, and so on, we have to join the disaster-tolerant mechanism.



Monitoring service is mainly responsible for monitoring the load Balancer service whether there is an outage, if there is, set to the corresponding state, the client requests monitoring services, to obtain an effective load balancing service address, to connect, so that even if there is a service outage, in fact, does not affect the operation of the entire system, of course, the database disaster tolerance, There's not much to discuss here!

V. Summary

There are many factors that affect the performance of the whole system, there are only a few superficial discussions on the framework, the actual situation may be considered more factors, as for the optimization of common procedures, there is time I will write an article summarizing some. In addition, the framework of high-performance Web applications can be referenced in this article: http://www.csdn.net/article/2014-11-06/2822529. In short, the constant principle of increasing system performance is how to quickly process business data.


Finally, you have any questions or good suggestions to join the group: 291368579


General High Performance Service Framework parsing

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.