CN117707726A - Processing method and device of flow node, electronic equipment and readable medium - Google Patents

Processing method and device of flow node, electronic equipment and readable medium Download PDF

Info

Publication number
CN117707726A
CN117707726A CN202311601452.0A CN202311601452A CN117707726A CN 117707726 A CN117707726 A CN 117707726A CN 202311601452 A CN202311601452 A CN 202311601452A CN 117707726 A CN117707726 A CN 117707726A
Authority
CN
China
Prior art keywords
flow
node
compensation
task node
workflow engine
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.)
Pending
Application number
CN202311601452.0A
Other languages
Chinese (zh)
Inventor
彭捷
邓宗平
蔡平
程宏达
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
China International Marine Containers Group Co Ltd
CIMC Container Group Co Ltd
CIMC IoT Technology Co Ltd
Shenzhen CIMC Smart Parking Co Ltd
Original Assignee
China International Marine Containers Group Co Ltd
CIMC Container Group Co Ltd
CIMC IoT Technology Co Ltd
Shenzhen CIMC Smart Parking Co Ltd
Priority date (The priority date 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 date listed.)
Filing date
Publication date
Application filed by China International Marine Containers Group Co Ltd, CIMC Container Group Co Ltd, CIMC IoT Technology Co Ltd, Shenzhen CIMC Smart Parking Co Ltd filed Critical China International Marine Containers Group Co Ltd
Priority to CN202311601452.0A priority Critical patent/CN117707726A/en
Publication of CN117707726A publication Critical patent/CN117707726A/en
Pending legal-status Critical Current

Links

Landscapes

  • Management, Administration, Business Operations System, And Electronic Commerce (AREA)

Abstract

The application belongs to the technical field of computers, and particularly relates to a processing method and device of a flow node, electronic equipment and a readable medium. The method comprises the following steps: acquiring the working state of a first flow, and acquiring a second flow through a workflow engine based on node information of the first flow if the working state of the first flow is an abnormal state, wherein a flow compensation relation exists between the second flow and the first flow; creating a compensation task node based on the second process, and monitoring an execution result of the compensation task node through the workflow engine; judging whether the compensation task node is successfully executed according to the execution result, and canceling the first flow through the workflow engine if the compensation task node is successfully executed. According to the method and the device, the flow node data are saved under the condition that the flow node is interrupted, and the execution effect of the flow is improved.

Description

