Process instance processing method and apparatus, device, and storage medium

By setting up process instances and nodes in the financial system, the operation of microservices is automatically controlled, which solves the problem of complex operations caused by the interaction of multiple microservices and improves business execution efficiency.

CN119597508BActive Publication Date: 2025-11-04PING AN TECH (SHENZHEN) CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202411677372.8
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-11-21
Publication Date
2025-11-04
Estimated Expiration
2044-11-21

AI Technical Summary

Technical Problem

In financial systems, the interaction of multiple microservices or subsystems to complete process instances is complex and consumes a lot of manpower, resulting in low efficiency.

Method used

By setting up process instances and multiple process nodes, each node is responsible for starting and operating the corresponding microservice. The interaction between microservices is automatically controlled according to the execution order of the nodes, reducing manual intervention.

Benefits of technology

It enables automated control between microservices, saving manpower and improving the efficiency of financial business operations.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119597508B_ABST
    Figure CN119597508B_ABST
Patent Text Reader

Abstract

Embodiments of the present application provide a process instance processing method and device, equipment and a storage medium, belonging to the technical field of financial technology. The method comprises: putting a candidate process instance with a process priority into an instance waiting queue; extracting a candidate process node and a node execution order of a target process instance from the instance waiting queue according to the process priority; executing the target process instance according to the node execution order to obtain a target execution instance; obtaining a target process node in a waiting state from the target execution instance to obtain a target process node, and putting the target process node into a node waiting queue; extracting a current node category and a current execution operation of a current process node from the node waiting queue according to the node execution order; calling a microservice to execute the current execution operation according to the current node category to obtain a node execution result; and executing the target execution instance according to the node execution result and the node execution order. The embodiments of the present application can automatically control the microservice to complete the business, and improve the efficiency of business completion.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present application relates to the technical field of financial technology, and in particular to a process instance processing method and device, equipment and a storage medium. BACKGROUND

[0002] With the development of computer technology, computer technology is integrated into the financial field to form financial technology. Various financial businesses are completed through financial technology to improve the efficiency of completing financial businesses. With the technical update iteration of financial technology, in order to improve the comprehensiveness of financial services, a financial system with multiple functions is set up, and different functions are split into microservices or subsystems according to business, responsibility and scale, so that an operator can complete multiple operations on one financial system.

[0003] In the related art, if a financial process instance involves multiple microservices or subsystems interacting to complete, the operator needs to manipulate each microservice according to the process instance to complete the process instance, which makes the process instance operation complicated and consumes a lot of manpower. Therefore, how to simplify the process instance operation and reduce manpower has become a technical problem to be solved. SUMMARY

[0004] The main purpose of the embodiments of the present application is to provide a process instance processing method and device, equipment and a storage medium, which aims to automatically control the interaction between corresponding microservices in an instance and nodes in the instance to complete the business, save manpower and improve the efficiency of business execution.

[0005] To achieve the above purpose, a first aspect of the embodiments of the present application provides a process instance processing method, which comprises:

[0006] putting a pre-acquired candidate process instance into a preset instance waiting queue; wherein the candidate process instance has a process priority;

[0007] extracting a candidate process instance from the instance waiting queue according to the process priority to obtain a target process instance; wherein the target process instance includes a candidate process node and a node execution order of the candidate process node;

[0008] executing the target process instance according to the node execution order to obtain a target execution instance;

[0009] obtaining a target process node from the target execution instance in a waiting state;

[0010] putting the target process node into a preset node waiting queue;

[0011] extracting the target flow node from the node waiting queue according to the node execution sequence, to obtain a current flow node; wherein the current flow node comprises a current node category and a current execution operation;

[0012] calling a preset microservice according to the current node category to execute the current execution operation, to obtain a node execution result; wherein the node execution result represents that the microservice completes or does not complete the current execution operation;

[0013] executing the target execution instance according to the node execution result and the node execution sequence.

[0014] In some embodiments, the current node category comprises any one of a start node category, an end node category, an artificial node category, a timing node category and a calling node category; the current execution operation comprises any one of a wakeup operation, a shutdown operation, an artificial notification operation, a timing operation and an interface calling operation; the calling of the preset microservice according to the current node category to execute the current execution operation, to obtain a node execution result, comprises any one of:

[0015] calling the microservice according to the start node category to execute the wakeup operation, to obtain a start node execution result;

[0016] calling the microservice according to the artificial node category to execute the artificial notification operation, to obtain an artificial node execution result;

[0017] calling the microservice according to the timing node category to execute the timing operation, to obtain a timing node execution result;

[0018] calling the microservice according to the calling node category to execute the interface calling operation, to obtain a calling node execution result;

[0019] calling the microservice according to the end node category to execute the shutdown operation, to obtain an end node execution result.

[0020] In some embodiments, the node waiting queue comprises a selected flow node, the selected flow node being a next node of the target flow node, and the execution of the target execution instance according to the node execution result and the node execution sequence comprises:

[0021] obtaining an execution position of the current flow node according to the node execution sequence, to obtain a node execution position; wherein the node execution position comprises a tail position or a non-tail position;

[0022] if the node execution result represents that the microservice completes the current execution operation and the node execution position is the tail position, then stopping the execution of the target execution instance;

[0023] if the node execution result represents that the microservice has completed the current execution operation and the node execution position is the non-end position, then the selected flow node is extracted from the node waiting queue according to the node execution order, and the target execution instance is executed according to the selected flow node;

[0024] if the node execution result represents that the microservice has not completed the current execution operation and the node execution position is the non-end position, then execution prompt information is obtained, and the target execution instance is executed according to the execution prompt information.

[0025] In some embodiments, if the node execution result represents that the microservice has not completed the current execution operation and the node execution position is the non-end position, then execution prompt information is obtained, and the target execution instance is executed according to the execution prompt information, including:

[0026] if the node execution result represents that the microservice has not completed the current execution operation and the node execution position is the non-end position, then the execution prompt information is obtained; wherein the execution prompt information includes failure-ignoring prompt information or failure-terminating prompt information;

[0027] if the execution prompt information is the failure-ignoring prompt information, then the selected flow node is extracted from the node waiting queue according to the node execution order, and the target execution instance is executed according to the selected flow node;

[0028] if the execution prompt information is the failure-terminating prompt information, then the execution of the target execution instance is stopped.

[0029] In some embodiments, after the current execution operation is executed on the target execution instance according to the current node category, a node execution result is obtained, the method further includes:

[0030] an instance operation request for the target execution instance is obtained; wherein the instance operation request includes an operation category and a target execution operation;

[0031] an instance state of the target execution instance is obtained according to the instance operation request, to obtain a current instance state;

[0032] a node state of the target flow node is obtained according to the current instance state and the operation category, to obtain a current node state;

[0033] the target execution operation is executed on the target flow node according to the operation category and the current node state.

[0034] In some embodiments, the operation category includes any one of the following: a pause operation category and a termination operation category; the current node state includes any one of the following: a waiting state, a blocking state, an executing state, a pausing state; the target execution operation includes: a deletion operation, a state change operation, a pause operation and a termination operation; and the performing the target execution operation on the target process node according to the operation category and the current node state includes any one of the following:

[0035] performing the deletion operation on the target process node according to the pause operation category and the waiting state;

[0036] performing the state change operation on the target process node according to the pause operation category and the blocking state;

[0037] performing the pause operation on the target process node according to the pause operation category and the executing state;

[0038] performing the deletion operation on the target process node according to the termination operation category and the waiting state;

[0039] performing the termination operation on the target process node according to the termination operation category and the pausing state;

[0040] performing the termination operation on the target process node according to the termination operation category and the executing state.

[0041] In some embodiments, before the placing the pre-acquired candidate process instance into the preset instance waiting queue, the method further includes:

[0042] acquiring a business process request; wherein the business process request includes: business process data and process node information;

[0043] selecting a selected process instance from preset process instances according to the business process data;

[0044] adjusting node order of the selected process instance according to the process node information to obtain the candidate process instance.

[0045] To achieve the above object, a second aspect of the embodiment of the present application provides a process instance processing device, which comprises:

[0046] a data acquisition module configured to place a pre-acquired candidate process instance into a preset instance waiting queue; wherein the candidate process instance has a process priority;

[0047] An instance extraction module is configured to extract a candidate process instance from the instance waiting queue according to the process priority, to obtain a target process instance; wherein the target process instance comprises a candidate process node and a node execution order of the candidate process node.

[0048] An instance execution module is configured to execute the target process instance according to the node execution order, to obtain a target execution instance.

[0049] A target node extraction module is configured to obtain a candidate process node in a waiting state from the target execution instance, to obtain a target process node.

