Allocation control program and allocation control method

By determining resource allocation patterns and using horizontal scaling to adjust resources based on processing volume, the system optimizes resource allocation to microservices, preventing performance degradation and downtime.

JP7715991B2Active Publication Date: 2025-07-31FUJITSU LTD
View PDF 7 Cites 0 Cited by

Patent Information

Application Number
JP2021177001
Authority / Receiving Office
JP · JP
Patent Type
Patents
Current Assignee / Owner
Filing Date
2021-10-28
Publication Date
2025-07-31
Estimated Expiration
2041-10-28

AI Technical Summary

Technical Problem

Existing systems fail to appropriately control resource allocation to microservices, leading to potential quality deterioration of services.

Method used

Determine resource allocation patterns based on processing volume for each microservice, calculate allocation units, and adjust resources using horizontal scaling without restarting containers.

Benefits of technology

Optimizes resource allocation to each microservice, preventing performance degradation and downtime, ensuring consistent service quality.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure 0007715991000001
    Figure 0007715991000001
  • Figure 0007715991000002
    Figure 0007715991000002
  • Figure 0007715991000003
    Figure 0007715991000003
Patent Text Reader

Abstract

To adjust an amount of resources to be allocated to each of a plurality of microservices according to a processing amount for each of the plurality of microservices.SOLUTION: An information processing apparatus 101 determines, based on a processing amount measured for each of a related plurality of microservices (e.g., MS1 to MS3), a plurality of patterns for a resource allocation ratio to be horizontally scaled with regards to the plurality of microservices. The information processing apparatus 101 calculates, based on the determined allocation ratio for each of the plurality of patterns (e.g., pattern A, B), an allocation unit (e.g., allocation unit p,q,r) for each of the plurality of microservices to be horizontally scaled with the plurality of patterns. When horizontally scaling with any pattern of the plurality of patterns, the information processing apparatus 101 uses the calculated allocation unit for each of the plurality of microservices, for adjusting an amount of resources to be allocated to each of the plurality of microservices.SELECTED DRAWING: Figure 1
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to an allocation control program and an allocation control method.

Background Art

[0002] In recent years, in the development of IT (Information Technology) systems, an architecture has been used in which one service is divided into a plurality of microservices, and the microservices are connected to each other by an API (Application Programming Interface) or the like.

[0003] As a prior art, for each of a plurality of resources of each of a plurality of application instances, it is determined whether it is necessary to change at least one allocation of the plurality of resources, and operation requirements are calculated for each of the plurality of application instances. The calculated requirements include vertical increase and decrease operations, as well as horizontal division and folding operations.

[0004] Also, there is a technique for performing autoscaling to increase or decrease the number and resources of VMs / containers generated on a server. Further, when the resource usage amount of an application set satisfies a predetermined condition for resource scaling, there is a technique for executing a resource scaling process for each application in the application set according to a resource scaling policy corresponding to the predetermined condition.

Prior Art Documents

Patent Documents

[0005]

Patent Document 1

Patent Document 2

Patent Document 3

Summary of the Invention

Problems to be Solved by the Invention

[0006] However, in the prior art, it is not possible to appropriately control the amount of resources allocated to each of a plurality of related microservices, and the quality of the service may deteriorate.

[0007] In one aspect, the present invention aims to adjust the amount of resources allocated to each of a plurality of microservices according to the processing volume of each of the plurality of microservices.

Means for Solving the Problems

[0008] In one embodiment, based on the processing volume measured for each of a plurality of related microservices, a plurality of patterns of the allocation ratio of resources to be horizontally scaled for the plurality of microservices are determined, and based on the allocation ratio of each of the determined plurality of patterns, the allocation unit for each of the plurality of microservices for horizontal scaling in the plurality of patterns is calculated. When horizontally scaling in any one of the plurality of patterns, an allocation control program is provided that adjusts the amount of resources allocated to each of the plurality of microservices using the calculated allocation unit for each of the plurality of microservices.

Effects of the Invention

[0009] According to one aspect of the present invention, there is an effect that the amount of resources allocated to each of a plurality of microservices can be adjusted according to the processing volume of each of the plurality of microservices.

Brief Description of the Drawings

[0010]

Figure 1

Figure 2

Figure 3

Figure 4

Figure 5

Figure 6

Figure 7

Figure 8

Figure 9

Figure 10

Figure 11

Figure 12

Figure 13

Figure 14

Figure 15

Mode for Carrying Out the Invention

[0011] Hereinafter, with reference to the drawings, embodiments of the allocation control program and the allocation control method according to the present invention will be described in detail.

[0012] (Embodiment) FIG. 1 is an explanatory diagram showing an example of an allocation control method according to an embodiment. In FIG. 1, an information processing apparatus 101 is a computer that controls the amount of resources allocated to each of a plurality of related microservices. A microservice is software that realizes an architecture in which one service is divided by function, or each of the functions obtained by dividing one service.

[0013] For example, by dividing one service into a plurality of microservices, it becomes easier to add functions and perform maintenance, leading to an improvement in the development speed. Resources are resources shared by a plurality of microservices, and are, for example, a CPU (Central Processing Unit), memory, communication I / F (Interface), and the like.

[0014] A microservice is executed by, for example, one or more containers. A container corresponds to a user space that is created by internally dividing the kernel of an OS (Operating System) and is isolated from others, and operates as one of the processes of the OS.

[0015] The user space is an execution environment that groups together resources for executing software. The resources of the OS are logically divided and shared by a plurality of containers, for example. A container may be executed on the information processing apparatus 101, or may be executed on another computer different from the information processing apparatus 101.

[0016] However, a microservice may be executed by, for example, one or more virtual machines (Virtual Machine), or may be executed by one or more physical machines. A virtual machine is a virtual computer that operates in an execution environment constructed by dividing the hardware resources of a physical computer.

[0017] Here, when sharing resources among multiple microservices, there is a risk of problems occurring when some microservices exhaust the resources. Therefore, in order to ensure the quality of services with the same amount of resources (without increasing or decreasing the total amount of resources), it is important to optimize the resource allocation for each of the multiple microservices.

[0018] For example, it is conceivable to optimize resource allocation by distributing the total resources according to the processing capacity of each of multiple microservices with a call relationship.

[0019] As an example, there are microservices 1 and 2 with a call relationship, and the resource allocation ratio for each of microservices 1 and 2 is set to "1:1". In this case, when the processing capacity of microservice 2 is greater than that of microservice 1, microservice 2 becomes a bottleneck, and the number of processing requests per unit time decreases.

[0020] Therefore, by changing the resource allocation ratio according to the processing capacity of each of microservices 1 and 2, the number of processing requests can be increased. For example, by setting the resource allocation ratio for each of microservices 1 and 2 to "4:6", more resources are used for microservice 2, and the number of processing requests can be increased.

[0021] However, due to parameter specifications of requests and the like, the processing capacity of each of the multiple microservices fluctuates. Here, with reference to FIG. 2, an example of the fluctuation of the processing capacity of each of the multiple microservices will be described.

[0022] FIG. 2 is an explanatory diagram showing an example of the fluctuation of the processing capacity of each of multiple microservices. In FIG. 2, MS_a to MS_e are examples of a plurality of related microservices. MS is an abbreviation for Micro Services (microservices).

[0023] Here, in response to a request for Service A, among MS_a to MS_e, MS_a, MS_b, and MS_d are executed. Also, in response to a request for Service B, among MS_a to MS_e, MS_a, MS_c, and MS_e are executed.

[0024] In this way, depending on the parameter specification of the request, the microservices to be called change. Therefore, for example, when the requests for Service A increase, the processing volumes of MS_a, MS_b, and MS_d increase. On the other hand, when the requests for Service B increase, the processing volumes of MS_a, MS_c, and MS_e increase.

[0025] The number of requests for each service may change depending on temporal factors such as time zone, date, and day of the week. Therefore, it is preferable to optimize the resource allocation for each of the plurality of microservices according to the processing volume of each of the plurality of microservices that varies over time.

[0026] As optimization methods for resource allocation, there are, for example, optimization by vertical scaling and optimization by horizontal scaling.

[0027] Vertical scaling is a method of adjusting the amount of resources allocated to each microservice by scaling up and scaling down. Scaling up is to adjust by increasing the resource allocation amount per container (the size of the container itself). Scaling down is to adjust by reducing the resource allocation amount per container.

[0028] Also, horizontal scaling is a method of adjusting the amount of resources allocated to each microservice by scaling out and scaling in. Scaling out is to adjust by increasing the number of containers themselves. Scaling in is to adjust by reducing the number of containers themselves.

