CN114169801A - Workflow scheduling method and device - Google Patents

Workflow scheduling method and device Download PDF

Info

Publication number
CN114169801A
CN114169801A CN202111618927.8A CN202111618927A CN114169801A CN 114169801 A CN114169801 A CN 114169801A CN 202111618927 A CN202111618927 A CN 202111618927A CN 114169801 A CN114169801 A CN 114169801A
Authority
CN
China
Prior art keywords
instance
node
task
task node
workflow
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202111618927.8A
Other languages
Chinese (zh)
Inventor
林俊
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
China Construction Bank Corp
Original Assignee
China Construction Bank Corp
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by China Construction Bank Corp filed Critical China Construction Bank Corp
Priority to CN202111618927.8A priority Critical patent/CN114169801A/en
Publication of CN114169801A publication Critical patent/CN114169801A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06QINFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
    • G06Q10/00Administration; Management
    • G06Q10/06Resources, workflows, human or project management; Enterprise or organisation planning; Enterprise or organisation modelling
    • G06Q10/063Operations research, analysis or management
    • G06Q10/0631Resource planning, allocation, distributing or scheduling for enterprises or organisations
    • G06Q10/06311Scheduling, planning or task assignment for a person or group
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06QINFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
    • G06Q10/00Administration; Management
    • G06Q10/06Resources, workflows, human or project management; Enterprise or organisation planning; Enterprise or organisation modelling
    • G06Q10/063Operations research, analysis or management
    • G06Q10/0633Workflow analysis
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06QINFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
    • G06Q10/00Administration; Management
    • G06Q10/10Office automation; Time management
    • G06Q10/103Workflow collaboration or project management

Landscapes

  • Business, Economics & Management (AREA)
  • Human Resources & Organizations (AREA)
  • Engineering & Computer Science (AREA)
  • Strategic Management (AREA)
  • Entrepreneurship & Innovation (AREA)
  • Economics (AREA)
  • Tourism & Hospitality (AREA)
  • Marketing (AREA)
  • Operations Research (AREA)
  • Quality & Reliability (AREA)
  • Physics & Mathematics (AREA)
  • General Business, Economics & Management (AREA)
  • General Physics & Mathematics (AREA)
  • Theoretical Computer Science (AREA)
  • Game Theory and Decision Science (AREA)
  • Development Economics (AREA)
  • Educational Administration (AREA)
  • Data Mining & Analysis (AREA)
  • Management, Administration, Business Operations System, And Electronic Commerce (AREA)

Abstract

The invention discloses a workflow scheduling method and a workflow scheduling device, and relates to the technical field of resource scheduling. One embodiment of the method comprises: loading a pre-drawn graphic process model, and generating a process instance corresponding to the graphic process model; the process example comprises at least one task node; determining a current task node of the process instance, creating a task instance for the current task node, and sending the created task instance to a predetermined processing role terminal of the task instance; acquiring processing result data returned by the processing role terminal; and when the processing result data represents that the task of the current task node is completed, determining the next task node of the process instance, and recording related data of the current task node in a preset process flow transfer table. The implementation method can improve the monitoring granularity and the monitoring performance in the workflow system based on the flow circulation table, thereby meeting the data security requirement of the workflow system.

Description

