Delay estimation device, delay estimation method, and delay estimation system

The microservice response time is obtained through the data model of pre-association query and the delay is determined based on the response time, which solves the problem of difficulty in accurately positioning the microservice delay source in the prior art, and achieves the effect of quickly identifying the delay part.

CN119968621AInactive Publication Date: 2025-05-09MITSUBISHI ELECTRIC CORP
View PDF 4 Cites 0 Cited by

Patent Information

Application Number
CN202280100744.3
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2022-10-14
Publication Date
2025-05-09
Estimated Expiration
Not applicable · inactive patent

AI Technical Summary

Technical Problem

The prior art is difficult to quickly determine the specific part of delays in microservices, which leads to users requiring confirmation within a wide range during maintenance, making it difficult to accurately locate the delay source.

Method used

By pre-associating the data model of multiple queries, the acquiring unit obtains the response time of the microservice used by each query, and the determination unit determines whether a delay occurs based on the current and past response times.

Benefits of technology

It realizes rapid identification of the delay part in microservices, and users can easily determine the specific query of delays, improving maintenance efficiency.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119968621A_ABST
    Figure CN119968621A_ABST
Patent Text Reader

Abstract

The purpose of the present invention is to provide a technique by which a user can easily identify a portion in which a delay has occurred in a microservice. The delay estimation device includes an acquisition unit and a determination unit. The acquisition unit acquires, for each of a plurality of queries, a response time of one or more microservices using the query with respect to a data model in which the queries are associated in advance. The determination unit determines whether or not a delay has occurred for each of the queries on the basis of the response time of this time and the past response time.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present disclosure relates to a delayed speculation device, a delayed speculation method, and a delayed speculation system. Background Art

[0002] In recent years, various technologies have been proposed for the architecture of a system such as a cloud, which divides a plurality of functions into a plurality of microservices and combines the plurality of microservices. For example, Patent Document 1 proposes a technology for determining the delay of a microservice.

[0003] Prior art literature

[0004] Patent Literature

[0005] Patent Document 1: Japanese Patent Application Publication No. 2021-196970 Summary of the invention

[0006] In the prior art, the response time between microservices is focused, so the delay of the path of the delayed microservice can be determined. However, it is not determined in which query used by the microservice the delay occurred. Therefore, when performing maintenance, the user needs to confirm the part of the microservice that has been delayed in a relatively wide range, and there is a problem that such a part cannot be easily determined.

[0007] Therefore, the present disclosure has been made in view of the above-mentioned problems, and an object of the present disclosure is to provide a technology that allows a user to easily identify a portion where a delay has occurred in a microservice.

[0008] The delay estimation device disclosed in the present invention comprises: an acquisition unit, which acquires the response time of one or more microservices using each query with respect to a data model that pre-associates multiple queries; and a determination unit, which determines whether a delay has occurred for each query based on the current response time and the past response time.

[0009] According to the present disclosure, whether a delay has occurred is determined for each query based on the current response time and the past response time. According to such a structure, the user can easily identify the part where the delay has occurred in the microservice.

[0010] The objects, features, aspects and advantages of the present disclosure will become more apparent from the following detailed description and accompanying drawings. BRIEF DESCRIPTION OF THE DRAWINGS

[0011] Figure 1 This is a block diagram showing the structure of the delay estimation system according to the first embodiment.

[0012] Figure 2 This is a diagram showing an example of data stored in the monitoring data management DB according to the first embodiment.

[0013] Figure 3 This is a diagram showing an example of a data model stored in the data model management DB according to the first embodiment.

[0014] Figure 4 This is a diagram showing an example of the response time stored in the history management unit according to the first embodiment.

[0015] Figure 5 This is a flowchart showing the operation of the delay estimation device according to the first embodiment.

[0016] Figure 6 This is a flowchart showing the operation of the delay estimation device according to the first embodiment.

[0017] Figure 7 This is a diagram showing an example of the response time stored in the history management unit according to Modification 3.

[0018] Figure 8 This is a block diagram showing a hardware configuration of a delay estimation device according to another modification.

[0019] Fig. 9 This is a block diagram showing a hardware configuration of a delay estimation device according to another modification. DETAILED DESCRIPTION

[0020] <Implementation Method 1>