[0029] Here, optimization by vertical scaling requires restarting the container during optimization, as adjustments are made by increasing or decreasing the limit value. The limit value is a setting value that indicates the resource allocation per container (the size of the container itself). However, if it takes a long time to generate a container, downtime will occur. Downtime is a period during which services cannot be provided.

[0030] On the other hand, in optimization using horizontal scaling, limit values may be reduced to increase optimization accuracy. Also, when manually setting limit values for each microservice, the configuration work is tedious, so the same value is often set for all microservices. However, if the limit values for all microservices are the same, reducing the limit values may increase the number of containers, which could lead to performance degradation.

[0031] Therefore, in this embodiment, a resource control method for appropriately controlling the amount of resources allocated to each of a plurality of related microservices will be described. Below, processing examples (corresponding to the following (1) to (3)) of the information processing device 101 will be described.

[0032] (1) The information processing device 101 determines multiple patterns of resource allocation ratios to be subject to horizontal scaling for multiple related microservices based on the measured processing volume for each of the multiple related microservices. For example, the information processing device 101 may calculate the resource allocation ratio to be allocated to each of the multiple microservices based on the measured processing volume for each of the multiple microservices over a predetermined period of time. The predetermined period is, for example, a second period described below.

[0033] The plurality of related microservices include, for example, microservices in a call relationship. One service is provided by two or more of the plurality of related microservices. The plurality of related microservices include, for example, a microservice called from a plurality of services (services A and B) like MS_a shown in FIG. 2. The throughput is, for example, the CPU usage or the CPU usage time.

[0034] The resource allocation ratio for a plurality of microservices represents how to allocate resources (total resource amount) to each of the plurality of microservices. The resource allocation ratio may be represented, for example, by the amount of resources allocated to each of the plurality of microservices. Also, the resource allocation ratio for resources targeted for horizontal scaling is the resource allocation ratio when adjusting the amount of resources allocated to each of the plurality of microservices through optimization by horizontal scaling.

[0035] Specifically, for example, the information processing apparatus 101 calculates the resource allocation ratio for each of the plurality of microservices for each first period based on the throughput measured for each of the plurality of microservices for each first period. The first period can be arbitrarily set and is set to, for example, a time of about 10 minutes. More specifically, for example, the information processing apparatus 101 calculates the resource allocation ratio such that the higher the measured throughput of a microservice, the higher the allocation ratio.

[0036] Then, the information processing apparatus 101 determines a plurality of patterns of the resource allocation ratio for resources targeted for horizontal scaling based on the calculated resource allocation ratio for each first period. For example, the information processing apparatus 101 may determine, as the resources targeted for horizontal scaling, two or more allocation ratios with high occurrence frequencies among the resource allocation ratios for each first period.

[0037] In the example of FIG. 1, a plurality of related microservices are designated as "MS1 to MS3". In this case, the information processing apparatus 101 calculates the resource allocation ratio for each first period based on the processing amount measured for each of MS1 to MS3 for each first period. For example, bar graphs 111 to 115 are the calculation results representing the resource allocation ratio for each first period (left: MS1, middle: MS2, right: MS3).

[0038] Then, based on the calculated calculation results (for example, bar graphs 111 to 115), the information processing apparatus 101 determines a plurality of patterns of the resource allocation ratio for the resources to be horizontally scaled for MS1 to MS3. Here, assume that patterns A and B are determined as the resource allocation ratios for the resources to be horizontally scaled for MS1 to MS3.

[0039] (2) The information processing apparatus 101 calculates the allocation unit for each of the plurality of microservices for horizontal scaling in a plurality of patterns based on the allocation ratio of each of the determined plurality of patterns. Here, the allocation unit for each of the plurality of microservices is the allocation unit when adjusting the resource amount by optimization by horizontal scaling. The allocation unit corresponds to, for example, a limit value representing the resource allocation amount per container.

[0040] As the allocation unit, for example, a value that is as large as possible and is easy to horizontally scale among the determined plurality of patterns and that prevents an increase in the number of containers is calculated. Specifically, for example, the information processing apparatus 101 calculates the allocation unit based on the greatest common divisor of the resource amounts corresponding to the allocation ratios of each of the plurality of patterns for each of the plurality of microservices.

[0041] In the example of Figure 1, it is assumed that allocation units p, q, and r have been calculated for MS1, MS2, and MS3, respectively. Allocation unit p corresponds to the limit value for horizontal scaling between patterns A and B for MS1. Allocation unit q corresponds to the limit value for horizontal scaling between patterns A and B for MS2. Allocation unit r corresponds to the limit value for horizontal scaling between patterns A and B for MS3.

[0042] (3) When horizontally scaling using one of the multiple patterns, the information processing device 101 adjusts the amount of resources allocated to each of the multiple microservices using the calculated allocation unit for each of the multiple microservices. However, the actual total amount of resources allocable to the multiple microservices does not change, and resource allocation is performed within the range of the actual total amount of resources.

[0043] Specifically, for example, the information processing device 101 performs horizontal scaling in one of a plurality of patterns in response to detection of deterioration in the quality of a service. The service is related to a plurality of microservices and is provided by two or more microservices among the plurality of microservices.

[0044] Here, it is assumed that microservices are executed by containers. In this case, the information processing device 101 increases or decreases the number of containers allocated to each of the multiple microservices so that the amount of resources corresponds to the allocation ratio of one of the multiple patterns. This adjusts the amount of resources allocated to each of the multiple microservices. However, the amount of resources allocated per container to each microservice is the allocation unit (limit value) of each microservice.

[0045] In the example of FIG. 1, when horizontally scaling in either pattern A or B, the information processing apparatus 101 adjusts the amount of resources allocated to each of MS1, MS2, and MS3 using the allocation units p, q, and r of each. For example, assume a case where quality degradation is detected while MS1, MS2, and MS3 are operating at the allocation ratio of pattern A, and thus horizontal scaling is to be performed in pattern B.

[0046] In this case, the information processing apparatus 101 increases or decreases the number of containers allocated to each of MS1, MS2, and MS3 so that the amount of resources becomes the amount corresponding to the allocation ratio of pattern B. However, the limit value of MS1 is the allocation unit p. The limit value of MS2 is the allocation unit q. The limit value of MS3 is the allocation unit r.

[0047] For example, the amount of resources of MS1 corresponding to the allocation ratio of pattern A is equivalent to one container of the allocation unit p. The amount of resources of MS1 corresponding to the allocation ratio of pattern B is also equivalent to one container of the allocation unit p. Therefore, the number of containers allocated to MS1 does not change.

[0048] Also, the amount of resources of MS2 corresponding to the allocation ratio of pattern A is equivalent to three containers of the allocation unit q. The amount of resources of MS2 corresponding to the allocation ratio of pattern B is equivalent to one container of the allocation unit q. Therefore, the number of containers allocated to MS2 decreases from "3" to "1".

[0049] Also, the amount of resources of MS3 corresponding to the allocation ratio of pattern A is equivalent to one container of the allocation unit r. The amount of resources of MS3 corresponding to the allocation ratio of pattern B is equivalent to two containers of the allocation unit r. Therefore, the number of containers allocated to MS3 increases from "1" to "2".

[0050] Note that in the optimization by horizontal scaling, since the adjustment of the amount of resources is performed with at least one container allocated to each of MS1, MS2, and MS3, no downtime occurs as in the optimization by vertical scaling.

[0051] In this way, according to the information processing apparatus 101, horizontal scaling can be performed at a plurality of resource allocation ratios (for example, patterns A and B) according to the processing amounts of a plurality of related microservices. Thereby, the information processing apparatus 101 can adjust the amount of resources allocated to each of the plurality of microservices without, for example, restarting the containers. Here, the restart of the containers means stopping all the containers allocated to the microservice and newly generating and allocating the containers.

[0052] Further, according to the information processing apparatus 101, an allocation unit (for example, a limit value) for horizontal scaling in a plurality of patterns can be calculated for each microservice. Thereby, the information processing apparatus 101 can, for example, easily perform horizontal scaling among a plurality of patterns and can set a value as large as possible as the limit value, thereby preventing the performance from degrading as the number of containers increases.

[0053] In the example of FIG. 1, by performing horizontal scaling in patterns A and B according to the processing amounts of related MS1 to MS3, the amount of resources allocated to each of MS1 to MS3 can be appropriately controlled without restarting the containers. Further, by calculating a limit value for horizontal scaling in patterns A and B for each of MS1 to MS3, it is easy to perform horizontal scaling between patterns A and B, and by setting a value as large as possible as the limit value, it is possible to prevent the performance degradation accompanying the increase in the number of containers.