[0050] A node placement module is configured to place the target process node into a preset node waiting queue.

[0051] A current node extraction module is configured to extract the target process node from the node waiting queue according to the node execution order, to obtain a current process node; wherein the current process node comprises a current node category and a current execution operation.

[0052] A node calling module is configured to call a preset microservice according to the current node category to execute the current execution operation, to obtain a node execution result; wherein the node execution result represents that the microservice completes or does not complete the current execution operation.

[0053] A node execution module is configured to execute the target execution instance according to the node execution result and the node execution order.

[0054] To achieve the above object, a third aspect of the embodiments of the present application provides an electronic device, which comprises a memory and a processor, the memory stores a computer program, and the processor implements the method of the first aspect when executing the computer program.

[0055] To achieve the above object, a fourth aspect of the embodiments of the present application provides a computer readable storage medium, which stores a computer program, and the computer program is executed by a processor to implement the method of the first aspect.

[0056] The process instance processing method and device, equipment and storage medium provided by the present application set a process instance, and multiple process nodes are set in the process instance, and each process node is responsible for starting and specific operation of a corresponding microservice. Therefore, the process nodes are executed according to the node execution order, so as to realize the execution of the corresponding microservices according to the process order, realize the automatic control between different microservices, save the manpower for manual intervention in the control between multiple microservices, and make the control between microservices more efficient. BRIEF DESCRIPTION OF DRAWINGS

[0057] Figure 1 is a flowchart of a process instance processing method provided by an embodiment of the present application;

[0058] Figure 2 is a module block diagram of a workflow engine in the process instance processing method provided by an embodiment of the present application;

[0059] Figure 3 is a flowchart of a process instance processing method provided by another embodiment of the present application;

[0060] Figure 4 is a flowchart of a process node of automatic version update of M financial software in the process instance processing method provided by an embodiment of the present application;

[0061] Figure 5 is a flowchart of a process instance processing method provided by another embodiment of the present application;

[0062] Figure 6 is a schematic diagram of node state conversion in the process instance processing method provided by an embodiment of the present application;

[0063] Figure 7 is a flowchart of step S108 in Figure 1

[0064] Figure 8 is a schematic diagram of instance state conversion in the process instance processing method provided by an embodiment of the present application;

[0065] Figure 9 is a flowchart of step S704 in Figure 7

[0066] Figure 10 is a structural schematic diagram of a process instance processing apparatus provided by an embodiment of the present application;

[0067] Figure 11 is a hardware structural schematic diagram of an electronic device provided by an embodiment of the present application. DETAILED DESCRIPTION

[0068] In order to make the objectives, technical solutions and advantages of the present application clearer, the present application is further described in detail below with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present application and should not be used to limit the present application.

[0069] ​​It should be noted that although the functional modules are divided in the device schematic diagram, the logical order is shown in the flowchart, but in some cases, the steps shown or described can be performed in a manner different from the module division in the device or the order in the flowchart. The terms "first", "second", etc. in the specification and claims and the above-mentioned drawings are used to distinguish similar objects, and do not necessarily describe a specific order or sequence.

[0070] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as commonly understood by one of ordinary skill in the art to which this application belongs. The terminology used in the specification herein is for the purpose of describing the embodiments of the present application only and is not intended to be limiting of the present application.

[0071] First, the meanings of several terms involved in the present application are analyzed:

[0072] Artificial intelligence (AI): is a new technical science that studies, develops theories, methods, technologies and application systems for simulating, extending and expanding human intelligence; artificial intelligence is a branch of computer science, and artificial intelligence attempts to understand the essence of intelligence and produce a new intelligent machine that can react in a similar way to human intelligence. The research in this field includes robots, language recognition, image recognition, natural language processing and expert systems, etc. Artificial intelligence is the simulation of human consciousness and thinking information process. Artificial intelligence is also the theory, method, technology and application system of using digital computers or digital computer controlled machines to simulate, extend and expand human intelligence, to perceive the environment, acquire knowledge and use knowledge to obtain the best results.

[0073] Microservice: refers to an application architecture in which a series of independent services communicate through lightweight APIs. Microservice is a distributed system that is divided into independent service units according to business, to solve the shortcomings of monolithic systems and meet the increasingly complex business requirements.

[0074] Workflow engine: refers to workflow as part of an application system and provides core solutions for decision-making information transmission routes, content levels, etc. according to roles, divisions of labor and conditions, which have a decisive effect on each application system. Workflow engine includes important functions such as node management, flow management, and process example management.

[0075] Process node: refers to the transfer point (category point or time point) when a program or a stage ends and another program or a stage starts when the engineering needs several different programs (processes) or is divided into several stages.

[0076] With the computer technology into the financial field to form financial technology, and with the development of financial technology, various financial systems appear, and financial business is automatically completed through the financial system. With the development of the financial system, and the process of financial business is more and more complex, a financial system containing multiple functions appears, and a financial business can be completed through the interaction between multiple functions in the financial system. It should be noted that the financial system is divided into multiple microservices or subsystems according to functions, and a financial business is completed through the calling between multiple microservices or subsystems, so that the operator can complete the financial business in one financial system. For example, for a financial system composed of multiple microservices, different functions are divided into microservices according to business, responsibility and scale, and the workflow between microservices needs to be combined with manual and timing management to complete a financial business, so that the operation of the financial business still needs to consume manpower, and the operator needs to manipulate one by one according to the execution order between microservices, so that the efficiency of completing the financial business is low.

[0077] Based on this, the embodiment of the application provides a process instance processing method and device, equipment and storage medium, by setting a process instance, and multiple process nodes are set in the process instance, and each process node is responsible for starting and specific operation of the corresponding microservice. When the process node executes according to the preset node execution order, the corresponding microservice also executes the corresponding operation. Therefore, the microservice in the system automatically executes the corresponding operation without too much human participation, not only saving manpower, but also improving the execution efficiency of the business.

[0078] The process instance processing method and device, equipment and storage medium provided by the embodiment of the application are specifically described by the following embodiments. First, the process instance processing method in the embodiment of the application is described.

[0079] The embodiment of the application can acquire and process related data based on artificial intelligence technology. Among them, artificial intelligence (Artificial Intelligence, AI) is to use digital computer or digital computer controlled machine to simulate, extend and expand human intelligence, perceive environment, acquire knowledge and use knowledge to obtain the best results.

[0080] The basic technology of artificial intelligence generally includes technologies such as sensors, special artificial intelligence chips, cloud computing, distributed storage, big data processing technology, operation / interaction system, mechatronics, etc. The software technology of artificial intelligence mainly includes computer vision technology, robot technology, biometric technology, speech processing technology, natural language processing technology, and machine learning / deep learning, etc.

[0081] The process instance processing method provided by the embodiments of the present application relates to the technical field of financial technology. The process instance processing method provided by the embodiments of the present application can be applied to a terminal, can also be applied to a server side, and can also be software running in the terminal or the server side. In some embodiments, the terminal can be a smart phone, a tablet computer, a notebook computer, a desktop computer, etc.; the server side can be configured as a stand-alone physical server, can also be configured as a server cluster or a distributed system formed by multiple physical servers, and can also be configured as a cloud server providing basic cloud computing services such as cloud service, cloud database, cloud computing, cloud function, cloud storage, network service, cloud communication, middleware service, domain name service, security service, CDN, and big data and artificial intelligence platform; and the software can be an application that implements the process instance processing method, but is not limited to the above forms.

[0082] The present application can be used in many general or special computer system environments or configurations. For example: personal computers, server computers, handheld devices or portable devices, tablet devices, multi-processor systems, microprocessor-based systems, set-top boxes, programmable consumer electronics, network PCs, minicomputers, mainframe computers, distributed computing environments including any of the above systems or devices, etc. The present application can be described in the general context of computer-executable instructions executed by a computer, such as program modules. Generally, program modules include routines, programs, objects, components, data structures, etc. that perform specific tasks or implement specific abstract data types. The present application can also be practiced in a distributed computing environment in which tasks are performed by remote processing devices connected by a communication network. In a distributed computing environment, program modules can be located in local and remote computer storage media, including storage devices.

[0083] It should be noted that in each specific embodiment of the present application, when relevant processing needs to be performed on data related to the identity or characteristics of the user, such as user information, user behavior data, user history data, and user location information, the user's permission or consent will be obtained first, and the collection, use, and processing of such data will comply with relevant laws, regulations, and standards. In addition, when the embodiments of the present application need to obtain sensitive personal information of the user, the separate permission or separate consent of the user will be obtained through a pop-up window or a jump to a confirmation page, and after obtaining the separate permission or separate consent of the user, the necessary user-related data for enabling the embodiments of the present application to normally operate will be obtained.