[0021] Figure 1 This is a block diagram showing the configuration of the delay estimation system according to the first embodiment. Figure 1 The delay estimation system includes a microservice 1, a monitoring data management DB 2, a delay estimation device 3, a data model management DB 4, a history management unit 5, and a control device 6. In addition, DB in the monitoring data management DB 2 and the data model management DB 4 means "database".

[0022] Microservice 1 has a specific function, and multiple microservices 1 build a functional system such as a cloud with a desired function that combines specific functions. Microservice 1 uses queries to obtain, retrieve, and change data stored in monitoring data management DB2, thereby realizing specific functions. In addition, microservice 1 uses queries to obtain, retrieve, and change data not only stored in monitoring data management DB2, but also data processed by other microservices 1, thereby realizing specific functions.

[0023] Microservice 1 uses one or more queries. Metadata such as equipment, year, and building are assigned to names used to identify queries. For example, microservice 1 uses a query to which year is added as a name to perform processing such as acquisition, retrieval, and modification of data related to the year. In addition, a microservice 1 can use multiple queries in parallel, in series, or selectively.

[0024] The data to be acquired, searched, or changed by the query of the microservice 1 is stored in the monitoring data management DB 2 .

[0025] Figure 2 FIG. 2 is a diagram showing an example of data stored in the monitoring data management DB 2 according to the first embodiment. Figure 2 In the example, the sensor name and the sensor's measured value are stored in correspondence. Figure 2 The tables are associated with each sensor and stored in the monitoring data management DB2. When the microservice 1 uses the query of the sensor A3, the microservice 1 obtains the data related to the sensor A3 from the multiple tables of the monitoring data management DB2. The monitoring data management DB2 is composed of a relational database, for example.

[0026] Figure 1 When the microservice 1 executes a specific function, the delay estimation device 3 cooperates with the data model management DB 4 and the history management unit 5 to estimate the delay of the query used by the microservice 1. The delay estimation device 3, the data model management DB 4 and the history management unit 5 are described in detail below.

[0027] The delay estimation device 3 includes an acquisition unit 3a, a determination unit 3b, and an estimation unit 3c.

[0028] The acquisition unit 3a acquires the response time of one or more microservices 1 using the query for each query, regarding the data model that pre-associates multiple queries. In the first embodiment, the one or more microservices 1 include one microservice 1 and other microservices 1. In the first embodiment, the data model is stored in the data model management DB 4.

[0029] Figure 3 FIG. 4 is a diagram showing an example of a data model stored in the data model management DB 4 according to the first embodiment. Figure 3 In the example, multiple queries are pre-associated in the data model in a hierarchical structure, including queries for devices, queries for instruments, and queries for sensors that are sequentially specified from the upper level of the hierarchical structure. In the first embodiment, the data model is set by the user, but is not limited thereto.

[0030] exist Figure 3In the example, the query of device A1 is associated with the query of the subordinate instruments A2 and B2. The query of instrument A2 is associated with the query of the subordinate sensors A3, B3, and C3, and the query of instrument B2 is associated with the query of the subordinate sensor D3. The query of sensors A3, B3, C3, and D3 is associated with Figure 2 The query of sensor C3 is also associated with the value obtained as a result of the processing of microservice E.

[0031] For example, in Figure 3 In the case of the data model setting shown, the microservice 1 using the query of device A1 actually uses the queries of devices A2 and B2. Similarly, the microservice 1 using the query of device A2 actually uses the queries of sensors A3, B3, and C3.

[0032] Figure 1 The acquisition unit 3a acquires the response time of the microservice 1 using the query for each query, based on the data model that pre-associates multiple queries. For example, when the microservice 1 uses the query of the sensor A3, the acquisition unit 3a Figure 3 For example, when microservice 1 uses the query of instrument A2, acquisition unit 3a follows Figure 3 The data model of is used to obtain the response time from the request to the response of the query of the device A2 and the sensors A3, B3, and C3. The history management unit 5 stores the response time obtained by the acquisition unit 3a.

[0033] Figure 4 1 is a diagram showing an example of the response time stored in the history management unit 5 according to Embodiment 1. The history management unit 5 stores the most recently acquired response time of this time and the previous response time as an example of the past response time acquired in the past.

