当前位置:网站首页>From monomer structure to microservice architecture, introduction to microservices
From monomer structure to microservice architecture, introduction to microservices
2022-07-06 07:59:00 【Frog at the bottom of the well】
Monomer architecture VS Microservice architecture
1.1 Starting from the single architecture
One project corresponds to one archive package (war)
, This war package The work of the project includes all the work
can . We become this application as a monomer application , That is what we often call monomer architecture ( One
war try to do everything all by oneself ).
A detailed description : It's in one of our war In bag , It gathers various functions and resources , such as JSP、JS、CSS、HTML etc. .
The business includes our user module , Order module , Payment module and so on .
Single structure diagram
1.3 Summary of advantages and disadvantages of monomer structure
advantage :
- Simple and clear architecture , No, ” tart “ The problem needs to be solved .
- Development , test , Simple deployment ( Especially the operation and maintenance personnel You'll wake up laughing when you're asleep )
shortcoming :
- As the business expands , The code is getting more complicated , The quality of the code is uneven ( The level of developers varies ), Will let you submit code every time , Modify every little bug All are heart startling and gallbladder trembling -- be deeply Of .
- Slow deployment ( Due to the monomer Architecture , Complex functions ) Imagine the next one coming from 200W+ The speed of code deployment .
- High expansion cost , According to the monomer architecture diagram Suppose the user module is a CPU intensive Module ( It involves a lot of operations ) So we need to replace something more powerful CPU, And our order module is a IO Dense modules ( It involves a lot of reading and writing disks ), Then we need to replace more powerful memory and efficient disks . But in our monomer Architecture Cannot be extended for a single function module , Then you need to replace something more powerful CPU More powerful memory Better disks The price goes up slowly .
- Hindering the development of new technology … Like our web Architecture module from struts2 Migrate to springboot, Then it will become disastrous
2、 Microservices and microservice architecture
2.1 Definition of microservices
The core of microservice is to integrate the traditional stand-alone application , Separate stand-alone applications into one by one according to business service , Complete decoupling , Each service provides a specific function , A service does only one thing , Similar process , Every service can Separate deployment , You can even own your own database . Such a small service is Microservices .
For example, traditional stand-alone e-commerce applications , A mall system has
Order / payment / stock / logistics / integral
Equal module ( Understood as aservcie
)We according to the business model To split , It can be divided into
Order service
,Payment services
,Inventory service
,Logistics services
,Points service
If you don't split it , My non core business points module There's something big bug Cause system memory overflow , Cause the whole system to go down .
If after splitting , It's just that my point and micro service is not available , The core function of my whole system is still Be able to use .
A big man has a good summary of the definition and understanding of microservice , Here I just quoted some simple language to understand microservices , For more information, please refer to the boss blog :http://blog.cuicc.com/blog/2015/07/22/microservices/
2.2 Expansion of stand-alone architecture and microservice
// To be continued , Have time to continue writing
边栏推荐
- 继电反馈PID控制器参数自整定
- Golang DNS 随便写写
- Circuit breaker: use of hystrix
- Le chemin du navigateur Edge obtient
- Key value judgment in the cycle of TS type gymnastics, as keyword use
- C # display the list control, select the file to obtain the file path and filter the file extension, and RichTextBox displays the data
- Comparison of usage scenarios and implementations of extensions, equal, and like in TS type Gymnastics
- Linked list interview questions (Graphic explanation)
- NFT smart contract release, blind box, public offering technology practice -- contract
- (lightoj - 1410) consistent verbs (thinking)
猜你喜欢
Apache middleware vulnerability recurrence
Nft智能合约发行,盲盒,公开发售技术实战--合约篇
Nft智能合约发行,盲盒,公开发售技术实战--拼图篇
datax自检报错 /datax/plugin/reader/._drdsreader/plugin.json]不存在
wincc7.5下载安装教程(Win10系统)
Golang DNS write casually
Data governance: 3 characteristics, 4 transcendence and 3 28 principles of master data
[t31zl intelligent video application processor data]
[nonlinear control theory]9_ A series of lectures on nonlinear control theory
Solution: intelligent site intelligent inspection scheme video monitoring system
随机推荐
In the era of digital economy, how to ensure security?
Get the path of edge browser
Machine learning - decision tree
Risk planning and identification of Oracle project management system
上线APS系统,破除物料采购计划与生产实际脱钩的难题
【云原生】手把手教你搭建ferry开源工单系统
On why we should program for all
Data governance: metadata management
[count] [combined number] value series
数据治理:元数据管理篇
The State Economic Information Center "APEC industry +" Western Silicon Valley will invest 2trillion yuan in Chengdu Chongqing economic circle, which will surpass the observation of Shanghai | stable
Artcube information of "designer universe": Guangzhou implements the community designer system to achieve "great improvement" of urban quality | national economic and Information Center
Description of octomap averagenodecolor function
将 NFT 设置为 ENS 个人资料头像的分步指南
Inspiration from the recruitment of bioinformatics analysts in the Department of laboratory medicine, Zhujiang Hospital, Southern Medical University
[Yugong series] creation of 009 unity object of U3D full stack class in February 2022
Wireshark grabs packets to understand its word TCP segment
Data governance: data quality
The Vice Minister of the Ministry of industry and information technology of "APEC industry +" of the national economic and information technology center led a team to Sichuan to investigate the operat
Codeforces Global Round 19(A~D)