A path planning method and device
By extracting information and performing dependency analysis on the configuration data of cloud services, a directed acyclic graph is constructed to determine parallel target paths. This solves the inefficiency problem of the serial pipeline approach and enables rapid anomaly identification and improved compilation and deployment efficiency.
Patent Information
- Application Number
- CN202111615291.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2021-12-27
- Publication Date
- 2025-12-19
- Estimated Expiration
- 2041-12-27
AI Technical Summary
In existing technologies, the compilation and deployment of cloud services uses a serial pipeline approach, which leads to inefficiency and makes it difficult to quickly identify the steps that cause failure.
By extracting information and performing dependency analysis on the configuration data of the original paths, multiple path nodes and dependencies are identified, a directed acyclic graph is constructed, multiple target paths are obtained, and path nodes are detected in parallel to quickly identify anomalies.
It enables path processing to be completed in a shorter time, improving the efficiency of compilation and deployment, quickly identifying configuration data anomalies, saving waiting time, and improving R&D efficiency.
Smart Images

Figure CN114489665B_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The present application relates to the technical field of data processing, and particularly relates to a path planning method and device. BACKGROUND
[0002] The compilation and deployment work of some projects, such as the compilation and deployment work of cloud services, is performed in a serial pipeline manner. For example, a series of serial pipeline steps such as corresponding compilation, source code quality inspection, source code security vulnerability inspection, deployment package vulnerability inspection, deployment environment detection, target environment deployment, and the like are sequentially completed according to an execution order.
[0003] However, in actual use, it is necessary to find out as quickly as possible the link that causes the entire compilation and deployment work to fail, so as to improve efficiency. However, if the last link has a problem, the above steps need to be executed in sequence, and it is necessary to wait until the previous operations are completed, which has the problem of low efficiency. SUMMARY
[0004] Embodiments of the present application are provided to solve the above problems in the background art, and provide a path planning method and device.
[0005] In one aspect, the present application provides a path planning method, which comprises: obtaining configuration data corresponding to an original path; performing information extraction on the configuration data to determine a plurality of path nodes and a dependency relationship corresponding to the configuration data; performing dependency analysis according to the dependency relationship and the path nodes to obtain a directed relationship between the plurality of path nodes; and connecting the path nodes according to the directed relationship to obtain a plurality of target paths.
[0006] In one implementation, the method further comprises: performing parallel detection according to the plurality of target paths; and determining that there is a first data abnormality in the configuration data corresponding to the original path when any of the path nodes has an abnormality.
[0007] In one implementation, the information extraction on the configuration data to determine the plurality of path nodes and the dependency relationship corresponding to the configuration data comprises: determining a data syntax type corresponding to the configuration data; and performing abstract syntax analysis on the plurality of path nodes according to the data syntax type to determine the plurality of path nodes and the dependency relationship corresponding to the configuration data.
[0008] In an implementation, the abstract syntax analysis of the plurality of path nodes according to the data syntax type to determine the plurality of path nodes and the dependency relationship corresponding to the configuration data comprises: determining a preset keyword according to the syntax type; performing information reduction on the configuration data according to the preset keyword to obtain key data containing the preset keyword; and performing abstract syntax analysis on the key data to determine the plurality of path nodes and the dependency relationship corresponding to the configuration data.
[0009] In an implementation, the abstract syntax analysis of the key data to determine the plurality of path nodes and the dependency relationship corresponding to the configuration data comprises: performing information extraction on the key data to determine the plurality of path nodes; and performing data analysis on the key data to determine the dependency relationship corresponding to the plurality of path nodes.
[0010] In an implementation, the dependency analysis according to the dependency relationship and the path nodes to obtain the directed relationship between the plurality of path nodes comprises: integrating the path nodes and the dependency relationship according to a stack storage structure to determine a plurality of intra-stack paths; and determining a directed acyclic graph according to the intra-stack paths and the path nodes, the directed acyclic graph being used to represent the directed relationship between the plurality of path nodes.
[0011] In an implementation, the method further comprises: detecting the configuration data according to the original path to determine a weight value corresponding to each directed relationship; and weighting and integrating the directed relationship of each target path according to the weight value to obtain a criticality score corresponding to each target path; and determining the target path with the highest criticality score as a critical path.
[0012] In an implementation, the method further comprises: detecting the critical path; and determining that the configuration data corresponding to the original path has a second data abnormality when the critical path has a data abnormality.
[0013] In an implementation, the method further comprises: detecting other target paths except the critical path; and determining that the configuration data corresponding to the original path has a third data abnormality when the other target paths except the critical path are detected to have a data abnormality.
[0014] In another aspect, an embodiment of the present application provides a path planning device, the device comprising: an obtaining module configured to obtain configuration data corresponding to an original path; an extracting module configured to perform information extraction on the configuration data to determine a plurality of path nodes and a dependency relationship corresponding to the configuration data; an analyzing module configured to perform dependency analysis on the dependency relationship and the path nodes to obtain a directed relationship between the plurality of path nodes; and a connecting module configured to connect the path nodes according to the directed relationship to obtain a plurality of target paths.
[0015] In an implementation, the device further comprises: a detecting module configured to perform parallel detection according to the plurality of target paths; and a determining module configured to determine that the configuration data corresponding to the original path has a first data abnormality when any of the path nodes has an abnormality.
[0016] In an implementation, the extracting module comprises: a determining sub-module configured to determine a data syntax type corresponding to the configuration data; and an analyzing sub-module configured to perform abstract syntax analysis on the plurality of path nodes according to the data syntax type to determine the plurality of path nodes and the dependency relationship corresponding to the configuration data.
[0017] In an implementation, the analyzing sub-module comprises: determining a preset keyword corresponding to the syntax type; performing information reduction on the configuration data according to the preset keyword to obtain key data containing the preset keyword; and performing abstract syntax analysis on the key data to determine the plurality of path nodes and the dependency relationship corresponding to the configuration data.
[0018] In an implementation, the analyzing sub-module comprises: performing information extraction on the key data to determine the plurality of path nodes; and performing data analysis on the key data to determine the dependency relationship corresponding to the plurality of path nodes.
[0019] In an implementation, the analyzing module comprises: integrating the path nodes and the dependency relationship according to a stack storage structure to determine a plurality of intra-stack paths; and determining a directed acyclic graph according to the intra-stack paths and the path nodes, the directed acyclic graph being used to represent the directed relationship between the plurality of path nodes.
[0020] In an implementation, the detecting module is further configured to detect the configuration data according to the original path to determine a weight value corresponding to each directed relationship; the device further comprises: an integrating module configured to perform weighted integration on the directed relationship of each target path according to the weight value to obtain a criticality score corresponding to each target path; and the determining module is further configured to determine the target path with the highest criticality score as a critical path.
[0021] In an implementation, the detecting module is further configured to detect the critical path; and the determining module is further configured to determine that the configuration data corresponding to the original path has a second data abnormality when the critical path has a data abnormality.
[0022] In an implementation, the apparatus further includes: the detecting module is further configured to detect other target paths except the critical path; and the determining module is further configured to determine that the configuration data corresponding to the original path has a third data abnormality when the other target paths except the critical path are detected to have data abnormality.
[0023] The path planning method and apparatus provided by the embodiments of the present application can determine a plurality of target paths corresponding to an original path by performing information extraction and dependency analysis on configuration data of the original path. By applying the method, the parallel feasibility between path nodes in the original path can be determined, and thus a plurality of target paths corresponding to the original path and being parallel can be obtained. BRIEF DESCRIPTION OF DRAWINGS
[0024] The above and other objects, features and advantages of the present application will become more apparent from the following detailed description when taken in conjunction with the accompanying drawings in which a number of embodiments of the present application are shown by way of example, in which:
[0025] In the drawings, identical or corresponding elements are denoted by the same or corresponding reference numerals.
[0026] Figure 1 An implementation flowchart of a path planning method according to an embodiment of the present application;
[0027] Figure 2 An implementation flowchart of a path planning method according to another embodiment of the present application;
[0028] Figure 3 An implementation flowchart of a path planning method according to yet another embodiment of the present application;
[0029] Figure 4 A stack storage structure diagram of a path planning method according to yet another embodiment of the present application;
[0030] Figure 5 A directed acyclic graph diagram of a path planning method according to yet another embodiment of the present application;
[0031] Figure 6 An implementation module diagram of a path planning apparatus according to an embodiment of the present application. DETAILED DESCRIPTION
[0032] In order to make the purposes, characteristics and advantages of the present application more obvious and easy to understand, the technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the drawings in the embodiments of the present application. Obviously, the described embodiments are only some of the embodiments of the present application, but not all the embodiments. Based on the embodiments in the present application, all other embodiments obtained by those skilled in the art without creative work fall within the scope of the present application.
[0033] Figure 1 The implementation flowchart of the path planning method in the embodiments of the present application is shown.
[0034] Referring to Figure 1 The path planning method provided by the embodiments of the present application comprises the following steps: obtaining configuration data corresponding to an original path in operation 101; performing information extraction on the configuration data to determine a plurality of path nodes and a dependency relationship corresponding to the configuration data in operation 102; performing dependency analysis according to the dependency relationship and the path nodes to obtain a directed relationship between the plurality of path nodes in operation 103; and connecting the path nodes according to the directed relationship to obtain a plurality of target paths in operation 104.
[0035] The path planning method provided by the embodiments of the present application can determine a plurality of target paths corresponding to an original path by performing information extraction and dependency analysis on the configuration data of the original path. By applying the method, the parallel feasibility between each path node in the original path can be determined by analysis, thereby obtaining a plurality of target paths corresponding to the original path and being parallel. Further, based on the characteristic that the target paths are parallel, the method can realize subsequent processing of the original path through the target paths, thereby being able to complete the processing of the original path in a shorter time.
[0036] In operation 101 of the method, the original path can refer to a running process corresponding to a specific method running in a serial manner. For example, when the method is an operation method, the operation method has four steps ①, ②, ③ and ④ in the running process, and the four steps ①, ②, ③ and ④ are executed in sequence in strict accordance with the serial running manner, then the four steps ①, ②, ③ and ④ can be determined as the original path.
[0037] It is further necessary to supplement that branch paths can also be formed on the original path. For example, in the running process of a certain specific operation method, the operation method has five steps ①, ②, ③, ④ and ⑤ in the running process, wherein the three steps ①, ② and ③ are strictly run in accordance with the serial running manner, and ④ or ⑤ can be run after ③ according to needs. In this case, ①, ② and ③ can be determined as the original path, or ①, ②, ③ and ④ can be determined as the original path, or ①, ②, ③ and ⑤ can be determined as the original path, that is, as long as the operation steps are run in a serial manner, they can be determined as the original path.
[0038] That is, the path planning method provided by the present method is applicable to any path with a serial direction operation. It can be understood that the original path can refer to various operation methods, including but not limited to cloud service compilation and deployment operation methods, process detection methods, product manufacturing methods, algorithms, simulation test methods, etc. The configuration data refers to various parameter information required to be applied in the running process corresponding to the original path. Including but not limited to, such as: running object, running time, running condition, running dependency, etc.
[0039] In the operation 102 of the present method, the present method takes the keyword capable of being used to distinguish the path operation steps as the basis for information extraction, and performs information extraction on the configuration information, so as to determine a plurality of path nodes and dependency relationships corresponding to the configuration data. When the original path is used to represent the operation method, the path node can be used to represent the operation of each step corresponding to the operation method, and the dependency relationship can be used to represent the operation connection between the operations. Specifically, the dependency relationship can include various types of dependency relationships, such as: freely processable dependency relationship, external dependency relationship and forced dependency relationship. Specifically, an operation in a path node uses an object in another path node as an operation parameter thereof; an operation in a path node uses an object in another path node as a data member thereof; an operation in a path node is used to send information to an object in another path node, etc. The above operations can be understood as the dependency relationship between the path nodes.
[0040] In the operation 103 of the present method, dependency analysis is performed according to the dependency relationship and the path node. Specifically, the dependency analysis refers to the analysis of the front and rear order between the path nodes with the dependency relationship. Specifically, it can be understood that the dependency analysis is performed on the path nodes with the dependency relationship to determine the leading path node located in the leading operation and the subsequent path node located in the subsequent operation. Thus, the directed relationship between a plurality of path nodes is obtained. Further, the directed relationship can be represented by a directed graph. In the directed graph, two path nodes can be connected by a line segment with an arrow. One end of the line segment with the arrow points to the subsequent path node, and the other end is used to connect the leading path node.
[0041] In operation 104 of the method, after the directed relationship between the two path nodes is obtained, all path nodes are connected according to the directed relationship, so that a plurality of target paths can be obtained. Each of the target paths thus obtained can be run independently by the path nodes on the path. Compared with the original path, since the target path has a plurality of paths, that is, the number of path nodes on each target path does not exceed the number of path nodes on the original path, the running time of each target path can be shorter than the running time of the original path, and since each path can be run independently, all path nodes can be run in parallel, so that the time for completing the running of all nodes by the route node is shorter than the time for running all path nodes by the original path, thereby realizing the fast completion of path running by the multi-path parallel running mode to achieve the purpose of meeting the target running requirement.
[0042] Figure 2 An implementation flowchart of a path planning method according to another embodiment of the present application.
[0043] Referring to Figure 2 In an implementation manner, after the plurality of target paths are obtained in operation 104, the method further includes: operation 201, performing parallel detection according to the plurality of target paths; and operation 202, when any path node has an exception, determining that the configuration data corresponding to the original path has a first data exception.
[0044] In an implementation scenario, the method can be used for path planning of a detection type operation method. Specifically, the detection type operation method can be a method for detecting configuration data corresponding to the original path. The detection type operation method can also be an operation method for single-class and / or multi-class detection of a certain product or certain products. The detection type operation method can also be a method for simulating a certain operation method to determine its feasibility. The detection type operation method can also be a method for simulating specific data of a specific object.
[0045] Specifically, when the method is for simulating a certain operation method, the method can be used for path planning of the operation method to obtain a plurality of target paths. Then, parallel detection is performed on the plurality of target paths, that is, the plurality of target paths are simultaneously simulated and run to realize the simulation detection of each path. In the simulation running process, the simulation running process of each target path is simultaneously run, and the configuration data from other target paths is not required in the target path running process. For example:
[0046] According to the original path, the following two target paths are obtained:
[0047] Path one: S1→S2→S7→S8
[0048] Path two: S1→S3→S6→S8
[0049] Meanwhile, the operation data required by S2 in path one is provided by S1, the operation data required by S7 in path one is provided by at least one of S1 and S2 in path one, and the operation data required by S8 in path one is provided by at least one of S1, S2 and S7 in path one.
[0050] Similarly, the operation data required by S3 in path two is provided by S1 in path two, the operation data required by S6 in path two is provided by at least one of S1 and S3 in path two, and the operation data required by S8 in path two is provided by at least one of S1, S3 and S6 in path two.
[0051] To quickly determine whether such an operation method is abnormal, the method can set the parallel detection process of multiple target paths as a multi-thread competition mechanism, that is, in the case that any path node in the target path is abnormal, it is determined that the configuration data corresponding to the original path has a first data abnormality. That is, it is determined that the operation method has an error operation. Specifically, whether there is an abnormal path node can be determined by whether the target path can run smoothly, and when the target path cannot run, it is considered that there is an abnormal path node, and it is determined that the configuration data corresponding to the original path has a first data abnormality. The first data abnormality can be used to indicate that the configuration data corresponding to the original path has an error, which leads to the failure to complete the operation.
[0052] It should be understood that when any path node is abnormal, the method can stop the running of all target paths and directly determine that the detection result is that the configuration data corresponding to the original path has a first data abnormality. This provides the fastest feedback to the developer, saves waiting time, and greatly improves the research and development efficiency.
[0053] Figure 3 FIG. 1 is a schematic diagram of an implementation process of a path planning method according to another embodiment of the present application.
[0054] Referring to Figure 3 In an implementable manner, operation 102, information extraction is performed on the configuration data to determine a plurality of path nodes and dependency relationships corresponding to the configuration data, including: operation 1021, determining a data syntax type corresponding to the configuration data; and operation 1022, performing abstract syntax analysis on the plurality of path nodes according to the data syntax type to determine the plurality of path nodes and the dependency relationships corresponding to the configuration data.
[0055] In different implementation scenarios, i.e., corresponding to different original paths, the configuration data of the original path can be expressed in different ways. For example, the configuration data can be a configuration file based on a domain specific language (DSL) syntax, and the configuration data can also be a configuration file based on a key-value relationship. It can be understood that different syntax types correspond to different syntax analysis methods.
[0056] Based on this, the method first determines the data syntax type corresponding to the configuration data. Specifically, the syntax type of the configuration data can be determined by comparing the configuration data with the expression of different syntax types and / or keywords. After determining the corresponding syntax type, the method can perform abstract syntax analysis according to the syntax type corresponding to the configuration data to determine the plurality of path nodes and the dependency relationship corresponding to the configuration data. By performing syntax analysis on the syntax type corresponding to the configuration data, the analysis result can be more accurate. For example, when it is determined that the configuration data is a configuration file based on a DSL syntax, the configuration data can be analyzed according to an AST syntax to determine the plurality of path nodes and the dependency relationship. When it is determined that the configuration data is a configuration file based on a key-value relationship, the configuration data can be traversed to determine the plurality of path nodes and the dependency relationship. It can be understood that when the configuration data of the method has multiple syntax types, different syntax types can be used to perform syntax analysis on the configuration data based on the syntax type.
[0057] In an implementation, operation 1022, performing abstract syntax analysis on the plurality of path nodes according to the data syntax type to determine the plurality of path nodes and the dependency relationship corresponding to the configuration data, includes: first, determining the corresponding preset keyword according to the syntax type; then, performing information reduction on the configuration data according to the preset keyword to obtain key data containing the preset keyword; and then, performing abstract syntax analysis on the key data to determine the plurality of path nodes and the dependency relationship corresponding to the configuration data.
[0058] In a specific implementation scenario, when the configuration data is a configuration file based on a DSL syntax, the configuration data is analyzed by an AST syntax. Further, in order to facilitate data processing, the method can also extract data based on the preset keyword corresponding to the configuration file based on the DSL syntax, thereby realizing information reduction, achieving the purpose of retaining the required fields, and obtaining key data. Specifically, for a configuration file based on a DSL syntax, the corresponding preset keyword can be a keyword such as "dependency" and "when". It can be understood that the preset keyword can be a keyword related to information such as operation content, operation object, and trigger condition corresponding to the configuration data.
[0059] In an implementation, the syntax analysis of the key data determines the path nodes and the dependency relationships corresponding to the configuration data, including: first, information extraction of the key data determines the path nodes; and then, data analysis of the key data determines the dependency relationships corresponding to the path nodes.
[0060] By syntax analysis of the key data, the data division of the key data can be achieved, so that each piece of the divided key data is determined as a path node. The path nodes are obtained, and in this case, each path node can be used to represent part of the configuration data and the corresponding key data. Then, information analysis of the key data corresponding to each path node is performed to determine the dependency relationships between each path node. Specifically, the dependency relationships can be represented by abstract descriptions. Specifically, the abstract descriptions can include no dependency descriptions and dependency-related descriptions.
[0061] In a specific implementation scenario, each path node is in the form of "stage-number", so that the path nodes are "stage-1", "stage-2", "stage-3", "stage-4", "stage-5", "stage-6", "stage-7", and "stage-8". The abstract descriptions of the dependency relationships generated are as follows:
[0062] Stage-1
[0063] Initial stage, no dependency
[0064] Stage-3
[0065] Depend: Stage-1
[0066] Stage-4
[0067] Depend: Stage-3
[0068] Stage-5
[0069] Depend: Stage-4
[0070] Stage-6
[0071] Depend: Stage-3
[0072] Stage-7
[0073] Depend: Stage-2
[0074] Stage-8
[0075] Depend: Stage-1
[0076] Stage-2
[0077] End stage, rely on all.
[0078] In an implementation manner, operation 103, according to the dependency relationship and the path node, the dependency analysis is performed to obtain the directed relationship between the plurality of path nodes, including: first, the path node and the dependency relationship are integrated according to the stack storage structure, and a plurality of intra-stack paths are determined; and then, the directed acyclic graph is determined according to the intra-stack path and the path node, and the directed acyclic graph is used to represent the directed relationship between the plurality of path nodes.
[0079] Specifically, the method integrates the path node and the dependency relationship through the stack storage structure, thereby constructing the corresponding directed acyclic graph, to determine the directed relationship between the plurality of path nodes, and further determine the corresponding target path.
[0080] Figure 4 The stack storage structure of the path planning method of another embodiment of the application is shown in the figure.
[0081] Referring to Figure 4 , taking the above implementation scenario as an example, the path node and the dependency relationship are integrated through the stack storage structure, and an auxiliary line needs to be constructed to traverse all paths from stage-1 to stage-8. It needs to be understood that according to the above implementation scenario, the vertex with an in-degree of 0 can only be stage-1, and the vertex with an out-degree of 0 can only be stage-8. It needs to be understood that for the convenience of drawing, in the figure, node a corresponds to stage-1, node b corresponds to stage-2, node c corresponds to stage-3, and so on. The following will not be repeated.
[0082] The specific method is as follows:
[0083] Operation one, determining the starting node according to the dependency relationship.
[0084] Operation two, checking whether the top node of the stack has an accessible node in the directed acyclic graph, and has not been stacked, and has not triggered an accessed node from the top node of the stack.
[0085] Operation three, if there is a node satisfying the above conditions, the node is stacked.
[0086] Operation four, if there is no node satisfying the above conditions, the top node of the stack is out of stack.
[0087] Operation five, if the top node of the stack is the end node, the elements in the stack are a path, the end node is set to an unvisited state, and the top node of the stack is out of stack.
[0088] Operation six, repeating operation two to operation five until the stack is empty.
[0089] Thus, the in-stack paths are determined, and it can be understood that each in-stack path corresponds to each target path, and the nodes in the stack structure are path nodes corresponding to the paths. Thus, the directed acyclic graph can be determined according to the in-stack paths and the path nodes, and the nodes in the directed acyclic graph represent the path nodes, and the arrowed line segments represent the directed relationships between the path nodes.
[0090] In an implementable manner, the method further comprises: first, detecting the configuration data according to the original path to determine the weight corresponding to each directed relationship; then, weighting and integrating the directed relationships of each target path according to the weight to obtain the criticality score corresponding to each target path; and then, determining the target path with the highest criticality score as the critical path.
[0091] Figure 5 A directed acyclic graph of a path planning method according to another embodiment of the present application.
[0092] Referring to Figure 5 Further, in order to further compare the criticality between each target path, the method can further detect the configuration data according to the original path to determine the weight corresponding to each path node and / or directed relationship. As shown in Figure 5 S1, S2, S3, …, respectively represent path nodes, the directed line segments connecting the path nodes represent directed relationships, and the values on the directed line segments are the corresponding weights. Specifically, according to the purpose of applying the method, the method can be set to determine different weights according to different characteristics of the original path. For example, if the method needs to improve the efficiency in the path detection process. The method can determine the detection time corresponding to each path node and / or directed relationship by detection, and determine the time weight corresponding to each path node and / or directed relationship according to the detection time. In this way, by weighting and integrating the target paths according to the weights, the criticality score corresponding to each target path can be obtained, and then by comparing the criticality scores between the target paths, the method can determine the target path with the longest time consumption in the multiple target paths, that is, the target path with the longest time consumption is determined as the critical path. In other implementable manners, the weight can also be determined by the data amount, calculation amount, and other parameters corresponding to each path node and / or directed relationship.
[0093] The method can find all the connected paths from the arc tail to the arc head in the directed acyclic graph, as follows:
[0094] Path one: S1→S2→S7→S8
[0095] Path two: S1→S3→S6→S8
[0096] Path three: S1→S3→S4→S5→S8
[0097] By weighted summation through the weight, it can be found that path three is the critical path. For the task corresponding to the critical path, the method can be started independently and executed in series. For the tasks corresponding to other paths, the method can weigh the process overhead and dynamically decide whether to execute in parallel.
[0098] In an implementation manner, the method further comprises: first, detecting the critical path; and then, when the critical path has data anomaly, determining that the configuration data corresponding to the original path has second data anomaly.
[0099] When the method determines the criticality score of each target path through the weight, the method can determine the path with the highest criticality score as the critical path. If the critical path is detected through operation 201 and it is determined that the critical path has data anomaly, it is determined that the configuration data corresponding to the original path has second data anomaly. The second data anomaly is used to represent that there is a serious anomaly in the configuration data corresponding to the original path.
[0100] In an implementation manner, the method further comprises: first, detecting other target paths except the critical path; and then, when other target paths except the critical path are detected to have data anomaly, determining that the configuration data corresponding to the original path has third data anomaly.
[0101] It should be understood that the critical path and the non-critical path of the method can also be detected in parallel. In one implementation, the method can first detect the critical path and then detect the non-critical path. In another implementation, the method can detect the critical path and the non-critical path in parallel. Taking the second data anomaly as an example, the method can divide the third data anomaly and the second data anomaly into degrees, determine the second data anomaly as a first warning level, and determine the third data anomaly as a second warning level, wherein the severity of the first warning level is higher than that of the second warning level. The first data anomaly can include the second data anomaly and the third data anomaly.
[0102] Specifically, in one implementation, the method can understand the third data anomaly as a partial error of the configuration data and the second data anomaly as a complete error of the configuration data. In another implementation, the method can understand the third data anomaly as a correctable error of the configuration data and the second data anomaly as an uncorrectable error of the configuration data.
[0103] Further, when the method is used to detect critical paths and non-critical paths in parallel, if the non-critical path is detected to have the third data abnormality, the method can continue to run the critical path, and if the critical path is detected to have the second data abnormality, the configuration data is determined to have the second data abnormality.
[0104] It should be noted that when the method is used in a development method, the method can determine the critical path to prioritize the development of operations on the critical path, thereby achieving the purpose of improving the development efficiency and reducing the waste in the development process.
[0105] Figure 6 An implementation module schematic diagram of a path planning device according to an embodiment of the present application.
[0106] Referring to Figure 6 According to another aspect of the present application, a path planning device is provided, which comprises: an obtaining module 601 configured to obtain configuration data corresponding to an original path; an extracting module 602 configured to perform information extraction on the configuration data to determine a plurality of path nodes and a dependency relationship corresponding to the configuration data; an analyzing module 603 configured to perform dependency analysis according to the dependency relationship and the path nodes to obtain a directed relationship between the plurality of path nodes; and a connecting module 604 configured to connect the path nodes according to the directed relationship to obtain a plurality of target paths.
[0107] In an implementation manner, the device further comprises: a detecting module 605 configured to perform parallel detection according to the plurality of target paths; and a determining module 606 configured to determine that the configuration data corresponding to the original path has a first data abnormality when any path node has an abnormality.
[0108] In an implementation manner, the extracting module 602 comprises: a determining sub-module 6021 configured to determine a data syntax type corresponding to the configuration data; and an analyzing sub-module 6022 configured to perform abstract syntax analysis on the plurality of path nodes according to the data syntax type to determine the plurality of path nodes and the dependency relationship corresponding to the configuration data.
[0109] In an implementation manner, the analyzing sub-module 6022 comprises: determining a preset keyword corresponding to the syntax type; performing information reduction on the configuration data according to the preset keyword to obtain critical data containing the preset keyword; and performing abstract syntax analysis on the critical data to determine the plurality of path nodes and the dependency relationship corresponding to the configuration data.
[0110] In an implementation manner, the analyzing sub-module 6022 comprises: performing information extraction on the critical data to determine the plurality of path nodes; and performing data analysis on the critical data to determine the dependency relationship corresponding to the plurality of path nodes.
[0111] In an implementation, the analysis module 603 is configured to integrate the path nodes and the dependencies according to the stack storage structure, and determine a plurality of intra-stack paths; and determine a directed acyclic graph according to the intra-stack paths and the path nodes, the directed acyclic graph being used to represent the directed relationships between the plurality of path nodes.
[0112] In an implementation, the detection module 605 is further configured to detect the configuration data according to the original path, and determine a weight corresponding to each directed relationship; and the apparatus further comprises an integration module 607 configured to weight-integrate the directed relationships of each target path according to the weight, and obtain a criticality score corresponding to each target path; and the determination module 606 is further configured to determine the target path with the highest criticality score as the critical path.
[0113] In an implementation, the detection module 605 is further configured to detect the critical path; and the determination module 606 is further configured to determine that the configuration data corresponding to the original path has a second data abnormality when the critical path has a data abnormality.
[0114] In an implementation, the apparatus further comprises: the detection module 605 is further configured to detect other target paths except the critical path; and the determination module 606 is further configured to determine that the configuration data corresponding to the original path has a third data abnormality when the other target paths except the critical path are detected to have a data abnormality.
[0115] In the description of the present specification, the description of the terms “one embodiment”, “some embodiments”, “an example”, “a specific example”, or “some examples” means that the specific features, structures, materials or characteristics described in connection with the embodiment or example are included in at least one embodiment or example of the present application. Moreover, the specific features, structures, materials or characteristics described can be combined in any appropriate manner in any one or more embodiments or examples. In addition, the person skilled in the art can combine and combine the different embodiments or examples described in the present specification and the features of the different embodiments or examples without contradiction.
[0116] In addition, the terms “first”, “second” are only for descriptive purposes, and cannot be understood as indicating or implying relative importance or implicitly indicating the number of the indicated technical features. Therefore, the features defined with “first”, “second” can explicitly or implicitly include at least one of the features. In the description of the present application, the meaning of “a plurality of” is two or more, unless otherwise specifically limited.
[0117] The above merely provides the specific implementation of the present application, but the protection scope of the present application is not limited to this. Any person skilled in the art can easily think of the changes or replacements within the technical range disclosed by the present application, which should be covered in the protection scope of the present application. Therefore, the protection scope of the present application should be subject to the protection scope of the claims.
Claims
1. A path planning method, comprising: obtaining configuration data corresponding to an original path; performing information extraction on the configuration data to determine a plurality of path nodes and dependency relationships corresponding to the configuration data; performing dependency analysis on the dependency relationships and the path nodes to obtain directed relationships between the plurality of path nodes; connecting the path nodes according to the directed relationships to obtain a plurality of target paths; performing parallel detection on the plurality of target paths; when any of the path nodes has an abnormality, determining that the configuration data corresponding to the original path has a first data abnormality; the performing dependency analysis on the dependency relationships and the path nodes to obtain directed relationships between the plurality of path nodes comprises: integrating the path nodes and the dependency relationships according to a stack storage structure to determine a plurality of intra-stack paths; determining a directed acyclic graph according to the intra-stack paths and the path nodes, the directed acyclic graph being used to represent the directed relationships between the plurality of path nodes. 2.The method of claim 1, the performing information extraction on the configuration data to determine a plurality of path nodes and dependency relationships corresponding to the configuration data comprises: determining a data syntax type corresponding to the configuration data; performing abstract syntax analysis on the plurality of path nodes according to the data syntax type to determine a plurality of path nodes and dependency relationships corresponding to the configuration data. 3.The method of claim 2, the performing abstract syntax analysis on the plurality of path nodes according to the data syntax type to determine a plurality of path nodes and dependency relationships corresponding to the configuration data comprises: determining a preset keyword corresponding to the syntax type; performing information reduction on the configuration data according to the preset keyword to obtain key data containing the preset keyword; performing abstract syntax analysis on the key data to determine a plurality of path nodes and dependency relationships corresponding to the configuration data. 4.The method of claim 3, the performing abstract syntax analysis on the key data to determine a plurality of path nodes and dependency relationships corresponding to the configuration data comprises: performing information extraction on the key data to determine a plurality of path nodes; performing data analysis on the key data to determine dependency relationships corresponding to the plurality of path nodes. 5.The method of claim 1, further comprising: detecting the configuration data according to the original path to determine a weight value corresponding to each directed relationship; weighting the directed relationships of each target path according to the weight value to obtain a criticality score corresponding to each target path; determining a target path with the highest criticality score as a critical path. 6.The method of claim 5, further comprising: detecting the critical path; when the critical path has a data abnormality, determining that the configuration data corresponding to the original path has a second data abnormality. 7.The method of claim 5, further comprising: detecting other target paths except the critical path. When the target path other than the critical path is detected as having data abnormality, it is determined that the configuration data corresponding to the original path has a third data abnormality.
8. A path planning apparatus, the apparatus comprising: an obtaining module configured to obtain configuration data corresponding to an original path; an extraction module configured to perform information extraction on the configuration data to determine a plurality of path nodes and dependency relationships corresponding to the configuration data; an analysis module configured to perform dependency analysis on the dependency relationships and the path nodes to obtain directed relationships between the path nodes; a connectivity module configured to connect the path nodes according to the directed relationships to obtain a plurality of target paths; a detection module configured to perform parallel detection according to the plurality of target paths; a determination module configured to determine that the configuration data corresponding to the original path has a first data abnormality when any path node has abnormality; the analysis module is further configured to integrate the path nodes and the dependency relationships according to a stack storage structure to determine a plurality of intra-stack paths; a directed acyclic graph is determined according to the intra-stack paths and the path nodes, and the directed acyclic graph is used to represent the directed relationships between the path nodes.
Citation Information
Patent Citations
Optimization method and device for task scheduling based on metadata
CN107688488A
Method and device for optimizing task flow of data center station
CN112559287A
Data analysis method and device, storage medium and server
CN113420097A