[0034] exist Figure 4 In the example of , microservice A selectively uses the query of sensor A3 and the query of sensor B3, and obtains the response time of sensor B3. Figure 4 In the example, microservices C and E use the query of sensor A3, and the response time of sensor A3 is obtained. In addition, the difference in response time between microservices C and E using the same query of sensor A3 is caused by differences in other parts other than the query of sensor A3, such as the network.

[0035] Figure 1The determination unit 3b determines whether a delay has occurred for each query based on the current response time and the past response time. In the first embodiment, the determination unit 3b determines whether a delay has occurred for each query based on the current response time and the threshold value.

[0036] Figure 5 : is a flowchart showing the operation of the determination unit 3b according to the first embodiment. Figure 5 The operation is performed for each query when the microservice 1 uses the query and the acquisition unit 3a acquires the response time.

[0037] First, in step S1, the determination unit 3b performs statistical processing on a plurality of past response times to calculate statistics of the past response times. Examples of the statistics include an average value, a median, a variance, and a standard deviation.

[0038] In step S2, the determination unit 3b calculates the weight of the query. For example, the determination unit 3b calculates the importance of the query or the importance of the microservice 1 using the query as the weight of the query based on query information such as the usage frequency of the query.

[0039] In step S3 , the determination unit 3 b determines a threshold value based on the statistic calculated in step S1 and the query weight calculated in step S2 .

[0040] In step S4, the determination unit 3b determines whether a delay has occurred in the query for which the response time has been obtained, based on whether the response time is greater than the threshold value determined in step S3. In the first embodiment, the determination unit 3b determines that a delay has occurred in the query when the response time is greater than the threshold value, and determines that no delay has occurred in the query when the response time is less than the threshold value. Thereafter, Figure 5 The action is finished.

[0041] In the above operation, for example, when the statistic is an average value, the determination unit 3b determines the sum or product of the average value and a predetermined margin value as a threshold value. When only one past response time is obtained and the statistic of step S1 cannot be calculated, the determination unit 3b determines the sum or product of the past response time value and a predetermined margin value as a threshold value. Moreover, in the determination unit 3b, the higher the weight of the query, that is, the higher the importance of the query or microservice, the smaller the margin value. According to such a structure, the higher the importance of the query, the stricter the determination of the query delay can be, so it is easy to detect the delay of the query or microservice 1 with high importance.

[0042] exist Figure 4In the example, in microservice A using the query of sensor B3, the response time this time is approximately the same as the response time last time, so the determination unit 3b tends to determine that no delay has occurred in the query of sensor B3. On the other hand, in microservices C and E using the query of sensor A3, the response time this time is significantly longer than the response time last time, so the determination unit 3b tends to determine that a delay has occurred in the query of sensor A3.

[0043] In the following description, for convenience of explanation, a query determined by the determination unit 3 b to be delayed may be referred to as a “delayed query”.

[0044] Figure 1 The inference unit 3c infers that a delay occurs in both the microservice 1 using the delayed query and the query associated with the delayed query in the data model based on the data model and the delayed query. In addition, without limitation to this, the inference unit 3c may also infer that a delay occurs in one of the two parties, not the microservice 1 using the delayed query and the query associated with the delayed query in the data model.

[0045] In the first embodiment, the estimation unit 3 c estimates, based on the data model and the delayed query, that a delay has occurred in a query that is associated with the delayed query and is at a higher level than the delayed query in the hierarchical structure.

[0046] Figure 6 : is a flowchart showing the operation of the estimation unit 3c according to the first embodiment. Figure 6 The action is performed when the determination unit 3b determines that the query is delayed.

[0047] First, in step S11 , the estimation unit 3 c identifies the position of the delayed query in the data model.

[0048] In step S12, the inference unit 3c identifies a query that is associated with the delayed query and is at a higher level than the delayed query in the hierarchical structure of the data model. Figure 3 If the query of the sensor A3 is determined to be a delayed query based on the data model, in step S12, the estimation unit 3c specifies the queries of the device A2 and the equipment A1.

[0049] In step S13, the inference unit 3c infers that a delay has occurred in the microservice 1 using the delayed query and the query determined in step S12. For example, assuming that the data model is Figure 3 The data model, Figure 4 The query of sensor A3 used by microservice E is determined to be a delayed query. In this case, in step S13, the estimation unit 3c estimates that Figure 4There is a delay in the query of microservice E, instrument A2, and device A1. Figure 6 The action is finished.