[0084] Figure 1 is an optional flowchart of the process instance processing method provided by the embodiments of the present application, Figure 1 The method in can include but is not limited to steps S101 to S108.

[0085] Step S101, put the pre-acquired candidate process instance into a preset instance waiting queue; wherein the candidate process instance has a process priority;

[0086] Step S102, extract the candidate process instance from the instance waiting queue according to the process priority, to obtain a target process instance; wherein the target process instance includes a candidate process node and a node execution order of the candidate process node;

[0087] Step S103, execute the target process instance according to the node execution order, to obtain a target execution instance;

[0088] Step S104, acquire a candidate process node in a waiting state from the target execution instance, to obtain a target process node;

[0089] Step S105, put the target process node into a preset node waiting queue;

[0090] Step S106, extract the target process node from the node waiting queue according to the node execution order, to obtain a current process node; wherein the current process node includes a current node category and a current execution operation;

[0091] Step S107, call a preset microservice according to the current node category to execute the current execution operation, to obtain a node execution result; wherein the node execution result represents that the microservice completes or does not complete the current execution operation;

[0092] Step S108, execute the target execution instance according to the node execution result and the node execution order.

[0093] The steps S101 to S108 shown in the embodiments of the present application are as follows: after the candidate process instances are put into the instance waiting queue, the candidate process instance currently needed to be executed is extracted from the instance waiting queue as a target process instance according to the process priority of each candidate process instance. The target process instance is executed according to the node execution order in the target process instance to obtain a target execution instance, and the target execution instance represents a process instance currently being executed. Therefore, the process instance is executed according to the process priority, so that important process instances can be executed preferentially. Because the target execution instance includes multiple candidate process nodes, the candidate process nodes are first put into the node waiting queue for execution one by one. In the process of executing the target execution instance, the target process node is taken out from the node waiting queue as a current process node according to the node execution order, and the node category of the current process node is obtained to obtain a current node category. Different current node categories execute the current execution operation by the node control microservice of different categories, so the corresponding microservice is called according to the current node category to execute the current execution operation, so as to control the microservice to execute the corresponding operation. After the execution of one current process node is completed, the node execution result of the current process node is determined to judge whether the microservice completes the current execution operation according to the node execution result, and the target execution instance is continuously executed according to the node execution result and the node execution order, so that the microservice corresponding to the instance is executed automatically, and the manpower is saved. It needs to be further explained that whether each microservice is executed will determine the subsequent execution of the target execution instance, so that the instance execution is more stable.

[0094] It needs to be explained that, as Figure 2As shown, the process instance processing method is executed by a workflow engine, and the workflow engine is linked with a calling end. The workflow engine includes an instance scheduling module, an instance execution module, a node scheduling module, a node execution module, a timing module, a notification module, an instance waiting queue, and a node waiting queue. The instances or nodes are placed into corresponding waiting queues by different scheduling modules, and the corresponding instances or nodes are extracted from the waiting queues by different execution modules for execution. The instance execution module is connected with multiple microservices, so that the corresponding microservices are called for execution when the instances are executed, and the target business can be automatically executed. The traditional workflow engine is suitable for monolithic applications, distributed applications, or intensive applications, and the workflow engine manages various functional modules within the application according to pre-set business logic. Because the manipulation between different microservices or subsystems needs to be implemented by different configurations and different nodes, and the nodes of the traditional workflow engine are fixedly set, the traditional workflow engine is less suitable for the scene of multiple microservices or multiple subsystems. In the embodiment, the workflow engine including the instance scheduling module, the instance execution module, the node scheduling module, the node execution module, the timing module, and the notification module is set, different nodes can be configured to manipulate the microservices to perform corresponding operations, multiple microservices can be executed according to the execution order to complete corresponding target businesses, the business can be automatically executed, and manpower can be saved.

[0095] Before step S101 of some embodiments, the instance processing method further includes constructing a candidate process instance. It should be noted that the candidate process instance is a process instance for executing a business, and through the candidate process instance, it can be determined which microservices need to be called and which operations need to be performed by the microservices for a business.

[0096] Please refer to Figure 3 In some embodiments, constructing the candidate process instance can include, but is not limited to, steps S301 to S303:

[0097] In step S301, a business process request is acquired. The business process request includes business process data and process node information.

[0098] In step S302, a selected process instance is filtered from pre-set process instances according to the business process data.

[0099] In step S303, the selected process instance is adjusted in node order according to the process node information, and a candidate process instance is obtained.

[0100] In step S301 of some embodiments, the business process request is a request initiated by a calling end, and the business process request represents an application for a process instance associated with a target business, so as to complete the target business through the process instance. It should be noted that the calling end is connected with the workflow engine, and the workflow engine can be connected with multiple microservices or subsystems through an interface to call different microservices or subsystems to perform corresponding operations. When the calling end needs to apply for an instance, the business process request fed back from the calling end is received, and the business process request is parsed to obtain business process data and process node information. It should be noted that the business process data records the process content of the target business to be executed, and the process node information represents the information of the nodes involved in the process. Through the business process data and the process node information, it can be known which microservices or subsystems are needed to complete the target business, and what operation each process node corresponding to the microservices or subsystems needs to perform.

[0101] Specifically, the calling end forms the service flow data by sending relevant content involved in the target service. The relevant content includes interface information, execution sequence, operation information, etc. of the microservice or subsystem, and is not specifically limited. It should be noted that each microservice or subsystem is divided as a corresponding node according to the execution sequence to obtain the flow node information. For example, if the target service is to automatically update the version of M financial software and release the version update information, the relevant content is "start the execution flow, and notify the responsible personnel of the development group, wait for the responsible personnel to feedback whether to automatically update the version of M financial software, if the received instruction is passed, call the operation and maintenance platform to update the version of M financial software according to the preset update time. Then, call the system configuration platform to update the system information of M financial software. If the update of M financial software is successful, send the update success information of M financial software to the operation personnel of the development group according to the mail platform. If the update of M financial software fails, the operation and maintenance platform needs to be called to perform the version rollback operation on M financial software, and after the version rollback is completed, the mail platform needs to be called to send the update failure information to the responsible personnel of the development group". Therefore, through the relevant content, it can be determined that multiple microservices or subsystems need to be associated with each other to complete a target service. In this embodiment, after the relevant content is determined, the execution sequence of the flow node corresponding to the relevant content is: start flow → manual inquiry → timing start → operation and maintenance platform call update version → system configuration platform update system information → mail platform send update success information → end; there is also an execution sequence of the flow node corresponding to: start flow → manual inquiry → timing start → operation and maintenance platform call update version → operation and maintenance platform version rollback → mail platform send update failure information → end. It should be noted that the flow node information can be determined through the execution sequence of the flow node and the relevant content, so as to determine which microservices or subsystems need to be called to perform corresponding operations to complete the target service according to the service flow data and the flow node information.

[0102] In step S302 of some embodiments, in order to quickly build a process instance, a preset process instance is set in advance, and the preset process instance is constructed according to the general process of each process category, so the preset process instance is suitable for the process of the same process category. The business process category is determined by the business process data, and the selected process instance is selected from the preset process instance according to the business process category, so that the flow node can be adjusted in the selected process instance, without the need to construct a new process instance based on the business process data and the flow node information, saving the resources of instance construction. For example, if the business process category is determined to be the software update category according to the business process data, the preset process instance corresponding to the software update category is obtained as the selected process instance, so that the instance construction is more simple.

[0103] In step S303 of some embodiments, the process node information contains information of the nodes involved in the process and the execution order of the process nodes, so the process nodes in the selected process instance are adjusted in order according to the process node information to obtain a candidate process instance corresponding to the process nodes in the selected process instance. For example, if the preset process instance corresponding to the software update category includes: a start node→a timing node→a calling node→an end node, then the corresponding process nodes are added in the preset process instance nodes according to the actual process node information, and the execution order of the process nodes is adjusted to obtain the candidate process instance.

[0104] In steps S301 to S303 shown in the embodiment, when receiving a service process request from a calling end, the service process data and process node information are obtained by analyzing the service process request, and the service process category is determined according to the service process data. The selected process instance is filtered from the preset process instance according to the service process category to determine the general process instance of the same process category. Then, the execution order of the process nodes in the selected process instance is adjusted according to the process node information to obtain a candidate process instance, and the candidate process instance matching the requirements of the calling end is constructed to automatically complete the target service when the candidate process instance is executed.

[0105] In step S101 of some embodiments, because the workflow engine interfaces with multiple calling ends, multiple candidate process instances are generated, and each candidate process instance is put into a preset instance waiting queue according to the order of creation, so as to be extracted from the instance waiting queue when the instance is executed subsequently. It should be noted that the candidate process instance has a process priority, which represents the importance of the candidate process instance, and the process priority can be used as reference information for the execution order of the candidate process instance.