Workflow scheduling method and device
Technical Field
The present invention relates to the technical field of resource scheduling, and in particular, to a method and an apparatus for workflow scheduling.
Background
In order to facilitate each level of organization to strengthen supervision of daily business process, grasp latest completion condition of business in real time and facilitate related business work of all levels of related business parties, the functions can be gradually optimized and displayed through a service end system related to a workflow engine, so that employees are liberated from the existing daily complicated work, and a set of workflow integrating multitask, multiple judgment conditions and multiple scheduling strategies is formed.
The workflow engine is a part of an application system, provides a core solution with decision function for each application system, can decide information transmission routes, content levels and the like according to different roles, division of labor and conditions, and comprises important functions of node management, flow direction management, process sample management and the like of a process.
In the process of implementing the invention, the inventor finds that the prior art has at least the following problems: in the existing workflow engine, the workflow engine mainly focuses on the flow circulation, the monitoring of each flow node is easy to lose control, the monitoring granularity and the monitoring performance are low, and the data security requirement of a workflow system cannot be met.
Disclosure of Invention
In view of this, embodiments of the present invention provide a method and an apparatus for workflow scheduling, which can improve monitoring granularity and monitoring performance in a workflow system based on a flow chart, so as to meet a data security requirement of the workflow system.
To achieve the above object, according to one aspect of the present invention, a workflow scheduling method is provided.
The workflow scheduling method of the embodiment of the invention comprises the following steps: loading a pre-drawn graphic process model, and generating a process instance corresponding to the graphic process model; wherein, the process instance comprises at least one task node; determining a current task node of the process instance, creating a task instance for the current task node, and sending the created task instance to a predetermined processing role terminal of the task instance; acquiring processing result data returned by the processing role terminal; and when the processing result data represents that the task of the current task node is completed, determining the next task node of the process instance, and recording related data of the current task node in a preset process flow transfer table.
Optionally, the generating a process instance corresponding to the graphical process model includes: and generating a process instance corresponding to the graphic process model based on the input initialized service data and the loaded graphic process model.
Optionally, the process instance further includes at least one routing node, where the routing node includes at least one of: serial routing nodes, parallel routing nodes, aggregation routing nodes, conditional routing nodes, and hop routing nodes.
Optionally, the determining a next task node of the process instance includes: when the next node of the current task node is a conditional routing node, acquiring the discrimination data required by the conditional routing node; and selecting a path of the conditional routing node according to the judging data, and determining the task node which is not completed and closest to the path as the next task node of the process instance.
Optionally, the relevant data of the current task node includes at least one of the following: the identification of the current task node, the latest state, the identification of the processing role and the processing result data.
Optionally, the method further comprises: and monitoring the execution process of the process instance according to the record in the process flow transfer table.
Optionally, the method further comprises: after the determining a next task node for the process instance, a task instance is created for the next task node.
Optionally, the loading a pre-drawn graphics process model includes: trying to load a pre-drawn graphic process model from a preset cache; and when the loading from the cache fails, loading the graphic process model from a preset database.
Optionally, the processing result data includes: and the mark and the service mark of the corresponding graphic flow model and the processing result of the processing role terminal to the task instance of the current task node.
Optionally, the method further comprises: after the processing result data returned by the processing role terminal is obtained, a process instance corresponding to the processing result is determined according to the identifier of the graph process model and the service identifier in the processing result data, and a task node corresponding to the processing result is determined in the process instance.
To achieve the above object, according to another aspect of the present invention, a workflow scheduling apparatus is provided.
The workflow scheduling device of the embodiment of the invention comprises: a flow instance generation unit configured to: loading a pre-drawn graphic process model, and generating a process instance corresponding to the graphic process model; wherein, the process instance comprises at least one task node; a task instance execution unit to: determining a current task node of the process instance, creating a task instance for the current task node, and sending the created task instance to a predetermined processing role terminal of the task instance; a scheduling and recording unit for: acquiring processing result data returned by the processing role terminal; and when the processing result data represents that the task of the current task node is completed, determining the next task node of the process instance, and recording related data of the current task node in a preset process flow transfer table.
Optionally, the relevant data of the current task node includes at least one of the following: the identification, the latest state, the processing role identification and the processing result data of the current task node; the scheduling and recording unit is further configured to: and monitoring the execution process of the process instance according to the record in the process flow transfer table.
To achieve the above object, according to still another aspect of the present invention, there is provided an electronic apparatus.
An electronic device of the present invention includes: one or more processors; and the storage device is used for storing one or more programs, and when the one or more programs are executed by the one or more processors, the one or more processors realize the workflow scheduling method provided by the invention.
To achieve the above object, according to still another aspect of the present invention, there is provided a computer-readable storage medium.
A computer-readable storage medium of the present invention has stored thereon a computer program which, when executed by a processor, implements the workflow scheduling method provided by the present invention.
To achieve the above object, according to still another aspect of an embodiment of the present invention, there is provided a computer program product.
The computer program product of the embodiment of the present invention includes a computer program, and when the computer program is executed by a processor, the method for scheduling a workflow provided by the embodiment of the present invention is implemented.
According to the technical scheme of the invention, the embodiment of the invention has the following advantages or beneficial effects: firstly, loading a pre-drawn graphic process model, and generating a process instance corresponding to the graphic process model; wherein, the process instance comprises at least one task node; then, determining a current task node of the process instance, creating a task instance for the current task node, and sending the created task instance to a predetermined processing role terminal of the task instance; then, processing result data returned by the processing role terminal is obtained; when the processing result data indicates that the task of the current task node is completed, determining a next task node of the process instance, and recording related data of the current task node in a preset process flow transfer table, where the related data may include: the identification of the current task node, the latest state of the current task node, the processing role identification of the current task node, the processing result data returned to the workflow system by the processing role identification of the current task node, and the associated data of the upper node and the lower node. Through the steps, real-time comprehensive recording of each execution action in the workflow system can be realized based on the flow chart, so that powerful monitoring of the whole service life cycle of the workflow is realized, and the operation condition and related data of the whole workflow system can be comprehensively checked afterwards. In addition, the workflow scheduling method and the workflow scheduling device have the advantages of simplicity, easiness in use and low code development, and can be flexibly adjusted according to actual service requirements, so that the current service requirements can be met quickly.
Further effects of the above-mentioned non-conventional alternatives will be described below in connection with the embodiments.
Drawings
The drawings are included to provide a better understanding of the invention and are not to be construed as unduly limiting the invention. Wherein:
FIG. 1 is a schematic diagram illustrating the main steps of a workflow scheduling method according to an embodiment of the present invention;
FIG. 2 is a schematic diagram of the internal structure of a workflow engine according to an embodiment of the invention;
FIG. 3 is a workflow process diagram of an embodiment of the invention;
FIG. 4 is a schematic diagram of workflow initialization for an embodiment of the present invention;
FIG. 5 is a schematic diagram of workflow intermediate node execution logic according to an embodiment of the invention;
FIG. 6 is a schematic diagram of a component of a workflow scheduling apparatus according to an embodiment of the present invention;
FIG. 7 is an exemplary system architecture diagram in which embodiments of the present invention may be employed;
fig. 8 is a schematic structural diagram of an electronic device for implementing the workflow scheduling method in the embodiment of the present invention.
Detailed Description
Exemplary embodiments of the present invention are described below with reference to the accompanying drawings, in which various details of embodiments of the invention are included to assist understanding, and which are to be considered as merely exemplary. Accordingly, those of ordinary skill in the art will recognize that various changes and modifications of the embodiments described herein can be made without departing from the scope and spirit of the invention. Also, descriptions of well-known functions and constructions are omitted in the following description for clarity and conciseness.
It should be noted that the embodiments of the present invention and the technical features of the embodiments may be combined with each other without conflict.
Fig. 1 is a schematic diagram of main steps of a workflow scheduling method according to an embodiment of the present invention.
As shown in fig. 1, the workflow scheduling method according to the embodiment of the present invention may be specifically executed according to the following steps:
step S101: loading a pre-drawn graphic process model, and generating a process instance corresponding to the graphic process model; the process instance comprises at least one task node.
The workflow scheduling method of the embodiment of the present invention may be executed by a workflow engine, and the workflow engine and a corresponding workflow system are first described below.
In order to solve the problem of orderly execution and reasonable scheduling of each task in practical application, the workflow engine is adopted to formulate a related flow and control the execution tasks, the execution sequence and the execution conditions of each terminal and the related system according to the related flow, so that each related system is decoupled, the original flow control strategy is simplified, and the possible data disorder of each related system is avoided. Since the workflow engine may be part of an application system, the workflow engine and associated task scheduling and execution modules may be collectively referred to as a workflow system.
The basic concept of a workflow system is presented below. The workflow refers to a calculation model of the workflow, namely the display of logic and rules which are organized together before and after work in the workflow in a proper model in a computer, and the main problems to be solved are as follows: the process of transferring documents, information or tasks between multiple participants according to some predefined rules is automated to achieve some desired business goal. The workflow engine is a core solution which is provided by the workflow for each service system, has a decision function, and determines information transmission routes and content levels according to different roles, division of labor and conditions.
The workflow engine activti is explained below as an example. It should be understood that the workflow engine used in the embodiment of the present invention is not limited to Activiti, and may be other workflow engines, and may also be a self-developed workflow engine.
Activiti is a workflow engine, which realizes the specification of a business Process Model and a symbol BPMN (Business Process Model and Notation)2.0, can issue a designed Process definition, and carries out Process scheduling through an application program interface. Activiti is taken as an open source platform for workflow and business process management complying with Apache (a server software) license, and the core of the platform is a fast and stable BPMN2.0 process engine based on Java (a programming language), so that the embeddability and the expandability of process services are emphasized.
When the Activiti is used for development, firstly, a graphic flow can be drawn by using a primitive symbol described by BPMN, then the flow is deployed in a workflow engine, and finally the flow is executed. The flowchart of activti may include task nodes, gateway nodes, and connecting lines between nodes. The method comprises the steps that a triggering condition can be set on a connecting line, task nodes comprise notification nodes and execution nodes, the notification nodes are automatically completed after a task is created, and the execution nodes are determined to be completed after a task completion message is received. The shape of the task node in the flowchart is generally a rectangle, and the shape of the gateway node in the flowchart is generally a diamond. The gateway nodes may include an exclusive gateway, a parallel gateway, an inclusive gateway, and an event-based gateway. Wherein, the interior of the exclusive gateway is generally an 'X' icon for condition judgment in the process; when the flow is executed to the exclusive gateway, all the outgoing sequential flows are processed, wherein the sequential flow with the condition of being resolved as true is selected, and the flow is allowed to continue to run. Inside the parallel gateway is typically a "plus" icon that allows the flow to be split into multiple branches, or multiple branches can be aggregated together. The interior of the gateway is generally a circle icon which can be regarded as a combination of an exclusive gateway and a parallel gateway; as with the exclusive gateway, conditions may be defined on the include gateway egress sequenced flows that the include gateway resolves, but the main difference between the include gateway and the exclusive gateway is that the include gateway can select more than one sequenced flow, as with the parallel gateway.
When the flow created in activti proceeds to a task node, a task instance is created, each task instance having a unique ID as an identifier. After the task is created, the workflow system sends a message to the message bus through the message queue, where the message contains an event code for determining an interface of the related business system, process information (e.g., process type, process identifier, process name, etc.), task information (e.g., type, identifier, name, etc. of the task node), and task instance information (i.e., business information required by the business system to execute the task), and then the related business system receives the message and starts to execute the corresponding task. If the task node is a notification node, the workflow system automatically ends the task and continues to execute the next node after sending the message; if the task type is an execution type node, the workflow system needs to acquire execution result data of the service system (the execution result data is returned to the workflow system by the service system through a message bus and a message queue) and then execute the next node.
The above is the main working mode of Activiti, and the present invention optimizes the existing workflow engine represented by Activiti through the self-developed workflow engine.
In step S101, the graphic flow model is first drawn by the staff member and saved in the database after the drawing is completed. When the workflow engine is started, a plurality of drawn graphic process models in the database can be stored in a cache, and then when the workflow engine needs to load the graphic process models, the graphic process models which are drawn in advance can be tried to be loaded from the cache; and when the loading from the cache fails, loading the graphic process model from a preset database, thereby realizing the quick loading and use of the graphic process model.
As a preferred scheme, after the loading of the graphical process model is successful, the workflow engine may generate a process instance corresponding to the graphical process model based on the initialized business data input by the staff and the loaded graphical process model. It is to be understood that the above process instances refer to workflow instances associated with specific businesses, and that the following steps will be performed based on the generated process instances.
Step S102: and determining a current task node of the process instance, creating a task instance for the current task node, and sending the created task instance to a predetermined processing role terminal of the task instance.
In this step, starting from the initial task node of the process instance, each task node may be sequentially determined as the current task node according to the completion condition of the task. After determining the current task node, a corresponding task instance may be created and sent to a corresponding processing role terminal.
Step S103: acquiring processing result data returned by the processing role terminal; and when the processing result data represents that the task of the current task node is completed, determining the next task node of the process instance, and recording related data of the current task node in a preset process flow transfer table.
In this step, after the processing role of the processing role terminal executes a certain action, the workflow engine may first obtain processing result data returned by the processing role terminal, where the processing result data may include: and the mark and the service mark of the corresponding graphic flow model and the processing result of the processing role terminal to the task instance of the current task node.
After the processing result data is obtained, a process instance corresponding to the processing result may be determined according to the identifier of the graph process model and the service identifier in the processing result data, and a task node corresponding to the processing result may be determined in the process instance.
Thereafter, the next task node of the process instance may be determined, specifically: firstly, when the next node of the current task node is a conditional routing node, acquiring the discrimination data required by the conditional routing node; and then, selecting a path of the conditional routing node according to the judging data, and determining an unfinished task node closest to the path as a next task node of the process instance.
Wherein, the above routing node belongs to a node in the process instance and is different from the task node, and the routing node includes at least one of the following: serial routing nodes, parallel routing nodes, aggregation routing nodes, conditional routing nodes, and hop routing nodes.
Specifically, the serial routing node represents a routing node that sequentially executes related tasks, the parallel routing node represents a routing node that processes traffic in a parallel manner, the aggregation routing node means that a plurality of branches need to be aggregated into a complete flow, the conditional routing node represents a routing node that performs path selection according to specific conditions, and the hop node represents a routing node that can skip one or more intermediate steps when certain conditions are met. In addition, there are also rollback operations, retirement operations, and related sub-flows in the flow instance. The return means that the former processor needs to re-handle due to some conditions, and the withdrawal means that the processor needs to modify the handled service, so that the next node is recovered, and the sub-process is subordinate to the main process, so that the network workflow process is realized.
After determining the next task node of the process instance, a task instance may be created for the next task node, and similar processing steps may be performed by the corresponding processing role terminal.
Particularly, in the embodiment of the present invention, if the processing of the current task node is completed, the workflow engine may record the relevant data of the current task node in a preset flow chart. The above related data may include: the identifier, the latest state, the processing role identifier and the processing result data of the current task node can also comprise the related information of the previous node and the next node.
And then, the workflow engine can monitor the execution process of the process instance according to the record in the process flow transfer table, thereby overcoming the condition that the existing workflow engine has omission in node and data monitoring and ensuring the data safety of the workflow execution process.
Fig. 2 is a schematic diagram of an internal structure of a workflow engine according to an embodiment of the present invention, and as shown in fig. 2, the workflow engine may call an external interface to obtain or provide related data, and complete task scheduling and ordered execution of related processes by interacting with an external process instance library (for storing various process instances), a process definition library (for drawing a graphic process model), and a process history library (for storing process instances used during a history period).
The workflow engine may include: the system comprises an engine controller, a process resolver, a rule manager, a condition resolver and a task executor. The engine controller is a core for realizing workflow process control, maintains the states of the process instance and the task instance, and calls related modules to carry out cooperative processing on the process according to an external request or an internal event, so that the process control is realized.
The flow parser is used for loading the graphic flow model. In the modeling phase, a user abstracts the business process into various entities in the workflow using a modeling tool, and finally persists into a database. The workflow engine may load the process model into a cache when it is started. When the workflow engine executes calling, the workflow engine can firstly call the flow model in the cache, and if the calling fails, the workflow engine inquires the database and loads the flow model into the cache.
The rule manager is used for realizing service rule control and routing of each node, the condition resolver is used for executing condition judgment of the condition routing node, and the task distributor is used for creating a specific task instance and associating the specific task instance with a specific processing role.
Fig. 3 is a schematic diagram of a workflow process according to an embodiment of the present invention, referring to fig. 3. The workflow processing process of the embodiment of the invention can be divided into a business processing part, a workflow processing part and a flow definition part, wherein the workflow processing part is the core of the business processing part, the workflow processing part and the flow definition part. Specifically, the workflow processing part is responsible for generating and executing task instances (i.e., "executing activities" in fig. 3), performing flow analysis and recording related historical data, and meanwhile, is responsible for sending to-do task events to the business processing part. The business processing part, namely the terminal where the staff is located, can start the process under the support of the business database according to specific application logic, and can complete the business to be handled according to the request of the workflow processing part. The flow definition part is used for executing various specific graphic flow definitions based on the flow model base so as to support the flow analysis link of the workflow processing part.
In practical application, a worker defines a graphic flow model in a flow model library in advance, when a flow is started, the worker performs initialization based on data in a service database, then a workflow engine performs flow analysis and processing of each task node (including submitting tasks to be handled by corresponding workers), and records related data in a flow transfer table after the processing of any task node is completed.
Fig. 4 is a schematic diagram of workflow initialization of an embodiment of the present invention, see fig. 4. After the process instance is started, the workflow engine firstly queries a process instance table (the table is related to the process instance and updates the latest task node in the process instance in sequence according to the task execution condition), the input data can be a graphic process model identifier, a service identifier and other related service information, and the output data can be a process instance identifier. If the initial task node exists in the flow instance table, the subsequent processing (i.e., the processing flow shown in fig. 5) is executed. If it is determined that the initial task node does not exist in the process instance table, the workflow role table (which is used to determine the processing roles of the nodes of the instance process) is first queried to determine the current processing role (the input data may be the process instance identifier and the current task node identifier, and the output data may be the processing role information), the initial task node is then generated according to the current processing role, the initial task node is finally updated to the process instance table, and then the process shown in fig. 5 is executed.
Fig. 5 is a schematic diagram of the workflow intermediate node execution logic according to an embodiment of the present invention, referring to fig. 5. After the intermediate node executes a certain action, the workflow engine firstly determines a corresponding process instance (the input data can be a graphic process model identifier and a service identifier, and the output data can be a process instance identifier) by querying a process instance table, then determines a current task node (the input data can be a process instance identifier, and the output data can be a current task node identifier) by querying a workflow routing table, and then judges the type of the current task node: if the current task node is an intermediate node, recording in the flow transfer table so as to update the flow transfer table, wherein the recorded data, namely the related data of the current task node, comprises the following steps: the identification of the corresponding graphic process model, the service identification, the process instance identification, the current task node identification, the latest state of the current task node, the processing role identification and the specific processing result of the processing role terminal to the task instance of the current task node. Thereafter, the next task node (the input data may be the process instance identifier and the current task node identifier, and the output data may be the next task node identifier) may be determined by querying the workflow role table, and finally the next task node is updated in the process instance table; if the current task node is the end node, only the operation of updating the flow circulation table and the flow instance table is needed to be executed because the next task node does not exist. In addition, if the result of querying the flow instance table for the first time is empty, which indicates that an exception occurs, at this time, a related normal task node may be generated and the flow instance table may be updated.
The following description relates to a specific embodiment of the present invention with respect to banking affiliation.
Firstly, a salesman of a sales agent initiates a product reporting flow, a graphic flow model in a cache or a database is loaded to a workflow engine, product reporting flow data is initialized to form a flow example, and a task distributor creates a proxy task according to the initialized data and the flow example.
Then, the sponsor auditor logs in the office application, executes the sponsor query, can view the sponsor task, can pick up the to-be-processed task, and executes the approval or the return operation on the sponsor task.
If yes, the condition analyzer judges the selection path of the condition route according to the relevant parameters, the rule manager judges the next task node of the process instance, the relevant data of the previous node is recorded in the process flow conversion table, and the task distributor creates the proxy task of the next node.
If the return operation is executed, the rule manager controls the process to return to the previous node and records the relevant data in the process flow transfer table.
Thereafter, the bank employee queries the agent for the alternative task, and receives the alternative task, which may perform an approval operation or a return operation on the alternative task.
If yes, the condition analyzer judges the selection path of the condition route according to the relevant parameters, the rule manager judges the next task node of the process instance, the relevant data of the previous node is recorded in the process flow conversion table, and the task distributor creates the proxy task of the next node. And if the rule manager judges that the process is finished, determining that the process instance is executed completely.
If the execution is the return operation, the rule manager controls the process to return to the previous node, records related data in the process flow transfer table, and resets the proxy task to be in an uncollected state.
In the technical scheme of the embodiment of the invention, firstly, a pre-drawn graphic process model is loaded to generate a process instance corresponding to the graphic process model; wherein, the process instance comprises at least one task node; then, determining a current task node of the process instance, creating a task instance for the current task node, and sending the created task instance to a predetermined processing role terminal of the task instance; then, processing result data returned by the processing role terminal is obtained; when the processing result data indicates that the task of the current task node is completed, determining a next task node of the process instance, and recording related data of the current task node in a preset process flow transfer table, where the related data may include: the identification of the current task node, the latest state of the current task node, the processing role identification of the current task node, the processing result data returned to the workflow system by the processing role identification of the current task node, and the associated data of the upper node and the lower node.
Through the steps, real-time comprehensive recording of each execution action in the workflow system can be realized based on the flow chart, so that powerful monitoring of the whole service life cycle of the workflow is realized, and the operation condition and related data of the whole workflow system can be comprehensively checked afterwards. In addition, the workflow scheduling method and the workflow scheduling device have the advantages of simplicity, easiness in use and low code development, and can be flexibly adjusted according to actual service requirements, so that the current service requirements can be met quickly.
It should be noted that, for the convenience of description, the foregoing method embodiments are described as a series of acts, but those skilled in the art will appreciate that the present invention is not limited by the order of acts described, and that some steps may in fact be performed in other orders or concurrently. Moreover, those skilled in the art will appreciate that the embodiments described in the specification are presently preferred and that no acts or modules are necessarily required to implement the invention.
To facilitate a better implementation of the above-described aspects of embodiments of the present invention, the following also provides relevant means for implementing the above-described aspects.
Referring to fig. 6, a workflow scheduling apparatus 600 according to an embodiment of the present invention may include: a flow instance generating unit 601, a task instance executing unit 602, and a scheduling and recording unit 603.
The process instance generating unit 601 may be configured to: loading a pre-drawn graphic process model, and generating a process instance corresponding to the graphic process model; wherein, the process instance comprises at least one task node; the task instance execution unit 602 may be configured to: determining a current task node of the process instance, creating a task instance for the current task node, and sending the created task instance to a predetermined processing role terminal of the task instance; the scheduling and recording unit 603 may be configured to: acquiring processing result data returned by the processing role terminal; and when the processing result data represents that the task of the current task node is completed, determining the next task node of the process instance, and recording related data of the current task node in a preset process flow transfer table.
In an embodiment of the present invention, the relevant data of the current task node includes at least one of the following: the identification, the latest state, the processing role identification and the processing result data of the current task node; the scheduling and recording unit 603 may be further configured to: and monitoring the execution process of the process instance according to the record in the process flow transfer table.
As a preferred solution, the process example generating unit 601 may further be configured to: and generating a process instance corresponding to the graphic process model based on the input initialized service data and the loaded graphic process model.
Preferably, the process instance further includes at least one routing node, and the routing node includes at least one of the following: serial routing nodes, parallel routing nodes, aggregation routing nodes, conditional routing nodes, and hop routing nodes.
In a specific application, the scheduling and recording unit 603 may further be configured to: when the next node of the current task node is a conditional routing node, acquiring the discrimination data required by the conditional routing node; and selecting a path of the conditional routing node according to the judging data, and determining the task node which is not completed and closest to the path as the next task node of the process instance.
In practical applications, the scheduling and recording unit 603 may further be configured to: after the determining a next task node for the process instance, a task instance is created for the next task node.
In some embodiments, the flow instance generation unit 601 may be further configured to: trying to load a pre-drawn graphic process model from a preset cache; and when the loading from the cache fails, loading the graphic process model from a preset database.
In an optional implementation manner, the processing result data includes: and the mark and the service mark of the corresponding graphic flow model and the processing result of the processing role terminal to the task instance of the current task node.
Furthermore, in the embodiment of the present invention, the scheduling and recording unit 603 may further be configured to: after the processing result data returned by the processing role terminal is obtained, a process instance corresponding to the processing result is determined according to the identifier of the graph process model and the service identifier in the processing result data, and a task node corresponding to the processing result is determined in the process instance.
According to the technical scheme of the embodiment of the invention, firstly, a pre-drawn graphic process model is loaded, and a process instance corresponding to the graphic process model is generated; wherein, the process instance comprises at least one task node; then, determining a current task node of the process instance, creating a task instance for the current task node, and sending the created task instance to a predetermined processing role terminal of the task instance; then, processing result data returned by the processing role terminal is obtained; when the processing result data indicates that the task of the current task node is completed, determining a next task node of the process instance, and recording related data of the current task node in a preset process flow transfer table, where the related data may include: the identification of the current task node, the latest state of the current task node, the processing role identification of the current task node, the processing result data returned to the workflow system by the processing role identification of the current task node, and the associated data of the upper node and the lower node.
Through the steps, real-time comprehensive recording of each execution action in the workflow system can be realized based on the flow chart, so that powerful monitoring of the whole service life cycle of the workflow is realized, and the operation condition and related data of the whole workflow system can be comprehensively checked afterwards. In addition, the workflow scheduling method and the workflow scheduling device have the advantages of simplicity, easiness in use and low code development, and can be flexibly adjusted according to actual service requirements, so that the current service requirements can be met quickly.
Fig. 7 shows an exemplary system architecture 700 to which the workflow scheduling method or the workflow scheduling apparatus according to the embodiment of the present invention can be applied.
As shown in fig. 7, the system architecture 700 may include terminal devices 701, 702, 703, a network 704 and a server 705 (this architecture is merely an example, and the components included in a specific architecture may be adjusted according to specific application). The network 704 serves to provide a medium for communication links between the terminal devices 701, 702, 703 and the server 705. Network 704 may include various connection types, such as wired, wireless communication links, or fiber optic cables, to name a few.
A user may use the terminal devices 701, 702, 703 to interact with a server 705 over a network 704, to receive or send messages or the like. Various client applications, such as a workflow scheduling application (for example only), may be installed on the terminal devices 701, 702, 703.
The terminal devices 701, 702, 703 may be various electronic devices having a display screen and supporting web browsing, including but not limited to smart phones, tablet computers, laptop portable computers, desktop computers, and the like.
The server 705 may be a server providing various services, such as a workflow system server (for example only) providing support for a workflow scheduling application operated by a user with the terminal devices 701, 702, 703. The workflow system server may process the received scheduling request and feed back the processing result (e.g., workflow process execution result-just an example) to the terminal devices 701, 702, 703.
It should be noted that the workflow scheduling method provided by the embodiment of the present invention is generally executed by the server 705, and accordingly, the workflow scheduling apparatus provided by the embodiment of the present invention is generally disposed in the server 705.
It should be understood that the number of terminal devices, networks, and servers in fig. 7 is merely illustrative. There may be any number of terminal devices, networks, and servers, as desired for implementation.
The invention also provides the electronic equipment. The electronic device of the embodiment of the invention comprises: one or more processors; and the storage device is used for storing one or more programs, and when the one or more programs are executed by the one or more processors, the one or more processors realize the workflow scheduling method provided by the invention.
Referring now to FIG. 8, shown is a block diagram of a computer system 800 suitable for use in implementing an electronic device of an embodiment of the present invention. The electronic device shown in fig. 8 is only an example, and should not bring any limitation to the functions and the scope of use of the embodiments of the present invention.
As shown in fig. 8, the computer system 800 includes a Central Processing Unit (CPU)801 that can perform various appropriate actions and processes in accordance with a program stored in a Read Only Memory (ROM)802 or a program loaded from a storage section 808 into a Random Access Memory (RAM) 803. In the RAM803, various programs and data necessary for the operation of the computer system 800 are also stored. The CPU801, ROM 802, and RAM803 are connected to each other via a bus 804. An input/output (I/O) interface 805 is also connected to bus 804.
The following components are connected to the I/O interface 805: an input portion 806 including a keyboard, a mouse, and the like; an output section 807 including a signal such as a Cathode Ray Tube (CRT), a Liquid Crystal Display (LCD), and the like, and a speaker; a storage portion 808 including a hard disk and the like; and a communication section 809 including a network interface card such as a LAN card, a modem, or the like. The communication section 809 performs communication processing via a network such as the internet. A drive 810 is also connected to the I/O interface 805 as necessary. A removable medium 811 such as a magnetic disk, an optical disk, a magneto-optical disk, a semiconductor memory, or the like is mounted on the drive 810 as necessary, so that a computer program read out therefrom is mounted into the storage section 808 as necessary.
In particular, the processes described in the main step diagrams above may be implemented as computer software programs, according to embodiments of the present disclosure. For example, embodiments of the invention include a computer program product comprising a computer program embodied on a computer readable medium, the computer program comprising program code for performing the method illustrated in the main step diagram. In the above-described embodiment, the computer program can be downloaded and installed from a network via the communication section 809 and/or installed from the removable medium 811. The computer program, when executed by the central processing unit 801, performs the above-described functions defined in the system of the present invention.
It should be noted that the computer readable medium shown in the present invention can be a computer readable signal medium or a computer readable storage medium or any combination of the two. A computer readable storage medium may be, for example, but not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any combination of the foregoing. More specific examples of the computer readable storage medium may include, but are not limited to: an electrical connection having one or more wires, a portable computer diskette, a hard disk, a Random Access Memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing. In the present invention, a computer readable storage medium may be any tangible medium that can contain, or store a program for use by or in connection with an instruction execution system, apparatus, or device. In the present invention, a computer readable signal medium may include a propagated data signal with computer readable program code embodied therein, for example, in baseband or as part of a carrier wave. Such a propagated data signal may take many forms, including, but not limited to, electro-magnetic, optical, or any suitable combination thereof. A computer readable signal medium may also be any computer readable medium that is not a computer readable storage medium and that can communicate, propagate, or transport a program for use by or in connection with an instruction execution system, apparatus, or device. Program code embodied on a computer readable medium may be transmitted using any appropriate medium, including but not limited to: wireless, wire, fiber optic cable, RF, etc., or any suitable combination of the foregoing.
The flowchart and block diagrams in the figures illustrate the architecture, functionality, and operation of possible implementations of systems, methods and computer program products according to various embodiments of the present invention. In this regard, each block in the flowchart or block diagrams may represent a module, segment, or portion of code, which comprises one or more executable instructions for implementing the specified logical function(s). It should also be noted that, in some alternative implementations, the functions noted in the block may occur out of the order noted in the figures. For example, two blocks shown in succession may, in fact, be executed substantially concurrently, or the blocks may sometimes be executed in the reverse order, depending upon the functionality involved. It will also be noted that each block of the block diagrams or flowchart illustration, and combinations of blocks in the block diagrams or flowchart illustration, can be implemented by special purpose hardware-based systems which perform the specified functions or acts, or combinations of special purpose hardware and computer instructions.
The units described in the embodiments of the present invention may be implemented by software or hardware. The described units may also be provided in a processor, and may be described as: a processor includes a flow instance generation unit, a task instance execution unit, and a scheduling and recording unit. The names of these units do not in some cases form a limitation on the units themselves, and for example, the flow instance generation unit may also be described as a "unit that provides a flow instance to the task instance execution unit".
As another aspect, the present invention also provides a computer-readable medium that may be contained in the apparatus described in the above embodiments; or may be separate and not incorporated into the device. The computer readable medium carries one or more programs which, when executed by the apparatus, cause the apparatus to perform steps comprising: loading a pre-drawn graphic process model, and generating a process instance corresponding to the graphic process model; wherein, the process instance comprises at least one task node; determining a current task node of the process instance, creating a task instance for the current task node, and sending the created task instance to a predetermined processing role terminal of the task instance; acquiring processing result data returned by the processing role terminal; and when the processing result data represents that the task of the current task node is completed, determining the next task node of the process instance, and recording related data of the current task node in a preset process flow transfer table.
A computer program product of an embodiment of the invention comprises a computer program which, when executed by a processor, implements a method of workflow scheduling in the practice of the invention.
In the technical scheme of the embodiment of the invention, firstly, a pre-drawn graphic process model is loaded to generate a process instance corresponding to the graphic process model; wherein, the process instance comprises at least one task node; then, determining a current task node of the process instance, creating a task instance for the current task node, and sending the created task instance to a predetermined processing role terminal of the task instance; then, processing result data returned by the processing role terminal is obtained; when the processing result data indicates that the task of the current task node is completed, determining a next task node of the process instance, and recording related data of the current task node in a preset process flow transfer table, where the related data may include: the identification of the current task node, the latest state of the current task node, the processing role identification of the current task node, the processing result data returned to the workflow system by the processing role identification of the current task node, and the associated data of the upper node and the lower node.
Through the steps, real-time comprehensive recording of each execution action in the workflow system can be realized based on the flow chart, so that powerful monitoring of the whole service life cycle of the workflow is realized, and the operation condition and related data of the whole workflow system can be comprehensively checked afterwards. In addition, the workflow scheduling method and the workflow scheduling device have the advantages of simplicity, easiness in use and low code development, and can be flexibly adjusted according to actual service requirements, so that the current service requirements can be met quickly.
The above-described embodiments should not be construed as limiting the scope of the invention. Those skilled in the art will appreciate that various modifications, combinations, sub-combinations, and substitutions can occur, depending on design requirements and other factors. Any modification, equivalent replacement, and improvement made within the spirit and principle of the present invention should be included in the protection scope of the present invention.