[0054] (System configuration example of the information processing system 300) Next, a system configuration example of the information processing system 300 including the information processing apparatus 101 shown in FIG. 1 will be described. Here, the case where the information processing apparatus 101 shown in FIG. 1 is applied to the resource control apparatus 301 in the information processing system 300 will be described as an example. The information processing system 300 is applied to, for example, a computer system that provides web services using a microservice architecture.

[0055] In the following explanation, multiple related microservices may be referred to as "microservices MS1 to MSn" (n: a natural number equal to or greater than 2). Also, any microservice among microservices MS1 to MSn may be referred to as "microservice MSi" (i = 1, 2, ..., n). Also, an example will be explained in which microservice MSi is executed by a container.

[0056] Fig. 3 is an explanatory diagram showing an example of the system configuration of an information processing system 300. In Fig. 3, the information processing system 300 includes a resource control device 301 and a client device 302. In the information processing system 300, the resource control device 301 and the client device 302 are connected via a wired or wireless network 310. The network 310 is, for example, the Internet, a LAN (Local Area Network), or a WAN (Wide Area Network).

[0057] Here, the resource control device 301 has a target pattern table 320 and controls the amount of resources allocated to each of the microservices MS1 to MSn. The resource control device 301 is also capable of executing the microservice MSi. Specifically, for example, the resource control device 301 starts a container on its own device and executes the microservice MSi in the container (one or more containers).

[0058] Furthermore, the resource control device 301 may, for example, start a virtual machine on its own device and execute the microservice MSi in a container running on the virtual machine. The resource control device 301 is, for example, a server. The resource control device 301 may also be realized by a plurality of computers. The contents stored in the target pattern table 320 will be described later with reference to FIG. 5.

[0059] The client device 302 is a computer used by the user. The user is, for example, an administrator of the information processing system 300. The user can set various parameters (such as T1, T2 described later) using the client device 302, for example. The client device 302 is, for example, a PC (Personal Computer), a tablet PC, or the like.

[0060] Note that the information processing system 300 may include a processing device capable of executing the microservice MSi. In this case, the processing device may, for example, start a container on its own device and execute the microservice MSi in the container according to the control of the resource control device 301.

[0061] (Hardware configuration example of the resource control device 301) FIG. 4 is a block diagram showing a hardware configuration example of the resource control device 301. In FIG. 4, the resource control device 301 includes a CPU 401, a memory 402, a disk drive 403, a disk 404, a communication I / F 405, a portable recording medium I / F 406, and a portable recording medium 407. Also, each component is connected by a bus 400.

[0062] Here, the CPU 401 controls the entire resource control device 301. The resource control device 301 may have a plurality of CPUs 401. Also, the CPU 401 may have a plurality of cores. The memory 402 includes, for example, a ROM (Read Only Memory), a RAM (Random Access Memory), and a flash ROM. Specifically, for example, the flash ROM stores the OS program, the ROM stores the application program, and the RAM is used as the work area of the CPU 401. The program stored in the memory 402 is loaded into the CPU 401 to cause the CPU 401 to execute the coded processing.

[0063] The disk drive 403 controls the reading / writing of data to / from the disk 404 according to the control of the CPU 401. The disk 404 stores the data written under the control of the disk drive 403. Examples of the disk 404 include a magnetic disk and an optical disk.

[0064] The communication I / F 405 is connected to the network 310 through a communication line and is connected to an external computer (for example, the client device 302 shown in FIG. 3) via the network 310. Then, the communication I / F 405 serves as an interface between the network 310 and the inside of the device and controls the input / output of data from / to the external computer. For the communication I / F 405, for example, a modem, a LAN adapter, etc. can be adopted.

[0065] The portable recording medium I / F 406 controls the reading / writing of data to / from the portable recording medium 407 according to the control of the CPU 401. The portable recording medium 407 stores the data written under the control of the portable recording medium I / F 406. Examples of the portable recording medium 407 include a CD (Compact Disc)-ROM, a DVD (Digital Versatile Disk), a USB (Universal Serial Bus) memory, etc.

[0066] Note that the resource control device 301 may not have, for example, the portable recording medium I / F 406 and the portable recording medium 407 among the above-described components. Also, the resource control device 301 may have, for example, an input device, a display, etc. in addition to the above-described components. Also, the client device 302 shown in FIG. 3 can be realized with a hardware configuration similar to that of the resource control device 301. However, the client device 302 has, for example, an input device, a display, etc. in addition to the above-described components.

[0067] (Stored content of the target pattern table 320) Next, the contents stored in the target pattern table 320 will be described with reference to Fig. 5. The target pattern table 320 is realized by a storage device such as the memory 402 or the disk 404 shown in Fig. 4, for example.

[0068] Fig. 5 is an explanatory diagram showing an example of the contents stored in the target pattern table 320. In Fig. 5, the target pattern table 320 has fields for pattern ID, ID, optimum value, limit value, number of containers, and total limit value, and stores target pattern information (for example, target pattern information 500-1, 500-2) by setting information in each field.

[0069] Here, the pattern ID is an identifier that identifies the target pattern. The ID is an identifier that identifies the microservice MSi. The optimal value is the optimal value of the amount of resources to be allocated to the microservice MSi. The combination of the optimal values of the microservices MS1 to MS6 represents the target pattern.

[0070] The limit value is the limit value (allocation unit) corresponding to the microservice MSi. The limit value represents the resource allocation amount per container. The number of containers is the number of containers that run the microservice MSi. The total limit value is the amount of resources allocated to the microservice MSi. The total limit value corresponds to the value obtained by multiplying the limit value by the number of containers.

[0071] The target pattern table 320 is used when performing horizontal scaling optimization for the microservices MS1 to MS6.

[0072] (Example of functional configuration of resource control device 301) FIG. 6 is a block diagram showing a functional configuration example of the resource control device 301. In FIG. 6, the resource control device 301 includes a measurement unit 601, a first calculation unit 602, a determination unit 603, a second calculation unit 604, and an allocation control unit 605. The measurement unit 601 to the allocation control unit 605 are functions that serve as a control unit. Specifically, for example, by causing the CPU 401 to execute a program stored in a storage device such as the memory 402, the disk 404, or the portable recording medium 407 shown in FIG. 4, or by means of the communication I / F 405, their functions are realized. The communication I / F 405 is used, for example, to realize the functions of the measurement unit 601 and the allocation control unit 605 when the microservice MSi is executed on another computer (processing device) different from the resource control device 301. The processing results of each functional unit are stored in a storage device such as the memory 402 or the disk 404.

[0073] The measurement unit 601 measures the processing amount of each of the microservices MS1 to MSn. The microservices MS1 to MSn are a plurality of related microservices and include, for example, microservices in a call relationship. The processing amount to be measured is determined according to the resource to be allocated.

[0074] For example, if the resource to be allocated is "CPU", the processing amount to be measured is the CPU usage or the CPU usage time. In the following description, "CPU" will be taken as an example of the resource to be allocated for explanation.

[0075] Specifically, for example, the measurement unit 601 measures the processing amount for each of the microservices MS1 to MSn every first period T1. The first period can be arbitrarily set and is set to, for example, a time of about 10 minutes. More specifically, for example, the measurement unit 601 measures the CPU usage time of each microservice MSi every first period by querying the OS. Each microservice MSi operates, for example, on a container of the resource control device 301.

[0076] A specific example of the measurement results of the amount of processing for each of the microservices MS1 to MSn will be described later with reference to FIG.

[0077] The first calculation unit 602 calculates the allocation ratio of resources to be allocated to each of the microservices MS1 to MSn based on the measured processing amount for each of the microservices MS1 to MSn. Here, it is preferable that the microservice MSi having a larger processing amount among the microservices MS1 to MSn has a higher allocation ratio of resources.

[0078] For this reason, the first calculation unit 602 calculates the allocation ratio of resources to be allocated to each of the microservices MS1 to MSn for each first period, based on the ratio of the processing amount measured for each of the microservices MS1 to MSn for each first period. The calculated allocation ratio for each microservice MSi can be said to be the optimal value of the allocation ratio according to the processing amount of each microservice MSi in the first period.

[0079] In the following description, the allocation ratio of resources to be allocated to each of the microservices MS1 to MSn, calculated based on the processing amount measured for each of the microservices MS1 to MSn, may be referred to as the “optimal value pattern.” Also, the first period may be referred to as the “optimal value calculation period T1.”

[0080] An example of calculating the optimum value pattern will be described later with reference to FIGS.