[0050] Figure 1 The control device 6 controls the display device (not shown) to display the judgment result and the judgment result of the delay estimation device 3. In addition, the control device 6 stops the microservice 1 that uses the delay query determined by the delay estimation device 3. For example, as in the above example, Figure 4 If the query of sensor A3 used by microservice E is determined to be a delayed query, the control device 6 stops Figure 4 The microservice E. In addition, the control device 6 may stop all functional systems constructed by the microservice 1 using delayed query, or may stop only the microservice 1 using delayed query in the functional system.

[0051] <Summary of Implementation Method 1>

[0052] According to the delay estimation device 3 involved in the above-mentioned embodiment 1, whether a delay has occurred is determined for each query based on the current response time and the past response time. According to such a structure, it is possible to determine in which query of the microservice 1 the delay has occurred, so the user can easily identify the part of the microservice 1 in which the delay has occurred.

[0053] In addition, in the first embodiment, based on the data model and the delayed query, it is inferred that a delay has occurred in at least one of the microservice using the delayed query and the query associated with the delayed query in the data model. As an example, based on the data model and the delayed query, it is inferred that a delay has occurred in a query at a level higher than the delayed query in the hierarchical structure that is associated with the delayed query. With such a structure, it is possible to reduce the effort of the user to investigate the data model and determine the microservice using the delayed query and the query associated with the delayed query.

[0054] In addition, in the first embodiment, a threshold for determining whether a delay has occurred for each query is determined based on the past response time and the weight of the query. With such a configuration, the determination of delay can be made stricter for queries or microservices 1 with high importance.

[0055] In addition, in the first embodiment, the microservice using the delayed query is stopped, so it is possible to suppress further occurrence of troubles due to the delayed query.

[0056] <Modification 1>

[0057] Embodiment 1 Figure 3The multiple queries of the data model include a group of queries of equipment, queries of instruments, and queries of sensors specified in order from the upper level of the hierarchical structure, but are not limited thereto. For example, the multiple queries may include a group of queries of years, queries of months, and queries of days specified in order from the upper level of the hierarchical structure, and may also include a group of queries of buildings, queries of floors, and queries of people specified in order from the upper level of the hierarchical structure.

[0058] <Modification 2>

[0059] In the first embodiment, the inference unit 3c may also infer that a delay occurs in other microservices 1 that use the delay query when a delay query is determined from one microservice 1 based on the data model and the delay query. Furthermore, the control device 6 may also stop the other microservices 1 that use the delay query. For example, Figure 4 In the case where the query of sensor A3 is determined to be a delayed query in microservice E, it may be inferred that a delay has occurred in microservices A and C using the query of sensor A3, and microservices A and C may be stopped. With such a configuration, it is possible to suppress further occurrence of malfunctions due to delayed queries.

[0060] <Variation 3>

[0061] Suppose that in the first embodiment, the second variation is not applied and other microservices 1 use the same query as the query used in one microservice. In such a case, one microservice 1 may determine that the query is delayed, but other microservices may not determine that the query is delayed. In this case, the inference unit 3c may also infer that a delay has occurred in a part other than the query in one microservice 1.

[0062] Figure 7 FIG. 4 is a diagram showing an example of the response time stored in the history management unit 5 according to the third modification. Figure 7 In, with Figure 4 The response time of this time in microservice C is changed to a smaller value.

[0063] For example, in Figure 7 In the example, it is assumed that the microservice E determines that the query of sensor A3 is delayed, and the microservice C does not determine that the query of sensor A3 is delayed. In this case, the inference unit 3c may also infer that the delay is not caused in the query of sensor A3, but in a part other than the query of sensor A3 in microservice E, for example, in the network of microservice E. According to such a structure, the part where the delay occurs is inferred in more detail, so the user can easily identify the part where the delay occurs in the microservice.

[0064] <Variation 4>

[0065] In embodiment 1, Figure 3 The number of data models is 1, but it can be multiple.

[0066] In addition, for example, the control device 6 may perform machine learning including at least one of supervised learning, unsupervised learning, and reinforcement learning, such as deep learning, on the names of the plurality of queries, thereby generating a data model.