[0106] Specifically, the instance scheduling module generates a candidate process instance according to the service process request, sets the instance state of the candidate process instance to a waiting state, and puts the candidate process instance in the waiting state into a preset instance waiting queue, so as to execute the candidate process instance in order.

[0107] In some embodiments, before step S102, the instance concurrency number in the execution state needs to be obtained, and the instance concurrency number is the number of instances in the execution state. The workflow engine will pre-set a concurrency threshold, and the concurrency threshold is determined according to the performance parameters of the workflow engine. By comparing the instance concurrency number with the concurrency threshold, if the instance concurrency number is greater than the concurrency threshold, the instance concurrency number is obtained after the instance in the execution state is completed, until the instance concurrency number is less than the concurrency threshold, which indicates that the next instance can be processed.

[0108] In step S102 of some embodiments, if the instance concurrency number is less than the concurrency threshold, a candidate process instance is extracted from the instance waiting queue as a target process instance according to the process priority. It should be noted that the candidate process instance with high process priority is extracted as the target process instance, so that important instances can be completed in advance. It should be further noted that the target process instance includes a candidate process node and a node execution order of the candidate process node, and the candidate process node is used to control the preset microservice to perform a corresponding operation, i.e., a process node in the target business. Because the process nodes have a process order, the node execution order of the corresponding candidate process node is set according to the process order of the process node.

[0109] Specifically, if the instance concurrency number is less than the concurrency threshold, the instance scheduling module extracts the target process instance from the instance waiting queue according to the process priority, and sends the target process instance to the instance execution module, so that the process instances are executed according to the priority.

[0110] In step S103 of some embodiments, the target process instance is executed according to the node execution order to obtain a target execution instance. It should be noted that the target execution instance represents an instance being executed, and the instance state of the target execution instance is set to an executing state. Specifically, after the instance execution module receives the target process instance, the target process instance is executed according to the node execution order to obtain the target execution instance, and the instance state of the target execution instance is switched from the waiting state to the executing state.

[0111] In step S104 of some embodiments, when the target execution instance starts to execute, a target process node needs to be extracted from the target execution instance according to the node execution order, and the target process node is a candidate process node with a node state of the waiting state. It should be noted that the instance execution module extracts the candidate process node with the waiting state as the target process node from the target execution instance according to the node execution order.

[0112] In step S105 of some embodiments, the target process node is a candidate process node in a waiting state, and the target process node needs to be placed in the node waiting queue first to execute the corresponding target process node one by one according to the node execution order. It should be noted that before the target process node is placed in the node waiting queue, the execution progress of the target execution instance is obtained. If the execution progress is empty, it indicates that the target execution instance still has no target process node to be executed. The first target process node in the waiting state is placed in the node waiting queue according to the node execution order, and the remaining target process nodes are placed again after the first target process node is completed. Because the first target process node executed by a target execution instance is used to inquire whether the responsible person executes the target execution instance, if the target execution instance is not executed, the remaining target process nodes do not need to be placed in the node waiting queue. If the responsible person determines to execute the target execution instance, the remaining target process nodes in the target execution instance are placed in the node waiting queue, reducing the space occupation of the node waiting queue. If the execution progress is not empty, it indicates that the target process node in the target execution instance has been executed, and all the remaining target process nodes in the waiting state are placed in the node waiting queue to facilitate the execution of the target process node one by one.

[0113] It should be noted that the target process node in the waiting state is placed in the node waiting queue by the node scheduling module.

[0114] In step S106 of some embodiments, when the target process node is executed, the target process node is extracted from the node waiting queue as a current process node according to the node execution order, and the current process node is a process node that needs to be executed. It should be noted that before the current process node is extracted from the node waiting queue, it is necessary to determine whether there is an additional node execution resource. Specifically, the number of concurrent nodes in the execution state is obtained, and the number of concurrent nodes is compared with a preset node concurrency threshold, and the node concurrency threshold represents the maximum amount of process nodes that can be executed by the workflow engine at the same time. If the number of concurrent nodes is less than the node concurrency threshold, it indicates that there is an additional node execution resource, and the current process node can be extracted from the node waiting queue to execute the current process node.

[0115] Specifically, the current process node includes a current node category and a current execution operation. The current node category represents the node category of the current process node, and the current execution operation is the operation that the microservice corresponding to the current process node needs to execute. Therefore, the current node category can be used to determine which node category of the current process node controls the corresponding microservice to execute the current execution operation, so that each process node in the target business is executed accurately.

[0116] In some embodiments, the current node category includes any one of the following: a start node category, an end node category, an artificial node category, a timing node category, and a calling node category; and the current execution operation includes any one of the following: a wake-up operation, a shutdown operation, an artificial notification operation, a timing operation, and an interface calling operation. It should be noted that the start node category represents the category of the start node, and the start node is the first flow node of the target execution instance. The end node category represents the category of the end node, and the end node is the last flow node in the target execution instance. The artificial node category is the category of the artificial node, which represents the need to communicate with the person in charge of the flow node. The timing node category is the category of the timing node, which is used to set a time point in advance and control the corresponding microservice to perform the current execution operation according to the pre-set time point. The calling node category is the category of the calling node, which is used to call the interface of the microservice to make the microservice perform the corresponding operation. It should be further noted that the wake-up operation is used to wake up the microservice to make the microservice run. The shutdown operation is used to shut down the microservice to make the microservice stop running. The artificial notification operation is used to send a notification to the person in charge of the microservice. The timing operation is used to perform a certain current execution operation at a timing. The interface calling operation is used to call the interface of the microservice to perform the current execution operation on the target system through the interface connection.

[0117] In some embodiments, step S107 can include any one of the following:

[0118] Step S11, calling the microservice to perform a wake-up operation according to the start node category to obtain a start node execution result;

[0119] Step S12, calling the microservice to perform an artificial notification operation according to the artificial node category to obtain an artificial node execution result;

[0120] Step S13, calling the microservice to perform a timing operation according to the timing node category to obtain a timing node execution result;

[0121] Step S14, calling the microservice to perform an interface calling operation according to the calling node category to obtain a calling node execution result;

[0122] Step S15, calling the microservice to perform a shutdown operation according to the end node category to obtain an end node execution result.

[0123] In step S11 of some embodiments, if the current node category is the start node category, the start node category is allowed to let the microservice perform the wake-up operation so that the microservice is in a running state. Meanwhile, the start node corresponding to the start node category is subjected to execution state detection to obtain a start node result, which represents whether the microservice corresponding to the start node completes or fails to perform the wake-up operation. For example, as shown in Figure 4 the target execution instance, the start node starts to control all microservices in the target execution instance to perform the wake-up operation, so that the microservices can timely perform corresponding operations when the subsequent process nodes are executed.

[0124] In step S12 of some embodiments, if the current node category is the manual node category, the microservice corresponding to the manual node is controlled by the manual node to perform a manual notification operation to notify a responsible person of the microservice whether to continue to execute the target execution instance. Meanwhile, the microservice corresponding to the manual node is subjected to progress detection to obtain a manual node execution result, so as to determine whether the microservice completes the manual notification operation according to the manual execution result. It should be noted that the manual node generates notification information according to pre-set notification configuration information, and the microservice corresponding to the manual node is a notification module, which sends the notification information to the corresponding responsible person according to a pre-set communication address. It should be further noted that the notification configuration information includes a notifing person, a notification mode, a notification template, etc., which is set according to requirements, and is not limited in this embodiment. During the execution of the manual node, the execution state of the notification module is detected. If the execution state represents failure, the manual node execution result represents that the microservice fails to complete the manual notification operation. If the execution state represents success, i.e., the manual node execution result represents that the microservice completes the manual notification operation.

[0125] For example, as shown in Figure 4 the start node is executed, the manual node is executed. If the notifing person of the manual node is set as the responsible person of the development group, the notification mode is short message and email, and the notification template is an xx version update template. The manual node generates notification information according to the notifing person, the notification mode and the notification template, and then sends the notification information to the responsible person of the development group through the manual node control notification module, to realize automatic notification in the target business.

[0126] In step S13 of some embodiments, if the current node category is the timing node category, the timing node needs to be called to invoke the microservice to perform a timing operation, and the execution state of the microservice performing the timing operation is detected to obtain a timing node execution result. It should be noted that the timing time information is pre-set on the timing node, and the microservice corresponding to the timing node is a timing module, which triggers the next target process node according to the timing time information.