[0081] The determining unit 603 determines a plurality of target patterns based on the calculation results calculated by the first calculating unit 602. Here, the target patterns represent resource allocation ratios targeted for horizontal scaling for the microservices MS1 to MSn. Specifically, for example, the determining unit 603 determines a plurality of target patterns based on the resource allocation ratios (optimum value patterns) calculated for each optimum value calculation period T1.

[0082] To explain in more detail, for example, the determination unit 603 may determine, as the target patterns, the top m optimum value patterns with the highest appearance frequency among the optimum value patterns calculated for each optimum value calculation period T1 during a predetermined period (for example, a second period described later). m is a value equal to or greater than 2 and can be set arbitrarily. For example, m is set to "m=2".

[0083] Furthermore, the determination unit 603 may determine, as target patterns, the optimum value patterns corresponding to the top m periods with the highest number of requests from among the optimum value patterns calculated for each optimum value calculation period T1. The number of requests is the number of requests received during the measurement period (optimum value calculation period T1). A request is a request for the execution of a service.

[0084] Furthermore, each time the second period elapses, the determination unit 603 determines a plurality of target patterns based on the resource allocation ratios (optimum value patterns) calculated for each optimum value calculation period T1 within the second period. Here, the second period is a period longer than the optimum value calculation period T1 (first period) and can be set arbitrarily. The second period is set to, for example, about six hours.

[0085] The resource allocation ratios represented by the determined target pattern are stored, for example, in the target pattern table 320 shown in Fig. 5. Specifically, for example, the allocation ratios (optimum values) of the microservices MS1 to MSn are associated with the target pattern (pattern ID) and stored in the target pattern table 320. However, at this point, the limit value, the number of containers, and the total limit value have not yet been set.

[0086] An example of determining the target pattern will be described later with reference to FIG.

[0087] In the following description, there may be cases where a plurality of target patterns determined as horizontal scale targets for microservices MS1 to MSn are denoted as "target patterns P1 to Pm" (m: a natural number of 2 or more). Also, any one of the target patterns P1 to Pm may be denoted as "target pattern Pj" (j = 1, 2,..., m).

[0088] The second calculation unit 604 calculates a limit value for each of the microservices MS1 to MSn for horizontal scaling in the target patterns P1 to Pm based on the allocation ratio represented by each of the determined target patterns P1 to Pm. Here, the limit value is an allocation unit when adjusting the resource amount by optimization through horizontal scaling, and represents, for example, the resource allocation amount per container.

[0089] As the limit value, for example, a value that is easy to horizontally scale among the target patterns P1 to Pm and is as large as possible to prevent an increase in the number of containers is calculated. Specifically, for example, the second calculation unit 604 calculates the limit value for each of the microservices MS1 to MSn based on the greatest common divisor of the resource amounts corresponding to the allocation ratios represented by each of the target patterns P1 to Pm.

[0090] The calculated limit value is stored, for example, in the target pattern table 320. Specifically, for example, the limit value (limit value), the number of containers, and the total limit value for each of the microservices MS1 to MSn are stored in the target pattern table 320 in association with the target pattern Pj (pattern ID). The total limit value corresponds to the value obtained by multiplying the limit value by the number of containers.

[0091] Note that an example of calculating the limit value for each of the microservices MS1 to MSn will be described later with reference to FIG. 11.

[0092] Further, when the currently determined target patterns P1 to Pm are different from the previously determined target patterns P1 to Pm, the second calculation unit 604 may newly calculate the limit values of the microservices MS1 to MSn. In this case, the second calculation unit 604 calculates the limit values of the microservices MS1 to MSn based on the allocation ratios represented by the currently determined target patterns P1 to Pm.

[0093] Here, the currently determined target patterns P1 to Pm are the latest of the plurality of target patterns determined each time the second period elapses. Also, the previously determined target patterns P1 to Pm are the plurality of target patterns determined one before among the plurality of target patterns determined each time the second period elapses.

[0094] In the following description, the second period may be referred to as the "limit value calculation period T2".

[0095] When horizontally scaling with any one of the target patterns Pj of the target patterns P1 to Pm, the allocation control unit 605 adjusts the amount of resources allocated to each of the microservices MS1 to MSn using the calculated limit values of the microservices MS1 to MSn.

[0096] Specifically, for example, the allocation control unit 605 refers to the target pattern table 320 and increases or decreases the number of containers allocated to each of the microservices MS1 to MSn so that the amount of resources corresponds to the allocation ratio represented by any one of the target patterns Pj of the target patterns P1 to Pm. The amount of resource allocation per container allocated to the microservice MSi is the limit value (allocation unit) of the microservice MSi.

[0097] Depending on the limit values of each of the microservices MS1 to MSn, the adjusted amount of resources may not exactly match the allocation ratio (total limit value) represented by the target pattern Pj. However, it is assumed that the limit values of each of the microservices MS1 to MSn are calculated so as not to deviate significantly from the allocation ratio represented by the target pattern Pj.

[0098] In addition, the allocation control unit 605 may horizontally scale using one of the target patterns P1 to Pm in response to detecting a deterioration in the quality of the services related to the microservices MS1 to MSn. The services related to the microservices MS1 to MSn are services provided by two or more of the microservices MS1 to MSn.

[0099] Specifically, for example, each time the optimal value calculation period T1 elapses, the allocation control unit 605 may detect a deterioration in the quality of the service based on the calculated optimal value pattern (resource allocation ratio of the microservices MS1 to MSn) in the optimal value calculation period T1.

[0100] More specifically, for example, the allocation control unit 605 detects a deterioration in the quality of the service based on the result of comparing the current target pattern with the latest optimal value pattern. Here, the current target pattern is the target pattern corresponding to the current resource allocation ratio of each of the microservices MS1 to MSn among the target patterns P1 to Pm determined as the target of horizontal scaling. The latest optimal value pattern is the optimal value pattern in the most recent optimal value calculation period T1 among the optimal value patterns for each calculated optimal value calculation period T1.

[0101] More specifically, for example, the allocation control unit 605 detects a deterioration in the quality of the service when the current target pattern and the latest optimal value pattern do not match. On the other hand, when the current target pattern and the latest optimal value pattern match, the allocation control unit 605 does not detect a deterioration in the quality of the service.

[0102] Furthermore, the allocation control unit 605 may compare the current target pattern with the latest optimum value pattern and calculate the sum of the differences in allocation ratios for each microservice MSi. When comparing patterns (for example, the current target pattern with the latest optimum value pattern), the allocation control unit 605 may adjust the values of each pattern so that the total resource amount becomes the same value.

[0103] Then, the allocation control unit 605 may detect a deterioration in the quality of the service when the calculated sum of the differences is equal to or greater than the threshold value α. On the other hand, when the calculated sum of the differences is less than the threshold value α, the allocation control unit 605 may not detect a deterioration in the quality of the service. The threshold value α can be set arbitrarily.

[0104] Moreover, which target pattern Pj among the target patterns P1 to Pm is to be horizontally scaled is determined based on, for example, the latest optimum value pattern.

[0105] Specifically, for example, the allocation control unit 605 may determine the target pattern Pj that matches the latest optimum value pattern among the target patterns P1 to Pm as the target pattern to be horizontally scaled. In this case, if there is no target pattern that matches the latest optimum value pattern, the allocation control unit 605 may decide not to perform horizontal scaling.

[0106] Furthermore, for example, the allocation control unit 605 may compare each of the target patterns P1 to Pm with the latest optimum value pattern and calculate the sum of the differences in the allocation ratios for each microservice MSi. Then, the allocation control unit 605 may determine the target pattern Pj with the smallest sum of the calculated differences as the target pattern to be horizontally scaled.

[0107] An example of adjusting the amount of resources by horizontal scaling using the limit values of each of the microservices MS1 to MSn will be described later with reference to FIG.

[0108] In addition, when the limit values of each of the microservices MS1 to MSn are newly calculated, the allocation control unit 605 sets the target patterns P1 to Pm determined this time as the targets for horizontal scaling for the microservices MS1 to MSn. Then, the allocation control unit 605 performs optimization by vertical scaling for the microservices MS1 to MSn using the newly calculated limit values of each of the microservices MS1 to MSn.

[0109] Note that the functional units (measurement unit 601 to allocation control unit 605) of the resource control device 301 described above may be realized by a plurality of computers (for example, resource control device 301, client device 302) within the information processing system 300.

[0110] (Specific example of measurement result) Here, with reference to FIG. 7, a specific example of the measurement results of the processing amounts of each of the microservices MS1 to MSn will be described. Here, the microservices MS1 to MSn are referred to as "microservices MS1 to MS6" (n = 6).