Claims (15)

1. A workflow scheduling method, comprising:
loading a pre-drawn graphic process model, and generating a process instance corresponding to the graphic process model; wherein, the process instance comprises at least one task node;
determining a current task node of the process instance, creating a task instance for the current task node, and sending the created task instance to a predetermined processing role terminal of the task instance;
acquiring processing result data returned by the processing role terminal; and when the processing result data represents that the task of the current task node is completed, determining the next task node of the process instance, and recording related data of the current task node in a preset process flow transfer table.
2. The method of claim 1, wherein generating the process instance corresponding to the graphical process model comprises:
and generating a process instance corresponding to the graphic process model based on the input initialized service data and the loaded graphic process model.
3. The method of claim 2, further comprising at least one routing node in the process instance, the routing node comprising at least one of: serial routing nodes, parallel routing nodes, aggregation routing nodes, conditional routing nodes, and hop routing nodes.
4. The method of claim 3, wherein the determining the next task node for the process instance comprises:
when the next node of the current task node is a conditional routing node, acquiring the discrimination data required by the conditional routing node;
and selecting a path of the conditional routing node according to the judging data, and determining the task node which is not completed and closest to the path as the next task node of the process instance.
5. The method of claim 1, wherein the relevant data of the current task node comprises at least one of: the identification of the current task node, the latest state, the identification of the processing role and the processing result data.
6. The method of claim 5, further comprising:
and monitoring the execution process of the process instance according to the record in the process flow transfer table.
7. The method of claim 6, further comprising:
after the determining a next task node for the process instance, a task instance is created for the next task node.
8. The method of claim 7, wherein loading the pre-rendered graphical flow model comprises:
trying to load a pre-drawn graphic process model from a preset cache;
and when the loading from the cache fails, loading the graphic process model from a preset database.
9. The method of claim 8, wherein the processing result data comprises: and the mark and the service mark of the corresponding graphic flow model and the processing result of the processing role terminal to the task instance of the current task node.
10. The method of claim 9, further comprising:
after the processing result data returned by the processing role terminal is obtained, a process instance corresponding to the processing result is determined according to the identifier of the graph process model and the service identifier in the processing result data, and a task node corresponding to the processing result is determined in the process instance.
11. A workflow scheduling apparatus, comprising:
a flow instance generation unit configured to: loading a pre-drawn graphic process model, and generating a process instance corresponding to the graphic process model; wherein, the process instance comprises at least one task node;
a task instance execution unit to: determining a current task node of the process instance, creating a task instance for the current task node, and sending the created task instance to a predetermined processing role terminal of the task instance;
a scheduling and recording unit for: acquiring processing result data returned by the processing role terminal; and when the processing result data represents that the task of the current task node is completed, determining the next task node of the process instance, and recording related data of the current task node in a preset process flow transfer table.
12. The apparatus of claim 11, wherein the relevant data of the current task node comprises at least one of: the identification, the latest state, the processing role identification and the processing result data of the current task node;
the scheduling and recording unit is further configured to: and monitoring the execution process of the process instance according to the record in the process flow transfer table.
13. An electronic device, comprising:
one or more processors;
a storage device for storing one or more programs,
when executed by the one or more processors, cause the one or more processors to implement the method of any one of claims 1-10.
14. A computer-readable storage medium, on which a computer program is stored, which, when being executed by a processor, carries out the method according to any one of claims 1-10.
15. A computer program product comprising a computer program, characterized in that the computer program realizes the method according to any of claims 1-10 when executed by a processor.
CN202111618927.8A 2021-12-27 2021-12-27 Workflow scheduling method and device Pending CN114169801A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202111618927.8A CN114169801A (en) 2021-12-27 2021-12-27 Workflow scheduling method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202111618927.8A CN114169801A (en) 2021-12-27 2021-12-27 Workflow scheduling method and device