Processing method and device of flow node, electronic equipment and readable medium
Technical Field
The application belongs to the technical field of computers, and particularly relates to a processing method and device of a flow node, electronic equipment and a readable medium.
Background
In order to efficiently execute tasks to be processed of a business system, a coordination relationship of related components or devices is generally controlled through a flow engine, and each task to be processed is processed into a flow example consisting of a plurality of flow nodes. However, when the task flow to be processed is transferred to a certain flow node in the middle process, the subsequent flow node cannot execute due to the burst state or service adjustment, the equipment or data involved in the flow example is still in the middle state, and if the equipment or data is not timely restored to the normal state, the normal execution of the subsequent flow is affected.
Disclosure of Invention
The invention aims to provide a processing method, a processing device, electronic equipment and a readable medium of a flow node, which are used for storing flow node data under the condition that the flow node is interrupted, so that the execution effect of a flow is improved.
According to an aspect of an embodiment of the present application, there is provided a method for processing a flow node, including:
acquiring the working state of a first flow, and acquiring a second flow through a workflow engine based on node information of the first flow if the working state of the first flow is an abnormal state, wherein a flow compensation relation exists between the second flow and the first flow;
creating a compensation task node based on the second process, and monitoring an execution result of the compensation task node through the workflow engine;
judging whether the compensation task node is successfully executed according to the execution result, and canceling the first flow through the workflow engine if the compensation task node is successfully executed.
According to an aspect of an embodiment of the present application, there is provided a processing apparatus of a flow node, including:
the first flow state acquisition module is used for acquiring the working state of a first flow, and acquiring a second flow through a workflow engine based on node information of the first flow if the working state of the first flow is an abnormal state, wherein a flow compensation relation exists between the second flow and the first flow;
the compensation flow creation module is used for creating a compensation task node based on the second flow and monitoring an execution result of the compensation task node through the workflow engine;
and the first flow cancellation module is used for judging whether the compensation task node is successfully executed according to the execution result, and canceling the first flow through the workflow engine if the compensation task node is successfully executed.
According to an aspect of the embodiments of the present application, there is provided an electronic device including: a processor; and a memory for storing executable instructions of the processor; wherein the processor is configured to perform the processing method of the flow node as in the above technical solution via execution of the executable instructions.
According to an aspect of the embodiments of the present application, there is provided a computer readable medium having stored thereon a computer program which, when executed by a processor, implements a processing method of a flow node as in the above technical solution.
According to an aspect of embodiments of the present application, there is provided a computer program product or computer program comprising computer instructions stored in a computer readable storage medium. The processor of the computer device reads the computer instructions from the computer-readable storage medium, and the processor executes the computer instructions, so that the computer device performs the processing method of the flow node as in the above technical solution.
In the technical scheme provided by the embodiment of the application, by acquiring the working state of the first flow, when the working state of the first flow is determined to be an abnormal state, acquiring a second flow through a workflow engine based on node information of the first flow, wherein a flow compensation relationship exists between the second flow and the first flow; and creating a compensation task node based on the second flow, monitoring an execution result of the compensation task node through the workflow engine, judging whether the compensation task node is successfully executed according to the execution result, and canceling the first flow through the workflow engine if the compensation task node is successfully executed. The first process is not successfully executed, which means that a certain intermediate node in the first process is not successfully executed or suddenly interrupted, and the failure of the execution of the whole process is caused by the failure of the execution of the intermediate node.
Other features and advantages of the present application will be apparent from the following detailed description, or may be learned in part by the practice of the application.
It is to be understood that both the foregoing general description and the following detailed description are exemplary and explanatory only and are not restrictive of the application.
Drawings
The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the application and together with the description, serve to explain the principles of the application. It is apparent that the drawings in the following description are only some embodiments of the present application, and that other drawings may be obtained from these drawings without inventive effort for a person of ordinary skill in the art.
Fig. 1 shows a flow diagram of a processing method of a flow node according to an embodiment of the present application.
Fig. 2 shows a flow chart of a processing method of the flow node provided in this embodiment.
Fig. 3 schematically shows a block diagram of a processing apparatus of a flow node according to an embodiment of the present application.
Fig. 4 schematically shows a block diagram of a computer system for implementing an electronic device according to an embodiment of the present application.
Detailed Description
Example embodiments will now be described more fully with reference to the accompanying drawings. However, the exemplary embodiments may be embodied in many forms and should not be construed as limited to the examples set forth herein; rather, these embodiments are provided so that this disclosure will be thorough and complete, and will fully convey the concept of the example embodiments to those skilled in the art.
Furthermore, the described features, structures, or characteristics may be combined in any suitable manner in one or more embodiments. In the following description, numerous specific details are provided to give a thorough understanding of embodiments of the present application. One skilled in the relevant art will recognize, however, that the aspects of the application can be practiced without one or more of the specific details, or with other methods, components, devices, steps, etc. In other instances, well-known methods, devices, implementations, or operations are not shown or described in detail to avoid obscuring aspects of the application.
The block diagrams depicted in the figures are merely functional entities and do not necessarily correspond to physically separate entities. That is, the functional entities may be implemented in software, or in one or more hardware modules or integrated circuits, or in different networks and/or processor devices and/or microcontroller devices.
The flow diagrams depicted in the figures are exemplary only, and do not necessarily include all of the elements and operations/steps, nor must they be performed in the order described. For example, some operations/steps may be decomposed, and some operations/steps may be combined or partially combined, so that the order of actual execution may be changed according to actual situations.
In order to ensure that the process tasks in the business system can be efficiently executed, the tasks to be processed are generally arranged into a process consisting of a plurality of nodes, and each control device is coordinated through a workflow engine, so that the nodes are executed according to a preset sequence and rule until one process is completed. The dependency on the execution sequence exists among the nodes, if a certain flow node is suddenly interrupted, the subsequent flow node cannot execute, wherein the related equipment data can be in an intermediate state, and if the data is not timely restored to a normal task, the normal execution of the subsequent task can be influenced.
In general, when a process is being executed, a certain process node is suddenly interrupted, but the equipment or control device associated with the process node may still be in a state to be interacted, and if a certain process node is suddenly canceled, the state of the equipment and data associated with the certain process node is not restored to a normal state, so that the execution of other processes is affected.
In particular, a business processing task to be completed can be decomposed into a flow task consisting of a plurality of flow nodes by a computer device using a workflow engine. And executing each flow node in the flow tasks through the workflow engine to realize the task execution intellectualization. The workflow engine is used for executing tasks corresponding to the flow nodes in the flow tasks, monitoring the execution state of each task, and supervising the execution state of each flow node according to a preset sequence and rules to intelligently complete the flow tasks.
A workflow is an abstract, generalized description of the workflow and business rules between its operational steps, and the workflow engine is capable of organizing the work in the workflow according to predetermined logic, expressed and implemented in an appropriate model by computer equipment. The workflow refers to that the workflow is related in a mode of each flow node, and each flow node triggers through internal and external driving to cause the progress of the flow node, so that a flow state is formed and reaches a work end point. For example, a process of registering after a user finishes on a platform may be called a workflow.
The embodiment provides a compensation flow which is applied to a workflow engine and is used for executing a business flow cancel by the workflow engine, an index between a target flow and the compensation flow is created by the workflow engine, when the target flow is suddenly canceled or temporarily adjusted to cause the execution failure, and data or equipment involved in the target flow is restored to a normal state by executing the compensation flow.
Fig. 1 shows a flow diagram of a processing method of a flow node according to an embodiment of the present application.
As shown in fig. 1, the processing method of the flow node includes the following steps:
s100, acquiring the working state of the first flow, and acquiring a second flow through a workflow engine based on node information of the first flow if the working state of the first flow is an abnormal state, wherein the second flow and the first flow have a flow compensation relationship.
Specifically, the working state of the first flow is obtained, and the function of the working state is to judge the execution result of the first flow.
The working state may include execution results of each flow node in the first flow. The first flow is composed of a plurality of adjacent flow nodes, such as node 1→node 2→node 3. There is a time sequence order of the nodes 1, 2 and 3, and there is a data dependency between the nodes, for example, the data a obtained after the execution of the node 1 is completed helps the execution of the node 2.
And if the working state of the first flow is an abnormal state, acquiring a second flow with a flow compensation relation with the first flow according to the node information of the first flow.
The mode of confirming that the working state of the first flow is an abnormal state may be: the state identifier of each flow node is obtained, and the state identifier is updated after the flow node executes, for example, the state identifier is 0 before the flow node does not execute, and the state identifier is updated to be 1 after the flow node executes.
Further, the execution time limit of each flow node may be set, and after receiving the execution result of the node 1, if the execution result of the node 2 is not received after exceeding the execution time limit, the working state of the first flow is confirmed to be an abnormal state.
The flow compensation relationship refers to a relationship having mutual compensation with the first flow, that is, a relationship corresponding to a flow node of the first flow.
S200, creating a compensation task node based on the second process, and monitoring an execution result of the compensation task node through a workflow engine.
Specifically, a compensation flow node is created according to the second flow, and the execution result of the compensation task node is monitored through a workflow engine.
The compensation flow node may be one or more. When a plurality of compensation task nodes exist, each compensation task node is ordered according to sequential logic.
The compensation task node is associated with node information of a process node which is not executed in the first process, and data or states which are not reset in the first process can be restored to be normal according to the node information.
And S300, judging whether the compensation task node is successfully executed according to the execution result, and canceling the first flow through the workflow engine if the compensation task node is successfully executed.
Specifically, whether the compensation task node is successfully executed is judged according to the execution result, and if the compensation task is successfully executed, the first flow is canceled through the workflow engine.
The first flow Cheng Quxiao indicates that flow nodes in the first flow that did not execute the completion do not continue to execute, and that the data or state associated with each flow node is restored to a normal state. The normal state refers to a default state of the respective data or states.
The method for judging whether the compensation task node is successfully executed according to the execution result can be as follows: and acquiring the state change condition of the compensation task node.
Optionally, the execution result of each flow node is stored in a database by the workflow engine. After the preset time, determining whether the execution result of the corresponding flow node is stored in the database.
Optionally, when creating the compensation task node, a node identification of the compensation task node is stored in a database. Inquiring a state identifier corresponding to the node identifier, and if the state identifier is 1, indicating that the compensation task node is successfully executed; if the status flag is 0, it indicates that the compensation task node has not executed successfully.
In the embodiment of the application, by acquiring the working state of the first procedure, when the working state of the first procedure is determined to be an abnormal state, acquiring the second procedure through the workflow engine based on the node information of the first procedure, creating the compensation task node based on the second procedure, monitoring the execution result of the compensation task node through the workflow engine, judging whether the compensation task node is successfully executed or not according to the execution result, if the compensation task node is successfully executed, canceling the first procedure through the workflow engine, when the working state of the first procedure is the abnormal state, the first procedure is not successfully executed, indicating that a certain intermediate node in the first procedure is not successfully executed or suddenly interrupted, creating the compensation task node based on the procedure compensation relation of the first procedure, and restoring the data or equipment which is not timely restored in the first procedure to the normal state through the compensation task node, thereby ensuring that other procedures can be normally executed later, and improving the efficiency of the procedure execution.
Further, S100, acquiring the working state of the first flow includes:
s110, responding to the execution request of the first flow and receiving the execution state returned by the first flow.
S120, after the preset time, the execution state returned by the first flow is not received, and the working state of the first flow is determined to be an abnormal state.
Specifically, first, in response to an execution request of a first flow, each flow node forming the first flow and a node identifier thereof are acquired. Optionally, when receiving the execution request of the first flow, the node attribute of each flow node of the first flow is queried in the database.
The execution order of each flow node of the first flow and the data or equipment and the like in which interaction is required are determined based on the node attributes.
The first flow is assumed to be a flow for guiding the vehicle to stop. When the vehicle arrives at the hall door, the ground sensing signal is triggered. And triggering an execution request of a first process while receiving the ground sensing signal, wherein the first process needs to open the hall door, guide the vehicle to stop, detect that the vehicle enters the hall and close the hall door.
The node attribute represents the type of task that each flow node needs to perform and the data that needs to be given or obtained to perform the task. For example, the process node of opening the outer door of the car hall needs to acquire the state of the outer door of the car hall, if the outer door of the car hall is in a closed state, the outer door of the car hall needs to be controlled to be opened, and finally, the opened result of the outer door of the car hall is returned.
After the execution is completed, the door outside the car hall is opened, the car is stopped and guided, whether the car enters the car hall or not is detected, when the execution state returned by the flow node is not received for more than the preset time, the flow node can be determined not to be executed, and the working state of the first flow is confirmed to be an abnormal state.
In this embodiment, by receiving the execution state returned by the first flow, if the execution state returned by the first flow is not received after the preset time elapses, the working state of the first flow is confirmed to be an abnormal state, and when the first flow is in the abnormal state, the subsequent flow cannot be executed, and the first flow needs to be cancelled, which is beneficial to the execution of the subsequent flow.
Further, S100, if the working state of the first flow is an abnormal state, obtaining, by the workflow engine, the second flow based on the node information of the first flow includes:
s130, acquiring the compensation flow configuration information of the first flow through a workflow engine.
S140, if the compensation flow configuration information indicates that the first flow is provided with the compensation flow, the compensation flow is obtained as the second flow.
Specifically, the workflow engine configures information by accessing the compensation flow of the first flow in the database. The compensation flow configuration information indicates whether the first flow is provided with a compensation flow, and the compensation flow is used for restoring data or equipment involved in the first flow to a normal state when the first flow is canceled.
The compensation flow can be created by a workflow engine, after the creation is successful, the flow information of the whole compensation flow is stored in a database, and the state of the compensation flow configuration information is configured as available. When the first flow needs to be canceled, the compensation flow is acquired as a second flow by the workflow engine.
In this embodiment, compensation flow configuration information of the first flow is obtained, where the compensation flow configuration information is used to obtain a compensation flow of the first flow, and according to the compensation flow, a task can be reset when the first flow is suddenly interrupted, so as to reset data or equipment involved in the first flow.
Further, S130, obtaining, by the workflow engine, compensation flow configuration information of the first flow includes:
s131, if the compensation flow configuration information indicates that the first flow is not configured with the compensation flow, the node index of the first flow is obtained.
S132, based on the node index, inquiring a second flow with an index relation with the first flow in the workflow engine.
Specifically, if the compensation flow configuration information of the first flow indicates that the first flow does not configure the compensation flow, a second flow having an index relationship with the first flow is obtained according to the node index of the first flow.
The second flow may be composed of a plurality of flow nodes having an index relationship with the flow nodes in the first flow.
In addition, a node index is used to indicate associations between the various flow nodes. Firstly, establishing node indexes according to the flow information of each flow node, and establishing an index relation with a preset sequence of the flow nodes with the index relation.
For example, node a and node B store an association in execution order. In another flow, node A has an association with node C in order of execution, and then node A's node index includes node B and node C.
Specifically, the node index of the flow node includes different node attributes of the flow node, and the flow task corresponding to each node attribute is different.
The first flow includes a node A, and other flow nodes are obtained according to the node index of the node A. It should be noted that, if the node index includes a plurality of flow nodes, the corresponding flow nodes are matched according to the task information of the first flow. And acquiring a second flow with an index relation with the first flow according to the node attribute of the flow node in the first flow and the node index, wherein the second flow consists of a plurality of flow nodes with an index relation with the flow node of the first flow.
Specifically, the node index of the first flow is created by the workflow engine, an index relationship is constructed according to the node representations of the nodes of each flow, and the index relationship is stored in the database. And inquiring the index relation of the first process in the database through the workflow engine to obtain a second process with the index relation with the first process.
Optionally, node indexes of the flow nodes are stored in the form of building node trees, and a second flow with an index relation with the first flow is obtained by inquiring the index relation of the tree nodes.
In this embodiment, a second flow having an index relationship with the first flow is obtained through the node index of the first flow, and the second flow is beneficial to the subsequent construction of the compensation flow.
Further, S200, creating a compensation task node based on the second procedure, and monitoring, by the workflow engine, an execution result of the compensation task node, including:
s210, obtaining a flow node of the last return execution result of the first flow through the workflow engine.
S220, determining the next flow node of the flow node, creating a compensation task node based on the next flow node and the second flow, and monitoring the execution result of the compensation task node.
Specifically, the process node of the last return of the execution result of the first process refers to the process node that is executed last when the working state of the first process changes to the abnormal state.
For example, the first procedure needs to complete the parking process of the user, firstly, the vehicle arrives at the hall door, the ground sensing signal is triggered, the hall outer door is controlled to be opened, the display screen is controlled to display information for guiding the user how to park, the vehicle enters the hall, and the hall outer door is closed after parking is completed.
The user cannot park due to temporary something or other, because the result of the vehicle entering the hall and parking is not received, and the hall door is always in an open state.
The hall door is always in an open state, which creates a safety hazard and requires the hall door to be closed before the first procedure is canceled.
After the last time of the process node which returns the execution result is obtained, a compensation task node is created according to the next execution task node of the process node, and the execution result of the compensation task node is monitored.
As an alternative implementation manner, the judging process is set based on the task result by acquiring the task result of the first process, and whether the compensation task node is successfully executed is determined by the execution result of the judging process.
For example, the task result of the first procedure corresponds to the closing of the hall door, and the compensation task node needs to perform an action of closing the hall door, and then determines whether the hall door has been closed by the determination node based on whether the hall door is closed or not.
In this embodiment, the execution details of the first flow are acquired based on the workflow engine to create the compensation task node, and the execution state of the compensation task node is determined by monitoring the execution result of the compensation task node, so that the first flow can be smoothly canceled, the subsequent flow can be ensured to be executed, and the execution effect of the flow is improved.
Further, S300 is configured to determine whether the execution of the compensation task node is successful according to the execution result, and cancel the first flow through the workflow engine if the execution of the compensation task node is successful, including:
s310, acquiring a flow update state corresponding to the compensation task node from the execution result, wherein the flow update state comprises a state change label of the compensation task node.
S320, if the state change label indicates that the compensation task node is successfully executed, the first flow is canceled through the workflow engine.
Specifically, a flow update state corresponding to the compensation task node is obtained from the execution result, the flow update state includes a state change label of the compensation task node, if the state change label is 1, it is indicated that the compensation task node is successfully executed, and the first flow can be cancelled.
The first procedure is, for example, opening the hall door, guiding the vehicle to stop, detecting that the vehicle has entered the hall, closing the hall door.
The second flow is to detect the state of the outer door of the car hall, and when the outer door of the car hall is in an open state, the outer door of the car hall is controlled to be closed. The compensation task node may be configured to control the closing of the hall door, return an execution result when the hall door is closed, and record a state change flag.
In this embodiment, the process update state of the compensation task node is obtained, and whether the first process is to be cancelled is determined according to the process update state, so that the first process is ensured not to occupy the execution process of other processes after the first process is cancelled, and meanwhile, after the first process is cancelled, the equipment or data involved in the first process can be restored to the normal state, so that the subsequent process can be ensured to be normally executed, and the execution efficiency of the process task is improved.
Further, after S300, the method further includes:
s400, if the compensation task node is not successfully executed, acquiring detailed flow information corresponding to the compensation task node, wherein the detailed flow information is used for indicating the task information of the compensation task node.
S410, generating reminding information based on the detailed flow information and the execution result of the compensation task node.
Specifically, if the compensation task node is not successfully executed, acquiring detailed flow information corresponding to the compensation task node, and generating reminding information based on the detailed flow information and an execution result of the compensation task node.
For example, the detailed information of the flow of the compensation task node is to control the door outside the car hall to be closed, and if the execution is not successful, a reminding message that the door outside the car hall is not closed can be generated.
The reminding information can be used for reminding a manager to manually close the hall outer door, so that potential safety hazards are prevented.
In this embodiment, if the compensation task node is not successfully executed, the reminding information is generated based on the detailed flow information of the compensation task node, so as to play a role in reminding.
Fig. 2 shows a flow chart of a processing method of the flow node provided in this embodiment.
S500, executing a first procedure;
s510, determining that the working state of the first flow is an abnormal state;
s520, acquiring a second flow having an index relation with the first flow;
s530, creating a compensation task node, and determining an execution result of the compensation task node;
s540, judging whether the compensation task node is successfully executed;
if the step S540 is not successful, the step S560 is executed, the detailed flow information of the compensation task node and the execution result of the compensation task node are obtained, and reminding information is generated;
if S540 is successful, S550 is performed, canceling the first flow.
Details of the flow implementation provided in this embodiment may refer to those of the foregoing embodiments, and are not described herein.
Fig. 3 schematically shows a block diagram of a processing apparatus of a flow node according to an embodiment of the present application. As shown in fig. 3, the processing apparatus of the flow node includes:
the first flow state obtaining module 31 is configured to obtain a working state of the first flow, and if the working state of the first flow is an abnormal state, obtain, by using the workflow engine, a second flow based on node information of the first flow, where the second flow has a flow compensation relationship with the first flow.
The compensation flow creation module 32 is configured to create a compensation task node based on the second flow, and monitor, by the workflow engine, an execution result of the compensation task node.
The first flow cancellation module 33 is configured to determine whether the compensation task node is executed successfully according to the execution result, and cancel the first flow through the workflow engine if the compensation task node is executed successfully.
Further, the first process state obtaining module 31 includes:
the execution state acquisition unit is used for responding to the execution request of the first flow and receiving the execution state returned by the first flow.
The state confirmation unit is used for determining that the working state of the first flow is an abnormal state when the execution state returned by the first flow is not received after the preset time.
Further, the first process state obtaining module 31 includes:
the configuration information acquisition unit is used for acquiring the compensation flow configuration information of the first flow through the workflow engine.
And the second procedure acquisition unit is used for acquiring the compensation procedure as a second procedure if the compensation procedure configuration information indicates that the first procedure is provided with the compensation procedure.
Further, the configuration information acquisition unit includes:
and the node index acquisition subunit is used for acquiring the node index of the first flow if the compensation flow configuration information indicates that the first flow is not configured with the compensation flow.
A second flow Cheng Huoqu subunit operable to query the workflow engine for a second flow having an indexed relationship with the first flow based on the node index.
Further, the compensation flow creation module 32 includes:
the process node obtaining unit is used for obtaining the process node of the last return execution result of the first process through the workflow engine.
And the compensation task state confirming unit is used for determining the next flow node of the flow node, creating a compensation task node based on the next flow node and the second flow, and monitoring the execution result of the compensation task node.
Further, the first process cancellation module 33 includes:
the updating state acquisition unit is used for acquiring a flow updating state corresponding to the compensation task node from the execution result, wherein the flow updating state comprises a state change label of the compensation task node.
And the flow canceling unit is used for canceling the first flow through the workflow engine if the state change label indicates that the compensation task node is successfully executed.
Further, the processing device of the flow node further includes:
the flow information acquisition module is used for acquiring flow detailed information corresponding to the compensation task node if the compensation task node is not successfully executed, wherein the flow detailed information is used for indicating the task information of the compensation task node.
The reminding information generation module is used for generating reminding information based on the detailed flow information and the execution result of the compensation task node.
Fig. 4 schematically shows a block diagram of a computer system for implementing an electronic device according to an embodiment of the present application.
It should be noted that, the computer system 700 of the electronic device shown in fig. 4 is only an example, and should not impose any limitation on the functions and the application scope of the embodiments of the present application.
As shown in fig. 4, the computer system 700 includes a central processing unit 701 (Central Processing Unit, CPU) which can execute various appropriate actions and processes according to a program stored in a Read-Only Memory 702 (ROM) or a program loaded from a storage section 708 into a random access Memory 703 (Random Access Memory, RAM). In the random access memory 703, various programs and data necessary for the system operation are also stored. The central processing unit 701, the read only memory 702, and the random access memory 703 are connected to each other via a bus 704. An Input/Output interface 705 (i.e., an I/O interface) is also connected to bus 704.
The following components are connected to the input/output interface 705: an input section 706 including a keyboard, a mouse, and the like; an output section 707 including a Cathode Ray Tube (CRT), a liquid crystal display (Liquid Crystal Display, LCD), and the like, a speaker, and the like; a storage section 708 including a hard disk or the like; and a communication section 709 including a network interface card such as a local area network card, a modem, or the like. The communication section 709 performs communication processing via a network such as the internet. The drive 710 is also connected to the input/output interface 705 as needed. A removable medium 711 such as a magnetic disk, an optical disk, a magneto-optical disk, a semiconductor memory, or the like is mounted on the drive 710 as necessary, so that a computer program read therefrom is mounted into the storage section 708 as necessary.
In particular, according to embodiments of the present application, the processes described in the various method flowcharts may be implemented as computer software programs. For example, embodiments of the present application include a computer program product comprising a computer program embodied on a computer readable medium, the computer program comprising program code for performing the method shown in the flowcharts. In such an embodiment, the computer program may be downloaded and installed from a network via the communication portion 709, and/or installed from the removable medium 711. The computer programs, when executed by the central processor 701, perform the various functions defined in the system of the present application.
It should be noted that, the computer readable medium shown in the embodiments of the present application may be a computer readable signal medium or a computer readable storage medium, or any combination of the two. The computer readable storage medium can be, for example, but not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or a combination of any of the foregoing. More specific examples of the computer-readable storage medium may include, but are not limited to: an electrical connection having one or more wires, a portable computer diskette, a hard disk, a Random Access Memory (RAM), a read-Only Memory (ROM), an erasable programmable read-Only Memory (Erasable Programmable Read Only Memory, EPROM), flash Memory, an optical fiber, a portable compact disc read-Only Memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing. In the context of this document, a computer readable storage medium may be any tangible medium that can contain, or store a program for use by or in connection with an instruction execution system, apparatus, or device. In the present application, however, a computer-readable signal medium may include a data signal that propagates in baseband or as part of a carrier wave, with the computer-readable program code embodied therein. Such a propagated data signal may take any of a variety of forms, including, but not limited to, electro-magnetic, optical, or any suitable combination of the foregoing. A computer readable signal medium may also be any computer readable medium that is not a computer readable storage medium and that can communicate, propagate, or transport a program for use by or in connection with an instruction execution system, apparatus, or device. Program code embodied on a computer readable medium may be transmitted using any appropriate medium, including but not limited to: wireless, wired, etc., or any suitable combination of the foregoing.
The flowcharts and block diagrams in the figures illustrate the architecture, functionality, and operation of possible implementations of systems, methods and computer program products according to various embodiments of the present application. In this regard, each block in the flowchart or block diagrams may represent a module, segment, or portion of code, which comprises one or more executable instructions for implementing the specified logical function(s). It should also be noted that, in some alternative implementations, the functions noted in the block may occur out of the order noted in the figures. For example, two blocks shown in succession may, in fact, be executed substantially concurrently, or the blocks may sometimes be executed in the reverse order, depending upon the functionality involved. It will also be noted that each block of the block diagrams or flowchart illustration, and combinations of blocks in the block diagrams or flowchart illustration, can be implemented by special purpose hardware-based systems which perform the specified functions or acts, or combinations of special purpose hardware and computer instructions.
It should be noted that although in the above detailed description several modules or units of a device for action execution are mentioned, such a division is not mandatory. Indeed, the features and functions of two or more modules or units described above may be embodied in one module or unit, in accordance with embodiments of the present application. Conversely, the features and functions of one module or unit described above may be further divided into a plurality of modules or units to be embodied.
From the above description of embodiments, those skilled in the art will readily appreciate that the example embodiments described herein may be implemented in software, or may be implemented in software in combination with the necessary hardware. Thus, the technical solution according to the embodiments of the present application may be embodied in the form of a software product, which may be stored in a non-volatile storage medium (may be a CD-ROM, a usb disk, a mobile hard disk, etc.) or on a network, and includes several instructions to cause a computing device (may be a personal computer, a server, a touch terminal, or a network device, etc.) to perform the method according to the embodiments of the present application.
Other embodiments of the present application will be apparent to those skilled in the art from consideration of the specification and practice of the invention disclosed herein. This application is intended to cover any variations, uses, or adaptations of the application following, in general, the principles of the application and including such departures from the present disclosure as come within known or customary practice within the art to which the application pertains.
It is to be understood that the present application is not limited to the precise arrangements and instrumentalities shown in the drawings, which have been described above, and that various modifications and changes may be effected without departing from the scope thereof. The scope of the application is limited only by the appended claims.