[0067] The control device 6 configured in this way can associate, for example, a query to which the name "water purification plant 0 sludge field △ sensor A3" is added and a query to which the name "water purification plant 0 sludge field △ sensor B3" is added to a query to which the name "water purification plant 0 sludge field △" is added. In addition, the control device 6 can, for example, associate a query to which the name "water purification plant 0 sludge field △" is added and a query to which the name "water purification plant 0" is added. In this way, the control device 6 can automatically generate a data model, so the user can reduce the effort of setting the data model.

[0068] <Variation 5>

[0069] In the first embodiment, the determination unit 3b determines whether a delay has occurred for each query based on the current response time and the threshold value, but the present invention is not limited thereto. For example, the determination unit 3b may also create a response time transition pattern based on the current response time and the past response time, and perform machine learning similar to the above-mentioned machine learning on the transition pattern, thereby determining whether a delay has occurred for each query.

[0070] <Variation 6>

[0071] In the first embodiment, the delay estimation device 3 and the control device 6 are independently provided, but the present invention is not limited thereto. For example, although not shown in the figure, the delay estimation device 3 may include a control unit having the same function as the control device 6 in addition to the acquisition unit 3a, the determination unit 3b, and the estimation unit 3c. In addition, the delay estimation system is not limited to the delay estimation system involved in the first embodiment as long as it is a system having the same function as the acquisition unit 3a and the same function as the determination unit 3b.

[0072] <Other Modifications>

[0073] Below, the above Figure 1 The acquisition unit 3a, determination unit 3b, and estimation unit 3c are described as "acquisition unit 3a, etc.". Figure 8The processing circuit 81 shown is implemented. That is, the processing circuit 81 includes: an acquisition unit 3a, which acquires the response time of one or more microservices using the query for each query with respect to a data model that pre-associates multiple queries; a determination unit 3b, which determines whether a delay has occurred for each query based on the current response time and the past response time; and an inference unit 3c, which infers that a delay has occurred in at least one of the microservices using the delayed query and the queries associated with the delayed query in the data model based on the data model and the delayed query. As the processing circuit 81, dedicated hardware can be applied, and a processor that executes a program stored in a memory can also be applied. For example, a central processing unit, a processing unit, an arithmetic unit, a microprocessor, a microcomputer, a DSP (Digital Signal Processor), etc. are equivalent to a processor, for example, provided in a personal computer or a server.

[0074] When the processing circuit 81 is dedicated hardware, for example, a single circuit, a composite circuit, a programmed processor, a parallel programmed processor, an ASIC (Application Specific Integrated Circuit), an FPGA (Field Programmable Gate Array), or a combination thereof corresponds to the processing circuit 81. Each of the functions of each unit such as the acquisition unit 3a may be implemented by a circuit in which the processing circuit is dispersed, or the functions of each unit may be concentrated and implemented by one processing circuit.

[0075] When the processing circuit 81 is a processor, the functions of the acquisition unit 3a and the like are realized by a combination with software and the like. In addition, software and the like correspond to, for example, software, firmware, or software and firmware. Software and the like are described as programs and stored in a memory. Fig. 9As shown, the processor 82 applied to the processing circuit 81 realizes the functions of each unit by reading and executing the program stored in the memory 83. That is, the delay estimation device 3 has a memory 83 for storing a program, and when the program is executed by the processing circuit 81, the following steps are executed: a step of obtaining the response time of one or more microservices using the query for each query with respect to a data model that pre-associates a plurality of queries; a step of determining whether a delay has occurred for each query based on the current response time and the past response time; and a step of inferring that a delay has occurred in at least one of the microservice using the delay query and the query associated with the delay query in the data model based on the data model and the delay query. In other words, the program can also be called a program for causing a computer to execute a process or method such as the acquisition unit 3a. Here, the memory 83 may be, for example, RAM (Random Access Memory), ROM (Read Only Memory), flash memory, EPROM (Erasable Programmable Read Only Memory), EEPROM (electrically erasable programmable read only memory), or other non-volatile or volatile semiconductor memories, HDD (Hard Disk Drive), magnetic disk, floppy disk, optical disk, compact disk, mini disk, DVD (Digital Versatile Disc), their drive devices, or all storage media used in the future.

