CN110599005B - Process analysis method and device, computer readable storage medium and electronic device - Google Patents
Process analysis method and device, computer readable storage medium and electronic device Download PDFInfo
- Publication number
- CN110599005B CN110599005B CN201910784861.6A CN201910784861A CN110599005B CN 110599005 B CN110599005 B CN 110599005B CN 201910784861 A CN201910784861 A CN 201910784861A CN 110599005 B CN110599005 B CN 110599005B
- Authority
- CN
- China
- Prior art keywords
- message
- node
- flow node
- flow
- completion
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Active
Links
Images
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06Q—INFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
- G06Q10/00—Administration; Management
- G06Q10/06—Resources, workflows, human or project management; Enterprise or organisation planning; Enterprise or organisation modelling
- G06Q10/063—Operations research, analysis or management
- G06Q10/0631—Resource planning, allocation, distributing or scheduling for enterprises or organisations
- G06Q10/06316—Sequencing of tasks or work
Landscapes
- Business, Economics & Management (AREA)
- Human Resources & Organizations (AREA)
- Engineering & Computer Science (AREA)
- Strategic Management (AREA)
- Entrepreneurship & Innovation (AREA)
- Economics (AREA)
- Operations Research (AREA)
- Game Theory and Decision Science (AREA)
- Development Economics (AREA)
- Marketing (AREA)
- Educational Administration (AREA)
- Quality & Reliability (AREA)
- Tourism & Hospitality (AREA)
- Physics & Mathematics (AREA)
- General Business, Economics & Management (AREA)
- General Physics & Mathematics (AREA)
- Theoretical Computer Science (AREA)
- Debugging And Monitoring (AREA)
Abstract
The present disclosure relates to a process parsing method, apparatus, computer-readable storage medium, and electronic device, the method comprising: the method comprises the steps that a first flow node receives a first completion message sent by a message center, the first completion message comprises identification information of a second flow node which is operated completely, the message center is used for sending the completion message from a message publisher to a message subscriber corresponding to the completion message, and the completion message from the message publisher comprises the identification information of the message publisher; if the second flow node is determined to be the front node of the first flow node according to the identification information of the second flow node, determining whether the operation of all the front nodes of the first flow node is finished; and if the operations of all the front nodes of the first flow node are finished and the execution condition of the first flow node is met, executing the operation of the first flow node. Therefore, the process analysis can be dispersed to each process node drive, and the concentration and complexity of the process analysis are reduced.
Description
Technical Field
The present disclosure relates to the field of process processing, and in particular, to a process parsing method and apparatus, a computer-readable storage medium, and an electronic device.
Background
A large number of daily operation and maintenance tasks exist in IT infrastructures such as physical hosts and network equipment, the tasks usually have a sequential relationship, one operation and maintenance step can be started only after being executed, and the operation and maintenance processes are formed by connecting the steps in series. In the prior art, when the process is analyzed, each process node is usually driven to operate through a main control program, in the method, the process analysis is centralized, the control logic is complex, and each process node associated with a node in the operation and maintenance process needs to be determined, so that the process flow can be driven only by triggering the next-stage node.
Disclosure of Invention
The purpose of the disclosure is to provide a low-complexity and low-concentration process analysis method and device, a computer-readable storage medium and an electronic device.
In order to achieve the above object, according to a first aspect of the present disclosure, there is provided a flow analysis method, including:
the method comprises the steps that a first flow node receives a first completion message sent by a message center, wherein the first completion message comprises identification information of a second flow node which is operated completely, the message center is used for sending the completion message from a message publisher to a message subscriber corresponding to the completion message, and the completion message from the message publisher comprises the identification information of the message publisher;
if the second flow node is determined to be the front node of the first flow node according to the identification information of the second flow node, determining whether the operation of all the front nodes of the first flow node is finished;
and if the operations of all front nodes of the first flow node are finished and the execution condition of the first flow node is met, executing the operation of the first flow node.
Optionally, the method further comprises:
and if the operation of all the front nodes of the first flow node is finished, sending a subscription ending message to the message center, wherein the subscription ending message comprises the identification information of the first flow node, and the subscription ending message is used for canceling the identity of the message subscriber of the first flow node by the message center.
Optionally, the method further comprises:
after the operation of the first process node is executed, updating the state of the first process node into a finished state, and sending a second finished message to the message center; or alternatively
If the operation execution of the first flow node is abnormal, updating the state of the first flow node into an abnormal termination state, and sending a second completion message to the message center; or alternatively
And if the first flow node is not executable, updating the state of the first flow node to an execution prohibition state, and sending a second completion message to the message center, wherein the second completion message comprises the identification information of the first flow node.
Optionally, the determining whether the operations of all front nodes of the first flow node are completed includes:
traversing the states of all front nodes of the first flow node;
and in all the front nodes of the first flow node, if all the front nodes are in a completion state, or are in an execution-prohibited state, or a part of the front nodes are in the completion state and another part of the front nodes are in the execution-prohibited state, determining that the operations of all the front nodes of the first flow node are completed.
Optionally, the message subscriber further includes a process instance, so that the process instance determines that the process parsing is ended after receiving a completion message of the end node or the abnormally terminated process node.
According to a second aspect of the present disclosure, there is provided a flow analysis apparatus, the apparatus including:
the message center is used for sending a completion message from a message publisher to a message subscriber corresponding to the completion message, wherein the completion message from the message publisher comprises the identification information of the message publisher;
a determining module, configured to determine whether operations of all front-end nodes of the first flow node have been completed when the second flow node is determined to be the front-end node of the first flow node according to the identification information of the second flow node;
and the execution module is used for executing the operation of the first flow node under the condition that the operations of all front nodes of the first flow node are finished and the execution condition of the first flow node is met.
Optionally, the apparatus further comprises:
a sending module, configured to send a subscription end message to the message center when operations of all front-end nodes of the first flow node are completed, where the subscription end message includes identification information of the first flow node, and the subscription end message is used for the message center to cancel an identity of a message subscriber of the first flow node.
Optionally, the apparatus further comprises:
the first processing module is used for updating the state of the first flow node into a finished state after the operation of the first flow node is executed, and sending a second finished message to the message center; or
The second processing module is used for updating the state of the first flow node into an abnormal termination state under the condition that the operation execution of the first flow node is abnormal, and sending a second completion message to the message center; or alternatively
And the third processing module is used for updating the state of the first process node into an execution prohibition state under the condition that the first process node is not executable, and sending a second completion message to the message center, wherein the second completion message comprises the identification information of the first process node.
Optionally, the determining module includes:
the traversing submodule is used for traversing the states of all front nodes of the first process node;
and the determining submodule is used for determining that the operation of all the prepositive nodes of the first flow node is finished if all the prepositive nodes are in a finished state or in an execution-prohibited state or one part of the prepositive nodes are in the finished state and the other part of the prepositive nodes are in the execution-prohibited state in all the prepositive nodes of the first flow node.
Optionally, the message subscriber further includes a process instance, so that the process instance determines that the process parsing is finished after receiving a completion message of the end node or the abnormally terminated process node.
According to a third aspect of the present disclosure, there is provided a computer readable storage medium having stored thereon a computer program which, when executed by a processor, performs the steps of any of the methods of the first aspect described above.
According to a fourth aspect of the present disclosure, there is provided an electronic device comprising:
a memory having a computer program stored thereon;
a processor for executing the computer program in the memory to implement the steps of the method of any of the first aspects above.
In the above technical solution, the message communication between each process node in the process is realized by completing the publishing and subscribing of the message, the current process node may determine whether the completion message is published by its front node according to the identification information included in the completion message, and when the operations of all the front nodes of the current process node are completed and the execution conditions of the current process node are satisfied, the operation of the current process node is executed. Therefore, on one hand, flow analysis can be dispersed to each flow node drive, the concentration and the complexity of the flow analysis are reduced, on the other hand, message communication among all flow nodes in the flow is realized by completing publishing and subscribing of messages, and the operation among the flow nodes can be realized by directly sending a trigger message to the rear node through the current node without needing to clarify the front node and the rear node of the current flow node as in the prior art, so that the efficiency and the data processing amount of the flow analysis are improved, and the accuracy of the flow analysis is further ensured.
Additional features and advantages of the present disclosure will be set forth in the detailed description which follows.
Drawings
The accompanying drawings, which are included to provide a further understanding of the disclosure and are incorporated in and constitute a part of this specification, illustrate embodiments of the disclosure and together with the description serve to explain the disclosure, but do not constitute a limitation of the disclosure. In the drawings:
FIG. 1 is a flow chart of a flow parsing method provided according to one embodiment of the present disclosure;
FIG. 2 is a schematic diagram of a process topology provided in accordance with one embodiment of the present disclosure;
FIG. 3 is a block diagram of a flow parsing apparatus provided according to an embodiment of the present disclosure;
FIG. 4 is a block diagram illustrating an electronic device in accordance with an exemplary embodiment;
FIG. 5 is a block diagram illustrating an electronic device in accordance with an example embodiment.
Detailed Description
The following detailed description of the embodiments of the disclosure refers to the accompanying drawings. It should be understood that the detailed description and specific examples, while indicating the present disclosure, are given by way of illustration and explanation only, not limitation.
Fig. 1 is a flowchart illustrating a flow analysis method according to an embodiment of the present disclosure. As shown in fig. 1, the method includes:
in S11, a first flow node receives a first completion message sent by a message center, where the first completion message includes identification information of a second flow node that has completed an operation, and the message center is configured to send a completion message from a message publisher to a message subscriber corresponding to the completion message, where the completion message from the message publisher includes the identification information of the message publisher. The message center can store the completion message from the message publisher through the message queue, the second process node is used as the message publisher of the completion message, and the first process node is the message subscriber of the completion message. The identification information of the message publisher may be a process node ID of the message publisher, which is not limited by the present disclosure.
Optionally, after publishing the message in the message queue to the corresponding message subscriber, the message center may remove the completion message from the message queue, so as to improve the utilization rate of the storage space and prevent the message subscriber from repeatedly acquiring the completion message.
Illustratively, at the start of a flow, a flow instance of the flow may be initialized. Specifically, the initialization may be performed as follows:
initializing all process nodes in the process instance, namely setting the states of all process nodes as initial states; and determining a front node corresponding to each process node according to the association relationship among the process nodes, wherein the front node has a direct association relationship with the current process node and runs in front of the current process node, as shown in fig. 2, the front node of the process node K is a process node E, and the front node of the process node E is a process node A, B, C. At the same time, each flow node registers a subscription message with the message center to subscribe to "completion messages" from the message center. The message subscriber corresponding to the completion message is the flow node currently subscribing the completion message in the message center. As shown in fig. 2, initially, the message subscribers are all flow nodes in the flow instance.
In S12, if it is determined that the second process node is the front-end node of the first process node according to the identification information of the second process node, it is determined whether the operations of all the front-end nodes of the first process node are completed.
Where the front-end node for each flow node has been determined at the initialization of the flow instance, as described above. Therefore, the first flow node may determine whether the identification information is the same as the identification information of the previous node of the first flow node according to the identification information of the second flow node included in the first completion message. If the first completion message is the same as the second completion message, the second flow node is the front-end node of the first flow node, and if the first completion message is not the same as the second completion message, the second flow node is not the front-end node of the first flow node.
In S13, if the operations of all the front nodes of the first flow node are completed and the execution condition of the first flow node is satisfied, the operation of the first flow node is executed.
When the number of the front nodes of the first flow node is multiple, the first flow node may be executed after the operations of the front nodes are determined to be completed.
Optionally, if the front node of the first flow node is one and the front node is the judgment node, the execution condition of the first flow node is: the status of the front node of the first flow node is a finished status, and the first flow node satisfies the judgment result of the front node.
If the front node of the first flow node does not include the judgment node, the execution condition of the first flow node is as follows: at least one preposed node with the state of completion exists in the preposed nodes of the first flow node.
If the front-end node of the first flow node is a plurality of nodes and comprises a judgment node, the execution condition of the first flow node is as follows: at least one preposed node with the state of completion exists in the preposed nodes of the first flow node, and when the preposed node with the state of completion is a judgment node, the first flow node meets the judgment result of the judgment node.
In the above technical solution, the message communication between each process node in the process is realized by completing the publishing and subscribing of the message, the current process node may determine whether the completion message is published by its front node according to the identification information included in the completion message, and when the operations of all the front nodes of the current process node are completed and the execution conditions of the current process node are satisfied, the operation of the current process node is executed. Therefore, on one hand, flow analysis can be dispersed to each flow node drive, the concentration and the complexity of the flow analysis are reduced, on the other hand, message communication among all flow nodes in the flow is realized by completing publishing and subscribing of messages, and the operation among the flow nodes can be realized by directly sending a trigger message to the rear node through the current node without needing to clarify the front node and the rear node of the current flow node as in the prior art, so that the efficiency and the data processing amount of the flow analysis are improved, and the accuracy of the flow analysis is further ensured.
Optionally, the method further comprises:
and if the operation of all the front nodes of the first flow node is finished, sending a subscription ending message to the message center, wherein the subscription ending message comprises the identification information of the first flow node, and the subscription ending message is used for canceling the identity of the message subscriber of the first flow node by the message center.
The operations of all the front nodes of the first flow node are completed, and no matter whether the first flow node is executable or not, the first flow node does not need to receive the completion messages of other flow nodes, so that the first flow node can send a subscription completion message to the message center. When the message center receives the subscription ending message, the message subscriber identity of the first process node is cancelled according to the identification information of the first process node, so that the first process node does not receive the completion message from the message center any more, thereby avoiding the waste of data transmission resources caused by receiving too many unnecessary completion messages, effectively reducing the data distribution amount of the message center, reducing the data amount of process data analysis and improving the efficiency of process analysis.
Optionally, the method further comprises:
after the operation of the first flow node is executed, the state of the first flow node is updated to a completion state, and a second completion message is sent to the message center, so that the message center can distribute the second completion message to a corresponding message subscriber when receiving the second completion message, and other flow nodes can timely know that the operation of the first flow node is completed; or alternatively
If the operation execution of the first flow node is abnormal, updating the state of the first flow node into an abnormal termination state, and sending a second completion message to the message center, wherein the operation execution abnormality can be an abnormality that the operation cannot be continuously executed due to insufficient memory, program interruption and the like; or
And if the first flow node is not executable, updating the state of the first flow node to an execution prohibition state, and sending a second completion message to the message center, wherein the second completion message comprises the identification information of the first flow node.
If the first flow node is the flow node I, the number of the front-end nodes of the flow node I is one, and the front-end node is the determination node K, and if the determination result of the determination node K is tune, since the flow node I is the flow node corresponding to the determination result FALSE, the determination result of the front-end node is not satisfied, and the state of the flow node I is updated to the execution prohibition state.
For another example, if the first process node is the process node H, and there is no front node with a completion status in the front node corresponding to the process node H (the front node is the process node I, and the status of the process node I is the execution prohibition status), the process node H is not executable, and the status is updated to the execution prohibition status.
In the above technical solution, the state of the first flow node is updated according to different execution results of the operation of the first flow node, on one hand, data support can be provided for the analysis of the subsequent flow node, and on the other hand, the state of the first flow node can be updated in time, which is convenient for the backtracking of the subsequent flow and the exception handling and checking of the flow node.
Optionally, the determining whether the operations of all front nodes of the first flow node are completed includes:
traversing the states of all front nodes of the first flow node;
as illustrated in fig. 2, when the first flow node is the flow node E, the front node of the flow node E determined during initialization is A, B, C.
Wherein, the states of all the front nodes traversing the first flow node can be traversed in the following way:
and selecting any front node as the front node of the current traversal, and determining the state of the front node of the current traversal. Illustratively, the front node currently traversed is flow node a.
If the current traversed front node is in the complete state or the execution prohibition state, one of the non-traversed front nodes is selected as the current traversed front node, and the steps are executed again. For example, if the state of the flow node a is the completion state, a node is selected from the flow nodes B, C as the current traversal front-end node, and if the state of the flow node C is determined to be the completion state, the flow node B is used as the current traversal front-end node.
And if the state of the current traversed front node is not a completion state or a forbidden execution state, ending the traversal.
For example, if the state of the flow node B is the running state, it indicates that the operation corresponding to the flow node B is being executed, and the traversal is ended.
After the traversal is finished, whether the operations of all the front nodes of the first flow node are finished or not can be determined through the traversed state, and the following steps are carried out:
and in all the front nodes of the first flow node, if all the front nodes are in a completion state, or are in an execution prohibition state, or a part of the front nodes are in the completion state and another part of the front nodes are in the execution prohibition state, determining that the operations of all the front nodes of the first flow node are completed.
Optionally, if there is a pre-node that is not traversed after the states of all the pre-nodes that traverse the first flow node are finished, or the states of the traversed pre-nodes are neither a complete state nor a prohibited state, it may be directly determined that the operations of all the pre-nodes of the first flow node are not completely finished.
As in the above example, when the traversal is finished, the process nodes A, B, C are traversed, and it is determined that the states of the process nodes a and C are in the complete state, and the state of the process node B is in the running state, it may be determined that the operations of all the front nodes of the first process node E are not completely completed.
If the state of the flow node B in the above example is the completion state, all the front nodes of the flow node E are the completion state, and at this time, it may be determined that the operations of all the front nodes of the first flow node E are completed.
By the technical scheme, whether the operation of all the front nodes of the first process node is finished or not is determined by traversing the states of the front nodes of the first process node, so that whether the first process node can be triggered or not is determined, accurate circulation among the process nodes in the process is ensured, and the efficiency and accuracy of process analysis are ensured.
Optionally, the message subscriber further includes a process instance, so that the process instance determines that the process parsing is ended after receiving a completion message of the end node or the abnormally terminated process node.
The flow node which is abnormally terminated is a node which is abnormal in the process of flow execution, and whether the flow node is the node which is abnormally terminated can be determined by accessing the state of the flow node.
Illustratively, when receiving a completion message, the process instance may determine, through identification information included in the completion message, whether a node that issues the completion message is an end node, and if the node is the end node, it may determine that the process analysis is ended. If the node is not the end node, the state of the node issuing the completion message may be further determined, if the state is the completion state or the execution prohibition state, it indicates that the current flow is normally circulated and has not been ended, at this time, the completion message may be directly ignored, if the state is the abnormal end state, it indicates that the current flow has not been executed, but a node which is abnormally executed occurs in the intermediate process, at this time, the flow execution is abnormal, and it is also necessary to determine that the flow analysis is ended. Therefore, the flow analysis state can be determined in time, the fault tolerance of the flow analysis method is improved, the flexibility of the flow topology is improved, and the use experience of a user is further improved.
Furthermore, after the process instance determines that the process analysis is finished according to the completion message of the abnormally terminated process node, a prompt message can be output to prompt a user that the process execution is abnormal, so that the follow-up abnormal investigation is facilitated.
The present disclosure also provides a process analysis apparatus, as shown in fig. 3, the apparatus 10 includes:
a receiving module 100, configured to receive a first completion message sent by a message center, where the first completion message includes identification information of a second process node whose operation is completed, and the message center is configured to send a completion message from a message publisher to a message subscriber corresponding to the completion message, where the completion message from the message publisher includes the identification information of the message publisher;
a determining module 200, configured to determine whether operations of all front-end nodes of the first flow node have been completed when the second flow node is determined to be the front-end node of the first flow node according to the identification information of the second flow node;
an executing module 300, configured to execute the operation of the first flow node if the operations of all the front nodes of the first flow node are completed and the executing condition of the first flow node is met.
Optionally, the apparatus further comprises:
a sending module, configured to send a subscription end message to the message center when operations of all front-end nodes of the first process node are completed, where the subscription end message includes identification information of the first process node, and the subscription end message is used for canceling, by the message center, a message subscriber identity of the first process node.
Optionally, the apparatus further comprises:
the first processing module is used for updating the state of the first flow node into a finished state after the operation of the first flow node is executed, and sending a second finished message to the message center; or alternatively
The second processing module is used for updating the state of the first flow node into an abnormal termination state under the condition that the operation execution of the first flow node is abnormal, and sending a second completion message to the message center; or
And the third processing module is configured to update the state of the first flow node to an execution prohibition state under the condition that the first flow node is not executable, and send a second completion message to the message center, where the second completion message includes identification information of the first flow node.
Optionally, the determining module includes:
the traversing submodule is used for traversing the states of all front nodes of the first process node;
and the determining submodule is used for determining that the operation of all the prepositive nodes of the first flow node is finished if all the prepositive nodes are in a finished state or in an execution-prohibited state or one part of the prepositive nodes are in the finished state and the other part of the prepositive nodes are in the execution-prohibited state in all the prepositive nodes of the first flow node.
Optionally, the message subscriber further includes a process instance, so that the process instance determines that the process parsing is ended after receiving a completion message of the end node or the abnormally terminated process node.
With regard to the apparatus in the above-described embodiment, the specific manner in which each module performs the operation has been described in detail in the embodiment related to the method, and will not be elaborated here.
Fig. 4 is a block diagram illustrating an electronic device 700 according to an example embodiment. As shown in fig. 4, the electronic device 700 may include: a processor 701 and a memory 702. The electronic device 700 may also include one or more of a multimedia component 703, an input/output (I/O) interface 704, and a communication component 705.
The processor 701 is configured to control the overall operation of the electronic device 700, so as to complete all or part of the steps in the above-mentioned flow analysis method. The memory 702 is used to store various types of data to support operation at the electronic device 700, such as instructions for any application or method operating on the electronic device 700 and application-related data, such as contact data, transmitted and received messages, pictures, audio, video, and the like. The Memory 702 may be implemented by any type or combination of volatile and non-volatile Memory devices, such as Static Random Access Memory (SRAM), electrically Erasable Programmable Read-Only Memory (EEPROM), erasable Programmable Read-Only Memory (EPROM), programmable Read-Only Memory (PROM), read-Only Memory (ROM), magnetic Memory, flash Memory, magnetic or optical disk. The multimedia components 703 may include screen and audio components. Wherein the screen may be, for example, a touch screen and the audio component is used for outputting and/or inputting audio signals. For example, the audio component may include a microphone for receiving external audio signals. The received audio signal may further be stored in the memory 702 or transmitted through the communication component 705. The audio assembly further comprises at least one speaker for outputting audio signals. The I/O interface 704 provides an interface between the processor 701 and other interface modules, such as a keyboard, mouse, buttons, etc. These buttons may be virtual buttons or physical buttons. The communication component 705 is used for wired or wireless communication between the electronic device 700 and other devices. Wireless Communication, such as Wi-Fi, bluetooth, near Field Communication (NFC), 2G, 3G, 4G, NB-IOT, eMTC, or other 5G, etc., or one or a combination thereof, which is not limited herein. The corresponding communication component 705 may thus comprise: wi-Fi modules, bluetooth modules, NFC modules, and the like.
In an exemplary embodiment, the electronic Device 700 may be implemented by one or more Application Specific Integrated Circuits (ASICs), digital Signal Processors (DSPs), digital Signal Processing Devices (DSPDs), programmable Logic Devices (PLDs), field Programmable Gate Arrays (FPGAs), controllers, microcontrollers, microprocessors, or other electronic components for performing the above-described flow parsing method.
In another exemplary embodiment, a computer readable storage medium comprising program instructions which, when executed by a processor, implement the steps of the flow parsing method described above is also provided. For example, the computer readable storage medium may be the memory 702 comprising program instructions executable by the processor 701 of the electronic device 700 to perform the flow analysis method described above.
Fig. 5 is a block diagram illustrating an electronic device 1900 according to an example embodiment. For example, the electronic device 1900 may be provided as a server. Referring to fig. 5, an electronic device 1900 includes a processor 1922, which may be one or more in number, and a memory 1932 for storing computer programs executable by the processor 1922. The computer program stored in memory 1932 may include one or more modules that each correspond to a set of instructions. Further, the processor 1922 may be configured to execute the computer program to perform the flow parsing method described above.
Additionally, electronic device 1900 may also include a power component 1926 and a communication component 1950, the power component 1926 may be configured to perform power management of the electronic device 1900, and the communication component 1950 may be configured to enable communication, e.g., wired or wireless communication, of the electronic device 1900. In addition, the electronic device 1900 may also include input/output (I/O) interfaces 1958. The electronic device 1900 may operate based on an operating system, such as Windows Server, mac OS XTM, unixTM, linuxTM, etc., stored in memory 1932.
In another exemplary embodiment, a computer readable storage medium comprising program instructions which, when executed by a processor, implement the steps of the flow parsing method described above is also provided. For example, the computer readable storage medium may be the memory 1932 that includes program instructions executable by the processor 1922 of the electronic device 1900 to perform the flow analysis method described above.
In another exemplary embodiment, a computer program product is also provided, which comprises a computer program executable by a programmable apparatus, the computer program having code portions for performing the above-mentioned flow parsing method when executed by the programmable apparatus.
The preferred embodiments of the present disclosure are described in detail above with reference to the accompanying drawings, however, the present disclosure is not limited to the specific details in the above embodiments, and various simple modifications may be made to the technical solution of the present disclosure within the technical idea of the present disclosure, and these simple modifications all belong to the protection scope of the present disclosure.
It should be noted that the various features described in the above embodiments may be combined in any suitable manner without departing from the scope of the invention. In order to avoid unnecessary repetition, various possible combinations will not be separately described in this disclosure.
In addition, any combination of various embodiments of the present disclosure may be made, and the same should be considered as the disclosure of the present disclosure, as long as it does not depart from the spirit of the present disclosure.
Claims (8)
1. A method for process parsing, the method comprising:
the method comprises the steps that a first flow node receives a first completion message sent by a message center, wherein the first completion message comprises identification information of a second flow node which is operated completely, the message center is used for sending the completion message from a message publisher to a message subscriber corresponding to the completion message, wherein the completion message from the message publisher comprises the identification information of the message publisher, and the message subscriber sends a subscription message to the message center to subscribe the completion message from the message center;
if the second flow node is determined to be the front node of the first flow node according to the identification information of the second flow node, determining whether the operation of all the front nodes of the first flow node is finished;
if the operations of all front nodes of the first flow node are finished and the execution condition of the first flow node is met, executing the operation of the first flow node;
and if the operation of all the front nodes of the first flow node is finished, sending a subscription ending message to the message center, wherein the subscription ending message comprises the identification information of the first flow node, and the subscription ending message is used for canceling the identity of the message subscriber of the first flow node by the message center.
2. The method of claim 1, further comprising:
after the operation of the first flow node is executed, updating the state of the first flow node into a finished state, and sending a second finished message to the message center; or
If the operation execution of the first flow node is abnormal, updating the state of the first flow node into an abnormal termination state, and sending a second completion message to the message center; or
And if the first flow node is not executable, updating the state of the first flow node to an execution prohibition state, and sending a second completion message to the message center, wherein the second completion message comprises the identification information of the first flow node.
3. The method of claim 1, wherein determining whether all operations of a predecessor node of the first flow node have been completed comprises:
traversing the states of all front nodes of the first flow node;
and in all the front nodes of the first flow node, if all the front nodes are in a completion state, or are in an execution-prohibited state, or a part of the front nodes are in the completion state and another part of the front nodes are in the execution-prohibited state, determining that the operations of all the front nodes of the first flow node are completed.
4. The method according to any of claims 1-3, wherein the message subscriber further comprises a flow instance, such that the flow instance determines that flow parsing is finished upon receiving a completion message of an end node or an abnormally terminated flow node.
5. A process analysis device, comprising:
a receiving module, configured to receive a first completion message sent by a message center, where the first completion message includes identification information of a second process node whose operation is completed, and the message center is configured to send a completion message from a message publisher to a message subscriber corresponding to the completion message, where the completion message from the message publisher includes the identification information of the message publisher and the message subscriber sends a subscription message to the message center to subscribe to the completion message from the message center;
a determining module, configured to determine whether operations of all front-end nodes of the first flow node have been completed when the second flow node is determined to be the front-end node of the first flow node according to the identification information of the second flow node;
the execution module is used for executing the operation of the first flow node under the condition that the operations of all front nodes of the first flow node are finished and the execution condition of the first flow node is met;
a sending module, configured to send a subscription end message to the message center when operations of all front-end nodes of the first flow node are completed, where the subscription end message includes identification information of the first flow node, and the subscription end message is used for the message center to cancel an identity of a message subscriber of the first flow node.
6. The apparatus of claim 5, further comprising:
the first processing module is used for updating the state of the first flow node into a finished state after the operation of the first flow node is executed, and sending a second finished message to the message center; or
The second processing module is used for updating the state of the first process node into an abnormal termination state under the condition that the operation execution of the first process node is abnormal, and sending a second completion message to the message center; or alternatively
And the third processing module is configured to update the state of the first flow node to an execution prohibition state under the condition that the first flow node is not executable, and send a second completion message to the message center, where the second completion message includes identification information of the first flow node.
7. A computer-readable storage medium, on which a computer program is stored which, when being executed by a processor, carries out the steps of the method according to any one of claims 1 to 4.
8. An electronic device, comprising:
a memory having a computer program stored thereon;
a processor for executing the computer program in the memory to carry out the steps of the method of any one of claims 1 to 4.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201910784861.6A CN110599005B (en) | 2019-08-23 | 2019-08-23 | Process analysis method and device, computer readable storage medium and electronic device |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201910784861.6A CN110599005B (en) | 2019-08-23 | 2019-08-23 | Process analysis method and device, computer readable storage medium and electronic device |
Publications (2)
Publication Number | Publication Date |
---|---|
CN110599005A CN110599005A (en) | 2019-12-20 |
CN110599005B true CN110599005B (en) | 2023-01-31 |
Family
ID=68855324
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201910784861.6A Active CN110599005B (en) | 2019-08-23 | 2019-08-23 | Process analysis method and device, computer readable storage medium and electronic device |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN110599005B (en) |
Citations (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN103197920A (en) * | 2013-03-25 | 2013-07-10 | 华为技术有限公司 | Concurrency control method, control nodes and system |
JP2014021778A (en) * | 2012-07-19 | 2014-02-03 | Mitsubishi Electric Corp | Synchronization processing method for update processing to shared data, data sharing system and data sharing program |
Family Cites Families (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CA2420842C (en) * | 2002-03-06 | 2010-05-11 | Nippon Telegraph And Telephone Corporation | Upper layer node, lower layer node, and node control method |
CN102143041B (en) * | 2010-07-02 | 2014-03-26 | 华为技术有限公司 | Network traffic sharing method, device and system |
CN103530740B (en) * | 2013-10-25 | 2019-01-01 | 金蝶软件(中国)有限公司 | A kind of pair of flow of task carries out the method and device of node control |
CN104573965A (en) * | 2015-01-19 | 2015-04-29 | 浪潮软件股份有限公司 | Front and rear relation circulation method and device based on parallel connection |
CN109104306A (en) * | 2018-07-26 | 2018-12-28 | 东软集团股份有限公司 | Process analytic method, device, computer readable storage medium and electronic equipment |
CN109165931A (en) * | 2018-09-25 | 2019-01-08 | 阿里巴巴集团控股有限公司 | Project workflow management method and device |
-
2019
- 2019-08-23 CN CN201910784861.6A patent/CN110599005B/en active Active
Patent Citations (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP2014021778A (en) * | 2012-07-19 | 2014-02-03 | Mitsubishi Electric Corp | Synchronization processing method for update processing to shared data, data sharing system and data sharing program |
CN103197920A (en) * | 2013-03-25 | 2013-07-10 | 华为技术有限公司 | Concurrency control method, control nodes and system |
Also Published As
Publication number | Publication date |
---|---|
CN110599005A (en) | 2019-12-20 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
US10929180B2 (en) | Task scheduling method, apparatus, electronic device and storage medium | |
CN110471718B (en) | Task processing method and device | |
CN109725950B (en) | Method, device and storage medium for realizing single-instance operation of client | |
CN112631919B (en) | Contrast test method, device, computer equipment and storage medium | |
US20180024874A1 (en) | Anomaly detection using sequences of system calls | |
CN109412967B (en) | System flow control method and device based on token, electronic equipment and storage medium | |
CN113872951B (en) | Hybrid cloud security policy issuing method and device, electronic equipment and storage medium | |
CN110609755A (en) | Cross-blockchain node message processing method, device, device, and medium | |
CN108038010A (en) | Android system startup stage broadcast transmission method, apparatus and terminal | |
CN107133741B (en) | To-do task processing method and device, readable storage medium and electronic equipment | |
CN112486492A (en) | Page generation method and device, storage medium and electronic equipment | |
US10740218B2 (en) | Method and device for determining usage log | |
CN110930110B (en) | Distributed flow monitoring method and device, storage medium and electronic equipment | |
CN110599005B (en) | Process analysis method and device, computer readable storage medium and electronic device | |
CN111080250B (en) | Flow backspacing compensation method and device, storage medium and electronic equipment | |
CN113687882A (en) | Process rollback method, device and storage medium based on activiti | |
CN111143311A (en) | Method, device, medium and equipment for determining correlation between applications and searching log correlation | |
CN114780346A (en) | Method, device, storage medium and electronic equipment for acquiring program blockage information | |
CN105763365A (en) | Method and device for processing anomaly | |
CN113726885B (en) | Flow quota adjusting method and device | |
CN113176931B (en) | Task stream processing method and device, storage medium and electronic equipment | |
CN110825461A (en) | Data processing method and device | |
EP4044043A1 (en) | Storage process running method and apparatus, database system, and storage medium | |
CN117149365A (en) | Task processing method, device, electronic equipment and storage medium | |
CN109327726B (en) | Barrage message processing method and device, terminal and storage medium |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
GR01 | Patent grant | ||
GR01 | Patent grant |