Font Size: a A A

The Design And Implementation Of Horizontal Scaling System For Microservice Application

Posted on:2022-02-10Degree:MasterType:Thesis
Country:ChinaCandidate:L YangFull Text:PDF
GTID:2518306494486644Subject:Electronics and Communications Engineering
Abstract/Summary:PDF Full Text Request
With the development and popularization of cloud-native technology,container virtualization technology represented by docker provides users with a more lightweight,simple,efficient and controllable way of resource pooling.Kubernetes is favored by major cloud manufacturers at home and abroad because of its powerful container layout ability.With the rapid change of these basic technologies,applications with cloud native architecture can maximize the use of cloud services and improve the ability of software continuous delivery.Large-scale cloud data centers that provide infrastructure guarantees for cloudnative applications are limited by service-side factors such as heterogeneous resources,diverse software and hardware configurations,complicated management rules,open application characteristics,mixed deployment of multiple types of loads and user-side factors such as the unbalanced distribution of time and space in the user's habit of accessing cloud services.As a result,resource utilization is generally low and redundancy is serious.The current horizontal scaling design of the community version of Kubernetes is too simple.It can only calculate the number of scaling replicas based on the real-time perceived load value and the predefined resource level threshold.Risk control mechanism of horizontal scaling is vacant and it is not suitable for the environment of industrial production.How to improve the efficiency of resource allocation and use while ensuring that Qo S does not damage is a hot issue that needs to be solved urgently.Aiming at the problem of Latency-Critical online applications that can't provide services in time,this thesis focuses on improving the efficiency of resource allocation and utilization based on the microservice scenario without violating the current SLA.The specific research work includes the following three aspects:(1)Proactive scaling strategy:This thesis chooses multiple time series prediction models to characterize the long-term stable traffic rules of online applications.Through comparing several common machine learning models such as ARIMA,LSTM,LightGBM and Cat Boost,this thesis chooses the proper model to predict the rate of flow in next cycle.Also,this thesis reasonably determines the QPS a single instance can serve.Finally,based on the principle of least resource per cycle,this thesis recommends the best number of replicas in each period.(2)Reactive scaling strategy:Since it is difficult to predict the flow change in the next cycle for online applications without obvious periodicity.In daily scenarios,reasonable target load threshold is recommended to maintain the stability of resource water level based on metrics guidance scaling.At the same time,the risk of capacity reduction is controlled by cooling period,progressive capacity reduction and middleware flow control.(3)The implementation of horizontal scaling system: In order to achieve the above two scaling strategies,this thesis builds a capacity platform as the central decisionmaking end,the kubernetes horizontal scaling component is extended as the executive end,the proactive scaling is carried out by configuring the capacity portrait,and the reactive scaling is carried out by recommending setting the target load threshold.In this way,it can not only guarantee Qo S without loss,but also improve the efficiency of resource allocation and utilization.
Keywords/Search Tags:Microservice, Kubernetes, Horizontal Autoscaler, Capacity Planning
PDF Full Text Request
Related items