当前位置:网站首页>Personal thoughts on Architecture Design (this article will be revised and updated continuously later)
Personal thoughts on Architecture Design (this article will be revised and updated continuously later)
2022-07-04 19:34:00 【RichardGeek】
Preface
lately , Participated in many internal or external technical architecture sharing , In the process of personal learning, I often occasionally post on various blogs 、 In other cases, such as official account articles, we often see resources about architecture design .
There are many design ideas that can be used for reference , This article aims at personal superficial understanding , Make personal summary and record , For reference only . Key design ideas such as Trade Off( Balance )、 The robustness considerations of the architecture include but are not limited to three high ( High performance 、 Highly reliable 、 High concurrency ) etc. 、DDD Domain design ( Such as domain events 、 Add anti-corrosion coating )、 layered design idea (MVC framework 、 Adaptive layer 、 similar DDD Anticorrosive coating Transformation Data Data conversion layer 、 Business tier and storage tier ) And so on decoupling Thoughts, etc .
Trade Off
” Balance “, This idea is a design concept that I find interesting and personally agree with recently . There is a popular saying about architecture design ” quotes “: There is no perfect architecture , Only the most appropriate and suitable architecture .
This trade-off involves many factors , Such as the current business scenario 、 The landing cost of the feasible technical scheme ( Machine cluster budget cost 、 Developer labor costs 、 Post operation and maintenance costs, etc ), In short , Some decisions are needed Boss Level consideration , It is input and output trade off. To achieve the current optimal architecture scheme at the lowest cost is “ king ”.
Highly reliable
In addition to simply setting up a service cluster , Add copy and other conventional design ideas . From some special ” spot “ Ability to be highly reliable .
Consistent and reliable data
For example, in the business scenario of service design and implementation, consider the key “ Business node ”、“ Milestones ” Check the reliability of data .
Design ideas such as : Before the business logic is triggered 、 Trigger process 、 After the completion of the key stage, do the corresponding treatment .” Pre storage snapshots or notifications 、 Mid - check、 Post reconciliation “. Do a good job in snapshot data storage 、 Event notification or "double check" Data snapshot reconciliation, etc . consider ODPS Flink/Spark Near real time / offline Stream data analysis , comparison . The unified data of the central data center is quasi real-time 、MQ Event notification & retry 、 backstage Job Task check&alarm etc. 、 Solutions for distributed transactions, such as TCC/2PC/3PC/ Message record table, final consistency, flexible transaction, etc .
High concurrency
There are often ” Lock “ Design idea , Some... Used to guarantee concurrency ” The order “ Feature scenario . Distributed locking scenarios are common, such as using other middleware : Such as Redis Of lua Script /setNx/watch Dog/Redission wait ,zookeeper The order of temporary nodes plus watch Mechanism ,mysql Wait for the pessimistic lock of the database Such as select ... from table where status=' ' for update etc. .
Except for the similar “ Pessimistic locking ” The implementation of the ( It has a great impact on concurrent performance , It's similar to the above trade off The concept of trade-offs ), It can also be used ” Optimism lock “ Such as CAS(compare and swap) Ideas . prevent ABA problem You can add a list of snapshot version numbers to ensure . mysql Examples of optimistic locking implemented by the library are update .... where status=' ' and snapshot_version=' ';
The process stage of architecture design
research - Technology selection
Focus assessment :
1、 Investigate the ecological environment of related technologies . Such as the activity of the technology community 、 Prospects for sustainable development in the future
2、 Study 、 Development cost problem . New technology ” Get started “ Efficiency of the 、 Secondary development ability in the later stage 、 Team acceptance ( Such as whether cross language , Cross technology stack )
3、 Compare the advantages and disadvantages of the technical framework or architecture direction horizontally and vertically . Such as three high (AP or CP) Implementation and support of 、 Long term consideration of possible follow-up “ transfer ” cost 、 Whether it supports cross machine room 、 Multi data center storage 、 Multi cluster and multi tenant isolation 、 The smoothness of data migration
4、 Evaluate performance .CPU、Mem、 The Internet IO、 Minimum support for machine performance, such as disk occupancy . High concurrency Multi Request、 throughput 、 Response time RT、 Fault tolerance and other indicators
etc...
Demo - Realize trial
Performance evaluation & Pressure measurement
Grayscale - Try it on a small scale
Comprehensive upgrading & Use
边栏推荐
- Online sql to excel (xls/xlsx) tool
- 1003 Emergency(25 分)(PAT甲级)
- Reflection (I)
- Shell 編程核心技術《四》
- The 15th youth informatics competition in Shushan District in 2019
- 联想首次详解绿色智城数字孪生平台 破解城市双碳升级难点
- 用实际例子详细探究OpenCV的轮廓绘制函数drawContours()
- Detailed explanation of issues related to SSL certificate renewal
- 26. 删除有序数组中的重复项 C#解答
- The page element is vertically and horizontally centered, realizing the vertical and horizontal centering of known or unknown width.
猜你喜欢

勾股数规律(任意三个数能够满足勾股定理需要满足的条件)

How to use async Awati asynchronous task processing instead of backgroundworker?

Use canal and rocketmq to listen to MySQL binlog logs

如何使用Async-Awati异步任务处理代替BackgroundWorker?

2022CoCa: Contrastive Captioners are Image-Text Fountion Models

读写关闭的channel是啥后果?

BI技巧丨权限轴

与二值化阈值处理相关的OpenCV函数、方法汇总,便于对比和拿来使用

MySQL数据库基本操作-DDL | 黑马程序员
关于判断点是否位于轮廓内的一点思考
随机推荐
1006 Sign In and Sign Out(25 分)(PAT甲级)
牛客小白月赛7 I 新建 Microsoft Office Word 文档
There are multiple divs in the large div, which are displayed on the same line. After overflow, scroll bars are generated without line breaks
PointNeXt:通过改进的模型训练和缩放策略审视PointNet++
《看完就懂系列》字符串截取方法substr() 、 slice() 和 substring()之间的区别和用法
Opencv functions and methods related to binary threshold processing are summarized for comparison and use
2021 Hefei informatics competition primary school group
Comment utiliser async awati asynchrone Task Handling au lieu de backgroundworker?
LeetCode第300场周赛(20220703)
sqlserver的CDC第一次查询的能读取到数据,但后面增删改读取不到,是什么原因
HDU 6440 2018中国大学生程序设计网络选拔赛
[release] a tool for testing WebService and database connection - dbtest v1.0
【问题】druid报异常sql injection violation, part alway true condition not allow 解决方案
The difference and usage between substr (), slice (), and substring () in the string interception methods of "understand series after reading"
反射(一)
Bi skills - permission axis
ftp、sftp文件传输
Wechat reading notes of "work, consumerism and the new poor"
用实际例子详细探究OpenCV的轮廓绘制函数drawContours()
Pointnet/Pointnet++点云数据集处理并训练