An index data acquisition method, device and equipment
By defining the target metric collection container and strategy within the application container, and using the target metric collection container to collect and store data, the problem of poor data collection accuracy and continuity in existing technologies is solved, and the accuracy and continuity of data collection are improved without restarting the application container.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- CHINA MOBILE GRP FUJIAN CO LTD
- Filing Date
- 2021-03-15
- Publication Date
- 2026-04-28
AI Technical Summary
Existing technologies for collecting metric data in application containers suffer from poor data collection accuracy, especially when the metric to be collected needs to be changed, requiring the application container to be restarted, resulting in poor continuity of metric data.
By defining the target metric collection container and collection strategy, the target metric collection container is used to collect metric data from the application container, and the data is stored in a specified location after the integrity check is passed, thus avoiding restarting the application container.
It improves the accuracy and continuity of indicator data collection, ensuring that the application container does not need to be restarted when the target indicator changes, thus guaranteeing data continuity.
Smart Images

Figure CN115081026B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of computer technology, and in particular to a method, apparatus, and device for acquiring indicator data. Background Technology
[0002] With the continuous development of computer technology, various computing systems, storage systems, and application systems have been rapidly built up along with the rapid development of business. In order to solve the problem of cumbersome deployment and maintenance, application container management platforms have emerged.
[0003] Application container management platforms can be used to manage containerized applications across multiple hosts on a cloud platform, making the deployment of containerized applications simpler and more efficient. Within an application container management platform, performance metrics data of application containers can be collected by reading the host file system.
[0004] However, if changes are needed to the metrics to be collected during the above-mentioned data collection process, it is necessary to restart one or more application containers corresponding to the entire application. Restarting the application container will cause the metric data stored in memory to become zero or have no value, resulting in poor continuity of metric data. In other words, the above-mentioned method of collecting metric data has the problem of poor data collection accuracy. Summary of the Invention
[0005] The purpose of this invention is to provide a method, apparatus, and device for acquiring indicator data, so as to solve the problem of poor data collection accuracy in the prior art when collecting indicator data from application containers.
[0006] To solve the above-mentioned technical problems, the embodiments of the present invention are implemented as follows:
[0007] In a first aspect, embodiments of the present invention provide a method for acquiring indicator data. The method includes: determining a target indicator acquisition container and a target indicator acquisition strategy corresponding to a target indicator to be acquired; sending the target indicator acquisition strategy to the target indicator acquisition container, so that the target indicator acquisition container acquires indicator data from the application container corresponding to the target indicator based on the target indicator acquisition strategy; and storing the indicator data of the target indicator acquired by the target indicator acquisition container in a designated storage location after the integrity check of the indicator data of the target indicator is passed.
[0008] Secondly, embodiments of the present invention provide an indicator data acquisition device, the device comprising: a determining module, configured to determine a target indicator acquisition container and a target indicator acquisition strategy corresponding to a target indicator to be acquired; a sending module, configured to send the target indicator acquisition strategy to the target indicator acquisition container, so that the target indicator acquisition container acquires indicator data from the application container corresponding to the target indicator based on the target indicator acquisition strategy; and a storage module, configured to store the indicator data of the target indicator in a designated storage location after the integrity check of the indicator data of the target indicator acquired by the target indicator acquisition container passes.
[0009] Thirdly, embodiments of the present invention provide a device including a processor, a memory, and a computer program stored in the memory and executable on the processor. When the computer program is executed by the processor, it implements the steps of the indicator data acquisition method provided in the above embodiments.
[0010] Fourthly, embodiments of the present invention provide a computer-readable storage medium, characterized in that a computer program is stored on the computer-readable storage medium, and when the computer program is executed by a processor, it implements the steps of the indicator data acquisition method provided in the above embodiments.
[0011] As can be seen from the technical solutions provided by the above embodiments of the present invention, the embodiments of the present invention determine the target indicator collection container and the target indicator collection strategy corresponding to the target indicator to be collected, and send the target indicator collection strategy to the target indicator collection container, so that the target indicator collection container collects indicator data from the application container corresponding to the target indicator based on the target indicator collection strategy. After the integrity check of the indicator data of the target indicator collected by the target indicator collection container passes, the indicator data of the target indicator is stored in a designated storage location. In this way, indicator data of the application container can be collected through the target indicator collection container, and the indicator data is stored in the designated storage location after the integrity check passes. This avoids the problem of poor data collection continuity when obtaining indicator data by reading the host file system. That is, if the target indicator changes, it is not necessary to restart the application container, thus ensuring the continuity of the collected target indicator data and improving the data collection accuracy when collecting indicator data from the application container. Attached Figure Description
[0012] To more clearly illustrate the technical solutions in the embodiments of the present invention or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments recorded in the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0013] Figure 1 This is a flowchart illustrating a method for acquiring indicator data according to the present invention;
[0014] Figure 2 This is a flowchart illustrating another method for acquiring indicator data according to the present invention;
[0015] Figure 3 This is a flowchart illustrating another method for acquiring indicator data according to the present invention;
[0016] Figure 4 This is a schematic diagram of the structure of an indicator data acquisition device according to the present invention;
[0017] Figure 5 This is a schematic diagram of the structure of an indicator data acquisition device according to the present invention. Detailed Implementation
[0018] This invention provides a method, apparatus, and device for acquiring indicator data.
[0019] To enable those skilled in the art to better understand the technical solutions of this invention, the technical solutions of the embodiments of this invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of this invention, and not all embodiments. Based on the embodiments of this invention, all other embodiments obtained by those skilled in the art without creative effort should fall within the scope of protection of this invention.
[0020] Example 1
[0021] like Figure 1 As shown, this embodiment of the invention provides a method for acquiring indicator data. The execution subject of this method can be a terminal device or a server. The server can be an independent server or a server cluster composed of multiple servers. Specifically, the method may include the following steps:
[0022] In S102, the target indicator collection container and target indicator collection strategy corresponding to the target indicator to be collected are determined.
[0023] The target metric can be a performance metric related to the application container, such as CPU utilization, memory utilization, request response time, or network throughput. The application container can be a lightweight, standalone executable software package containing the information needed to run the application: code, runtime, system tools, system libraries, and settings. The target metric collection container can be a container used to collect metric data from the application container, and the target metric collection strategy can include the collection time, collection method, and other details of the target metric.
[0024] In practice, with the continuous development of computer technology, various computing systems, storage systems, and application systems have been rapidly built up along with the rapid development of business. To solve the problem of cumbersome deployment and maintenance, application container management platforms have emerged. Application container management platforms can be used to manage containerized applications on multiple hosts in a cloud platform, making the deployment of containerized applications simpler and more efficient. Within the application container management platform, performance metrics data of application containers can be collected by reading the host file system.
[0025] However, during the metric data collection process described above, if changes are needed to the collected metrics, it is necessary to restart one or more application containers corresponding to the entire application. Restarting the application containers causes the metric data stored in memory to become zero or empty, resulting in poor continuity of the metric data. In other words, collecting metric data using the above method suffers from poor data collection accuracy. Therefore, this embodiment of the invention provides another implementation scheme, which may include the following:
[0026] The terminal device or server can be an instruction platform used to configure and manage indicator collection and scheduling instructions and to determine the target indicator collection strategy.
[0027] The command platform can receive a data collection command for a target indicator. Upon receiving the data collection command, the command platform can determine the target indicator collection container corresponding to the target indicator based on the preset correspondence between the indicator label and the indicator collection container. The target indicator collection container can be one or more.
[0028] Furthermore, the command platform can determine the target indicator collection strategy corresponding to the target indicator based on the preset correspondence between indicator tags and indicator collection strategies. For example, assuming the target indicator is maximum memory utilization, the corresponding target indicator collection strategy could be the latest indicator data collection strategy or the maximum value acquisition strategy.
[0029] Furthermore, there can be various target indicator collection strategies, which may vary depending on the actual application scenario. This embodiment of the invention does not impose any specific limitations on these strategies.
[0030] In S104, the target metric collection strategy is sent to the target metric collection container so that the target metric collection container can collect metric data from the application container corresponding to the target metric based on the target metric collection strategy.
[0031] In practice, the target metric collection container and the application container can be started in no fixed order. When the application container is in a ready or normal state, the target metric collection container can collect metric data from the application container corresponding to the target metric based on the target collection strategy.
[0032] Taking the target metric as maximum memory utilization as an example, when the application container is in a ready or normal state, the target metric collection container can collect the memory utilization of the application container and transmit the collected memory utilization to the metric value register. The metric value register can compare the received memory utilization with the locally stored memory utilization. If the received memory utilization is greater than the locally stored memory utilization, the received memory utilization will replace the locally stored memory utilization. If the metric value register does not store memory utilization, it can directly store the received memory utilization.
[0033] Furthermore, if there are multiple target metric collection containers, the metric value register can compare the received memory usage rates and determine and store the maximum memory usage rate based on the comparison results.
[0034] The indicator value register can transfer the maximum memory usage of local storage to the file transfer sequence based on a preset data transfer cycle.
[0035] In S106, after the integrity check of the target indicator data collected by the target indicator collection container passes, the target indicator data is stored in the specified storage location.
[0036] In implementation, integrity checks can be performed on the indicator data based on a preset integrity detection strategy. Specifically, as described in S104 above, the target indicator acquisition container can transmit the acquired indicator data to the indicator value register, and the indicator value register can transmit the target indicator data to the file transfer sequence based on a preset data transmission period.
[0037] The indicator file transfer sequence can be used to arrange the indicator data of the target indicator based on a preset transfer order (such as first-in-first-out order). After the indicator data collection adapter (i.e., an adapter that can use a container to mount a volume to collect data files) collects the data, the indicator data of the target indicator is removed from the file transfer sequence (that is, the indicator data of the target indicator is stored in a specified storage location). Then, the file transfer sequence after the move operation is renamed or the remaining indicator data is stored in the target indicator collection container based on a preset retention strategy.
[0038] The instruction platform can perform integrity checks on the indicator data of target indicators in the file transfer sequence. For example, it can check whether the indicator data of the target indicator is empty or whether the additional status of the indicator data of the target indicator (the additional status used to characterize whether the application container is in a normal or abnormal state) is abnormal.
[0039] Alternatively, when there are multiple target metric collection containers, the number of target metric data entries in the metric file sequence can be checked to determine whether the collected target metric data is complete. For example, if there are three target metric collection containers corresponding to the application container, and the number of target metric data entries in the file transfer sequence is less than three, then the target metric data integrity check will fail.
[0040] After the integrity check of the target indicator data collected by the target indicator collection container is passed, the command platform can store the target indicator data to the specified storage location, that is, the command platform can perform the reporting operation on the target indicator data.
[0041] In addition, the target indicator data can be stored in a preset network storage location. That is, the target indicator acquisition container can transfer the target indicator data to the preset network storage location via a file transfer sequence. The command platform can perform an integrity check on the target indicator data stored in the preset network storage location. After the integrity check is passed, the target indicator data is transferred from the preset network storage location to a specified storage location. In other words, the command platform completes the reporting operation of the target indicator data.
[0042] This invention provides a method for acquiring indicator data. By determining a target indicator acquisition container and a target indicator acquisition strategy corresponding to the target indicator to be collected, the target indicator acquisition strategy is sent to the target indicator acquisition container. This allows the target indicator acquisition container to collect indicator data from the application container corresponding to the target indicator based on the target indicator acquisition strategy. After the integrity check of the target indicator data collected by the target indicator acquisition container passes, the indicator data is stored in a designated storage location. This method allows indicator data to be collected from the application container through the target indicator acquisition container, and the indicator data is stored in the designated storage location after the integrity check passes. This avoids the problem of poor data collection continuity that occurs when acquiring indicator data by reading the host file system. Specifically, if the target indicator changes, the application container does not need to be restarted, ensuring the continuity of the collected target indicator data and improving the accuracy of data collection when acquiring indicator data from the application container.
[0043] Example 2
[0044] like Figure 2 As shown, this embodiment of the invention provides a method for acquiring indicator data. The execution subject of this method can be a terminal device or a server. The server can be an independent server or a server cluster composed of multiple servers. Specifically, the method may include the following steps:
[0045] In S202, the target indicator collection container and target indicator collection strategy corresponding to the target indicator to be collected are determined.
[0046] The specific processing procedure of S202 can be found in the relevant content of S102 in the above embodiment, and will not be repeated here.
[0047] In S204, upon receiving a destruction instruction for the target indicator collection container, the first indicator collection container corresponding to the target indicator is determined.
[0048] The first indicator collection container can be a different indicator collection container than the target indicator collection container.
[0049] In implementation, the command platform can receive upgrade commands for the target indicator, then obtain the first indicator collection container corresponding to the target indicator, and register the first indicator collection container under the indicator tag of the target indicator.
[0050] For example, indicator collection container 1, indicator collection container 2 and indicator collection container 3 can be used as target indicator collection containers for the target indicator. When the instruction platform receives a destruction instruction for target indicator collection container 1, it can obtain the first indicator collection container corresponding to the target indicator (such as indicator collection container 4). The instruction platform can register the first indicator collection container under the indicator tag of the target indicator.
[0051] In S206, when the target metric collection container is in a destroyed state and the first metric collection container is in a ready state, the target metric collection strategy is sent to the first metric collection container so that the first metric collection container can collect metric data from the application container corresponding to the target metric based on the target metric collection strategy.
[0052] In implementation, the command platform can detect the status of the target indicator collection container and the first indicator collection container. If the target indicator collection container is detected to be in a destroyed state and the first indicator collection container is in a ready state, the command platform can send the target indicator collection strategy to the first indicator collection container. The first indicator collection container can initialize the scheduling instruction and the indicator data of the target indicator, and then collect the indicator data based on the target indicator collection strategy.
[0053] Taking the application management cloud platform Kubernetes as an example, in Kubernetes, there can be multiple smallest working units, Pods. Each Pod can contain one or more application containers, and the application containers in the Pod can be scheduled as a whole to run on a Node.
[0054] During the rolling upgrade of application containers in a Kubernetes cluster, when the first metric collection container is in a ready state, the command platform needs to register and take over the first metric collection container (that is, register the first metric collection container under the metric tag of the target metric) before the collection scheduling command can be triggered. In addition, the first metric collection container also needs to collect metric data based on the target metric collection strategy to ensure that the collected target metric data meets expectations.
[0055] This invention provides a method for acquiring indicator data. By determining a target indicator acquisition container and a target indicator acquisition strategy corresponding to the target indicator to be collected, the target indicator acquisition strategy is sent to the target indicator acquisition container. This allows the target indicator acquisition container to collect indicator data from the application container corresponding to the target indicator based on the target indicator acquisition strategy. After the integrity check of the target indicator data collected by the target indicator acquisition container passes, the indicator data is stored in a designated storage location. This method allows indicator data to be collected from the application container through the target indicator acquisition container, and the indicator data is stored in the designated storage location after the integrity check passes. This avoids the problem of poor data collection continuity that occurs when acquiring indicator data by reading the host file system. Specifically, if the target indicator changes, the application container does not need to be restarted, ensuring the continuity of the collected target indicator data and improving the accuracy of data collection when acquiring indicator data from the application container.
[0056] Example 3
[0057] like Figure 3 As shown, this embodiment of the invention provides a method for acquiring indicator data. The execution subject of this method can be a terminal device or a server. The server can be an independent server or a server cluster composed of multiple servers. Specifically, the method may include the following steps:
[0058] In S302, the target indicator acquisition container and target indicator acquisition strategy corresponding to the target indicator to be acquired are determined.
[0059] The target indicator collection strategy can include one or more of the following: a latest indicator data collection strategy, an incremental aggregation collection strategy based on data usage rights, an incremental aggregation collection strategy based on the last valid value, and an incremental aggregation collection strategy based on a portion of the last valid value. Specifically, the latest indicator data collection strategy can be a strategy for acquiring the latest indicator data; the incremental aggregation collection strategy based on data usage rights can be a strategy where the target indicator collection container, having won the right to use historical indicator data through competition, can use historical indicator data for incremental aggregation; the incremental aggregation collection strategy based on the last valid value can be a strategy for acquiring the last valid indicator data of the target indicator for incremental aggregation; and the incremental aggregation collection strategy based on a portion of the last valid value of the target indicator can be a strategy for positive energy aggregation based on a portion of the last valid value of the target indicator.
[0060] In addition, the target indicator collection strategy also includes the collection method, which can be one or more of the following: data collection method based on shared volume, data collection method based on inter-process communication, and data collection method based on network communication.
[0061] One method for data acquisition based on shared volumes is that the application container and the target metric acquisition container share a volume. The application container can periodically transfer the target metric data to the shared volume file system, and the target metric acquisition container can obtain the target metric data based on the shared volume file system.
[0062] Data acquisition based on inter-process communication can be achieved by the target metric acquisition container sending a metric data acquisition command for the target metric to the process in the application container, and the process in the application container outputting the corresponding metric data to the target metric acquisition container based on the metric data acquisition command.
[0063] Data collection based on network communication can be achieved by accessing a preset port of the application container through a preset network protocol (such as HTTP) to obtain the target metric data.
[0064] In S304, the target metric collection strategy is sent to the target metric collection container so that the target metric collection container can collect metric data from the application container corresponding to the target metric based on the target metric collection strategy.
[0065] The specific processing steps of S302 to S304 can be found in the relevant content of S102 to S104 in the above embodiment, and will not be repeated here.
[0066] After S304, the integrity of the collected target indicator data can be checked. If the integrity check passes, S306 can be executed. If the integrity check fails, S308 can be executed.
[0067] In S306, after the integrity check of the target indicator data collected by the target indicator collection container passes, an integrity check pass message is sent to the target indicator collection container so that the target indicator collection container, upon receiving the integrity check pass message, transmits the collected indicator data to the specified storage location based on a preset file transfer order.
[0068] In practice, if the target indicator data passes the integrity check during the grace period, the target indicator acquisition container can transfer the target indicator data in the file transfer sequence to the designated storage location based on the preset file transfer order. In other words, the target indicator acquisition container can complete the reporting operation of the target indicator data.
[0069] In S308, if the integrity check of the target indicator data collected by the target indicator collection container fails, the target indicator data is processed based on the indicator data processing strategy corresponding to the target indicator so that the processed indicator data passes the integrity check.
[0070] In implementation and practical applications, the processing method of S308 can vary. The following is one optional implementation method, which can be found in steps one through three below:
[0071] Step 1: If the integrity check of the target indicator data collected by the target indicator collection container fails, check whether the target indicator collection container is in a ready state.
[0072] Step two: If the target indicator collection container is not in a ready state, process the indicator data of the target indicator based on the indicator data processing strategy corresponding to the target indicator.
[0073] Step 3: When the target indicator acquisition container is in a ready state, send a stop data reporting command to the target indicator acquisition container, and process the indicator data of the target indicator based on the indicator data processing strategy corresponding to the target indicator.
[0074] In implementation, for example, suppose the target indicator corresponds to three target indicator collection containers: indicator collection container 1, indicator collection container 2, and indicator collection container 3. The collected indicator data is only indicator data 1 and indicator data 2 collected by indicator collection container 1 and indicator collection container 2. Then, the instruction platform can obtain the working status of indicator collection container 3. If indicator collection container 3 is in a ready state, the instruction platform can send an instruction data reporting instruction to indicator collection container 3 and generate indicator data 3 based on historical indicator data. This indicator data is then used as the indicator data collected by indicator collection container 3, so that indicator data 1, indicator data 2, and the generated indicator data 3 pass the integrity check.
[0075] When the target metric acquisition container is working normally, the command platform can specify whether the target metric data should be reported by the target metric acquisition container or the command platform via the synchronization persistence command. Additionally, the command platform can use the purge command to clear metric data that the target metric acquisition container has not reported. When resuming reporting, the target metric acquisition container can choose not to report this cleared metric data.
[0076] In addition, the command platform can also generate target indicator data through the adjust command, and overwrite the indicator data in the file transfer sequence with the generated indicator data.
[0077] Taking the application management cloud platform Kubernetes as an example, in Kubernetes, there can be multiple smallest working units, Pods. Each Pod can contain one or more application containers, and the application containers in the Pod can be scheduled as a whole to run on a Node.
[0078] Kubernetes can contain Deployments for managing multiple replicas of Pods. Deployments can be used to ensure that Pods run in the desired state. DaemonSets are used to run daemons, which are used to ensure that each Node runs at most one replica of a Pod.
[0079] Kubernetes can also include Network Policy. Network Policy can select Pods using Labels and specify the communication methods for other Pods or external communication with Pods.
[0080] In Kubernetes, the RollingUpdate strategy can be used to gradually replace existing pods and create new ones.
[0081] The command platform can be used to configure and manage metric collection scheduling commands, determine the target metric collection strategy corresponding to the target metric (the target metric collection strategy includes one or more of the following: the latest metric data collection strategy always new, the incremental aggregation collection strategy based on data usage rights vote, the incremental aggregation collection strategy based on the last valid value always last, and the incremental aggregation collection strategy based on some last valid values optional last), send update requests to the Kubernetes Master to reconfigure or upgrade the target metric collection container in the Deployment or Pod, take over the metric data of the target metric reported by the target metric collection container, and reset or adjust the metric data of the target metric.
[0082] The target indicator acquisition container can consist of the following components: a time correction program, an indicator acquisition instruction adapter, a file transfer sequence, and an indicator data aggregation adapter.
[0083] The time calibration procedure can include setting container time differences and time zones. The calibration benchmark can be the time of a preset NTP (Network Time Protocol) server or the time of a Kubernetes node, to ensure consistent timekeeping.
[0084] The functions of the indicator acquisition instruction adapter may include: reading pre-configured acquisition scheduling instructions or receiving acquisition scheduling instructions sent by the instruction platform; acquiring indicator data of the target indicator according to the scheduled time and instruction commands, and writing the indicator data into the indicator file transfer sequence. The acquisition methods of the indicator acquisition container may include one or more of the following: acquiring indicators through shared volumes, acquiring indicators through inter-process communication, and acquiring indicators through network communication.
[0085] The metrics data aggregation adapter can use containers to mount volumes and aggregate data files.
[0086] The control commands that the command platform can send to the target indicator acquisition container may include:
[0087] 1. The `assume` command: The parameters of the `assume` command can include the target metric's name [metric_name], the target metric's labels [labels…|all], and the target metric's data. The target metric's data can be zero, last valid value, maximum historical value, custom value, or null value. Specifically, when the appended state is 1, the target metric's data can be the last valid value; when the appended state is 0, it can be any value from the above categories: zero, last valid value, maximum historical value, custom value, or null value.
[0088] The additional state of the metric data can be determined by the state of the application container. For example, if the application container is in a ready or normal state, the additional state up of the metric data can be 1. If the application container is not in a ready or normal state, the additional state up of the metric data can be 0.
[0089] 2. The `alive` command: This command is used to set additional status processing parameters for the indicator data in the indicator acquisition command adapter of the target indicator acquisition container. The `alive` command parameter can be `true` or `false`.
[0090] 3. purge command: Used to clear the metric data and metric file transfer sequence at the specified timestamp. The purge command parameters can include the metric name of the target metric [metrics_name], the metric label of the target metric [labels…|all], and the timestamp of the metric data [from_timestamp] and [to_timestamp].
[0091] 4. The adjust command: used to overwrite the target metric's metric data and file transfer sequence. The adjust command parameters can include the target metric's metric name [metrics_name], the target metric's metric label [labels…|all], and the timestamps of the metric data [from_timestamp] and [to_timestamp].
[0092] 5. The keep command: can be used to set the retention time strategy for historical real-time indicator data. The keep command parameters can include the interval.
[0093] 6. The persistence command: can be used to instruct the target metric collection container to stop reporting the target metric data, and the command platform will take over the reporting of the target metric data according to the target metric collection strategy. The persistence command parameter can be the target metric collection strategy [always new|vote|always last|optional last].
[0094] When a Pod starts, the application container and the target metric collection container can start in any order. The target metric collection container initializes the scheduling instructions and the target metric data, triggers the collection schedule, and checks whether the application container is in a ready or normal state. If the application container is in a ready or normal state, the instruction execution status of the collection instruction is returned as 0, the additional status of the metric data is up=1, the target metric data is collected, and the container waits for the next collection instruction to be triggered. If the application container is not in a ready or normal state, the instruction execution status of the collection instruction is returned as non-zero, the additional status of the metric data is up=0, and the container waits for the next collection instruction to be triggered.
[0095] Taking the collection of historical maximum values of a target metric (such as maximum memory usage) as an example, the target metric collection container can schedule and trigger a collection command. It checks if the `alive` command parameter is true. If the `alive` command parameter is true, the collection command is executed in the `up=0` state. If the collected target metric data is not null, the metric data stored in the metric value register is updated based on the collected target metric data (even if the metric data stored in the metric value register is the historical maximum value of the target metric). After updating the target metric data stored in the metric value register, the updated metric data can be written to the file transfer sequence. Alternatively, if the `alive` command parameter is false, the target metric data can be processed based on the metric data processing strategy contained in the `assume` command, and the processed metric data is written to the file transfer sequence.
[0096] When the assume command is set and the target metric collection container is working properly, the target metric collection container can output metric data and perform aggregation operations.
[0097] In addition, when the target indicator collection container is working normally, the command platform can also specify the command platform or the target indicator collection container to report the indicator data of the target indicator by means of the synchronous persistence command.
[0098] The command platform can schedule and trigger the first integrity check on the target indicator data. If the first integrity check passes, it can check whether the persistence command has been set.
[0099] If the `persistence` directive is not set, the target metric acquisition container can report the target metric data. A second integrity check can be performed on the target metric data within the grace period. If the target metric data passes the integrity check and the target metric acquisition container has reported the target metric data (i.e., stored the target metric data in the specified storage location) within the grace period, the scheduling can end. If the target metric data fails the integrity check and the target metric acquisition container has not reported the target metric data within the grace period, the instruction platform can process the target metric data using the data processing strategy set by the `assume` directive and take over the reporting operation of the target metric data.
[0100] If the persistence command has been set, the command platform can report the target indicator data. Then, the correspondence between the target indicator's indicator label and the target indicator collection container can be obtained, and the status of the target indicator collection container can be checked.
[0101] If the target indicator acquisition container is not in a ready state, a second integrity check can be performed on the target indicator data within the grace period. If the target indicator data passes the integrity check and the target indicator acquisition container has reported the target indicator data within the grace period, the scheduling can end. If the target indicator data fails the integrity check and the target indicator acquisition container has not reported the target indicator data within the grace period, the instruction platform can detect and process the target indicator data based on the indicator data processing strategy corresponding to the target indicator, and take over the reporting operation of the target indicator data.
[0102] When the target indicator acquisition container is in a ready state, a stop data reporting command can be sent to the target indicator acquisition container (that is, a persistence command can be sent to the target indicator acquisition container), and the indicator data of the target indicator can be processed based on the indicator data processing strategy corresponding to the target indicator.
[0103] In this way, the target metric collection container can collect metric data based on the target metric collection strategy through one-way interaction with the application container and two-way interaction with the command platform. Even when the application container restarts, the target metric data does not need to be reset, ensuring data continuity. Furthermore, it can utilize the metric data provided by the application container itself without modifying the application container, avoiding the risk of target metric data becoming zero or missing values due to pod restarts. After the application container shuts down, the command platform can take over the metric data reporting operation, avoiding monitoring data anomalies caused by missing metric data.
[0104] In addition, application containers do not need to expose additional ports or configure container network policies. They can be configured with metric collection commands through the command platform. Within the target metric collection container, the metric data of the target metric can be processed through commands issued by the command platform, providing additional custom metrics. Furthermore, the metric time can be corrected at the metric data source to ensure the correctness and consistency of metric time.
[0105] This invention provides a method for acquiring indicator data. By determining a target indicator acquisition container and a target indicator acquisition strategy corresponding to the target indicator to be collected, the target indicator acquisition strategy is sent to the target indicator acquisition container. This allows the target indicator acquisition container to collect indicator data from the application container corresponding to the target indicator based on the target indicator acquisition strategy. After the integrity check of the target indicator data collected by the target indicator acquisition container passes, the indicator data is stored in a designated storage location. This method allows indicator data to be collected from the application container through the target indicator acquisition container, and the indicator data is stored in the designated storage location after the integrity check passes. This avoids the problem of poor data collection continuity that occurs when acquiring indicator data by reading the host file system. Specifically, if the target indicator changes, the application container does not need to be restarted, ensuring the continuity of the collected target indicator data and improving the accuracy of data collection when acquiring indicator data from the application container.
[0106] Example 4
[0107] The above describes the indicator data acquisition method provided by the embodiments of the present invention. Based on the same idea, the embodiments of the present invention also provide an indicator data acquisition device, such as... Figure 4 As shown.
[0108] The indicator data acquisition device includes: a determination module 401, a transmission module 402, and a storage module 403, wherein:
[0109] The determination module 401 is used to determine the target indicator collection container and the target indicator collection strategy corresponding to the target indicator to be collected.
[0110] Sending module 402 is used to send the target indicator collection strategy to the target indicator collection container, so that the target indicator collection container can collect indicator data from the application container corresponding to the target indicator based on the target indicator collection strategy.
[0111] The storage module 403 is used to store the target indicator data to a designated storage location after the integrity check of the target indicator data collected by the target indicator collection container is passed.
[0112] In this embodiment of the invention, the sending module 402 is used for:
[0113] Upon receiving a destruction instruction for the target indicator collection container, the first indicator collection container corresponding to the target indicator is determined.
[0114] When the target metric collection container is in a destroyed state and the first metric collection container is in a ready state, the target metric collection strategy is sent to the first metric collection container so that the first metric collection container can collect metric data from the application container corresponding to the target metric based on the target metric collection strategy.
[0115] In this embodiment of the invention, the target indicator collection strategy includes one or more of the following: the latest indicator data collection strategy, the incremental aggregation collection strategy based on data usage rights, the incremental aggregation collection strategy based on the last valid value, and the incremental aggregation collection strategy based on a portion of the last valid values.
[0116] In this embodiment of the invention, the target indicator collection strategy further includes a collection method, which is one or more of the following: a data collection method based on shared volumes, a data collection method based on inter-process communication, and a data collection method based on network communication.
[0117] In this embodiment of the invention, the device further includes:
[0118] The processing module is used to process the indicator data of the target indicator based on the indicator data processing strategy corresponding to the target indicator when the integrity check of the indicator data of the target indicator collected by the target indicator collection container fails, so that the processed indicator data passes the integrity check.
[0119] In this embodiment of the invention, the processing module is used for:
[0120] If the integrity check of the target indicator data collected by the target indicator collection container fails, check whether the target indicator collection container is in a ready state.
[0121] If the target indicator collection container is not in a ready state, the indicator data of the target indicator is processed based on the indicator data processing strategy corresponding to the target indicator.
[0122] When the target indicator acquisition container is in a ready state, a stop data reporting command is sent to the target indicator acquisition container, and the indicator data of the target indicator is processed based on the indicator data processing strategy corresponding to the target indicator.
[0123] In this embodiment of the invention, the storage module 403 is used for:
[0124] After the integrity check of the target indicator data collected by the target indicator collection container passes, an integrity check pass message is sent to the target indicator collection container, so that the target indicator collection container, upon receiving the integrity check pass message, transmits the collected indicator data to the designated storage location based on a preset file transfer order.
[0125] This invention provides a metric data acquisition device. By determining a target metric acquisition container and a target metric acquisition strategy corresponding to the target metric to be collected, the device sends the target metric acquisition strategy to the target metric acquisition container. The target metric acquisition container then collects metric data from the application container corresponding to the target metric based on the target metric acquisition strategy. After the integrity check of the target metric data collected by the target metric acquisition container passes, the metric data is stored in a designated storage location. This allows for the collection of metric data from the application container via the target metric acquisition container, and after the integrity check passes, the metric data is stored in the designated storage location. This avoids the problem of poor data collection continuity that occurs when acquiring metric data by reading the host file system. Specifically, if the target metric changes, the application container does not need to be restarted, ensuring the continuity of the collected target metric data and improving the accuracy of data collection when collecting metric data from the application container.
[0126] Example 5
[0127] Figure 5 This is a schematic diagram of the hardware structure of a device according to various embodiments of the present invention.
[0128] The device 500 includes, but is not limited to, components such as: a radio frequency unit 501, a network module 502, an audio output unit 503, an input unit 504, a sensor 505, a display unit 506, a user input unit 507, an interface unit 508, a memory 509, a processor 510, and a power supply 511. Those skilled in the art will understand that... Figure 5The device structure shown does not constitute a limitation on the device. The device may include more or fewer components than shown, or combine certain components, or have different component arrangements. In embodiments of the present invention, the device includes, but is not limited to, mobile phones, tablet computers, laptops, PDAs, in-vehicle terminals, wearable devices, and pedometers.
[0129] The processor 510 is configured to: determine a target indicator collection container and a target indicator collection strategy corresponding to the target indicator to be collected; send the target indicator collection strategy to the target indicator collection container, so that the target indicator collection container collects indicator data from the application container corresponding to the target indicator based on the target indicator collection strategy; and after the integrity check of the indicator data of the target indicator collected by the target indicator collection container passes, store the indicator data of the target indicator in a specified storage location.
[0130] Furthermore, the processor 510 is also configured to: upon receiving a destruction instruction for the target indicator collection container, determine a first indicator collection container corresponding to the target indicator; and, when the target indicator collection container is in a destroyed state and the first indicator collection container is in a ready state, send the target indicator collection strategy to the first indicator collection container so that the first indicator collection container collects indicator data from the application container corresponding to the target indicator based on the target indicator collection strategy.
[0131] In addition, the target indicator collection strategy includes one or more of the following: the latest indicator data collection strategy, the incremental aggregation collection strategy based on data usage rights, the incremental aggregation collection strategy based on the last valid value, and the incremental aggregation collection strategy based on a portion of the last valid values.
[0132] In addition, the target indicator collection strategy also includes collection methods, which are one or more of the following: data collection based on shared volumes, data collection based on inter-process communication, and data collection based on network communication.
[0133] Furthermore, the processor 510 is also configured to: if the integrity check of the indicator data of the target indicator collected by the target indicator collection container fails, process the indicator data of the target indicator based on the indicator data processing strategy corresponding to the target indicator, so that the processed indicator data passes the integrity check.
[0134] Furthermore, the processor 510 is also configured to: detect whether the target indicator acquisition container is in a ready state if the integrity check of the indicator data of the target indicator collected by the target indicator acquisition container fails; if the target indicator acquisition container is not in a ready state, process the indicator data of the target indicator based on the indicator data processing strategy corresponding to the target indicator; and if the target indicator acquisition container is in a ready state, send a stop data reporting instruction to the target indicator acquisition container and process the indicator data of the target indicator based on the indicator data processing strategy corresponding to the target indicator.
[0135] In addition, the processor 510 is further configured to: after the integrity check of the indicator data of the target indicator collected by the target indicator collection container passes, send an integrity check pass message to the target indicator collection container, so that the target indicator collection container, upon receiving the integrity check pass message, transmits the collected indicator data to a specified storage location based on a preset file transfer order.
[0136] This invention provides a device that determines a target indicator collection container and a target indicator collection strategy corresponding to a target indicator to be collected. The target indicator collection strategy is sent to the target indicator collection container, enabling the container to collect indicator data from the application container corresponding to the target indicator based on the strategy. After the integrity check of the target indicator data collected by the target indicator collection container passes, the indicator data is stored in a designated storage location. This allows for the collection of indicator data from the application container via the target indicator collection container, and after the integrity check passes, the indicator data is stored in the designated storage location. This avoids the problem of poor data collection continuity that occurs when obtaining indicator data by reading the host file system. Specifically, if the target indicator changes, the application container does not need to be restarted, ensuring the continuity of the collected target indicator data and improving the accuracy of data collection when collecting indicator data from the application container.
[0137] It should be understood that, in this embodiment of the invention, the radio frequency unit 501 can be used for receiving and transmitting signals during information transmission or calls. Specifically, it receives downlink data from the base station and processes it with the processor 510; additionally, it transmits uplink data to the base station. Typically, the radio frequency unit 501 includes, but is not limited to, an antenna, at least one amplifier, a transceiver, a coupler, a low-noise amplifier, a duplexer, etc. Furthermore, the radio frequency unit 501 can also communicate with networks and other devices through a wireless communication system.
[0138] The device provides users with wireless broadband internet access through network module 502, enabling them to send and receive emails, browse web pages, and access streaming media.
[0139] The audio output unit 503 can convert audio data received by the radio frequency unit 501 or the network module 502 or stored in the memory 509 into audio signals and output them as sound. Furthermore, the audio output unit 503 can also provide audio output related to specific functions performed by the device 500 (e.g., call signal reception sound, message reception sound, etc.). The audio output unit 503 includes a speaker, a buzzer, and a receiver, etc.
[0140] Input unit 504 is used to receive audio or video signals. Input unit 504 may include a graphics processing unit (GPU) 5041 and a microphone 5042. The GPU 5041 processes image data of still images or videos acquired by an image capture device (such as a camera) in video capture mode or image capture mode. The processed image frames can be displayed on display unit 506. The image frames processed by GPU 5041 can be stored in memory 509 (or other storage medium) or transmitted via radio frequency unit 501 or network module 502. Microphone 5042 can receive sound and process such sound into audio data. The processed audio data can be converted into a format that can be transmitted to a mobile communication base station via radio frequency unit 501 in telephone call mode.
[0141] Device 500 also includes at least one sensor 505, such as a light sensor, a motion sensor, and other sensors. Specifically, the light sensor includes an ambient light sensor and a proximity sensor. The ambient light sensor can adjust the brightness of the display panel 5061 according to the ambient light level, and the proximity sensor can turn off the display panel 5061 and / or backlight when the device 500 is moved to the ear. As a type of motion sensor, an accelerometer sensor can detect the magnitude of acceleration in various directions (generally three axes). When stationary, it can detect the magnitude and direction of gravity and can be used to identify device posture (such as landscape / portrait switching, related games, magnetometer posture calibration), vibration recognition related functions (such as pedometer, tapping), etc. Sensor 505 may also include fingerprint sensors, pressure sensors, iris sensors, molecular sensors, gyroscopes, barometers, hygrometers, thermometers, infrared sensors, etc., which will not be described in detail here.
[0142] The display unit 506 is used to display information input by the user or information provided to the user. The display unit 506 may include a display panel 5061, which may be configured in the form of a liquid crystal display (LCD), an organic light-emitting diode (OLED), or the like.
[0143] User input unit 507 can be used to receive input numerical or character information, and generate key signal inputs related to user settings and function control of the device. Specifically, user input unit 507 includes a touch panel 5071 and other input devices 5072. Touch panel 5071, also known as a touch screen, can collect touch operations performed by the user on or near it (such as operations performed by the user using a finger, stylus, or any suitable object or accessory on or near touch panel 5071). Touch panel 5071 may include two parts: a touch detection device and a touch controller. The touch detection device detects the user's touch position and the signal generated by the touch operation, and transmits the signal to the touch controller; the touch controller receives touch information from the touch detection device, converts it into touch point coordinates, and sends it to the processor 510, which receives and executes commands from the processor 510. In addition, touch panel 5071 can be implemented using various types such as resistive, capacitive, infrared, and surface acoustic wave. In addition to touch panel 5071, user input unit 507 may also include other input devices 5072. Specifically, other input devices 5072 may include, but are not limited to, physical keyboards, function keys (such as volume control buttons, power buttons, etc.), trackballs, mice, joysticks, etc., which will not be described in detail here.
[0144] Furthermore, the touch panel 5071 can cover the display panel 5061. When the touch panel 5071 detects a touch operation on or near it, it transmits the information to the processor 510 to determine the type of touch event. Subsequently, the processor 510 provides corresponding visual output on the display panel 5061 based on the type of touch event. Although in Figure 5 In this embodiment, the touch panel 5071 and the display panel 5061 are two independent components to realize the input and output functions of the device. However, in some embodiments, the touch panel 5071 and the display panel 5061 can be integrated to realize the input and output functions of the device. The specific implementation is not limited here.
[0145] Interface unit 508 serves as an interface for connecting external devices to device 500. For example, external devices may include a wired or wireless headset port, an external power supply (or battery charger) port, a wired or wireless data port, a memory card port, a port for connecting a device with an identification module, an audio input / output (I / O) port, a video I / O port, a headphone port, and so on. Interface unit 508 can be used to receive input from external devices (e.g., data, power, etc.) and transmit the received input to one or more elements within device 500, or it can be used to transfer data between device 500 and external devices.
[0146] The memory 509 can be used to store software programs and various data. The memory 509 may primarily include a program storage area and a data storage area. The program storage area may store the operating system, applications required for at least one function (such as sound playback, image playback, etc.), etc.; the data storage area may store data created based on the use of the mobile phone (such as audio data, phonebook, etc.). Furthermore, the memory 509 may include high-speed random access memory, and may also include non-volatile memory, such as at least one disk storage device, flash memory device, or other volatile solid-state storage device.
[0147] The processor 510 is the control center of the device, connecting various parts of the device through various interfaces and lines. It performs various functions and processes data by running or executing software programs and / or modules stored in the memory 509, and by calling data stored in the memory 509, thereby providing overall monitoring of the device. The processor 510 may include one or more processing units; preferably, the processor 510 may integrate an application processor and a modem processor, wherein the application processor mainly handles the operating system, user interface, and applications, and the modem processor mainly handles wireless communication. It is understood that the modem processor may not be integrated into the processor 510.
[0148] The device 500 may also include a power supply 511 (such as a battery) to power various components. Preferably, the power supply 511 can be logically connected to the processor 510 through a power management system, thereby enabling functions such as charging, discharging, and power consumption management through the power management system.
[0149] Preferably, the present invention also provides a device including a processor 510, a memory 509, and a computer program stored in the memory 509 and executable on the processor 510. When the computer program is executed by the processor 510, it implements the various processes of the above-described indicator data acquisition method embodiments and achieves the same technical effect. To avoid repetition, it will not be described again here.
[0150] Example 6
[0151] This invention also provides a computer-readable storage medium storing a computer program. When executed by a processor, this computer program implements the various processes of the above-described method for acquiring indicator data, achieving the same technical effects. To avoid repetition, it will not be described again here. The computer-readable storage medium may be a read-only memory (ROM), a random access memory (RAM), a magnetic disk, or an optical disk.
[0152] This invention provides a computer-readable storage medium. By determining a target indicator collection container and a target indicator collection strategy corresponding to the target indicator to be collected, the target indicator collection strategy is sent to the target indicator collection container. The target indicator collection container then collects indicator data from the application container corresponding to the target indicator based on the target indicator collection strategy. After the integrity check of the target indicator data collected by the target indicator collection container passes, the indicator data is stored in a designated storage location. This allows for the collection of indicator data from the application container via the target indicator collection container, and after the integrity check passes, the indicator data is stored in the designated storage location. This avoids the problem of poor data collection continuity that occurs when obtaining indicator data by reading the host file system. Specifically, if the target indicator changes, the application container does not need to be restarted, ensuring the continuity of the collected target indicator data and improving the accuracy of data collection when collecting indicator data from the application container.
[0153] Those skilled in the art will understand that embodiments of the present invention can be provided as methods, systems, or computer program products. Therefore, the present invention can take the form of a completely hardware embodiment, a completely software embodiment, or an embodiment combining software and hardware aspects. Furthermore, the present invention can take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.
[0154] This invention is described with reference to flowchart illustrations and / or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of the invention. It will be understood that each block of the flowchart illustrations and / or block diagrams, and combinations of blocks in the flowchart illustrations and / or block diagrams, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, special-purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, generate instructions for implementing the flowchart illustrations and / or block diagrams. Figure 1 One or more processes and / or boxes Figure 1 A device that provides the functions specified in one or more boxes.
[0155] These computer program instructions may also be stored in a computer-readable storage medium that can direct a computer or other programmable data processing device to function in a particular manner, such that the instructions stored in the computer-readable storage medium produce an article of manufacture including instruction means, which are implemented in a process Figure 1 One or more processes and / or boxes Figure 1 The function specified in one or more boxes.
[0156] These computer program instructions may also be loaded onto a computer or other programmable data processing equipment to cause a series of operational steps to be performed on the computer or other programmable equipment to produce a computer-implemented process, thereby providing instructions that execute on the computer or other programmable equipment for implementing the process. Figure 1 One or more processes and / or boxes Figure 1 The steps of the function specified in one or more boxes.
[0157] In a typical configuration, a computing device includes one or more processors (CPU), input / output interfaces, network interfaces, and memory.
[0158] Memory may include non-persistent storage in computer-readable media, such as random access memory (RAM) and / or non-volatile memory, such as read-only memory (ROM) or flash RAM. Memory is an example of computer-readable media.
[0159] Computer-readable media includes both permanent and non-permanent, removable and non-removable media that can store information using any method or technology. Information can be computer-readable instructions, data structures, modules of programs, or other data. Examples of computer storage media include, but are not limited to, phase-change memory (PRAM), static random access memory (SRAM), dynamic random access memory (DRAM), other types of random access memory (RAM), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), flash memory or other memory technologies, CD-ROM, digital versatile optical disc (DVD) or other optical storage, magnetic tape, magnetic disk storage or other magnetic storage devices, or any other non-transferable medium that can be used to store information accessible by a computing device. As defined herein, computer-readable media does not include transient computer-readable media, such as modulated data signals and carrier waves.
[0160] It should also be noted that the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such a process, method, article, or apparatus. Without further limitation, an element defined by the phrase "comprising one..." does not exclude the presence of other identical elements in the process, method, article, or apparatus that includes said element.
[0161] Those skilled in the art will understand that embodiments of the present invention can be provided as methods, systems, or computer program products. Therefore, the present invention can take the form of a completely hardware embodiment, a completely software embodiment, or an embodiment combining software and hardware aspects. Furthermore, the present invention can take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.
[0162] The above description is merely an embodiment of the present invention and is not intended to limit the invention. Various modifications and variations can be made to the present invention by those skilled in the art. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principle of the present invention should be included within the scope of the claims of the present invention.
Claims
1. A method for acquiring indicator data, characterized in that, The method is applied to an instruction platform, and the method includes: Determine the target indicator collection container and target indicator collection strategy corresponding to the target indicator to be collected; The target metric collection strategy is sent to the target metric collection container, so that the target metric collection container collects metric data from the application container corresponding to the target metric based on the target metric collection strategy, including: Upon receiving a destruction instruction for the target metric collection container, a first metric collection container corresponding to the target metric is determined; if the target metric collection container is in a destroyed state and the first metric collection container is in a ready state, the target metric collection strategy is sent to the first metric collection container, so that the first metric collection container collects metric data from the application container corresponding to the target metric based on the target metric collection strategy. After the integrity check of the target indicator data collected by the target indicator collection container is passed, the target indicator data is stored in the designated storage location. If the integrity check of the target indicator data collected by the target indicator collection container fails, the target indicator data is processed based on the indicator data processing strategy corresponding to the target indicator so that the processed indicator data passes the integrity check.
2. The method according to claim 1, characterized in that, The target indicator collection strategy includes one or more of the following: the latest indicator data collection strategy, the incremental aggregation collection strategy based on data usage rights, the incremental aggregation collection strategy based on the last valid value, and the incremental aggregation collection strategy based on a portion of the last valid values.
3. The method according to claim 2, characterized in that, The target indicator collection strategy also includes collection methods, which are one or more of the following: data collection based on shared volumes, data collection based on inter-process communication, and data collection based on network communication.
4. The method according to claim 1, characterized in that, If the integrity check of the target indicator data collected by the target indicator collection container fails, the indicator data of the target indicator is processed based on the indicator data processing strategy corresponding to the target indicator, including: If the integrity check of the target indicator data collected by the target indicator collection container fails, check whether the target indicator collection container is in a ready state. If the target indicator collection container is not in a ready state, the indicator data of the target indicator is processed based on the indicator data processing strategy corresponding to the target indicator. When the target indicator acquisition container is in a ready state, a stop data reporting command is sent to the target indicator acquisition container, and the indicator data of the target indicator is processed based on the indicator data processing strategy corresponding to the target indicator.
5. The method according to claim 1, characterized in that, After the integrity check of the target indicator data collected by the target indicator collection container passes, the target indicator data is stored in a designated storage location, including: After the integrity check of the target indicator data collected by the target indicator collection container passes, an integrity check pass message is sent to the target indicator collection container, so that the target indicator collection container, upon receiving the integrity check pass message, transmits the collected indicator data to the designated storage location based on a preset file transfer order.
6. A device for acquiring indicator data, characterized in that, The device includes: The determination module is used to determine the target indicator collection container and target indicator collection strategy corresponding to the target indicator to be collected. The sending module is configured to send the target metric collection strategy to the target metric collection container, so that the target metric collection container can collect metric data from the application container corresponding to the target metric based on the target metric collection strategy, including: Upon receiving a destruction instruction for the target metric collection container, a first metric collection container corresponding to the target metric is determined; if the target metric collection container is in a destroyed state and the first metric collection container is in a ready state, the target metric collection strategy is sent to the first metric collection container, so that the first metric collection container collects metric data from the application container corresponding to the target metric based on the target metric collection strategy. The storage module is used to store the target indicator data to a specified storage location after the integrity check of the target indicator data collected by the target indicator collection container is passed. The processing module is used to process the indicator data of the target indicator based on the indicator data processing strategy corresponding to the target indicator when the integrity check of the indicator data of the target indicator collected by the target indicator collection container fails, so that the processed indicator data passes the integrity check.
7. A device, characterized in that, It includes a processor, a memory, and a computer program stored in the memory and executable on the processor, wherein the computer program, when executed by the processor, implements the steps of the indicator data acquisition method as described in any one of claims 1 to 5.
8. A computer-readable storage medium, characterized in that, A computer program is stored on the computer-readable storage medium, which, when executed by a processor, implements the steps of the indicator data acquisition method as described in any one of claims 1 to 5.
Citation Information
Patent Citations
Performance monitoring method and device for PaaS cloud platform
CN111611129A