[0111] FIG. 7 is an explanatory diagram showing a specific example of the measurement results of each of the microservices MS1 to MSn. In FIG. 7, the measurement result 700 includes a measurement period, an ID, and CPU usage time. The measurement period is the period during which the processing amounts of each of the microservices MS1 to MS6 are measured and corresponds to the first period T1.

[0112] The ID is an identifier for identifying the microservice MSi. The CPU usage time is the CPU usage time [seconds] measured for the microservice MSi. The CPU usage time is calculated based on, for example, the difference between the time when the microservice MSi starts using the CPU 401 and the time when the use of the CPU 401 ends.

[0113] (Example of calculation of optimal value pattern) Next, with reference to FIGS. 8 and 9, an example of calculating the optimal value pattern will be described. Here, the resource to be allocated is set to "3 CPUs", and the total resource amount is set to "3000 [m (millicores)]" (1 CPU = 1000 [m]).

[0114] FIG. 8 is an explanatory diagram (part 1) showing an example of calculating the optimal value pattern. In FIG. 8, the measurement result 800 indicates the throughput measured for each of the microservices MS1 to MS6. The measurement result 800 corresponds to the measurement result 700 shown in FIG. 7.

[0115] (8-1) The first calculation unit 602 distributes the total resource amount "3000 [m]" to each of the microservices MS1 to MS6 according to the ratio of the throughput of each of the microservices MS1 to MS6 based on the measurement result 800.

[0116] (8-2) The first calculation unit 602 adjusts the resource amounts of each of the microservices MS1 to MS6 so that the minimum value becomes "100". Specifically, for example, the first calculation unit 602 adds "100" to the resource amounts of each of the microservices MS3, MS5, and MS6 (values less than 100 [m] are set to 100 [m]). Then, according to the ratio of the throughput of each of the microservices MS1, MS2, and MS4, the remaining resource amount "2700 [m]" is distributed to each of the microservices MS1, MS2, and MS4.

[0117] (8-3) The first calculation unit 602 calculates the optimal value pattern by rounding down the fractional part less than 100 of the resource amounts of each of the microservices MS1 to MS6 (rounding to the nearest 100). For example, the resource amount "112.5" of the microservice MS1 becomes "100". The resource amount "1743.75" of the microservice MS2 becomes "1700". In this case, the total resource amount becomes "2900 [m]".

[0118] FIG. 9 is an explanatory diagram (part 2) showing an example of calculating an optimal value pattern. In FIG. 9, measurement result 900 shows the throughput measured for each of microservices MS1 to MS6. The measurement result 900 is a measurement result measured during a measurement period (first period T1) different from the measurement result 800 shown in FIG. 8.

[0119] (9-1) The first calculation unit 602 distributes the total resource amount "3000 [m]" to each of the microservices MS1 to MS6 according to the ratio of the throughput of each of the microservices MS1 to MS6 based on the measurement result 900.

[0120] (9-2) The first calculation unit 602 adjusts the resource amounts of each of the microservices MS1 to MS6 so that the minimum value becomes "100". Specifically, for example, the first calculation unit 602 adds "70.5882" to the resource amounts of each of the microservices MS3, MS4, and MS6. Then, according to the ratio of the throughput of each of the microservices MS1, MS2, and MS5, the remaining resource amount "2700 [m]" is distributed to each of the microservices MS1, MS2, and MS5.

[0121] (9-3) The first calculation unit 602 calculates an optimal value pattern by rounding down (rounding to 100) the fractional part less than 100 of the resource amounts of each of the microservices MS1 to MS6. For example, the resource amount "109,091" of the microservice MS1 becomes "100". The resource amount "1281.82" of the microservice MS5 becomes "1200". In this case, the total resource amount becomes "2900 [m]".

[0122] (Example of determining a target pattern) Next, an example of determining a target pattern will be described with reference to FIG. 10. However, the optimal value calculation period T1 is set to "T1 = 10 [minutes]" and the limit value calculation period T2 is set to "T2 = 6 [hours]".

[0123] Fig. 10 is an explanatory diagram showing an example of determining a target pattern. Fig. 10 shows measurement results (e.g., measurement results 1000-1 to 1000-5) and optimal value patterns (e.g., optimal value patterns A, B, C, and D) for each optimal value calculation period T1 for each of microservices MS1 to MS6.

[0124] For example, measurement result 1000-1 indicates the CPU usage time [seconds] for each of microservices MS1 to MS6 during the measurement period "06:00-06:10." The optimal value pattern for the measurement period "06:00-06:10" is "optimal value pattern A." Optimal value pattern A represents the resource allocation ratios (100, 1700, 100, 800, 100, 100) assigned to each of microservices MS1 to MS6.

[0125] For example, measurement result 1000-3 indicates the CPU usage time [seconds] for each of microservices MS1 to MS6 during the measurement period "06:20-06:30." The optimal value pattern for the measurement period "06:20-06:30" is "optimal value pattern B." Optimal value pattern B indicates the resource allocation ratios (100, 1300, 100, 100, 1200, 100) assigned to each of microservices MS1 to MS6.

[0126] 10, the determination unit 603 determines the two most frequently occurring optimal value patterns (N=2) from among the optimal value patterns calculated for each optimal value calculation period T1 (10 minutes) within the limit value calculation period T2 (6 hours) as target patterns. Here, it is assumed that optimal value patterns A and B are the two most frequently occurring optimal value patterns. In this case, the determination unit 603 determines optimal value patterns A and B as target patterns.

[0127] (Example of limit value calculation) Next, an example of calculating the limit values of each of the microservices MS1 to MSn will be described with reference to Fig. 11. Here, the case where the optimal value patterns A and B shown in Fig. 10 are determined as the target patterns P1 to Pm will be described as an example.

[0128] FIG. 11 is an explanatory diagram showing an example of limit value calculation. In FIG. 11, target patterns A and B are shown. Target patterns A and B represent the allocation ratio of resources targeted for horizontal scaling for microservices MS1 to MS6. Here, the resource allocation ratio is expressed by the resource amount (total resource amount "2900 [m]").

[0129] (11-1) The second calculation unit 604 refers to the target patterns A and B and identifies the greatest common denominator (GCD) of the allocation ratios (resource amounts) between the target patterns A and B for each of the microservices MS1 to MS6. Taking the microservice MS1 as an example, the allocation ratio in the target pattern A is "100" and the allocation ratio in the target pattern B is also "100". Therefore, the greatest common denominator is "100".

[0130] If the limit values of the microservices MS1 to MS6 are set to the greatest common denominator "100", the total number of containers in each of the target patterns A and B will be "29".

[0131] (11-2) The second calculation unit 604 searches for a limit value (limit value) for each of the microservices MS1 to MS6 such that the difference between the optimum value represented by the target patterns A and B and the total limit value is within X or within Y% of the optimum value. In this case, the second calculation unit 604 searches for the largest possible limit value by integrally multiplying the greatest common divisor identified for each of the microservices MS1 to MS6. The total limit value is the product of the limit value (limit value) and the number of containers. X and Y can be set arbitrarily, for example, so as not to reduce the accuracy of optimization by horizontal scaling. Here, X is set to "X=200" and Y is set to "Y=20".

[0132] Taking the microservice MS2 as an example, when the limit value is set to "600", for the target pattern A, when the number of containers is "3", the total limit value becomes "1800", and the difference from the optimal value "1700" is within 200. For the target pattern B, when the number of containers is "2", the total limit value becomes "1200", and the difference from the optimal value "1300" is within 200.

[0133] (11-3) The second calculation unit 604 adjusts the limit values of each of the microservices MS1 to MS6 so that the total number of containers in each of the target patterns A and B is Z or less. However, the difference between the optimal value represented by the target patterns A and B and the total limit value is within X or within Y% of the optimal value. Z can be arbitrarily set, and for example, it is set so that the number of containers is not too large and the performance does not deteriorate. Here, Z is set to "Z = 15".

[0134] At the time after the processing of (11-2) above, the total number of containers in the target pattern B is "18", which is not 15 or less. Therefore, the second calculation unit 604 adjusts the limit values of each of the microservices MS1 to MS6.

[0135] For example, when the limit values of the microservices MS4 and MS5 are set to "200", for the target pattern A, the total number of containers becomes "10". For the target pattern B, the total number of containers becomes "13". Furthermore, the difference between the optimal value represented by the target patterns A and B and the total limit value is within 200.

