当前位置:网站首页>Cloud native architecture (02) - what is cloud native
Cloud native architecture (02) - what is cloud native
2022-06-22 03:39:00 【Yanglinwei】
List of articles
Learning reference materials :《 Enterprise Cloud native architecture : technology 、 Service and practice )》
01 Cloud native Overview
1.1 Yun Yuansheng defines
Wikipedia is right Cloud native (Cloud Native) The definition of :
- Cloud native is a software development method , It makes full use of Cloud Computing , Deploy applications as microservices using the open source software technology stack . Usually , Cloud native applications are built in
DockerA set of microservices running in a container , stayKubernetesTo arrange , And useDevOps2andGit OpsWorkflow management and deployment . UseDockerThe advantage of container is that it can package all the software and environment configurations required for execution into an executable package . Containers run in virtualized environments , This isolates the included application from its environment .
The initial stage of going to the cloud , Most enterprises just change the application from the traditional IDC Move the computer room to the virtual machine on the cloud , This is the cloud hosting mode , Or infrastructure as a service (Infrastructure as a Service, IaaS) On the cloud .
But really make good use of the cloud , Not just infrastructure and platform upgrades , The application also needs to abandon the traditional design method , From architecture design 、 The whole software life cycle management from development mode to deployment and maintenance , It should be reconstructed based on the characteristics of the cloud , To build “ Primary cloud ” And the application of design , In this way, we can use the best architecture on the cloud 、 The best mode of operation , And make full use of the flexibility and distributed advantages of the cloud platform .
Adopt cloud native technology and management methods , We can better grow our business in “ cloud ” Or move to a cloud platform , To enjoy “ cloud ” High efficiency and continuous service ability .
1.2 Cloud native coverage
Matt Stine(《 Migrate to cloud native application architecture 》 author ) Think of cloud primitives as a collection of ideas and best practices , Including agile infrastructure (agle infrastructure)、 Microservices (microservice)、DevOps、 Continuous delivery (continuous delivery) etc. , It mainly covers the following important contents :
- Twelve elements app : A collection of cloud native application architecture patterns ;
- Microservices : Independently deployed Services , Each service does only one thing ;
- Agile infrastructure : Fast 、 A platform that can repeatedly and consistently provide application environment and background services ;
- Based on application program interface (
Application Programming Interface, API) Cooperation : Release and versioningAPI, Allow interaction between services in the cloud native application architecture ; - Compression resistance : The system has good robustness , It can resist the unexpected flow impact of the outside world .
In a narrow sense , Cloud natives contain containers 、 Microservices 、 Continuous integration and continuous release (Continuous Integration/Continuous Delivery,CI/CD) Cloud native technology represented by , Use a new way to build 、 Deploy 、 Operation and maintenance application .
In a broad sense , Cloud primitives design and develop application systems completely based on distributed Cloud Architecture , It is a building software that fully uses cloud services . With the continuous development and enrichment of cloud computing technology , Many users use the cloud , It is no longer simply renting cloud vendor infrastructure in the early days ( Calculation 、 Storage 、 The Internet ) etc. IaaS resources .
02 Why cloud primitives are needed