[0127] For example, as shown in Figure 4 After the artificial node is completed, the timing node is executed, and the timing node sets the timing configuration information in advance and sends the timing configuration information to the timing module, so that the next target flow node is triggered by the timing module according to the timing configuration information. It should be noted that the timing configuration information includes timing time information, and the timing time information represents a time point at which the next target flow node needs to be executed. If the timing time information is "date XXXX-XX-XX-22:00", the execution of the next target flow node needs to be triggered at "XXXX-XX-XX-22:00" to realize the timing operation.

[0128] In step S14 of some embodiments, if the current node category is the calling node category, the calling node calls the microservice to execute the interface calling operation. It should be noted that the interface calling operation is to call the operation of the target system corresponding to the microservice according to the interface calling mode. At the same time, during the execution of the calling node, the execution state of the microservice corresponding to the calling node is detected to obtain the execution result of the calling node, and the execution result of the calling node is determined according to the execution state of the microservice. Whether the microservice completes the current execution operation can be determined by the execution result of the calling node.

[0129] For example, as shown in Figure 4 After the timing node is completed, the calling node A is executed. The target business is to automatically update the version of the M financial software and publish the version update information, and the flow content of the calling node A is "calling the operation and maintenance platform to update the version of the M financial software". It can be determined that the microservice corresponding to the calling node A is the operation and maintenance platform, and the target system is the M financial software. The interface configuration information is set in advance by the calling node A, and the interface configuration information includes the interface address and the interface parameter. The calling node A calls the operation and maintenance platform according to the interface address and the interface parameter, so as to control the operation and maintenance platform to update the version of the M financial software. After the calling node A is executed, the calling node B is executed, and the flow content of the calling node B is "calling the system configuration platform to update the system information of the M financial software". Therefore, the calling node B calls the system configuration platform according to the interface address and the interface parameter, and updates the system information of the M financial software through the system configuration platform. After the calling node B is completed, the calling node C is executed. If the calling node execution result of the calling node A indicates that the operation and maintenance platform does not complete the version update, the calling node D and the calling node E are executed. It should be noted that the execution operations of the calling node C, the calling node D and the calling node E are similar, that is, the corresponding microservice is called to execute the corresponding operation through the interface configuration information, which will not be described here.

[0130] In step S15 of some embodiments, if the current node category is an end node category, the target execution instance is represented to be completed, and the current flow node is the last target flow node in the target execution instance. It should be noted that the last target flow node in the target execution instance is an end node, and the end node is executed to call the execution closing operation of all microservices in the target execution instance to automatically close after the microservices corresponding to the target execution instance complete the operation, reducing the resource loss caused by long-time standby of the microservices.

[0131] In any one of steps S11 to S15 shown in the embodiment, it is determined according to the current node category which category the current flow node belongs to, and then the corresponding flow node is executed according to the current node category, so that the flow node calls the corresponding microservice to execute the current execution operation through the preconfigured information, realizes the targeted calling of the microservice, and automatically calls multiple microservices on one system to respectively execute the current execution operation, fully automatically completes the target business, and saves manpower. At the same time, the node execution result is determined according to the execution state of the microservice executing the current operation, so as to determine whether the microservice corresponding to the current flow node completes the target execution operation according to the node execution result.

[0132] In some embodiments, please refer to Figure 5 After step S107, the flow instance processing method further includes but is not limited to steps S501 to S504:

[0133] Step S501, an instance operation request for a target execution instance is obtained; wherein the instance operation request includes: an operation category and a target execution operation;

[0134] Step S502, an instance state of the target execution instance is obtained according to the instance operation request, to obtain a current instance state;

[0135] Step S503, a node state of a target flow node is obtained according to the current instance state and the operation category, to obtain a current node state;

[0136] Step S504, the target execution operation is executed on the target flow node according to the operation category and the current node state.

[0137] In step S501 of some embodiments, when the calling end needs to change the execution of the target execution instance, an instance operation request for the target execution instance is received from the calling end, and the instance operation request represents that the target execution instance needs to be adjusted. It should be noted that the instance operation request includes: an operation category and a target execution operation, and the operation category represents the category of the target execution operation that needs to be executed on the target execution instance. Different categories of target operation categories adjust different target flow nodes in the target execution instance.

[0138] It should be noted that the operation category includes any one of the following: a pause operation category and a termination operation category, so that the target execution instance is paused or terminated according to the needs of the calling end.

[0139] In step S502 of some embodiments, the current instance state represents the instance state of the target execution instance corresponding to the instance operation request, and the current instance state affects the adjustment of the target execution instance.

[0140] In step S503 of some embodiments, after the current instance state is obtained, the node state of the target process node in the target execution instance is obtained according to the current instance state and the operation category to obtain the current node state, so that each target process node in the target execution instance is adjusted according to the current node state, and the targeted adjustment of the target process node is realized.

[0141] It should be noted that the current instance state includes any one of the following: a waiting state, a blocked state, an executing state, a pausing state, a paused state, a terminating state, and a terminated state. If the operation category is a pause operation, the current instance state is not allowed to be paused except for any one of the waiting state, the blocked state, and the executing state, so the node state of the target process node does not need to be obtained. If the operation category is a termination operation category, if the current instance state is not any one of the waiting state, the blocked state, the executing state, and the pausing state, the target execution instance cannot be terminated, and the node state of the target process node does not need to be obtained.

[0142] In step S504 of some embodiments, when it is determined that the target execution instance can be adjusted, the target execution operation is performed on the target process node in the target execution instance according to the operation category and the current node state, so that the target execution instance can be completely paused or terminated by adjusting the target process node.

[0143] In steps S501 to S504 shown in the embodiment, when the calling end needs to adjust the target execution instance, the instance state of the corresponding target execution instance is obtained according to the instance operation request sent by the calling end to obtain the current instance state. The node state of the target process node is obtained according to the current instance state and the operation category to obtain the current node state, so that the target process node in the target execution instance is adjusted according to the current node state and the operation category, and the additional target process node is still executed to make the target execution instance unable to completely execute the target execution operation.

[0144] In some embodiments, the current node state comprises any one of the following: a waiting state, a blocking state, an executing state, and a suspended state; and the target execution operation comprises any one of the following: a deletion operation, a state change operation, a suspension operation, and a termination operation. Because the execution category is the suspension operation category or the termination operation category, in order to completely suspend or terminate the target execution instance, the corresponding target execution operation needs to be performed according to the current node state of the different target process nodes, so that all the target process nodes in the target execution instance stop executing.

[0145] In some embodiments, step S504 can comprise any one of the following steps:

[0146] Step S21: performing a deletion operation on the target process node according to the suspension operation category and the waiting state;

[0147] Step S22: performing a state change operation on the target process node according to the suspension operation category and the blocking state;

[0148] Step S23: performing a suspension operation on the target process node according to the suspension operation category and the executing state;

[0149] Step S24: performing a deletion operation on the target process node according to the termination operation category and the waiting state;

[0150] Step S25: performing a termination operation on the target process node according to the termination operation category and the suspended state;

[0151] Step S26: performing a termination operation on the target process node according to the termination operation category and the executing state.

[0152] In step S21 of some embodiments, if the operation category is the suspension operation category and the current node state is the waiting state, the target process node is executed by the deletion operation, that is, the target process node in the waiting state is deleted, preventing the target process node in the waiting state from being executed subsequently and affecting the suspension operation of the target execution instance.

[0153] In step S22 of some embodiments, if the operation category is the suspension operation category and the current node state is the blocking state, the target process node in the blocking state needs to be executed by the state change operation. It should be noted that the state change operation is to change the blocking state of the target process node to the waiting state, and after the node state of the target process node is changed to the waiting state, the target process node converted to the waiting state is executed by the suspension operation, and the node state of the target process node is changed to the suspended state.

[0154] Please refer to Figure 6 For example Figure 6 The node state transition diagram of the target process node is shown in FIG. 1, which shows Figure 6It can be known that the current node state can be converted from the blocking state to the waiting state, and then the waiting state is converted to the pausing state. It should be noted that when the target process node completes the pause, the current node state is converted from the pausing state to the paused state.

[0155] In step S23 of some embodiments, if the operation category is the pause operation category and the current node category is the executing state, the pause operation needs to be performed on the target process node to pause the execution of the target process node. It should be noted that after the target process node performs the pause operation, the current node state of the target process node is converted from the executing state to the pausing state, so that whether the target process node in the target execution instance is completely paused can be determined according to the current node state, and the situation that the process of the target business continues to be reduced.