[0136] Therefore, the second calculation unit 604 sets the limit values of each of the microservices MS1 to MS6 to "(MS1, MS2, MS3, MS4, MS5, MS6) = (100, 600, 100, 200, 200, 100)". In this case, the number of containers for the target pattern A is "(MS1, MS2, MS3, MS4, MS5, MS6) = (1, 3, 1, 3, 1, 1)". For the target pattern B, the number of containers is "(MS1, MS2, MS3, MS4, MS5, MS6) = (2, 2, 1, 1, 5, 2)".

[0137] Also, the total limit value for the target pattern A is "(MS1, MS2, MS3, MS4, MS5, MS6) = (100, 1800, 100, 600, 200, 100)". Also, the total limit value for the target pattern B is "(MS1, MS2, MS3, MS4, MS5, MS6) = (200, 1200, 100, 200, 1000, 200)".

[0138] Although the total limit values for these target patterns A and B do not exactly match the allocation ratios (resource amounts) represented by the target patterns A and B, they satisfy the conditions (within X or within Y% of the optimal value) set so that the accuracy of optimization does not decrease. In the process of (11 - 3) above, when no limit value is found such that the total number of containers in each of the target patterns A and B is Z or less, the resource control device 301 may decide not to review the limit values of each of the microservices MS1 to MS6.

[0139] (Example of Adjusting Resource Amount by Horizontal Scaling) Next, with reference to FIG. 12, an example of adjusting the resource amount by horizontal scaling using the limit values of each of the microservices MS1 to MSn will be described. Here, as the target patterns P1 to Pm, the target patterns A and B will be taken as examples for explanation.

[0140] FIG. 12 is an explanatory diagram showing an example of adjusting the resource amount by horizontal scaling. In FIG. 12, a graph 1210 and a graph 1220 are shown. The graph 1210 is a bar graph representing the resource amount allocated to each of the microservices MS1 to MS6 when it is the target pattern A. Also, the graph 1220 is a bar graph representing the resource amount allocated to each of the microservices MS1 to MS6 when it is the target pattern B. In each of the graphs 1210 and 1220, 1 block corresponds to 1 container.

[0141] · Operating with the number of containers of the target pattern A First, assume a case where microservices MS1 to MS6 are operating with the number of containers for target pattern A being "(MS1, MS2, MS3, MS4, MS5, MS6) = (1, 3, 1, 3, 1, 1)". In this case, the allocation control unit 605 refers to the target pattern table 320 and compares target pattern A with the latest optimal value pattern.

[0142] Target pattern A is specified, for example, from the optimal value field within the target pattern table 320. Also, target pattern A may be specified from the total limit value field within the target pattern table 320. However, the total resource amount shall be the same value for target pattern A and the optimal value pattern.

[0143] Here, assume a case where target pattern A and the latest optimal value pattern do not match. In this case, the allocation control unit 605 detects a deterioration in service quality. Next, the allocation control unit 605 refers to the target pattern table 320 and compares target pattern B with the latest optimal value pattern. Here, assume a case where target pattern B and the latest optimal value pattern match.

[0144] In this case, the allocation control unit 605 refers to the target pattern table 320 and horizontally scales the microservices MS1 to MS6 according to target pattern B. Specifically, for example, the allocation control unit 605 increases the number of containers for microservice MS1 by one. As a result, the number of containers with a limit value of "200" becomes two, and the resource amount allocated to microservice MS1 increases.

[0145] The allocation control unit 605 also reduces the number of containers for microservice MS2 by one. As a result, the number of containers with a limit value of "600" becomes two, and the amount of resources allocated to microservice MS2 decreases. The allocation control unit 605 does not change the number of containers for microservice MS3. The allocation control unit 605 also reduces the number of containers for microservice MS4 by two. As a result, the number of containers with a limit value of "200" becomes one, and the amount of resources allocated to microservice MS4 decreases.

[0146] The allocation control unit 605 also increases the number of containers for microservice MS5 by four. This brings the number of containers with a limit value of "200" to five, increasing the amount of resources allocated to microservice MS5. The allocation control unit 605 also increases the number of containers for microservice MS6 by one. This brings the number of containers with a limit value of "100" to two, increasing the amount of resources allocated to microservice MS6.

[0147] -Operating with the number of containers in target pattern B Next, assume that microservices MS1 to MS6 are operating with the number of containers "(MS1, MS2, MS3, MS4, MS5, MS6) = (2, 2, 1, 1, 5, 2)" of target pattern B. In this case, the allocation control unit 605 refers to the target pattern table 320 and compares target pattern B with the latest optimum value pattern.

[0148] Here, it is assumed that object pattern B does not match the latest optimum value pattern. In this case, the allocation control unit 605 detects a deterioration in the quality of the service. Next, the allocation control unit 605 refers to the object pattern table 320 and compares object pattern A with the latest optimum value pattern. Here, it is assumed that object pattern A matches the latest optimum value pattern.

[0149] In this case, the allocation control unit 605 refers to the target pattern table 320 and horizontally scales the microservices MS1 to MS6 according to the target pattern A. Specifically, for example, the allocation control unit 605 reduces the number of containers for the microservice MS1 by one. As a result, the number of containers with the limit value of "200" becomes one, and the amount of resources allocated to the microservice MS1 decreases.

[0150] In addition, the allocation control unit 605 increases the number of containers for the microservice MS2 by one. As a result, the number of containers with the limit value of "600" becomes three, and the amount of resources allocated to the microservice MS2 increases. Also, the allocation control unit 605 does not change the number of containers for the microservice MS3. Further, the allocation control unit 605 increases the number of containers for the microservice MS4 by two. As a result, the number of containers with the limit value of "200" becomes three, and the amount of resources allocated to the microservice MS4 increases.

[0151] In addition, the allocation control unit 605 reduces the number of containers for the microservice MS5 by four. As a result, the number of containers with the limit value of "200" becomes one, and the amount of resources allocated to the microservice MS5 decreases. Also, the allocation control unit 605 reduces the number of containers for the microservice MS6 by one. As a result, the number of containers with the limit value of "100" becomes one, and the amount of resources allocated to the microservice MS6 decreases.

[0152] In this way, in the optimization by horizontal scaling, since the adjustment of the amount of resources is performed with at least one container allocated to each of the microservices MS1 to MS6, downtime such as that in the optimization by vertical scaling does not occur.

[0153] (Operation example of the resource control device 301) Next, an example of the operation of the resource control device 301 will be described with reference to Fig. 13. Here, the microservices MS1 to MSn are referred to as "microservices MS1 to MS3." The monitoring period is referred to as "March 1st to March 3rd." The monitoring period is, for example, a target period for controlling the amount of resources allocated to each of the microservices MS1 to MS3.

[0154] Fig. 13 is an explanatory diagram showing an example of the operation of the resource control device 301. In Fig. 13, it is assumed that, as an initial setting, target patterns P1 to Pm are set to "target patterns 1 and 2," and horizontal scaling is performed on target pattern 1 at time t1. Note that in Fig. 13, "pattern 1" indicates "target pattern 1." Furthermore, "pattern 2" indicates "target pattern 2." Furthermore, "pattern 3" indicates "target pattern 3." Furthermore, "pattern 4" indicates "target pattern 4."

[0155] After the initial setting, the resource control device 301 calculates an optimum value pattern for each optimum value calculation period T1. Then, the resource control device 301 determines the deterioration of the quality of the service based on the calculated optimum value pattern. Note that the bar graph at the bottom of Fig. 13 shows an enlarged view of the fluctuations in the optimum value pattern on March 1st.

[0156] Here, assume that a deterioration in the quality of the service is detected at time t2. Also assume that, of target patterns 1 and 2, target pattern 2 matches the most recent optimal value pattern. In this case, the resource control device 301 horizontally scales target pattern 2 and adjusts the resource amount of each of the microservices MS1 to MS3.

[0157] Next, assume that a deterioration in the quality of the service is detected at time t3. Also assume that, of target patterns 1 and 2, target pattern 1 matches the most recent optimal value pattern. In this case, the resource control device 301 horizontally scales target pattern 1 and adjusts the resource amount of each of the microservices MS1 to MS3.

[0158] Also, every time the limit value calculation period T2 elapses, the resource control device 301 determines target patterns P1 to Pm. Here, assume that at time t4, "target patterns 3 and 4" are determined as the target patterns P1 to Pm. Also, assume that the target patterns 3 and 4 are different from the immediately preceding target patterns 1 and 2.

[0159] In this case, the resource control device 301 newly calculates the limit values for each of the microservices MS1 to MS3 (review of the limit values). Then, the resource control device 301 restarts the containers assigned to each of the microservices MS1 to MS3 in order to horizontally scale with the target patterns 3 and 4 (equivalent to optimization by vertical scaling). Thereafter, the resource control device 301 performs horizontal scaling with the target patterns 3 and 4 in response to deterioration of the service quality, and adjusts the resource amounts of each of the microservices MS1 to MS3.