The core idea of the cloud is elastic , In the past, we often used virtualization as the cloud platform and the interface to interact with customer systems , It not only brings flexibility to the enterprise, but also brings a certain degree of management complexity . The emergence of containers , It encapsulates a layer of virtualization , It has gradually become one of the new interfaces for cloud platform and interaction with customer systems , Application building 、 Distribution and delivery To achieve standardization at this level , A big reduction in business IT Implementation and O & M costs , Improve the efficiency of business innovation .
① Complex business requires cloud native services : In the microservices architecture , The number of applications has increased significantly , performance 、 Consistency and other problems are becoming more and more serious , The architecture is getting more and more complex , The governance of a large number of services has also become challenging , How to deal with and solve these problems ? The emergence of cloud native technology decouples many complexities :
- With
DockerAs the representative of container technology, it realizes the decoupling between application and running environment , Many business application loads can be containerized , And application containerization satisfies agile 、 Moveable 、 The need for Standardization . KubernetesThe emergence of realizes the decoupling of resource scheduling and underlying infrastructure , Application and resource management and control also began to be handy , Container choreography implements resource choreography 、 Efficient scheduling .- With
IstioService grid technology, represented by, realizes the decoupling between service implementation and service governance .
② Business innovation requires cloud nativity : Internet companies often mention that they implement it dozens of times a day , Even hundreds of releases . Why is frequent publishing so important ?
- If you can release hundreds of times a day , Then you can recover from the wrong version almost immediately ; If you can recover from your mistakes immediately , Then you can take more risks ; If you can take more risks , Then you can do more “ insane ” The results of these tests may be your next competitive advantage .
③ Business uncertainty requires cloud nativity : throughout IT Development history of application server : The mainframe → minicomputer →x86 The server → virtual machine → Containers →Serverless, It is developing towards lightweight , This is also in line with the strategy of cloud native agile infrastructure . Lightweight means better elasticity , Application deployment time is reduced accordingly : month ( The mainframe )→ God ( minicomputer )→ Hours (x86 The server )→ minute ( virtual machine )→ second ( Containers )→ millisecond (Serverless). Extreme flexibility is an effective means for enterprises to solve business uncertainty .
03 Cloud native design principles
① The principle of decentralization : Centralization means a single point , In order to have good linear expansion ability , Distributed systems require decentralization , Avoid single point of failure . For the service capability of the system , As resources join , The performance and capacity of microservices can scale linearly ;
② Loose coupling principle
- Implementation of loose coupling : That is, the service consumer does not need to rely on a specific implementation of the service contract , In this way, the internal changes of the service provider will not affect the consumer )
- Loose coupling of time : A typical asynchronous message queuing system , Because there are intermediaries , Producers don't have to wait for a reply right away
- Loose coupling of position : Typically a service registry , The consumer does not need to know the specific location of the server directly , And are accessed through the registry lookup service
- Version of loose coupling : The consumer does not need to rely on a particular version of the service contract to work , This requires the service contract to provide downward compatibility as much as possible when upgrading ;
③ Failure oriented design principles : In order to ensure the robustness of the system , A very important principle in the field of software design is , All external inputs and external dependencies are untrusted , Inter system dependent calls may fail at any time , It also includes hardware infrastructure services that may crash at any time , There may also be a bottleneck in the system capacity of back-end stateful services . In short, it can fail quickly when an exception occurs , Then quickly recover , To ensure that business is always online , You can't let the business stand still .
④ Stateless principle : The cloud native application service design is stateless as much as possible , Make the business inherently scalable , During peak and low traffic periods , Automatic elastic capacity expansion based on cloud characteristics 、 Shrinkage capacity , Meet business needs . Statelessness means that when a service processes a request , Do not rely on anything other than the request itself , There will be no additional operations other than responding to the request . There are two main ways to change from stateful to stateless .
- State separation : All state information of the server is uniformly stored in external independent distributed storage ( Caching 、 Message queue 、 database ).
- Request with all status information : Precede the status information , Enrich the input parameters of the request , Put the data to be processed into the input parameter through the upstream client as far as possible .
⑤ Invariance principle : The premise of realizing the invariance principle is , Every service in the infrastructure 、 Components can be installed automatically 、 Deploy , No human intervention is required . All resources can be pulled up at any time 、 Release at any time , At the same time API Provide flexibility in a way 、 On demand calculation 、 Storage capacity . Each service or component will not change after installation and deployment , If you want to change , Just discard the old service or component , And redeploy a service or component . in addition , To improve usability , We should try our best to reduce the time to repair , You should know that the replacement speed is much faster than the repair speed .
⑥ Automation driven principles : It is divided into continuous integration 、 Continuous deployment 、 Continuous delivery, etc , To ensure that the requirements are put forward 、 Design, development and testing , Then to the code fast 、 Safely deploy to production . Continuous integration is when a developer commits a change , Build it right away 、 automated testing , Ensure that business applications and services meet expectations , Thus, it can be determined whether the new code and the original code can be correctly integrated . Continuous deployment refers to the automatic submission of each change to the test environment using a fully automated process , Trigger automated test cases , After passing the test and verification, the application is safely deployed to the production environment , Get through development 、 test 、 Production and other links . Continuous delivery is the ability of software release , After continuous integration , It can be provided to environments such as pre release , Meet the conditions of the production environment .
边栏推荐
- Irregular naming
- 3DE save to Favorites
- replacement has 2 rows, data has 0, 解决R语言如何动态生成dataframe
- Sword finger offer 68 - I. nearest common ancestor of binary search tree
- 76. 最小覆盖子串-滑动窗口法
- mysql-索引创建、优化分析、索引优化
- 2022.6.21-----leetcode. one thousand one hundred and eight
- 指针与指针的指针
- Shelling of ESP law of reverse crackme
- [netding Cup 2018] fakebook1 reference
猜你喜欢
随机推荐
DM达梦数据的关键字与表的字段冲突的解决办法
Using jemalloc to solve the memory overflow problem of Flink
cmd看控制台输出红桃、方块、黑桃、梅花乱码解决
How did we solve the realsense color bias problem?
Introduction and use of kubernetes
AtCoder Beginner Contest 252(dijkstra,逆向思维)
我们如何解决了RealSense偏色问题?
618来袭,当贝X3和极米H3S怎么选?带你全方位深度解析
3DE recover from design
利用jemalloc解决flink的内存溢出问题
如何高效的读写文件思考
If you specify it as a gateway, does it become a gateway
How to break through the sales dilemma of clothing stores
Why is the first program a programmer writes "Hello world!"
Policy mode
1690. 石子游戏 VII-动态规划法
Decorator II property - short answer logic
3de从设计中恢复
剑指 Offer 68 - II. 二叉树的最近公共祖先
3de 机器人吸盘抓box