Claims (10)

1. A method for processing a flow node, comprising:
acquiring the working state of a first flow, and acquiring a second flow through a workflow engine based on node information of the first flow if the working state of the first flow is an abnormal state, wherein a flow compensation relation exists between the second flow and the first flow;
creating a compensation task node based on the second process, and monitoring an execution result of the compensation task node through the workflow engine;
judging whether the compensation task node is successfully executed according to the execution result, and canceling the first flow through the workflow engine if the compensation task node is successfully executed.
2. The process node processing method according to claim 1, wherein the obtaining the working state of the first flow includes:
responding to the execution request of the first flow and receiving the execution state returned by the first flow;
and after the preset time passes, the execution state returned by the first flow is not received, and the working state of the first flow is determined to be an abnormal state.
3. The method for processing a flow node according to claim 1, wherein if the working state of the first flow is an abnormal state, acquiring, by a workflow engine, a second flow based on node information of the first flow includes:
acquiring compensation flow configuration information of the first flow through a workflow engine;
and if the compensation flow configuration information indicates that the first flow is provided with a compensation flow, acquiring the compensation flow as a second flow.
4. The method for processing a flow node according to claim 3, wherein the obtaining, by a workflow engine, the compensated flow configuration information of the first flow includes:
if the compensation flow configuration information indicates that the first flow is not configured with the compensation flow, acquiring a node index of the first flow;
and querying a second flow with an index relation with the first flow in the workflow engine based on the node index.
5. The process node processing method according to claim 1, wherein creating a compensation task node based on the second process and monitoring, by the workflow engine, an execution result of the compensation task node includes:
acquiring a flow node of the last return execution result of the first flow through the workflow engine;
determining a next flow node of the flow node, creating a compensation task node based on the next flow node and the second flow, and monitoring an execution result of the compensation task node.
6. The method according to claim 1, wherein the determining whether the compensation task node is executed successfully according to the execution result, and if the compensation task node is executed successfully, canceling the first flow by the workflow engine, includes:
acquiring a flow update state corresponding to the compensation task node from the execution result, wherein the flow update state comprises a state change label of the compensation task node;
and if the state change label indicates that the compensation task node is successfully executed, canceling the first flow through the workflow engine.
7. The processing method of a flow node according to claim 1, wherein after judging whether the execution of the compensation task node is successful according to the execution result, if the execution of the compensation task node is successful, canceling the first flow by the workflow engine, the method further comprises:
if the compensation task node is not successfully executed, acquiring detailed flow information corresponding to the compensation task node, wherein the detailed flow information is used for indicating task information of the compensation task node;
and generating reminding information based on the detailed flow information and the execution result of the compensation task node.
8. A processing apparatus of a flow node, comprising:
the first flow state acquisition module is used for acquiring the working state of a first flow, and acquiring a second flow through a workflow engine based on node information of the first flow if the working state of the first flow is an abnormal state, wherein a flow compensation relation exists between the second flow and the first flow;
the compensation flow creation module is used for creating a compensation task node based on the second flow and monitoring an execution result of the compensation task node through the workflow engine;
and the first flow cancellation module is used for judging whether the compensation task node is successfully executed according to the execution result, and canceling the first flow through the workflow engine if the compensation task node is successfully executed.
9. An electronic device, comprising:
a processor; and
a memory for storing executable instructions of the processor;
wherein the processor is configured to cause the electronic device to perform the processing method of the flow node of any of claims 1 to 7 via execution of the executable instructions.
10. A computer readable medium, characterized in that it has stored thereon a computer program which, when executed by a processor, implements the processing method of a flow node according to any of claims 1 to 7.
CN202311601452.0A 2023-11-27 2023-11-27 Processing method and device of flow node, electronic equipment and readable medium Pending CN117707726A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202311601452.0A CN117707726A (en) 2023-11-27 2023-11-27 Processing method and device of flow node, electronic equipment and readable medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202311601452.0A CN117707726A (en) 2023-11-27 2023-11-27 Processing method and device of flow node, electronic equipment and readable medium