[0160] Also, every time the limit value calculation period T2 elapses, the resource control device 301 determines target patterns P1 to Pm. Here, assume that at time t5, "target patterns 1 and 2" are determined as the target patterns P1 to Pm. Also, assume that the target patterns 1 and 2 are different from the immediately preceding target patterns 3 and 4.

[0161] In this case, the resource control device 301 newly calculates the limit values for each of the microservices MS1 to MS3 (review of the limit values). Then, the resource control device 301 restarts the containers assigned to each of the microservices MS1 to MS3 in order to horizontally scale with the target patterns 1 and 2. Thereafter, the resource control device 301 performs horizontal scaling with the target patterns 1 and 2 in response to deterioration of the service quality, and adjusts the resource amounts of each of the microservices MS1 to MS3.

[0162] (Resource control processing procedure of the resource control device 301) Next, with reference to FIGS. 14 and 15, the resource control processing procedure of the resource control device 301 will be described.

[0163] Figures 14 and 15 are flowcharts showing an example of the resource control processing procedure of the resource control device 301. In the flowchart of Figure 14, first, the resource control device 301 sets the limit values (default values) of the respective microservices MS1 to MSn for horizontal scaling with the target patterns P1 to Pm (step S1401).

[0164] Note that the target patterns P1 to Pn and the limit values (default values) can be arbitrarily set. For example, the target patterns P1 to Pn and the limit values (default values) are set by the administrator of the information processing system 300 based on the processing amounts of the respective microservices MS1 to MSn during test operation.

[0165] Then, the resource control device 301 horizontally scales with any one of the target patterns Pj of the target patterns P1 to Pm and starts measuring the processing amounts of the respective microservices MS1 to MSn (step S1402). Note that in step S1402, it is possible to arbitrarily set which of the target patterns Pj of the target patterns P1 to Pm to perform optimization.

[0166] Next, the resource control device 301 determines whether or not the optimum value calculation period T1 has elapsed (step S1403). Here, the resource control device 301 waits for the optimum value calculation period T1 to elapse (step S1403: No). Then, when the optimum value calculation period T1 has elapsed (step S1403: Yes), the resource control device 301 calculates an optimum value pattern based on the processing amounts of the respective microservices MS1 to MSn measured during the optimum value calculation period T1 (step S1404).

[0167] Next, the resource control device 301 determines whether or not the quality of the service has deteriorated based on the result of comparing the current target pattern Pj with the calculated optimum value pattern (step S1405). Here, when the quality of the service has not deteriorated (step S1405: No), the resource control device 301 proceeds to step S1408.

[0168] On the other hand, when the quality of the service deteriorates (step S1405: Yes), the resource control device 301 determines whether the calculated optimal value pattern matches another target pattern Pk (k ≠ j) different from the current target pattern Pj among the target patterns P1 to Pm (step S1406).

[0169] Here, when it does not match another target pattern Pk (step S1406: No), the resource control device 301 proceeds to step S1408. On the other hand, when it matches another target pattern Pk (step S1406: Yes), the resource control device 301 horizontally scales with the target pattern Pk and adjusts the amount of resources allocated to each of the microservices MS1 to MSn (step S1407).

[0170] Then, the resource control device 301 determines whether the limit value calculation period T2 has elapsed (step S1408). Here, when the limit value calculation period T2 has not elapsed (step S1408: No), the resource control device 301 returns to step S1403. On the other hand, when the limit value calculation period T2 has elapsed (step S1408: Yes), the resource control device 301 proceeds to step S1501 shown in FIG. 15.

[0171] In the flowchart of FIG. 15, first, the resource control device 301 determines the target patterns P1 to Pm based on the optimal value patterns calculated for each optimal value calculation period T1 within the limit value calculation period T2 (step S1501). Next, the resource control device 301 determines whether the determined target patterns P1 to Pm are different from the previous target patterns (step S1502).

[0172] If the target pattern is the same as the previous target pattern (step S1502: No), the resource control device 301 proceeds to step S1505. On the other hand, if the target pattern is different from the previous target pattern (step S1502: Yes), the resource control device 301 calculates the limit values of each of the microservices MS1 to MSn for horizontal scaling in the determined target patterns P1 to Pm (step S1503).

[0173] In step S1503, for example, the number of containers to be allocated to each of the microservices MS1 to MSn for each of the target patterns P1 to Pm is also calculated.

[0174] Then, the resource control device 301 restarts and allocates the containers of the calculated limit value according to the number of containers of any one of the target patterns Pj of the target patterns P1 to Pm for each of the microservices MS1 to MSn (step S1504). The processing of step S1504 corresponds to optimization by vertical scaling.

[0175] In step S1504, it is possible to arbitrarily set which of the target patterns P1 to Pm to use for optimization. For example, the resource control device 301 may use the target pattern Pj corresponding to the optimum value pattern with the highest appearance frequency among the target patterns P1 to Pm to use for optimization.

[0176] Next, the resource control device 301 determines whether the monitoring period for the microservices MS1 to MSn has ended (step S1505). If the monitoring period has not ended (step S1505: No), the resource control device 301 returns to step S1403 shown in Fig. 14. On the other hand, if the monitoring period has ended (step S1505: Yes), the resource control device 301 ends the series of processes according to this flowchart.

[0177] This makes it possible to reduce downtime caused by restarting containers when adjusting the amount of resources according to the processing volume of each of the microservices MS1 to MSn.

[0178] As described above, the resource control device 301 according to the embodiment can determine the target patterns P1 to Pm based on the processing amount measured for each of the microservices MS1 to MSn. Furthermore, the resource control device 301 can calculate the limit values of each of the microservices MS1 to MSn for horizontal scaling in the target patterns P1 to Pm based on the allocation ratios of each of the determined target patterns P1 to Pm. Then, the resource control device 301 can adjust the amount of resources allocated to each of the microservices MS1 to MSn using the calculated limit values of each of the microservices MS1 to MSn when horizontally scaling in any of the target patterns Pj of the target patterns P1 to Pm.

[0179] As a result, the resource control device 301 can perform horizontal scaling at multiple resource allocation ratios (target patterns P1 to Pm) according to the processing volume of each of the microservices MS1 to MSn. Therefore, the resource control device 301 can appropriately control the amount of resources allocated to each of the microservices MS1 to MSn without restarting the containers. Furthermore, the resource control device 301 can calculate a limit value for horizontal scaling in the target patterns P1 to Pm for each microservice MSi. Therefore, the resource control device 301 can set a limit value that is easy to horizontally scale between the target patterns P1 to Pm and is as large as possible, for example, and can prevent a decrease in performance due to an increase in the number of containers.

[0180] Furthermore, the resource control device 301 can calculate the resource allocation ratio (optimum value pattern) for each of the microservices MS1 to MSn for each optimum value calculation period T1 based on the processing amount measured for each of the microservices MS1 to MSn for each optimum value calculation period T1. Then, the resource control device 301 can determine the target patterns P1 to Pm based on the calculated resource allocation ratio for each optimum value calculation period T1.

[0181] This allows the resource control device 301 to determine the target patterns P1 to Pm in consideration of the fluctuation trends in the processing amount of each of the microservices MS1 to MSn for each optimum value calculation period T1. For example, the resource control device 301 can determine the top m optimum value patterns with the highest appearance frequency as the target patterns P1 to Pm from among the optimum value patterns for each optimum value calculation period T1.

[0182] Furthermore, according to the resource control device 301, each time the limit value calculation period T2 elapses, target patterns P1 to Pm can be determined based on the resource allocation ratio (optimum value pattern) calculated for each optimum value calculation period T1 within the limit value calculation period T2.

[0183] This allows the resource control device 301 to review the allocation ratio of resources to be subject to horizontal scaling for the microservices MS1 to MSn every time the limit value calculation period T2 elapses.

[0184] Furthermore, according to the resource control device 301, when the currently determined target patterns P1 to Pm are different from the previously determined target patterns P1 to Pm, it is possible to newly calculate the limit values of the microservices MS1 to MSn, respectively.

[0185] As a result, the resource control device 301 can change the target patterns P1 to Pm and review the limit values for each of the microservices MS1 to MSn every limit value calculation period T2 when the variation trend of the throughput of each of the microservices MS1 to MSn changes. For example, when the combination of the optimal value patterns with high occurrence frequencies changes, the quality of the service can be ensured by changing the target patterns P1 to Pm and reviewing the limit values so that the quality degradation of the service does not continue.