[0156] Specifically, the pause or deletion of the target process node is implemented by the node execution module. It should be further noted that, as shown in FIG. 2, the node execution module includes a pause module 21, a deletion module 22, and a termination module 23. Figure 6 It can be known that if the current node state is the executing state, it can be converted to the success state, the pausing state, the blocking state, and the failure state. It should be noted that the success state is the node state changed after the target process node is completed, and the failure state represents the node state that the target process node is not completed. The blocking state represents that the target process node execution exists a blocking situation. Therefore, the node state conversion of the target process node describes the state of the target process node during the life cycle, and the management of the life cycle of the target process node is realized, so that the manipulation of the target process node is more convenient.

[0157] In step S24 of some embodiments, if the operation category is the termination operation category and the current node state is the waiting state, the target process node is executed to perform the deletion operation, that is, the target process node in the waiting state is deleted, and the current node state is converted from the waiting state to the termination state.

[0158] Please refer to Figure 6 When the termination operation is performed on the target execution instance, if the target process node is deleted, the current node state of the target process node is converted from the waiting state to the terminated state. Therefore, when the target process node performs the operation, the current node state is updated synchronously, so that the current situation of the target process node can be determined according to the current node state.

[0159] In step S25 of some embodiments, if the operation category is the termination operation category and the current node state is the pausing state, the termination operation is directly performed on the target process node, that is, the execution of the target process node is terminated. It should be noted that please refer to Figure 6After the target process node is terminated, the current node state of the target process node needs to be converted from the suspended state to the terminating state, and then the current node state is converted from the terminating state to the terminated state after the termination of the target process node is completed.

[0160] In step S26 of some embodiments, if the operation category is the termination operation category and the current node state is the executing state, the termination operation is performed on the target process node, that is, the execution of the target process node in the executing state is terminated. Please refer to Figure 6 After the target process node in the executing state is terminated, the current node state is converted from the executing state to the terminating state, and then the current node state is converted from the terminating state to the terminated state after the termination of the target process node is completed. Therefore, the current situation of the target process node can be determined according to the current node state, so as to realize the management of the whole life cycle of the target process node according to the current node state.

[0161] In any one of steps S21 to S26 shown in the embodiment, different operations are performed on the target process node in different current node states according to different operation categories, so that the target process node can be completely suspended or terminated, and then the target execution instance can be accurately suspended or terminated. At the same time, when the target process node performs different operations, the current node state of the target process node is changed synchronously, so that the situation of the target process node can be determined according to the current node state.

[0162] In some embodiments, the operation category further includes a suspension and recovery operation category, and if the current instance state is any one of the suspended state and the suspending state, the target execution instance can be recovered according to the suspension and recovery operation, so that the remaining target process nodes of the target execution instance are recovered for execution.

[0163] In some embodiments, the node waiting queue includes a selected process node, and the selected process node is the next node of the target process node. When the target process node is executed, the next process node needs to be executed, so the next process node of the target process node is defined as the selected process node. Please refer to Figure 7 Step S108 includes but is not limited to steps S701 to S704:

[0164] In step S701, the execution position of the current process node is obtained according to the node execution order, and the node execution position is obtained. The node execution position includes: a tail position or a non-tail position.

[0165] In step S702, if the node execution result represents that the microservice completes the current execution operation, and the node execution position is the tail position, the execution of the target execution instance is stopped.

[0166] Step S703, if the node execution result represents that the microservice completes the current execution operation, and the node execution position is a non-end position, a selected flow node is extracted from the node waiting queue according to the node execution sequence, and a target execution instance is executed according to the selected flow node;

[0167] Step S704, if the node execution result represents that the microservice does not complete the current execution operation, and the node execution position is a non-end position, execution prompt information is obtained, and a target execution instance is executed according to the execution prompt information.

[0168] In step S701 of some embodiments, after the microservice is controlled to execute the current execution operation according to the current node category, it is necessary to determine whether the current flow node is the last target flow node, so as to determine whether the next target flow node needs to be executed according to the node execution result. It should be noted that the node execution sequence records the execution sequence of each target flow node, so the node execution position of the current flow node in the entire target execution instance can be determined according to the node execution sequence. It should be further noted that the node execution position includes an end position and a non-end position, so as to determine whether the current flow node is the last target flow node in the target execution instance.

[0169] In step S702 of some embodiments, when the node execution result represents that the microservice completes the current execution operation, and the node execution position is an end position, it represents that the current flow node can be normally executed, and the current flow node is an end node, so the target execution instance is stopped. It should be noted that, as shown in Figure 8 If the current flow node is an end node, the instance state of the target execution instance is switched from an executing state to a success state after the target execution instance is stopped, so that it can be determined which execution phase the target execution instance is in according to the instance state.

[0170] In step S703 of some embodiments, if the node execution result represents that the microservice completes the current execution operation, and the node execution position is a non-end position, it represents that the current flow node is successfully executed and there are other target flow nodes behind. A selected flow node needs to be extracted from the node waiting queue, and a target execution instance is executed according to the selected flow node. It should be noted that the selected flow node includes a selected node category and a selected execution operation, and the target execution instance is executed according to the selected flow node, that is, the microservice is called to execute the selected execution operation according to the selected node category of the selected flow node, and then it is determined whether the selected flow node is an end node, until all the subsequent target flow nodes are executed, and the target execution instance is completed.

[0171] In step S704 of some embodiments, if the node execution result indicates that the microservice does not complete the current execution operation, and the node execution position is a non-end position, it indicates that the current flow node execution fails and is not an end node. Therefore, the node execution failure information needs to be fed back to the calling end to receive the execution prompt information, and the execution prompt information indicates whether to continue to execute the next flow node, so as to execute the target execution instance according to the execution prompt information.

[0172] In steps S701 to S704 shown in the embodiment, whether the node execution result indicates that the microservice completes the current execution operation or not is used to determine whether the current flow node is executed normally, which will affect the execution of the subsequent target flow node. If the node execution result indicates that the microservice completes the current execution operation, it is needed to determine whether the node execution position is an end position, so as to stop or continue to execute the target execution instance, so that the execution operation of the target execution instance is more accurate. If the node execution result indicates that the microservice does not complete the current execution operation, and the node execution position is a non-end position, it is needed to confirm whether to continue to execute the target execution instance by the calling end, so that the execution operation of the target execution instance is more accurate.

[0173] Please refer to Figure 9 In some embodiments, step S704 can include but is not limited to steps S901 to S903:

[0174] In step S901, if the node execution result indicates that the microservice does not complete the current execution operation, and the node execution position is a non-end position, execution prompt information is obtained; wherein the execution prompt information includes failure ignore prompt information or failure termination prompt information.

[0175] In step S902, if the execution prompt information is the failure ignore prompt information, the selected flow node is extracted from the node waiting queue according to the node execution order, and the target execution instance of the selected flow node is executed.

[0176] In step S903, if the execution prompt information is the failure termination prompt information, the execution of the target execution instance is stopped.

[0177] In step S901 of some embodiments, when the node execution result indicates that the microservice does not complete the current execution operation, and the node execution position is a non-end position, it indicates that the current process node execution fails, and there are still target process nodes behind the current process node. Therefore, the execution failure information is fed back to the calling end, and the execution prompt information fed back by the calling end is obtained. It should be noted that the execution prompt information includes failure ignore prompt information or failure termination prompt information. The failure ignore prompt information indicates that the current process node execution failure is ignored, and the subsequent target process node is executed. The failure termination prompt information indicates that the subsequent target process node is not executed after the current process node execution fails.

[0178] In step S902 of some embodiments, if the execution prompt information is the failure ignore prompt information, the selected process node needs to be executed, and the target execution instance is executed according to the selected process node. It should be noted that the process of executing the target execution instance according to the selected process node is specifically described with reference to the description of step S703, and will not be described here.

[0179] In step S903 of some embodiments, if the execution prompt information is the failure termination information, the selected process node does not need to be executed, and the execution of the target execution instance is stopped. It should be noted that, as shown in Figure 8 When the target execution instance stops executing, the instance state of the target execution instance is converted from the execution state to the failure state. It should be further noted that the instance state of the target execution instance can be converted as shown in Figure 8 so that the execution stage of the target execution instance can be determined through the converted instance state, and the target execution instance is managed in the whole life cycle.

[0180] In steps S901 to S903 of the embodiment, when the node execution result indicates that the microservice does not complete the current execution operation, and the node execution position is a non-end position. Because the current process node execution failure may affect the execution of the subsequent target process node, the execution prompt information is obtained to determine whether to continue to execute the target execution instance according to the execution prompt information, so that the target execution instance is executed more accurately, and the execution of the subsequent instance is prevented from being affected by the target execution instance failure, which is beneficial to improve the efficiency of instance processing.