[0076] The above describes a structure in which each function of the acquisition unit 3a, etc. is realized by either hardware or software. However, the present invention is not limited thereto, and a part of the acquisition unit 3a, etc. may be realized by dedicated hardware, and another part may be realized by software, etc. For example, the acquisition unit 3a may realize its function by a processing circuit 81 or an acquisition processing circuit as dedicated hardware, and the other parts may realize their functions by the processing circuit 81 as a processor 82 reading and executing a program stored in a memory 83.

[0077] As described above, the processing circuit 81 can realize the above-mentioned functions through hardware, software, etc., or a combination thereof.

[0078] Furthermore, the contents of the embodiments can be modified or omitted as appropriate.

[0079] The above description is intended to be illustrative in all aspects and not restrictive. It should be understood that numerous modifications not shown are conceivable.

[0080] (Explanation of Reference Numerals)

[0081] 1: microservice; 3: delay estimation device; 3a: acquisition unit; 3b: determination unit; 3c: estimation unit.

Claims

1. A delay estimation device, comprising: an acquisition unit that acquires, for each of the queries, a response time of one or more microservices that use the query, with respect to a data model that pre-associates a plurality of queries; and The determination unit determines whether a delay has occurred for each of the inquiries based on the current response time and the past response time.

2. The delay estimation device according to claim 1, wherein: It also includes an inference unit that infers, based on the data model and the delayed query, that a delay has occurred in at least any one of the microservice using the delayed query and the queries associated with the delayed query in the data model, wherein the delayed query is the query determined to have been delayed.

3. The delay estimation device according to claim 1 or 2, wherein: The plurality of queries are pre-associated in the data model in a hierarchical structure.

4. The delay estimation device according to claim 2, wherein: The plurality of queries are pre-associated in the data model in a hierarchical structure, The estimation unit estimates, based on the data model and the delayed query, that a delay has occurred in the query that is associated with the delayed query and is located at a higher level than the delayed query in the hierarchical structure.

5. The delay estimation device according to claim 3 or 4, wherein: The plurality of queries include at least any one of the following groups: A group of device query, instrument query, and sensor query defined in order from the upper level of the hierarchical structure; A group of a year query, a month query, and a day query defined in order from the upper level of the hierarchical structure; as well as A group of a query of a building, a query of a floor, and a query of a person is defined in order from the upper level of the hierarchical structure.

6. The delay estimation device according to any one of claims 1 to 5, wherein: The determination unit determines whether a delay has occurred for each of the queries based on the current response time and a threshold value determined based on the past response time and the weight of the query.

7. The delay estimation device according to claim 2, wherein: Stop the microservice that uses the deferred query.

8. The delay estimation device according to claim 2, wherein: The one or more microservices include one microservice and other microservices, The estimation unit estimates, based on the data model and the delay query, that a delay has occurred in the other microservice using the delay query when the delay query is determined from the one microservice.

9. The delay estimation device according to claim 8, wherein: Stop the other microservices that use the delayed query.

10. The delay estimation device according to claim 2, wherein: The one or more microservices include one microservice and other microservices that use the query used in the one microservice, The estimation unit estimates that a delay has occurred in a portion other than the query in the one microservice, when the one microservice determines that the query is delayed and the other microservices do not determine that the query is delayed.

11. The delay estimation device according to any one of claims 1 to 10, wherein: The data model is generated by performing machine learning on the names of the plurality of queries.

12. A delayed speculation method, Regarding a data model that pre-associates a plurality of queries, for each of the queries, a response time of one or more microservices that use the query is obtained, Whether a delay has occurred is determined for each of the inquiries based on the current response time and the past response time.

13. A delay estimation system comprising: Regarding a data model that pre-associates a plurality of queries, a function of obtaining, for each of the queries, a response time of one or more microservices that use the query; and A function of determining whether a delay has occurred for each inquiry based on the current response time and the past response time.

Citation Information

Patent Citations

  • Distributed business tracking system and method

    CN107688520A

  • Delay cause specifying method and delay cause specifying program

    JP2021196970A

  • Model generation service for data retrieval

    US20220222225A1

  • Monitoring system, monitoring image information generation method, and monitoring image information generation program

    WO2021095268A1