当前位置:网站首页>Talk about relational database and serverless
Talk about relational database and serverless
2022-07-07 21:40:00 【Alibaba cloud yunqi】
brief introduction : See now Serverless In the cloud computing industry , It's like 《 sparks of fire , Can start a prairie fire 》 Description in : Although it can not predict the future development and changes , But for cloud computing, this is a relatively certain direction . This paper starts from the industry and academia , Talk about relational databases and serverless There are many kinds of Technology .
It's a ship standing on the coast and looking out into the sea, with its masts pointed , It is standing on the top of the mountain and looking at the East, it has seen a round of sunrise , It is a mature baby restless in the mother's abdomen .
-- sparks of fire , Can start a prairie fire
One 、 About Serverless
See now Serverless In the cloud computing industry , It's like 《 sparks of fire , Can start a prairie fire 》 Description in : Although it can not predict the future development and changes , But for cloud computing, this is a relatively certain direction .
from Google Trends Of Serverless The trend of keywords can be seen , about Serverless The search rate has been high , And it will also maintain a considerable heat in the future . from 2015 Year begins , With AWS Major cloud computing companies at home and abroad, represented by, are also constantly laying out Serverless Related products ,AWS Lambda、Aliyun FAAS, Research progress in the field of database Aurora Serverless、RedShift Serverless、Azure SQL Database etc. .
The academic community is right Serverless The research heat of is no less than the pursuit of commercialization scheme in the industry , At the end of the paper, some related articles are listed for reference . For Cloud Computing Serverless The trend of evolution , Academia has also experienced some doubts ,2018 year “Serverless Computing: One Step Forward, Two Steps Back”[3] The article once wrote about Serverless The development of IT There have been concerns about the impact of infrastructure , but 2019 In, the same group of people showed support and optimism in this direction . from Serverless The field has been cited more times , Mainstream scientific research institutions are right Serverless The trend and direction of research tend to be consistent , The focus of the research has gradually shifted from “why” Turn into “how”[6].
What is the Serverless? Why? Severless It's a trend ?“Cloud Programming Simplified: A Berkeley View on Serverless Computing”[5] This article makes a comprehensive analysis and prediction for the representatives . The same is Berkeley stay 2009 Another article published in “Above the Clouds: A Berkeley View of Cloud Computing”[7] Predicted cloud computing as IAAS Infrastructure perspective . This article continues the previous style , The current situation and difficulties are analyzed , Predicted Cloud Computing 2.0 The form of Serverless As the next generation infrastructure , It also defines Serverless The main three characteristics of :
Decoupling and servitization of resources :
Weakening the link between storage and Computing . The storage and calculation of services are deployed and charged separately , Storage is no longer part of the service itself , Instead, it evolved into an independent cloud service . This makes the computation stateless , Easier to schedule and expand , At the same time, it also reduces the risk of data loss .
Auto flex
:
Code execution no longer requires manual allocation of resources . There is no need to specify the required resources for the operation of the service ( For example, using several machines 、 How much bandwidth 、 How big the disk is ), Just provide a copy of the code , Leave the rest to Serverless Just deal with it on the platform . At the current stage, the implementation platform needs to provide some strategies when allocating resources , For example, the specification and maximum concurrency of a single instance , The maximum of a single instance CPU Usage rate . Ideally, some machine learning algorithms are used to perform fully automatic adaptive allocation .
Charge by usage
:
Serverless According to the usage of the service ( Call the number 、 Wait a long time ) charging , Not like the traditional Serverful The service is like that , According to the resources used (ECS example 、VM The specifications of ) charging .
It is worth mentioning that [5] This article has the endorsement of many cloud computing vendors , Include AWS、Micorsoft、Google、Alibaba etc. , At the same time, the article also directly uses AWS Lambda Services are analyzed as templates Serverless The problem of . And in combination with AWS After the Serverless We can see from the various services launched in the direction , In fact, this article fits AWS stay Serverless Evolution plan on , There will be specific analysis later .Serverless Its own technical difficulty , This article lists many contents , I won't elaborate here , You can read the article in detail .
About Serverless Technology realization of [3] A feasible system implementation method is given , Of course FAAS In the background . Mentioned Serverless Key technology paths include :
- The unified standard runtime environment supports the unified management of multi language runtime
- Lightweight / Fly level safety container ( stay [4] The importance of safety and isolation is additionally mentioned in )
- The cooling and heating capacity pool is designed to achieve the ultimate multi tenant reuse capability
- Efficient function scheduling capability
among , The implementation of function calculation , But with the database Serverless Is closely linked .
Two 、 Database Serverless
There are many kinds of databases , Relational databases are self-contained 1979 year E. F. Codd Description of the relational model [7] Start , Most of the latecomers just imitate , It has not yet surpassed the user acceptance and scale .
A database is more than just a “stateful” Application , And it's a “state-heavy” Application . The database is Serverless One of the most unfriendly applications , Including cloud native infrastructure kubernates about stateful Application support , Wait until StatefulSet and operator Then there is a better solution . Before that, databases were used as Serverless Tools for decoupling and sinking states , It's also the whole stack Serverless The last bastion of the solution .
about Serverless The definition of , The article gives a formula :Serverless = FAAS+ BAAS. take FAAS(Functions as a Service) Defined as an event 、API、 Message driven computing layer ; take BAAS(Backends as a Service ) Defined as a similar database 、 Back end services such as message queues .
“State-heavy applications will remain as BaaS” It is a basic understanding of database at present , But this is related to whether the database itself has a certain degree of Serveless Ability is actually two different things . The former emphasizes the application of Serverless During the process of architecture transformation , A large amount of state storage in the database cannot FAAS This is the ability to open and use , Only as “+” To connect Serverless ecology ; The latter says that to some extent, it can also meet “ Resource decoupling ”、“ Auto elastic ”、“ Pay per use ” Characteristics , To some extent, it can also be regarded as Serverless.
database Serverless What is the difficulty of ?
The database does Serverless There are several difficulties [4], Summarized below :
- Serverless No built-in persistent storage , Need to rely on remote storage , This results in a higher delay ;
- The client accesses the database based on the connection , On the client side, the connection pool is often maintained to provide access , And function calculation often has erratic network address , Traditional with database IP+User+password The authentication methods are quite different ;
- Many high-performance databases use shared memory technology , and FAAS It does not have the ability to share memory , It will make the calculation inconsistent with the resource dynamic expansion capability before the database
One of the most important things to pay attention to is 2 spot , In application FAAS after , The current database access method is no longer applicable to Serverless ecology :
- The server and DB Keep the connection , This means that the access state is maintained by both the client and the database , and FAAS Inability to maintain connectivity ;
- Server pass driver And connection pool , Each connection initialization is relatively heavy ,FAAS Can't afford such heavy connection initialization work on ;
- The server access authentication passed user/password/ip To access the database , and FAAS The multi tenant scenario is shared by all users IP Address pool ,user/password Built in to FAAS It also exposes great security risks ;
The database needs a new way to access , It directly affects whether the database can be used as Serverless Part of the ecology , Directly affect the current Serverless The application does the whole stack Serverless reform . It is even more important than the database Serverless( Resource decoupling 、 Ultimate flexibility 、 Pay by usage, etc ) In itself .
Of course, the database itself needs to do more than that , The database itself should achieve efficient spring up and spring down , It involves more control and close interaction with the kernel .
3、 ... and 、 His shan zhishi
Industry leaders AWS stay Serverless The relevant layouts are from 2015 Launched in 2013 Lambda Start , Leading the development in this direction . More attention is paid to the database , combination AWS stay Aurora Serverless The trade-offs on the Internet , Insight AWS For the database Serverless The understanding of the .
from Aurora Serverless V1 Published in 2018 year , stay Serverless Has made bold innovations in the concept of , Did a few things :
- With ACU To unify the underlying resources , No longer expose the specific model and algebra of the bottom layer to the upper layer .1ACU“ amount to ”2GiB Of RAM, Standardized and normalized the underlying resources . This is related to Serverless Decoupling of resources in the concept 、 And shielding the underlying resources ;
- Support automatic start and stop , It supports lowering the computing node to... Under no load “0”. take Serverless Paying by the amount of resources used is the ultimate , But it also brings about other problems . The automatic start and stop needs to be pulled up for the first time in general scenarios 30s about , Part of it was sacrificed auto scale The ability of ;
- Kernel related in the process of database elasticity buffer pool And other parameters change with the change of resource coordination , This is also some special processing required for this special application scenario of database ;
- 2019 Launched in 2013 Data API function , Complete the database as BAAS Access FAAS The ability of , It solves the problem of ecological compatibility mentioned above .
2020 Published in Aurora Serverless V2 And provide the application for internal test , And not long ago V2 Also formal GA. from Aurora Serverless V2 In terms of ability , stay Serverless Ability has been enhanced and trade-offs have been made :
- take V1 The medium elasticity ability continues to increase to the second level , Do extremely fast elasticity . take V1 The mid span machine upgrade capability is optimized to the local upgrade capability , Ensure that the business is not damaged in the process of elasticity . from Aurora Serverless Only in 3.0.2 It can be seen from the support of this version , The kernel layer is for Serverless The scene has also been greatly optimized ;
- In addition to the V1 About the ability of automatic start and stop , You can manually start and stop instances ; Pay more attention to the instance auto scale Ability , The minimum resources are reduced to 0.5ACU Instead of 0, At the expense of part of the capacity to pay by volume , This is also a trade-off ;
- Make the strategy of elastic volume reduction more conservative , To ensure that the impact on the business under business pressure is as small as possible .
from V1 To V2 The change of , contrast V2 and V1 Of User Case It can be seen that ,Aurora Serverless V2 The main solution is from “ Develop test environment ” Transition to a production environment in a limited scenario , As for the underlying implementation principle , It can be explored from the slightest trace . Combined with other cloud practices ,Serverless At present, we still attach importance to this concept , Each manufacturer is also approaching this concept with its own product form , As for the commercialization scheme of unifying industry standards , It's too early , There is great potential in this field .
in addition ,AWS Never in RDS Go ahead and realize Serverless Ability . According to insiders ,RDS MySQL The number of kernel developers is far less than Aurora Number of kernel developers , The main position is still DBA Mainly . It can be seen that , In open source managed products, we should do Serverless The ability of , It is much more difficult than in cloud native self-developed products . combination AWS Own product strategy , Open source hosting RDS Of Serverless We may never wait for that day .
Four 、 Future period
from 2009 Year begins , The capabilities of the cloud continue to grow , The essence of cloud is the pooling of resources , These resources include not only hardware resources , It also includes professional technical personnel 、 And the core technology patent standards . After ten years of fierce competition in terms of scale and cost ,IAAS Resources are also constantly moving towards Serverless Direction evolution of , Take Alibaba cloud itself as an example , Including elastic storage AutoPL、 An elastic container ECI、Serverless Service engine SAE. The enhancement of the underlying capabilities also means that the top PAAS Layer and the SAAS The service has a faster direction Serverless The path of evolution , Alibaba cloud database is the beneficiary PAAS.
From Eric 2022 Forecast the development trend of the database cloud management platform at the beginning of the year [9]、 And combine cloud trends with Serverless In itself , We can Aurora Severless Make some bold predictions about the future development direction :
- Intelligent blessing : from re:Invent2021 released Devops Guru See... On the product ,AWS Catching up in the intelligent scene . Built in intelligent engine for Serverless Can make more accurate predictions , Give Way “ Response type ” Upgrade the expansion to “ Responsive bottom pocket , Intelligent blessing ” Dual engine driven ;
- Resource decoupling and extreme flexibility : Shared memory technology 、Brust IO Ability will push Serverless Decoupling more resources , And carry out independent lifting configuration ;
- added Serverless methods : Capacity expansion is the most effective way to directly deal with database traffic , But with more intelligent means , pure “ Capacity expansion ” There are already more options , Automatic index optimization 、 Smart calling is a good option ;
- Automatic lateral expansion capability :scale out and scale up It can also cope with changes in business traffic , but scale out Is much more complex than scale out In itself , Is also a possible option ;
- Large scale use of low-cost hardware :ACU The unit definition of masked the underlying resource attributes ,ARM、x86 still RISC-V It's not that important anymore , The standardized computing power enables more types of hardware to be seamlessly connected to Serverless among .
Alibaba cloud RDS MySQL Also in the 4 Launched in April Serverless edition , We will focus on the following articles , We will use a standard website ( Front page +API The server + database ) As a template , How to FAAS+BAAS The next step is to build the whole stack Serverless The reconstruction of , Truly accomplish “0” The server .
reference
- 2016: "Emerging Technology Analysis: Serverless Computing and Function Platform as a Service", Gartner, Tech.
- 2017: "Serverless Computing: Current Trends and Open Problems", IBM Research
- 2017: "Serverless Computing:Design, Implementation, and Performance",IEEE 2017 ICDCSW
- 2018: "Serverless Computing: One Step Forward, Two Steps Back ", CIDR 2019
- 2019: "Cloud Programming Simplified: A Berkeley View on Serverless Computing", EECS 2019
- 2020: "Serverless Applications: Why, When, and How?", IEEE Software
- 2009: "Above the Clouds: A Berkeley View of Cloud Computing", EECS 2009
- 1970: "A relational model of data for large shared data banks", Commun. ACM 1970
- 2022: www.iresearch.com.cn/Detail/repo… IResearch
Link to the original text :click.aliyun.com/m/100034823…
This article is the original content of Alibaba cloud , No reprint without permission .
边栏推荐
- Intelligent transportation is full of vitality. What will happen in the future? [easy to understand]
- 95年专注安全这一件事 沃尔沃未来聚焦智能驾驶与电气化领域安全
- Wechat official account oauth2.0 authorizes login and displays user information
- L2:ZK-Rollup的现状,前景和痛点
- Ubuntu安装mysql8遇到的问题以及详细安装过程
- MySQL约束之默认约束default与零填充约束zerofill
- 解决uni-app中uni.request发送POST请求没有反应。
- 201215-03-19 - cocos2dx memory management - specific explanation "recommended collection"
- Codeforces round 275 (Div. 2) C – diverse permutation (construction) [easy to understand]
- 恶魔奶爸 B3 少量泛读,完成两万词汇量+
猜你喜欢
Demon daddy B3 read extensively in a small amount, and completed 20000 vocabulary+
Problems encountered in installing mysql8 for Ubuntu and the detailed installation process
解决uni-app中uni.request发送POST请求没有反应。
An overview of the latest research progress of "efficient deep segmentation of labels" at Shanghai Jiaotong University, which comprehensively expounds the deep segmentation methods of unsupervised, ro
NVR硬盤錄像機通過國標GB28181協議接入EasyCVR,設備通道信息不顯示是什麼原因?
Validutil, "Rethinking the setting of semi supervised learning on graphs"
NVR硬盘录像机通过国标GB28181协议接入EasyCVR,设备通道信息不显示是什么原因?
Virtual machine network configuration in VMWare
Solve the problem of using uni app mediaerror mediaerror errorcode -5
Debugging and handling the problem of jamming for about 30s during SSH login
随机推荐
Details of C language integer and floating-point data storage in memory (including details of original code, inverse code, complement, size end storage, etc.)
Ant destination multiple selection
UVA 12230 – crossing rivers (probability) "suggested collection"
Dry goods sharing | devaxpress v22.1 original help document download collection
Validutil, "Rethinking the setting of semi supervised learning on graphs"
Demon daddy guide post - simple version
MySQL约束之默认约束default与零填充约束zerofill
Arlo's troubles
Which financial products will yield high returns in 2022?
Google SEO external chain backlinks research tool recommendation
[200 opencv routines] 223 Polygon fitting for feature extraction (cv.approxpolydp)
智能交通焕发勃勃生机,未来会呈现哪些巨变?[通俗易懂]
Jetty: configure connector [easy to understand]
How to meet the dual needs of security and confidentiality of medical devices?
恶魔奶爸 B1 听力最后壁垒,一鼓作气突破
Ubuntu安装mysql8遇到的问题以及详细安装过程
恶魔奶爸 B2 突破语法,完成正统口语练习
Le capital - investissement est - il légal en Chine? C'est sûr?
L'enregistreur de disque dur NVR est connecté à easycvr par le Protocole GB 28181. Quelle est la raison pour laquelle l'information sur le canal de l'appareil n'est pas affichée?
Take the intersection of two sets