[0181] As shown in Figure 4As shown, the embodiment of the application takes the M financial software version automatic update as an example, creates a candidate process instance of A version automatic version update, and determines the execution order of the related content of the M financial software automatic version update as: starting process→manual inquiry→timing start→operation and maintenance platform calling updated version→system configuration platform updating system information→mail platform sending update success information→end; starting process→manual inquiry→timing start→operation and maintenance platform calling updated version→operation and maintenance platform performing version rollback→mail platform sending update failure information→end. Therefore, the selected process instance corresponding to software update is acquired first, and the manual node, timing node, calling node, starting node and ending node in the selected process instance are changed according to the execution order of the related content, so as to construct the node execution order as shown in Figure 4 When the starting node is executed, the starting node starts to control all microservice execution wake-up operations in the target execution instance. The manual node generates notification information according to the notified person, notification mode and notification template, and then sends the notification information to the responsible person of the development group through the manual node control notification module. Then the timing time information of the timing node is "date XXXX-XX-XX-22:00", which triggers the execution of calling node A at "XXXX-XX-XX-22:00". Calling node A is connected to the operation and maintenance platform according to the interface address and interface parameters, so as to control the operation and maintenance platform to update the version of the M financial software. After calling node A is executed, calling node B is executed, calling node B calls the system configuration platform according to the interface address and interface parameters, and updates the system information of the B software through the system configuration platform. After the completion of calling node B, calling node C is executed, and the calling node execution result of calling node A is that the operation and maintenance platform does not complete the version update, calling node D calls the operation and maintenance platform to perform the version rollback operation of the M financial software, and then calling node E calls the mail platform to notify the responsible person of the development group that the version update is not completed. Finally, the ending node is executed to call all microservice execution closing operations in the target execution instance. Therefore, the process instance is constructed in the workflow engine, and multiple process nodes in the process instance are responsible for calling the corresponding microservices, so that the interaction and control among multiple microservices are automatically realized without the need for too much human intervention, saving the manpower for completing the target business, and improving the efficiency of completing the target business.

[0182] Please refer to Figure 10 The embodiment of the application also provides a process instance processing device, which can implement the process instance processing method described above, and the device comprises:

[0183] The data acquisition module 1001 is configured to put the pre-acquired candidate process instance into a preset instance waiting queue; wherein the candidate process instance has a process priority;

[0184] The instance extraction module 1002 is configured to extract a candidate process instance from an instance waiting queue according to a process priority, to obtain a target process instance; the target process instance includes a candidate process node and a node execution order of the candidate process node;

[0185] The instance execution module 1003 is configured to execute the target process instance according to the node execution order, to obtain a target execution instance;

[0186] The target node extraction module 1004 is configured to obtain a candidate process node in a waiting state from the target execution instance, to obtain a target process node;

[0187] The node putting module 1005 is configured to put the target process node into a preset node waiting queue;

[0188] The current node extraction module 1006 is configured to extract the target process node from the node waiting queue according to the node execution order, to obtain a current process node; the current process node includes a current node category and a current execution operation;

[0189] The node calling module 1007 is configured to call a preset microservice according to the current node category to execute the current execution operation, to obtain a node execution result; the node execution result indicates that the microservice completes or does not complete the current execution operation;

[0190] The node execution module 1008 is configured to execute the target execution instance according to the node execution result and the node execution order

[0191] The specific implementation of the process instance processing apparatus is basically the same as the specific embodiments of the process instance processing method described above, and will not be repeated here.

[0192] The embodiments of the present application further provide an electronic device, which includes a memory and a processor, the memory stores a computer program, and the processor implements the process instance processing method described above when executing the computer program. The electronic device can be any intelligent terminal including a tablet computer, a vehicle-mounted computer, etc.

[0193] Please refer to Figure 11 , Figure 11 The hardware structure of the electronic device of another embodiment is illustrated, which includes:

[0194] The processor 1101 can be implemented in a general-purpose CPU (Central Processing Unit), a microprocessor, an application-specific integrated circuit (ASIC), or one or more integrated circuits, etc., and is configured to execute a related program to implement the technical solutions provided by the embodiments of the present application.

[0195] The memory 1102 can be implemented in the form of a read-only memory (ROM), a static storage device, a dynamic storage device, or a random access memory (RAM), etc. The memory 1102 can store an operating system and other application programs. When the technical solutions provided by the embodiments of the present specification are implemented by software or firmware, the related program codes are stored in the memory 1102 and are called and executed by the processor 1101 to implement the flow instance processing method of the embodiments of the present application.

[0196] The input / output interface 1103 is configured to realize information input and output.

[0197] The communication interface 1104 is configured to realize the communication interaction between the device and other devices. The communication can be realized by a wired manner (for example, a USB, a network cable, etc.) or a wireless manner (for example, a mobile network, WIFI, Bluetooth, etc.).

[0198] The bus 1105 is configured to transmit information between various components (for example, the processor 1101, the memory 1102, the input / output interface 1103, and the communication interface 1104) of the device.

[0199] The processor 1101, the memory 1102, the input / output interface 1103, and the communication interface 1104 are connected to each other through the bus 1105 to realize the communication connection between them in the device.

[0200] The embodiments of the present application also provide a computer readable storage medium, which stores a computer program. The computer program is executed by a processor to implement the above-mentioned flow instance processing method.

[0201] The memory is a non-transitory computer readable storage medium, which can be used to store non-transitory software programs and non-transitory computer executable programs. In addition, the memory can include a high-speed random access memory and can also include a non-transitory memory, such as at least one magnetic disk storage device, a flash memory device, or other non-transitory solid-state memory device. In some embodiments, the memory can optionally include a memory remotely arranged relative to the processor. These remote memories can be connected to the processor through a network. Examples of the above-mentioned network include but are not limited to the Internet, an intranet, a local area network, a mobile communication network, and a combination thereof.

[0202] The process instance processing method and device, equipment and storage medium provided by the embodiments of the present application can put a candidate process instance into an instance waiting queue first, extract a target process instance from the instance waiting queue according to a process priority, and the target process instance includes a candidate process node and a node execution order of the candidate process node, so as to execute the target process instance according to the node execution order to obtain a target execution instance in execution. A subsequent process node in a waiting state is extracted from the target execution instance as a target process node and put into a node waiting queue. When a process node needs to be executed, a current process node is extracted from the node waiting queue according to the node execution order, so as to execute the process nodes one by one in sequence. When the current process node is executed, that is, a preset microservice is controlled to execute a current execution operation according to a current node category of the current process node, so as to realize automatic execution of the microservice to obtain a node execution result, and other process nodes in the target execution instance are continuously executed according to the node execution result and the node execution order, so as to realize automatic control between different microservices, save manual intervention, save manpower for control between multiple microservices, and make the control between microservices more efficient.

[0203] The embodiments described in the embodiments of the present application are used to more clearly illustrate the technical solutions of the embodiments of the present application, and do not constitute a limitation on the technical solutions provided by the embodiments of the present application. Those skilled in the art can know that, with the evolution of technology and the appearance of new application scenarios, the technical solutions provided by the embodiments of the present application are also applicable to similar technical problems.

[0204] Those skilled in the art can understand that the technical solutions shown in the figures do not constitute a limitation on the embodiments of the present application, and can include more or fewer steps than the figures, or combine certain steps or different steps.

[0205] The device embodiments described above are only schematic, and the units illustrated as separate components can or can not be physically separate, that is, can be located in one place or distributed on multiple network units. Part or all of the modules can be selected according to actual needs to achieve the purpose of the embodiments of the present application.

[0206] Those skilled in the art can understand that all or some steps in the above disclosed method, the functions of the modules / units in the system and the equipment can be implemented as software, firmware, hardware and their appropriate combinations.

[0207] The terms "first", "second", "third", "fourth", and the like in the description and in the claims of this application, if any, are used for distinguishing between similar elements and not necessarily for describing a particular sequential or chronological order. It is to be understood that the use of the terms so termed is interchangeable under appropriate circumstances such that the embodiments of the application described herein are, for example, capable of orderly or chronological mundane operation, reverse order operation, based on circuitry availability, based on stated preference or the like, and that "default" or other orderings are thus permissible. Further, the terms "comprise", "comprising", "include", "including", and the like, are specifically intended to be open-ended. That is, references to individual steps and the like do not suhstantially exclude the presence of two or more of a given step or its integral presence in the process, method, system, article, or apparatus having been made with a wider scope. The use of notation such as "first", "second", "third", etc. does not generally limit the areas, but can be used for clarity, and merely establishes the order unless otherwise stated below.