Publications (1)

Publication Number Publication Date
CN114169801A true CN114169801A (en) 2022-03-11

Family

ID=80488220

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202111618927.8A Pending CN114169801A (en) 2021-12-27 2021-12-27 Workflow scheduling method and device

Country Status (1)

Country Link
CN (1) CN114169801A (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115129307A (en) * 2022-08-26 2022-09-30 湖南云畅网络科技有限公司 Action flow arrangement method and system based on low code visualization
CN117634866A (en) * 2024-01-25 2024-03-01 中国人民解放军国防科技大学 Method, device, equipment and medium for processing data among nodes of workflow scheduling engine

Citations (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20130238384A1 (en) * 2012-03-12 2013-09-12 Barium AB Business management system
CN106897857A (en) * 2015-12-17 2017-06-27 北京奇虎科技有限公司 A kind of workflow processing method and system
CN106897858A (en) * 2015-12-17 2017-06-27 北京奇虎科技有限公司 A kind of workflow processing method and system
CN106897810A (en) * 2015-12-17 2017-06-27 北京奇虎科技有限公司 Method for processing business and system, workflow engine and system, operation system
CN109978482A (en) * 2017-12-27 2019-07-05 华为技术有限公司 Workflow processing method, device, equipment and storage medium
CN110032571A (en) * 2019-04-18 2019-07-19 腾讯科技(深圳)有限公司 Business flow processing method, apparatus, storage medium and calculating equipment
CN110738389A (en) * 2019-09-03 2020-01-31 深圳壹账通智能科技有限公司 Workflow processing method and device, computer equipment and storage medium
CN111897815A (en) * 2020-07-15 2020-11-06 中国建设银行股份有限公司 Service processing method and device
CN113487273A (en) * 2021-06-21 2021-10-08 深圳市信润富联数字科技有限公司 Multi-tenant instance monitoring system and method based on Activiti

Patent Citations (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20130238384A1 (en) * 2012-03-12 2013-09-12 Barium AB Business management system
CN106897857A (en) * 2015-12-17 2017-06-27 北京奇虎科技有限公司 A kind of workflow processing method and system
CN106897858A (en) * 2015-12-17 2017-06-27 北京奇虎科技有限公司 A kind of workflow processing method and system
CN106897810A (en) * 2015-12-17 2017-06-27 北京奇虎科技有限公司 Method for processing business and system, workflow engine and system, operation system
CN109978482A (en) * 2017-12-27 2019-07-05 华为技术有限公司 Workflow processing method, device, equipment and storage medium
CN110032571A (en) * 2019-04-18 2019-07-19 腾讯科技(深圳)有限公司 Business flow processing method, apparatus, storage medium and calculating equipment
CN110738389A (en) * 2019-09-03 2020-01-31 深圳壹账通智能科技有限公司 Workflow processing method and device, computer equipment and storage medium
CN111897815A (en) * 2020-07-15 2020-11-06 中国建设银行股份有限公司 Service processing method and device
CN113487273A (en) * 2021-06-21 2021-10-08 深圳市信润富联数字科技有限公司 Multi-tenant instance monitoring system and method based on Activiti

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115129307A (en) * 2022-08-26 2022-09-30 湖南云畅网络科技有限公司 Action flow arrangement method and system based on low code visualization
CN117634866A (en) * 2024-01-25 2024-03-01 中国人民解放军国防科技大学 Method, device, equipment and medium for processing data among nodes of workflow scheduling engine
CN117634866B (en) * 2024-01-25 2024-04-19 中国人民解放军国防科技大学 Method, device, equipment and medium for processing data among nodes of workflow scheduling engine

Similar Documents

Publication Publication Date Title
US9720731B2 (en) Methods and apparatus for coordinating and selecting protocols for resources acquisition from multiple resource managers
US20200401913A1 (en) Resource configuration method and apparatus forheterogeneous cloud services
US9058577B2 (en) Network centric structured communications network
CN114169801A (en) Workflow scheduling method and device
CA2824393C (en) Method and system for providing a session involving a plurality of software applications
US20030233341A1 (en) Systems and methods for work list prediction
CN110825535A (en) Job scheduling method and system
CN107016480A (en) Method for scheduling task, apparatus and system
CN103825964A (en) SLS (Service Level Specification) scheduling device and SLS scheduling method based on cloud computing PaaS (platform-as-a-service) platform
CN109298948B (en) Distributed computing method and system
CN107729176A (en) The disaster recovery method and disaster tolerance system of a kind of profile management systems
US11954064B2 (en) Framework for migrating applications to cloud computing environment
CN110611707A (en) Task scheduling method and device
CN110515741A (en) A kind of degradation processing method and device based on local task queue
CN114924858A (en) Task scheduling method and device, storage medium and electronic equipment
CN109829639A (en) Service item monitoring method and device
CN110119279A (en) A kind of method and apparatus applied and its upgrade
US9323509B2 (en) Method and system for automated process distribution
CN113626472B (en) Method and device for processing order data
CN111178823B (en) Method and device for canceling residence related transaction
CN114625640A (en) Software test project management method and device, storage medium and electronic equipment
Mangler et al. Cloud process execution engine: architecture and interfaces
CN113159659A (en) Method, device, equipment and computer readable medium for updating manifest aging
CN109933459A (en) A kind of execution method and apparatus of multitask
CN112488649B (en) Flow closing method and device based on flow engine

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination