Dynamically meeting performance objectives for multiple services on a service mesh Forough Shahab Samaniyand Rolf Stadlery

2025-05-03 0 0 935.05KB 9 页 10玖币
侵权投诉
Dynamically meeting performance objectives for
multiple services on a service mesh
Forough Shahab Samani and Rolf Stadler
Dept. of Computer Science, KTH Royal Institute of Technology, Sweden
Email: {foro, stadler}@kth.se
October 11, 2022
Abstract—We present a framework that lets a service provider
achieve end-to-end management objectives under varying load.
Dynamic control actions are performed by a reinforcement
learning (RL) agent. Our work includes experimentation and
evaluation on a laboratory testbed where we have implemented
basic information services on a service mesh supported by the
Istio and Kubernetes platforms. We investigate different manage-
ment objectives that include end-to-end delay bounds on service
requests, throughput objectives, and service differentiation. These
objectives are mapped onto reward functions that an RL agent
learns to optimize, by executing control actions, namely, request
routing and request blocking. We compute the control policies not
on the testbed, but in a simulator, which speeds up the learning
process by orders of magnitude. In our approach, the system
model is learned on the testbed; it is then used to instantiate
the simulator, which produces near-optimal control policies for
various management objectives. The learned policies are then
evaluated on the testbed using unseen load patterns.
Index Terms—Performance management, reinforcement learn-
ing, service mesh, digital twin
I. INTRODUCTION
End-to-end performance objectives for a service are difficult
to achieve on a shared and virtualized infrastructure. This
is because the service load often changes in an operational
environment, and service platforms do not offer strict resource
isolation, so that the resource consumption of various tasks
running on a platform influences the service quality.
In order to continuously meet performance objectives for a
service, such as bounds on delays or throughput for service
requests, the management system must dynamically perform
control actions that re-allocate the resources of the infras-
tructure. Such control actions can be taken on the physical,
virtualization, or service layer, and they include horizontal and
vertical scaling of compute resources, function placement, as
well as request routing and request dropping.
The service abstraction we consider in this paper is a
directed graph, where the nodes represent processing functions
and the links communication channels. This general abstrac-
tion covers a variety of services and applications, such as a
network slice on a network substrate, a service chain on a
softwarized network, a micro-service based application, or a
pipeline of machine-learning tasks. We choose the service-
mesh abstraction in this work and apply it to micro-service
based applications.
In this paper, we propose a framework for achieving end-
to-end management objectives for multiple services that con-
currently execute on a service mesh. We apply reinforcement
learning (RL) techniques to train an agent that periodically per-
forms control actions to reallocate resources. A management
objective in this framework is expressed through the reward
function in the RL setup. We develop and evaluate the frame-
work using a laboratory testbed where we run information
services on a service mesh, supported by the Istio and Kuber-
netes platforms [1],[2]. We investigate different management
objectives that include end-to-end delay bounds on service
requests, throughput objectives, and service differentiation.
Training an RL agent in an operational environment (or
on a testbed in our case) is generally not feasible due to
the long training time, which can extend to weeks, unless
the state and action spaces of the agent are very limited.
We address this issue by computing the control policies in
a simulator rather than on the testbed, which speeds up the
learning process by orders of magnitude for the scenarios
we study. In our approach, the RL system model is learned
from testbed measurements; it is then used to instantiate
the simulator, which produces near-optimal control policies
for various management objectives, possibly in parallel. The
learned policies are then evaluated on the testbed using unseen
load patterns (i.e. patterns the agent has not been trained on).
We make two contributions with this paper. First, we present
an RL-based framework that computes near-optimal control
policies for end-to-end performance objectives on a service
graph. This framework simultaneously supports several ser-
vices with different performance objectives and several types
of control operations.
Second, as part of this framework, we introduce a simulator
component that efficiently produces the policies. Through
experimentation, we study the tradeoff of using the simulator
versus learning the policies on a testbed. We find that while
we lose some control effectiveness due to the inaccuracy of
the system model we gain by significantly shortening the
training time, which makes the approach suitable in practice.
To the best of our knowledge, this paper is the first to
advocate a simulation phase a part of implementing a dynamic
performance management solution on a real system.
Note that, when developing and presenting our framework,
we aim at simplicity, clarity, and rigorous treatment, which
helps us focus on the main ideas. For this reason, we choose
a small service mesh for our scenarios (which still includes
key complexities of larger ones), we consider only two types
1
arXiv:2210.04002v1 [cs.LG] 8 Oct 2022
of control actions, etc. Our plan is to refine and extend the
framework in future work, as we lay out in the last section of
the paper.
II. PROBLEM FORMULATION AND APPROACH
TABLE 1
Notation for formalizing the problem.
Concept Notation
Service index i
Node index j
Offered load of service i li
Carried load of service i lc
i=li(1 bi)
Utility of service i ui
Response time objective Oi
Response time di
Routing weight of service i pij
towards node j
Blocking rate bi
We consider application services built from microservice
components, whereby each component performs a unique
function. A service request traverses a path on a directed graph
whose nodes offer microservices. Figure 1(a) shows a directed
graph with a general topology of a microservice architecture,
which we call a service mesh. A service is realized as a
contiguous subgraph on the service mesh.
While the framework we present in this paper applies to the
general service mesh of Figure 1(a), we focus the discussion
and experimentation on the smaller configuration shown in
Figure 1(b). An incoming service request from a client is
processed first by the front node, before being routed to one
of the two processing nodes. The processing result is sent to
the responder node which sends it to the client.
We consider two services Siwith different resource require-
ments on the processing nodes. In the configuration in Figure
1(b), both processing nodes can process requests from both
services. We express the service quality in terms of end-to-
end delay diof a service request, the carried load of a service
lc
i(which we also call the throughput of the service), or the
utility uigenerated by a service.
In order to control the service quality, our framework
includes control actions. In this work, we consider request
routing expressed by pij [0,1] which indicates the fraction
of requests of service irouted to processing node j. In
addition, we consider blocking service requests at the front
node at the fraction bi[0,1].
Central to this work are management objectives, which
capture the end-to-end performance objectives for the services
on a given service mesh. These objectives include client
requirements, as well as provider priorities. To present and
evaluate our framework, we focus on the following three
management objectives. See Table 1 for notation.
Management Objective 1 (MO1): the response time of a
request of service iis upper bounded by Oiand the overall
carried load is maximized:
maximize X
i
lc
iwhile di< Oi(1)
(a) Directed graph of a service mesh
(b) Use case in this work
Fig. 1. (a) General service mesh; each processing node runs one or more
microservices; links are communication channels for service requests. (b)
Service mesh of the use case; dij is the processing delay of a request of
service ion node j;pij is the routing weight of request itowards node j.
Management Objective 2 (MO2): the response time of a
request of service iis upper bounded by Oiand the sum of
service utilities is maximized:
maximize X
i
uiwhile di< Oi(2)
Management Objective 3 (MO3): the response time of a
request of service iis upper bounded by Oi, the carried load
lc
iof service iis maximized, while service kis prevented from
starving (i.e., by specifying a lower threshold lmin for service
k):
maximize lc
iwhile di< Oiand lc
k> lmin i6=k(3)
For the management objective M1, M2, or M3, we solve
the following problem for the configuration in Figure 1(b).
Given the offered load of service i, and the response time di,
we need to find the control parameters pij and bi. We obtain
these parameters through reinforcement learning where they
represent the optimal policy.
Following the reinforcement learning approach, we formal-
ize the above problem as a Markov Decision Process (MDP),
which is a well-understood model for sequential decision
making [3][4]. The elements of this formalization for the
scenario in Figure 1(b) are:
State space: The state at time tincludes the response time
and offered load of the services running on the service mesh:
st∈ {(di,t, li,t)R2m|i= 1, ..., m}=S, where m is the
number of services.
2
摘要:

DynamicallymeetingperformanceobjectivesformultipleservicesonaservicemeshForoughShahabSamaniyandRolfStadleryyDept.ofComputerScience,KTHRoyalInstituteofTechnology,SwedenEmail:fforo,stadlerg@kth.seOctober11,2022Abstract—Wepresentaframeworkthatletsaserviceproviderachieveend-to-endmanagementobjectivesund...

展开>> 收起<<
Dynamically meeting performance objectives for multiple services on a service mesh Forough Shahab Samaniyand Rolf Stadlery.pdf

共9页,预览2页

还剩页未读, 继续阅读

声明:本站为文档C2C交易模式,即用户上传的文档直接被用户下载,本站只是中间服务平台,本站所有文档下载所得的收益归上传人(含作者)所有。玖贝云文库仅提供信息存储空间,仅对用户上传内容的表现方式做保护处理,对上载内容本身不做任何修改或编辑。若文档所含内容侵犯了您的版权或隐私,请立即通知玖贝云文库,我们立即给予删除!
分类:图书资源 价格:10玖币 属性:9 页 大小:935.05KB 格式:PDF 时间:2025-05-03

开通VIP享超值会员特权

  • 多端同步记录
  • 高速下载文档
  • 免费文档工具
  • 分享文档赚钱
  • 每日登录抽奖
  • 优质衍生服务
/ 9
客服
关注