[0208] It should be understood that, in the application, "at least one" means one or more, and "multiple" means two or more. "And / or" is used to describe the relationship between associated objects, which means that there can be three relationships, for example, "A and / or B" can mean that there are only A, only B, and A and B at the same time, where A and B can be singular or plural. The character " / " generally represents an "or" relationship between the associated objects. "At least one of the following" or the like means any combination of these items, including any combination of single or multiple items. For example, at least one of a, b or c can mean a, b, c, "a and b", "a and c", "b and c", or "a and b and c", where a, b, and c can be single or multiple.

[0209] In several embodiments provided in the application, it should be understood that the disclosed devices and methods can be implemented in other ways. For example, the device embodiments described above are only schematic, for example, the division of the above units is only a logical function division, and actual implementation can have another division manner, for example, a plurality of units or components can be combined or integrated into another system, or some features can be omitted or not executed. In addition, the coupling or direct coupling or communication connection between the displayed or discussed objects can be indirect coupling or communication connection through some interfaces, devices or units, which can be electrical, mechanical or other forms.

[0210] The units described above as separate components can or can not be physically separate, and the components shown as units can or can not be physical units, i.e. they can be located in one place or distributed on a plurality of network units. Part or all of the units can be selected according to actual needs to achieve the purpose of the embodiment.

[0211] In addition, each function unit in each embodiment of the present application can be integrated in one processing unit, or each unit can be physically present separately, or two or more units can be integrated in one unit. The integrated unit can be realized in the form of hardware or in the form of a software function unit.

[0212] When the integrated unit is realized in the form of a software function unit and sold or used as an independent product, it can be stored in a computer readable storage medium. Based on such understanding, the technical solutions of the present application, essentially or in part, or all or part of the technical solutions can be embodied in the form of a software product. The computer software product is stored in a storage medium, and includes multiple instructions used to cause a computer device (which can be a personal computer, a server, or a network device, etc.) to perform all or part of the steps of the methods in the embodiments of the present application. The foregoing storage medium includes: a U disk, a mobile hard disk, a read-only memory (ROM), a random access memory (RAM), a magnetic disk or an optical disk, and various other media that can store programs.

[0213] The preferred embodiments of the embodiments of the present application are described above with reference to the accompanying drawings, and are not intended to limit the scope of the embodiments of the present application. Any modifications, equivalent replacements and improvements made by those skilled in the art without departing from the scope and essence of the embodiments of the present application shall be within the scope of the embodiments of the present application.

Claims

1. A method for processing process instances, characterized in that, The method includes: The pre-acquired candidate process instances are placed into a preset instance waiting queue; wherein, the candidate process instances have process priorities; Candidate process instances are extracted from the instance waiting queue according to the process priority to obtain target process instances; wherein, the target process instance includes: candidate process nodes and the node execution order of the candidate process nodes; The target process instance is executed according to the execution order of the nodes to obtain the target execution instance; From the target execution instance, obtain the candidate process nodes that are in a waiting state to obtain the target process node; Place the target process node into a preset node waiting queue; The target process node is extracted from the node waiting queue according to the node execution order to obtain the current process node; wherein, the current process node includes the current node category and the current operation being executed; Based on the current node category, a preset microservice is invoked to execute the current execution operation, and a node execution result is obtained; wherein, the node execution result indicates whether the microservice has completed or not completed the current execution operation; The target execution instance is executed according to the execution result of the node and the execution order of the node. After the step of calling a preset microservice to execute the current execution operation according to the current node category and obtaining the node execution result, the method further includes: Obtain an instance operation request for the target execution instance; wherein, the instance operation request includes: operation category and target execution operation; Based on the instance operation request, obtain the instance status of the target execution instance to get the current instance status; The node status of the target process node is obtained based on the current instance status and the operation category, thus obtaining the current node status; Execute the target execution operation on the target process node according to the operation category and the current node status; The operation category includes any one of the following: pause operation category and terminate operation category; the current node state includes any one of the following: waiting state, blocked state, executing state, paused state; the target execution operation includes: delete operation, state change operation, pause operation, and terminate operation; the execution of the target execution operation on the target process node according to the operation category and the current node state includes any one of the following: The deletion operation is performed on the target process node according to the pause operation category and the waiting status. Perform the state change operation on the target process node according to the pause operation category and the blocking state; The pause operation is performed on the target process node according to the pause operation category and the execution status; The deletion operation is performed on the target process node according to the termination operation category and the waiting status. The termination operation is performed on the target process node according to the termination operation category and the paused status. The termination operation is performed on the target process node according to the termination operation category and the execution status.

2. The method according to claim 1, characterized in that, The current node category includes any one of the following: start node category, end node category, manual node category, scheduled node category, and calling node category; the current execution operation includes any one of the following: wake-up operation, shutdown operation, manual notification operation, scheduled operation, and interface call operation; the step of calling a preset microservice according to the current node category to execute the current execution operation and obtain the node execution result includes any one of the following: The microservice is invoked to perform the wake-up operation according to the starting node category, and the execution result of the starting node is obtained; Based on the category of the human node, the microservice is invoked to execute the human notification operation, and the execution result of the human node is obtained; The microservice is invoked according to the timed node category to execute the timed operation, and the execution result of the timed node is obtained. The microservice is invoked to perform the interface call operation according to the call node category, and the execution result of the call node is obtained; The microservice is invoked to perform the shutdown operation according to the end node category, and the execution result of the end node is obtained.

3. The method according to claim 1, characterized in that, The node waiting queue includes selected process nodes, which are the next nodes after the target process node. The step of executing the target execution instance based on the node execution results and the node execution order includes: The execution position of the current process node is obtained according to the execution order of the nodes, thus obtaining the node execution position; wherein, the node execution position includes: the end position or a non-end position; If the node execution result indicates that the microservice has completed the current execution operation, and the node execution position is the end position, then the execution of the target execution instance is stopped. If the node execution result indicates that the microservice has completed the current execution operation, and the node execution position is not the end position, then the selected process node is extracted from the node waiting queue according to the node execution order, and the target execution instance is executed according to the selected process node; If the node execution result indicates that the microservice has not completed the current execution operation, and the node execution position is not the end position, then an execution prompt message is obtained, and the target execution instance is executed according to the execution prompt message.

4. The method according to claim 3, characterized in that, If the node execution result indicates that the microservice has not completed the current execution operation, and the node execution position is not the end position, then execution prompt information is obtained, and the target execution instance is executed according to the execution prompt information, including: If the execution result of the node indicates that the microservice has not completed the current execution operation, and the execution position of the node is not the end position, then the execution prompt information is obtained; wherein, the execution prompt information includes: failure ignore prompt information or failure termination prompt information; If the execution prompt information is the failure ignore prompt information, then the selected process node is extracted from the node waiting queue according to the node execution order, and the target execution instance is executed according to the selected process node; If the execution prompt message is the failure termination prompt message, then the execution of the target execution instance will be stopped.

5. The method according to any one of claims 1 to 4, characterized in that, Before placing the pre-acquired candidate process instances into a preset instance waiting queue, the method further includes: Obtain a business process request; wherein, the business process request includes: business process data and process node information; Selected process instances are filtered from preset process instances based on the business process data; The node order of the selected process instance is adjusted according to the process node information to obtain the candidate process instance.

6. A process instance processing apparatus, characterized in that, The apparatus, applied to the process instance processing method according to any one of claims 1 to 5, comprises: The data acquisition module is used to place pre-acquired candidate process instances into a preset instance waiting queue; wherein, the candidate process instances have process priorities; The instance extraction module is used to extract candidate process instances from the instance waiting queue according to the process priority to obtain a target process instance; wherein, the target process instance includes: candidate process nodes and the node execution order of the candidate process nodes; The instance execution module is used to execute the target process instance according to the execution order of the nodes to obtain the target execution instance; The target node extraction module is used to obtain candidate process nodes in a waiting state from the target execution instance to obtain the target process node; The node placement module is used to place the target process node into a preset node waiting queue; The current node extraction module is used to extract the target process node from the node waiting queue according to the node execution order to obtain the current process node; wherein, the current process node includes the current node category and the currently executed operation; The node invocation module is used to invoke a preset microservice to execute the current execution operation according to the current node category, and obtain the node execution result; wherein, the node execution result indicates whether the microservice has completed or not completed the current execution operation; The node execution module is used to execute the target execution instance according to the node execution result and the node execution order.

7. An electronic device, characterized in that, The electronic device includes a memory and a processor, the memory storing a computer program, and the processor executing the computer program to implement the process instance processing method according to any one of claims 1 to 5.

8. A computer-readable storage medium storing a computer program, characterized in that, When the computer program is executed by a processor, it implements the process instance processing method according to any one of claims 1 to 5.

Citation Information

Patent Citations

  • Workflow-based task scheduling method and system

    CN118469474A

  • Workflow processing method, electronic device, and storage medium

    US20240311179A1