[0186] In addition, according to the resource control device 301, in response to detecting quality degradation of the service related to the microservices MS1 to MSn, horizontal scaling can be performed with any one of the target patterns Pj of the target patterns P1 to Pm.

[0187] As a result, when the quality of the service deteriorates, the resource control device 301 can perform optimization by horizontal scaling among the patterns of the target patterns P1 to Pm.

[0188] In addition, according to the resource control device 301, every time the optimal value calculation period T1 elapses, it is possible to detect quality degradation of the service based on the optimal value pattern (resource allocation ratio) in the calculated optimal value calculation period T1. And according to the resource control device 301, in response to detecting quality degradation of the service, horizontal scaling can be performed with any one of the target patterns Pj of the target patterns P1 to Pm.

[0189] As a result, the resource control device 301 can detect quality degradation of the service based on the degree of deviation between the optimal value pattern in the optimal value calculation period T1 and the current target pattern every optimal value calculation period T1. Further, when quality degradation of the service is detected, the resource control device 301 can perform optimization by horizontal scaling among the patterns of the target patterns P1 to Pm determined in consideration of the variation trend of the throughput every optimal value calculation period T1.

[0190] For these reasons, the resource control device 301 can reduce downtime due to container restarts by performing horizontal scaling optimization with a reduced number of containers when adjusting the amount of resources according to the processing volume of each microservice MS1 to MSn. Specifically, for example, during the limit value calculation period T2, the resource control device 301 can perform horizontal scaling optimization using target patterns P1 to Pm determined according to the processing volume of each microservice MS1 to MSn. In horizontal scaling optimization, since the limit values of each microservice MSi are the same across target patterns, the optimization can be achieved simply by increasing or decreasing the number of containers, and no container restart is required. Furthermore, the resource control device 301 can re-determine target patterns P1 to Pm according to the processing volume of each microservice MS1 to MSn and review the limit values of each microservice MS1 to MSn every time the limit value calculation period T2 elapses. Container restarts are performed only when the limit values are reviewed, minimizing downtime-inducing vertical scaling optimization.

[0191] The resource control method described in this embodiment can be realized by executing a prepared program on a computer such as a personal computer or a workstation. The resource control program is recorded on a computer-readable recording medium such as a hard disk, flexible disk, CD-ROM, DVD, or USB memory, and is executed by being read from the recording medium by the computer. The resource control program may also be distributed via a network such as the Internet.

[0192] In addition, the information processing device 101 (resource control device 301) described in this embodiment can also be realized by an application-specific IC such as a standard cell or a structured ASIC (Application Specific Integrated Circuit) or a PLD (Programmable Logic Device) such as an FPGA.

[0193] Regarding the above-described embodiments, the following additional remarks are disclosed.

[0194] (Supplementary Note 1) Based on the processing volumes measured for each of a plurality of related microservices, for the plurality of microservices, determine a plurality of patterns of the allocation ratios of resources to be horizontally scaled, Based on the determined allocation ratios of each of the plurality of patterns, calculate the allocation units of each of the plurality of microservices for horizontal scaling in the plurality of patterns, When horizontally scaling in any one of the plurality of patterns, use the calculated allocation units of each of the plurality of microservices to adjust the amount of resources allocated to each of the plurality of microservices. An allocation control program characterized by causing a computer to execute processing.

[0195] (Supplementary Note 2) The processing for determination is Based on the processing volumes measured for each of the plurality of microservices for each first period, calculate the allocation ratios of the resources for each first period for the plurality of microservices, Based on the calculated allocation ratios of the resources for each first period, determine a plurality of patterns of the allocation ratios of the resources to be horizontally scaled. The allocation control program according to Supplementary Note 1, characterized by the above.

[0196] (Supplementary Note 3) The processing for determination is Each time a second period having a longer period length than the first period elapses, based on the allocation ratios of the resources calculated for each first period within the second period, determine a plurality of patterns of the allocation ratios of the resources to be horizontally scaled. The allocation control program according to Supplementary Note 2 is characterized by the above.

[0197] (Supplementary Note 4) The processing for calculating the allocation unit is When the determined plurality of patterns are different from the plurality of patterns determined last time, calculating the allocation unit of each of the plurality of microservices based on the allocation ratio of each of the determined plurality of patterns. The allocation control program according to Supplementary Note 3, characterized in that.

[0198] (Supplementary Note 5) The process of adjusting is executed in response to detecting deterioration in the quality of the service related to the plurality of microservices. The allocation control program according to any one of Supplementary Notes 1 to 4, characterized in that.

[0199] (Supplementary Note 6) Each time the first period elapses, causing the computer to execute a process of detecting deterioration in the quality of the service related to the plurality of microservices based on the calculated allocation ratio of the resources in the first period. The allocation control program according to Supplementary Note 2, characterized in that.

[0200] (Supplementary Note 7) The plurality of microservices include microservices in a call relationship. The allocation control program according to any one of Supplementary Notes 1 to 5, characterized in that.

[0201] (Supplementary Note 8) Based on the processing amounts measured for each of the plurality of related microservices, determining a plurality of patterns of the allocation ratio of the resources to be targeted for horizontal scaling for the plurality of microservices, calculating the allocation unit of each of the plurality of microservices for horizontal scaling in the plurality of patterns based on the allocation ratio of each of the determined plurality of patterns, when horizontally scaling in any one of the plurality of patterns, adjusting the amount of resources allocated to each of the plurality of microservices using the calculated allocation unit of each of the plurality of microservices. An allocation control method characterized in that a computer executes the process.

Explanation of Signs

[0202] 101 Information processing apparatus 111,112,113,114,115 Bar graph 300 Information Processing Systems 301 Resource Control Device 302 Client Device 310 Network 320 Target Pattern Table 400 Bus 401 CPU 402 memory 403 disk drive 404 Disk 405 Communication I / F 406 Portable Recording Media I / F 407 Portable Recording Media 601 Measurement Unit 602 First Calculation Unit 603 Decision Section 604 Second Calculation Unit 605 Allocation control unit 700,800,900 Measurement results 1210,1220 graph

Claims

1. Based on the processing volumes measured for each of a plurality of related microservices, for the plurality of microservices, determine a plurality of patterns of the allocation ratios of resources to be horizontally scaled, Based on the allocation ratios of each of the determined plurality of patterns, calculate the allocation units of each of the plurality of microservices for horizontal scaling in the plurality of patterns, When horizontally scaling in any one of the plurality of patterns, adjust the amount of resources allocated to each of the plurality of microservices using the calculated allocation units of each of the plurality of microservices, A allocation control program characterized by causing a computer to execute the processing.

2. The determining process is Based on the processing volumes measured for each of the plurality of microservices for each first period, calculate, for the plurality of microservices, the allocation ratio of the resources for each first period, Based on the calculated allocation ratio of the resources for each first period, determine a plurality of patterns of the allocation ratio of the resources to be horizontally scaled, The allocation control program according to claim 1, characterized in that.

3. The determining process is Each time a second period having a longer period length than the first period elapses, based on the allocation ratio of the resources calculated for each first period within the second period, determine a plurality of patterns of the allocation ratio of the resources to be horizontally scaled. The allocation control program according to claim 2, characterized in that.

4. The process of calculating the allocation unit is When the determined plurality of patterns are different from the plurality of patterns determined last time, calculate the allocation units of each of the plurality of microservices based on the allocation ratios of each of the determined plurality of patterns. The allocation control program according to claim 3, characterized in that.

5. The adjusting process is executed in response to detecting a deterioration in the quality of the service related to the plurality of microservices. The allocation control program according to any one of claims 1 to 4, characterized in that.

6. Based on the processing volumes measured for each of a plurality of related microservices, for the plurality of microservices, determine a plurality of patterns of the allocation ratios of resources to be horizontally scaled, Based on the assigned ratio of each of the determined plurality of patterns, calculate the allocation unit of each of the plurality of microservices for horizontal scaling in the plurality of patterns. When horizontally scaling in any one of the plurality of patterns, use the calculated allocation unit of each of the plurality of microservices to adjust the amount of resources allocated to each of the plurality of microservices. An allocation control method characterized in that a computer executes the processing.

Citation Information

Patent Citations

  • Method for distributing process associated with two or more priority groups among two or more resources

    JP2004199674A

  • Performance adjustment program and performance adjustment method

    JP2019135597A

  • Network performance guarantee system and network performance guarantee method

    JP2020123848A

  • Auto scale type performance guarantee system and auto scale type performance guarantee method

    JP2020123849A

  • Automatic Diagonal Scaling of Workloads in Distributed Computing Environments

    JP2021504777A