Publications (1)

Publication Number Publication Date
CN117707726A true CN117707726A (en) 2024-03-15

Family

ID=90161522

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202311601452.0A Pending CN117707726A (en) 2023-11-27 2023-11-27 Processing method and device of flow node, electronic equipment and readable medium

Country Status (1)

Country Link
CN (1) CN117707726A (en)

Similar Documents

Publication Publication Date Title
US11119988B2 (en) Performing logical validation on loaded data in a database
US20080005747A1 (en) System and method for object state management
JP2017220074A (en) Work schedule supplementary information providing method, work schedule supplementary information providing program and work schedule supplementary information providing device
CN111352853B (en) Compatibility testing method, device, server and storage medium
CN112101803A (en) Business process monitoring method, device, system, equipment and medium
Wang et al. Reliability assessment of autonomous vehicles based on the safety control structure
CN115437339A (en) Remote diagnosis method and device, electronic equipment and storage medium
CN115034596A (en) Risk conduction prediction method, device, equipment and medium
CN111399868A (en) Software updating method, microprocessor, domain controller and readable storage medium
CN110599114A (en) Business process processing method, device, equipment and computer readable storage medium
CN112613288B (en) Method, device, computer equipment and storage medium for generating bill
CN117707726A (en) Processing method and device of flow node, electronic equipment and readable medium
CN115329347B (en) Prediction method, device and storage medium based on car networking vulnerability data
CN111611099A (en) Method, device, equipment and storage medium for repairing lost user information
CN115719167A (en) Vehicle information safety monitoring method and device
CN114860615A (en) Rule automatic testing method and device, electronic equipment and storage medium
CN115617823A (en) Map updating data downloading method, device, equipment and readable medium
CN108563759B (en) Method for clearing login user, device storage medium and electronic equipment
CN115311764A (en) Door lock safety evaluation method and related equipment
CN113935847A (en) Online process risk processing method, device, server and medium
CN111242753A (en) Cross-platform operation control method and system
CN115470292B (en) Block chain consensus method, device, electronic equipment and readable storage medium
CN114996668B (en) Processing method, device, equipment and medium of open source assembly
CN111324472B (en) Method and device for judging garbage items of information to be detected
CN111784459B (en) Civil aviation order information updating method and device

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