CN116860362A - Plug-in object management method and device applied to flow programming engine - Google Patents
Plug-in object management method and device applied to flow programming engine Download PDFInfo
- Publication number
- CN116860362A CN116860362A CN202310817744.1A CN202310817744A CN116860362A CN 116860362 A CN116860362 A CN 116860362A CN 202310817744 A CN202310817744 A CN 202310817744A CN 116860362 A CN116860362 A CN 116860362A
- Authority
- CN
- China
- Prior art keywords
- connection
- plug
- available
- node
- plugin
- 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.)
- Granted
Links
- 238000007726 management method Methods 0.000 title claims abstract description 65
- 238000000034 method Methods 0.000 claims description 56
- 238000004590 computer program Methods 0.000 claims description 21
- 238000012545 processing Methods 0.000 claims description 15
- 238000003860 storage Methods 0.000 claims description 14
- 238000005096 rolling process Methods 0.000 claims description 5
- 238000010586 diagram Methods 0.000 description 7
- 238000013461 design Methods 0.000 description 4
- 230000006870 function Effects 0.000 description 4
- 238000012986 modification Methods 0.000 description 4
- 230000004048 modification Effects 0.000 description 4
- 239000000243 solution Substances 0.000 description 3
- 238000006243 chemical reaction Methods 0.000 description 2
- 230000001419 dependent effect Effects 0.000 description 2
- 238000002347 injection Methods 0.000 description 2
- 239000007924 injection Substances 0.000 description 2
- 230000010354 integration Effects 0.000 description 2
- 238000013507 mapping Methods 0.000 description 2
- 238000012544 monitoring process Methods 0.000 description 2
- 238000011112 process operation Methods 0.000 description 2
- 238000006467 substitution reaction Methods 0.000 description 2
- 230000002159 abnormal effect Effects 0.000 description 1
- 238000004458 analytical method Methods 0.000 description 1
- 238000003491 array Methods 0.000 description 1
- 230000009286 beneficial effect Effects 0.000 description 1
- 230000001413 cellular effect Effects 0.000 description 1
- 238000004140 cleaning Methods 0.000 description 1
- 238000004891 communication Methods 0.000 description 1
- 230000006378 damage Effects 0.000 description 1
- 238000011161 development Methods 0.000 description 1
- 210000001503 joint Anatomy 0.000 description 1
- 230000003287 optical effect Effects 0.000 description 1
- 238000012546 transfer Methods 0.000 description 1
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F9/00—Arrangements for program control, e.g. control units
- G06F9/06—Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
- G06F9/44—Arrangements for executing specific programs
- G06F9/448—Execution paradigms, e.g. implementations of programming paradigms
- G06F9/4482—Procedural
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F9/00—Arrangements for program control, e.g. control units
- G06F9/06—Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
- G06F9/44—Arrangements for executing specific programs
- G06F9/445—Program loading or initiating
- G06F9/44521—Dynamic linking or loading; Link editing at or after load time, e.g. Java class loading
- G06F9/44526—Plug-ins; Add-ons
-
- Y—GENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
- Y02—TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
- Y02D—CLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
- Y02D10/00—Energy efficient computing, e.g. low power processors, power management or thermal management
Landscapes
- Engineering & Computer Science (AREA)
- Software Systems (AREA)
- Theoretical Computer Science (AREA)
- Physics & Mathematics (AREA)
- General Engineering & Computer Science (AREA)
- General Physics & Mathematics (AREA)
- Stored Programmes (AREA)
Abstract
The invention discloses a plug-in object management method and a plug-in object management device applied to a flow programming engine, which are implemented by calling a first plug-in node in an integrated flow; when the first plug-in needs database connection based on the arrangement engine and no available connection exists in the object manager, creating a first available connection, caching the first available connection into the object manager, injecting a first connection object corresponding to the first available connection into the first plug-in, and operating a first plug-in node; returning the first available connection with the first flag set to the transaction manager when it is determined that the first plug-in is successful in operation and the first available connection is used; when the first plug-in node is the last plug-in node in the integrated flow, acquiring all second available connections with the first mark from the event manager for unified submission; compared with the prior art, the technical scheme of the invention realizes unified management of database connection in different plug-in nodes by introducing the object manager.
Description
Technical Field
The present invention relates to the technical field of process management systems, and in particular, to a method and an apparatus for managing plug-in objects applied to a process orchestration engine.
Background
In large enterprises, a large number of management systems exist frequently, the problems of repeated functions, easy generation of data islands and the like exist among the systems, and how to integrate the systems to achieve high integration and reusability becomes a problem to be solved by developers; currently, micro-service orchestration is a solution in this area, and in a orchestration system, plug-ins are often used as a way of application connection.
In the existing micro-service architecture, the object rollback generally has solutions of XA, TCC, final consistency and the like; the open source framework in the market is mostly realized based on the modes; the most commonly used method is the seata of the alebab, the domestic distributed object open source framework LCN and the like, and the management modes of the objects can be basically supported.
In the design direction, however, most of the design of the existing scheme is based on a distributed micro-service architecture, so that the object management among a plurality of single services is emphasized, the object management support of different plug-ins in the single services is very limited, and the problem that the unified object management in a plurality of independent plug-ins is difficult to support in the existing technical scheme is caused; in the performance direction, for the XA scheme, the transaction coordinator is an independently deployed service, and this scheme increases the network overhead and the waiting time of communication between services, which results in a decrease in service performance, and in the final consistency scheme, strong consistency cannot be achieved, and sometimes, it is necessary to wait for manual data processing.
Disclosure of Invention
The invention aims to solve the technical problems that: a plug-in object management method and device applied to a flow programming engine are provided, and an object manager is introduced into the flow programming engine to realize unified management of database connection in different plug-in nodes.
In order to solve the above technical problems, the present invention provides a plugin transaction management method applied to a process orchestration engine, including:
when receiving an integrated flow call initiated by a user, calling a first plug-in node in the integrated flow according to the received integrated flow;
judging whether available connection exists in the object manager or not when the arrangement engine determines that the first plugin corresponding to the first plugin node needs database connection;
when it is determined that the available connection does not exist in the object manager, calling an acquisition connection interface to create a first available connection, caching the first available connection in the object manager, injecting a first connection object corresponding to the first available connection into the first plug-in, and operating a first plug-in node;
acquiring the running state of the first plug-in, judging whether the first available connection is used or not when the first plug-in is determined to run successfully, setting a first mark for the first available connection if the first available connection is used, and returning the first available connection to the object manager;
and judging whether the first plug-in node is the last plug-in node in the integrated flow, if so, acquiring second available connections with the first marks from the object manager, and uniformly submitting all the second available connections.
In one possible implementation manner, after obtaining the operation state of the first plug-in unit, the method further includes:
and when the first plug-in operation failure is determined, acquiring second available connections with the first marks from the transaction manager, and uniformly rolling back all the second available connections.
The invention provides a plug-in object management method applied to a process scheduling engine, which further comprises the following steps:
and operating the first plugin when the first plugin corresponding to the first plugin node is determined to not need database connection based on the orchestration engine.
In one possible implementation, after determining whether there is an available connection in the transaction manager, the method further includes:
when it is determined that the available connection exists in the transaction manager, the available connection is invoked from the transaction manager and injected into the first plug-in, running the first plug-in.
In one possible implementation manner, after determining whether the first available connection is used, the method further includes:
when the first available connection is not used, judging whether the first plug-in node is the last plug-in node in the integrated flow, if so, acquiring second available connections with the first marks from the object manager, uniformly submitting all the second available connections, and if not, operating the next plug-in node of the first plug-in node in the integrated flow.
In one possible implementation manner, determining whether there is an available connection in the transaction manager specifically includes:
acquiring a connection state of a first connection in the object manager;
when the connection state is a pause state or a disconnection state, determining that no available connection exists in the transaction manager;
when the connection state is an active state, it is determined that there are connections available in the transaction manager.
The invention also provides a plug-in object management device applied to the flow programming engine, which comprises: the device comprises a plug-in node calling module, a connection judging module, a first running module, a connection marking module and a first connection processing module;
the plug-in node calling module is used for calling a first plug-in node in the integrated flow according to the received integrated flow when receiving the integrated flow calling initiated by a user;
the connection judging module is used for judging whether available connection exists in the object manager or not based on the arrangement engine when the arrangement engine determines that the first plugin corresponding to the first plugin node needs database connection;
the first operation module is used for calling a connection obtaining interface to create a first available connection when the fact manager is determined that the available connection does not exist in the fact manager, caching the first available connection into the fact manager, and injecting a first connection object corresponding to the first available connection into the first plug-in unit to operate a first plug-in unit node;
the connection marking module is used for acquiring the running state of the first plug-in, judging whether the first available connection is used or not when the first plug-in is determined to run successfully, setting a first mark for the first available connection if the first available connection is used, and returning the first available connection to the object manager;
the first connection processing module is configured to determine whether the first plugin node is a last plugin node in the integrated flow, if yes, obtain second available connections with the first mark from the transaction manager, and uniformly submit all the second available connections.
The invention provides a plug-in object management device applied to a process scheduling engine, which further comprises: a first connection processing module;
and the first connection processing module is used for acquiring second available connections with the first marks from the object manager when determining that the first plug-in fails to operate, and uniformly rolling back all the second available connections.
The invention provides a plug-in object management device applied to a process scheduling engine, which further comprises: a second operation module;
and the second operation module is used for operating the first plug-in when the arrangement engine determines that the first plug-in corresponding to the first plug-in node does not need database connection.
The invention provides a plug-in object management device applied to a process scheduling engine, which further comprises: connecting a calling module;
the connection calling module is used for calling the available connection from the object manager when the available connection exists in the object manager, injecting the available connection into the first plug-in, and operating the first plug-in.
The invention provides a plug-in object management device applied to a process scheduling engine, which further comprises: a plug-in node judging module;
the plug-in node judging module is configured to judge whether the first plug-in node is a last plug-in node in the integrated flow when it is determined that the first available connection is not used yet, if yes, obtain second available connections with the first mark from the object manager, uniformly submit all the second available connections, and if not, operate a next plug-in node of the first plug-in node in the integrated flow.
In one possible implementation manner, the connection determining module is configured to determine whether an available connection exists in the transaction manager, and specifically includes:
acquiring a connection state of a first connection in the object manager;
when the connection state is a pause state or a disconnection state, determining that no available connection exists in the transaction manager;
when the connection state is an active state, it is determined that there are connections available in the transaction manager.
The invention also provides a terminal device comprising a processor, a memory and a computer program stored in the memory and configured to be executed by the processor, wherein the processor implements the plugin transaction management method applied to the flow orchestration engine according to any one of the above when executing the computer program.
The invention also provides a computer readable storage medium, which comprises a stored computer program, wherein the computer program controls equipment where the computer readable storage medium is located to execute the plugin object management method applied to the flow scheduling engine according to any one of the above.
Compared with the prior art, the plug-in object management method and device applied to the flow programming engine have the following beneficial effects:
by invoking a first plugin node in the integrated stream; when the first plug-in needs database connection based on the arrangement engine and no available connection exists in the object manager, creating a first available connection, caching the first available connection into the object manager, injecting a first connection object corresponding to the first available connection into the first plug-in, and operating a first plug-in node; returning the first available connection with the first flag set to the transaction manager when it is determined that the first plug-in is successful in operation and the first available connection is used; when the first plug-in node is the last plug-in node in the integrated flow, acquiring all second available connections with the first mark from the event manager for unified submission; compared with the prior art, the technical scheme of the invention realizes unified management of database connection in different plug-in nodes by introducing the object manager into the compiling engine, and unified submission is performed when the process operation is finished, so that the object consistency of the whole process is ensured; and meanwhile, the newly created first available connection is cached in the object manager, so that the object manager automatically caches the connection, and when the plug-in uses the connection again, the connection does not need to be created again, thereby greatly improving the operation performance.
Drawings
FIG. 1 is a flow diagram of one embodiment of a plug-in transaction management method for a flow orchestration engine according to the present invention;
FIG. 2 is a schematic diagram illustrating an exemplary architecture of a plugin transaction management device for a process orchestration engine according to the present invention;
FIG. 3 is a further flow diagram of a plugin transaction management method applied to a flow orchestration engine according to one embodiment of the present invention;
fig. 4 is a schematic diagram of a relationship connection between a plug-in and a transaction manager according to an embodiment of the present invention.
Detailed Description
The following description of the embodiments of the present invention will be made clearly and fully with reference to the accompanying drawings, in which it is evident that the embodiments described are only some, but not all embodiments of the invention. All other embodiments, which can be made by those skilled in the art based on the embodiments of the invention without making any inventive effort, are intended to be within the scope of the invention.
Embodiment 1, referring to fig. 1, fig. 1 is a flow chart of an embodiment of a plug-in transaction management method applied to a flow layout engine according to the present invention, as shown in fig. 1, the method includes steps 101 to 105, specifically as follows:
step 101: when receiving an integrated flow call initiated by a user, calling a first plug-in node in the integrated flow according to the received integrated flow.
In an embodiment, the integration flow generally needs to define and design each step of the service flow, such as service rules and data conversion rules, through a flow design tool, for example, based on an arrangement management system, the service flow is configured through an edit page, each service corresponds to one plug-in node, each plug-in node represents one plug-in, and the plug-in can call an interface, connect a database or call the plug-in to connect different systems, so as to achieve quick butt joint among the systems and flexible conversion of heterogeneous data; and after the business process arrangement is completed, a corresponding configuration protocol is generated.
In an embodiment, the execution sequence of the plug-in nodes is arranged based on the service flow, so as to obtain an arranging node file, and an integrated flow is generated based on the arranging node file and the configuration protocol.
In an embodiment, plug-in nodes are sequentially selected based on the node sequence in the arrangement node file, the selected nodes in the arrangement node file are set as first plug-in nodes, and the first plug-in nodes in the integrated stream are called based on an arrangement engine.
Preferably, the first plugin node is a service plugin node.
Step 102: and judging whether available connection exists in the object manager or not based on the arrangement engine determining that the first plugin corresponding to the first plugin node needs database connection.
In one embodiment, after receiving an integrated flow call initiated by a user, the received integrated flow is parsed based on a orchestration engine to obtain a configuration protocol corresponding to the integrated flow.
In an embodiment, the configuration protocol includes a plurality of logic plugins for performing logic determination and generating an analysis result, where the logic plugins are used for operations such as condition determination, recursion, and the like.
In an embodiment, based on a configuration protocol, a suitable logic plug-in is selected to determine whether the first plug-in node needs to modify the database, if so, it is determined that the first plug-in corresponding to the first plug-in node needs database connection, and if not, it is determined that the first plug-in corresponding to the first plug-in node does not need database connection.
Preferably, modifying the database includes adding, deleting and modifying the database.
In an embodiment, when the arrangement engine determines that the first plugin corresponding to the first plugin node does not need database connection, the first plugin is directly operated.
Preferably, when the service content corresponding to the first plugin node is only that the database needs to be checked, and modification of the database is not involved, it is considered that the current first plugin node does not need database connection, and the first plugin can be directly operated.
In an embodiment, the transaction manager caches the connection objects of each plug-in the transaction manager, maintains the mapping relationship between the connection objects and the plug-ins, and periodically cleans up expired connections to ensure the availability of the connections.
In one embodiment, determining whether an available connection exists in a transaction manager, and specifically, acquiring a connection state of a first connection in the transaction manager; when the connection state is a pause state or a disconnection state, determining that no available connection exists in the transaction manager; when the connection state is an active state, it is determined that there are connections available in the transaction manager.
In an embodiment, before judging whether the object manager has the available connection, selecting a database needing service operation based on the service corresponding to the first plugin; and simultaneously, based on the business operation corresponding to the first plug-in, determining a first connection corresponding to the business operation, and based on the first connection, calling the object manager to judge whether available connection exists in the database.
Preferably, a kernel method checkConnection based on the transaction manager is used for checking the connection availability; when a connection expires or is not available, the transaction manager destroys it.
In one embodiment, after determining whether there is an available connection in the transaction manager, the method further includes: when it is determined that the available connection exists in the transaction manager, the available connection is called from the transaction manager, the available connection is injected into the first plug-in, and the first plug-in is operated so that the first plug-in is connected to a corresponding database based on the available connection.
In one embodiment, for the object manager, the object manager provides various interfaces related to object management of the plug-in based on its own Abstract ConnectionHandler, the plug-in only needs to realize interfaces for connecting databases, for example, the MySQL/PostgreSQL database is connected by means of JDBC, and a plug-in developer does not need to care when the connection is created and destroyed, how the object is submitted/rolled back, only needs to realize specific services, and can perform operations of adding, deleting, changing and the like on the databases by calling a unified interface of the object manager when the connection is needed.
Step 103: and when the fact that the available connection does not exist in the object manager is determined, calling an acquisition connection interface to create a first available connection, caching the first available connection into the object manager, injecting a first connection object corresponding to the first available connection into the first plug-in, and operating a first plug-in node.
In an embodiment, when the first available connection is created by calling the connection obtaining interface, a connection object corresponding to the available connection is obtained from the event manager, and based on the connection object, a connection obtaining method corresponding to the connection object in the event manager is called to create a new first available connection.
In an embodiment, when the first connection object corresponding to the first available connection is injected into the first plugin, the first plugin may obtain the first available connection of the database through the dependent injection plugin container or framework, and the dependent injection framework may automatically inject the database connection object into the plugin according to the annotation or the configuration file of the plugin.
Preferably, the thread local variable is used to record and transfer the connection object corresponding to the first available connection during the execution of the first plug-in; wherein the thread local variables maintain a copy of the connection object for each thread, the copies being independent of the other threads; when the first plug-in needs to use a connection object, the connection object may be obtained from the thread local variable.
In one embodiment, because the creation and destruction of the database connection are time-consuming, in the traditional plug-in development mode, the connection is established only when the database needs to be connected, and destroyed immediately, and when the concurrency is large, the operation of frequently establishing or destroying the connection occupies a large amount of server resources, and the operation time of the service is preempted; in this embodiment, the newly created first available connection is cached in the object manager, so that the object manager automatically caches the connection, and when the plug-in uses the connection again, the connection does not need to be created again, thereby greatly improving the operation performance.
Step 104: and acquiring the running state of the first plug-in, judging whether the first available connection is used or not when the first plug-in is successfully run, setting a first mark for the first available connection if the first available connection is used, and returning the first available connection to the object manager.
In an embodiment, when the running state of the first plugin is obtained, the running state of the first plugin may be obtained by checking a log file of the plugin, monitoring log output of the plugin, checking the state of the plugin based on a plugin management tool, and monitoring resource usage of the plugin.
In an embodiment, when it is determined that the first plug-in fails to run, all second available connections with the first mark are obtained from the transaction manager, and all second available connections are rolled back uniformly.
In one embodiment, after the process is finished, the kernel method rollback () based on the transaction manager uniformly rolls back.
In an embodiment, by introducing the object manager, the database connection of different plugins is managed in a unified way, and when the node is abnormal, the unified rollback is realized, so that the unified management of the connection in the nodes of different plugins is realized.
In an embodiment, it is determined whether the first available connection is used, specifically, an allocation status of the first available connection in the database connection pool is obtained, when the allocation status of the first available connection is allocated, it is determined that the first available connection is used, and when the allocation status of the first available connection is unallocated, it is determined that the first available connection is unused.
Preferably, a query log of a database may be obtained, and based on the query log, it is determined whether the first plugin performs a modification operation on the database, if yes, it is determined that the first available connection is used, and if not, it is determined that the first available connection is not used.
In one embodiment, after determining whether the first available connection is used, the method further includes: when the first available connection is not used, judging whether the first plug-in node is the last plug-in node in the integrated flow, if so, acquiring second available connections with the first marks from the object manager, uniformly submitting all the second available connections, and if not, operating the next plug-in node of the first plug-in node in the integrated flow based on a state machine.
Preferably, the state machine is a component running in the orchestration engine, can judge the node state by analyzing the protocol mode and record the node running result, and drives the orchestration flow to the next node according to various logic components and the node running state.
In an embodiment, in the case that the first available connection is determined to be used, after the first available connection is marked, the first available connection is returned to the transaction manager in time, so that the situation that the first available connection is occupied for a long time or is not released in time is avoided, and insufficient connection resources in a database connection pool can be caused, and therefore performance and usability of an application program are affected.
Step 105: and judging whether the first plug-in node is the last plug-in node in the integrated flow, if so, acquiring second available connections with the first marks from the object manager, and uniformly submitting all the second available connections.
In one embodiment, after the process is finished, the transaction is uniformly submitted based on the core method commit () of the transaction manager.
In one embodiment, based on an orchestration node file of an integrated flow, it is determined whether the first add-on node is the last add-on node in the integrated flow.
In an embodiment, when the first plugin node is not the last plugin node in the integrated flow, then operating a next plugin node of the first plugin node in the integrated flow, and repeating the above steps until all plugin nodes in the integrated flow are called.
In one embodiment, the second available connection is a marked connection in the transaction manager.
In an embodiment, by introducing the transaction manager, the database connections of different plugins are managed in a unified manner, and submitted in a unified manner when the process operation is finished, so that the unified management of the connections in different plugin nodes is realized, and meanwhile, when different plugin nodes operate on the same platform and process different business data, the data consistency of the whole process can be ensured.
In order to more clearly describe the present invention, this embodiment is briefly described with respect to another flow diagram of the plugin transaction management method applied to the flow scheduling engine of fig. 3, as shown in fig. 3, a business flow is configured based on a scheduling management system, corresponding plugins are generated based on each business, after the business flow is scheduled, a corresponding configuration protocol is generated to obtain an integrated flow, plugins are sequentially operated based on the sequence of plugins in the integrated flow, and when plugins are operated, a transaction manager is configured in the scheduling engine based on different plugins, so that unified management of database connection of different plugins based on the transaction manager is realized; and the operation such as the mapping, expiration cleaning, availability check and the like of the connection is automatically carried out in the object manager, the available connection is automatically provided for the plug-in, and the operation efficiency of the plug-in is laterally improved.
In one embodiment, the relationship between the plugin and the object manager is as shown in fig. 4, and fig. 4 is a schematic diagram of the relationship connection between the plugin and the object manager; in the figure, a connection processor connection handler and a session processor sessionhandler of the object manager are respectively connected with abstract object management classes abstract connection handler classes of the object manager, abstract connection handler classes of the object manager are respectively connected with connection interfaces connectioninterface of the plug-in unit, and MySQL connection MySQLCconnection and postgreSQL connection of the plug-in unit are respectively connected with connection interfaces connectioninterface of the plug-in unit.
Embodiment 2, referring to fig. 2, fig. 2 is a schematic structural diagram of an embodiment of a plugin transaction management device applied to a process orchestration engine according to the present invention, and as shown in fig. 2, the device includes a plugin node calling module 201, a connection judging module 202, a first running module 203, a connection marking module 204, and a first connection processing module 205, which are specifically as follows:
the plugin node calling module 201 is configured to call a first plugin node in an integrated flow according to a received integrated flow when receiving an integrated flow call initiated by a user.
The connection determining module 202 is configured to determine, based on the orchestration engine, whether an available connection exists in the transaction manager when the orchestration engine determines that the first plugin corresponding to the first plugin node needs a database connection.
The first operation module 203 is configured to, when it is determined that the available connection does not exist in the transaction manager, invoke an acquisition connection interface to create a first available connection, cache the first available connection in the transaction manager, and inject a first connection object corresponding to the first available connection into the first plugin, so as to operate a first plugin node.
The connection marking module 204 is configured to obtain an operation state of the first plug-in, determine whether the first available connection is used when it is determined that the first plug-in is successfully operated, if yes, set a first mark for the first available connection, and return the first available connection to the transaction manager.
The first connection processing module 205 is configured to determine whether the first plugin node is a last plugin node in the integrated flow, if yes, obtain second available connections with the first flag from the transaction manager, and uniformly submit all the second available connections.
The plug-in object management device applied to the process scheduling engine provided in this embodiment further includes: a first connection processing module; and the first connection processing module is used for acquiring second available connections with the first marks from the object manager when determining that the first plug-in fails to operate, and uniformly rolling back all the second available connections.
The plug-in object management device applied to the process scheduling engine provided in this embodiment further includes: a second operation module; and the second operation module is used for operating the first plug-in when the arrangement engine determines that the first plug-in corresponding to the first plug-in node does not need database connection.
The plug-in object management device applied to the process scheduling engine provided in this embodiment further includes: connecting a calling module; the connection calling module is used for calling the available connection from the object manager when the available connection exists in the object manager, injecting the available connection into the first plug-in, and operating the first plug-in.
The plug-in object management device applied to the process scheduling engine provided in this embodiment further includes: a plug-in node judging module; the plug-in node judging module is configured to judge whether the first plug-in node is a last plug-in node in the integrated flow when it is determined that the first available connection is not used yet, if yes, obtain second available connections with the first mark from the object manager, uniformly submit all the second available connections, and if not, operate a next plug-in node of the first plug-in node in the integrated flow.
In one embodiment, the connection determining module 202 is configured to determine whether there is an available connection in the transaction manager, and specifically includes: acquiring a connection state of a first connection in the object manager; when the connection state is a pause state or a disconnection state, determining that no available connection exists in the transaction manager; when the connection state is an active state, it is determined that there are connections available in the transaction manager.
It will be clear to those skilled in the art that, for convenience and brevity of description, reference may be made to the corresponding process in the foregoing method embodiment for the specific working process of the above-described apparatus, which is not described in detail herein.
It should be noted that, the above embodiment of the plugin object management device applied to the flow orchestration engine is merely schematic, where the modules described as separate components may or may not be physically separated, and components displayed as modules may or may not be physical units, may be located in one place, or may be distributed over multiple network units. Some or all of the modules may be selected according to actual needs to achieve the purpose of the solution of this embodiment.
On the basis of the embodiment of the plugin object management method applied to the process planning engine, another embodiment of the present invention provides a plugin object management terminal device applied to the process planning engine, where the plugin object management terminal device applied to the process planning engine includes a processor, a memory, and a computer program stored in the memory and configured to be executed by the processor, where the processor executes the computer program to implement the plugin object management method applied to the process planning engine according to any one of the embodiments of the present invention.
Illustratively, in this embodiment the computer program may be partitioned into one or more modules, which are stored in the memory and executed by the processor to perform the present invention. The one or more modules may be a series of computer program instruction segments capable of performing a specific function for describing the execution of the computer program in the plug-in transaction management terminal device applied to the flow orchestration engine.
The plug-in object management terminal device applied to the process scheduling engine can be a desktop computer, a notebook computer, a palm computer, a cloud server and other computing devices. The plug-in transaction management terminal device applied to the process orchestration engine may include, but is not limited to, a processor, a memory.
The processor may be a central processing unit (Central Processing Unit, CPU), other general purpose processors, digital signal processors (Digital Signal Processor, DSP), application specific integrated circuits (Application Specific Integrated Circuit, ASIC), off-the-shelf programmable gate arrays (Field-Programmable Gate Array, FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, or the like. The general purpose processor may be a microprocessor or the processor may be any conventional processor, etc., which is a control center of the plug-in transaction management terminal device applied to the flow programming engine, and connects various parts of the plug-in transaction management terminal device applied to the flow programming engine as a whole using various interfaces and lines.
The memory may be used to store the computer program and/or module, and the processor may implement the various functions of the plug-in transaction management terminal device applied to the process orchestration engine by running or executing the computer program and/or module stored in the memory, and invoking data stored in the memory. The memory may mainly include a storage program area and a storage data area, wherein the storage program area may store an operating system, an application program required for at least one function, and the like; the storage data area may store data created according to the use of the cellular phone, etc. In addition, the memory may include high-speed random access memory, and may also include non-volatile memory, such as a hard disk, memory, plug-in hard disk, smart Media Card (SMC), secure Digital (SD) Card, flash Card (Flash Card), at least one disk storage device, flash memory device, or other volatile solid-state storage device.
On the basis of the embodiment of the plugin object management method applied to the process scheduling engine, another embodiment of the present invention provides a storage medium, where the storage medium includes a stored computer program, and when the computer program runs, the device where the storage medium is controlled to execute the plugin object management method applied to the process scheduling engine according to any embodiment of the present invention.
In this embodiment, the storage medium is a computer-readable storage medium, and the computer program includes computer program code, where the computer program code may be in a source code form, an object code form, an executable file, or some intermediate form, and so on. The computer readable medium may include: any entity or device capable of carrying the computer program code, a recording medium, a U disk, a removable hard disk, a magnetic disk, an optical disk, a computer Memory, a Read-Only Memory (ROM), a random access Memory (RAM, random Access Memory), an electrical carrier signal, a telecommunications signal, a software distribution medium, and so forth. It should be noted that the computer readable medium contains content that can be appropriately scaled according to the requirements of jurisdictions in which such content is subject to legislation and patent practice, such as in certain jurisdictions in which such content is subject to legislation and patent practice, the computer readable medium does not include electrical carrier signals and telecommunication signals.
In summary, the plug-in object management method and device applied to the process scheduling engine provided by the invention call a first plug-in node in an integrated flow; when the first plug-in needs database connection based on the arrangement engine and no available connection exists in the object manager, creating a first available connection, caching the first available connection into the object manager, injecting a first connection object corresponding to the first available connection into the first plug-in, and operating a first plug-in node; returning the first available connection with the first flag set to the transaction manager when it is determined that the first plug-in is successful in operation and the first available connection is used; when the first plug-in node is the last plug-in node in the integrated flow, acquiring all second available connections with the first mark from the event manager for unified submission; compared with the prior art, the technical scheme of the invention realizes unified management of database connection in different plug-in nodes by introducing the object manager.
The foregoing is merely a preferred embodiment of the present invention, and it should be noted that modifications and substitutions can be made by those skilled in the art without departing from the technical principles of the present invention, and these modifications and substitutions should also be considered as being within the scope of the present invention.
Claims (10)
1. A plugin transaction management method for a process orchestration engine, comprising:
when receiving an integrated flow call initiated by a user, calling a first plug-in node in the integrated flow according to the received integrated flow;
judging whether available connection exists in the object manager or not when the arrangement engine determines that the first plugin corresponding to the first plugin node needs database connection;
when it is determined that the available connection does not exist in the object manager, calling an acquisition connection interface to create a first available connection, caching the first available connection in the object manager, injecting a first connection object corresponding to the first available connection into the first plug-in, and operating a first plug-in node;
acquiring the running state of the first plug-in, judging whether the first available connection is used or not when the first plug-in is determined to run successfully, setting a first mark for the first available connection if the first available connection is used, and returning the first available connection to the object manager;
and judging whether the first plug-in node is the last plug-in node in the integrated flow, if so, acquiring second available connections with the first marks from the object manager, and uniformly submitting all the second available connections.
2. The plugin transaction management method for a process orchestration engine according to claim 1, wherein after obtaining the running state of the first plugin, further comprises:
and when the first plug-in operation failure is determined, acquiring second available connections with the first marks from the transaction manager, and uniformly rolling back all the second available connections.
3. The plug-in transaction management method applied to a process orchestration engine according to claim 1, further comprising:
and operating the first plugin when the first plugin corresponding to the first plugin node is determined to not need database connection based on the orchestration engine.
4. The method for managing plug-in objects for use in a process orchestration engine according to claim 1, wherein after determining whether there is a connection available in the object manager, further comprising:
when it is determined that the available connection exists in the transaction manager, the available connection is invoked from the transaction manager and injected into the first plug-in, running the first plug-in.
5. The plug-in transaction management method for a process orchestration engine according to claim 1, wherein determining whether the first available connection is used further comprises:
when the first available connection is not used, judging whether the first plug-in node is the last plug-in node in the integrated flow, if so, acquiring second available connections with the first marks from the object manager, uniformly submitting all the second available connections, and if not, operating the next plug-in node of the first plug-in node in the integrated flow.
6. The method for managing plug-in objects for a process orchestration engine according to claim 1, wherein determining whether there is a connection available in the object manager comprises:
acquiring a connection state of a first connection in the object manager;
when the connection state is a pause state or a disconnection state, determining that no available connection exists in the transaction manager;
when the connection state is an active state, it is determined that there are connections available in the transaction manager.
7. A plugin transaction management device for a process orchestration engine, comprising: the device comprises a plug-in node calling module, a connection judging module, a first running module, a connection marking module and a first connection processing module;
the plug-in node calling module is used for calling a first plug-in node in the integrated flow according to the received integrated flow when receiving the integrated flow calling initiated by a user;
the connection judging module is used for judging whether available connection exists in the object manager or not based on the arrangement engine when the arrangement engine determines that the first plugin corresponding to the first plugin node needs database connection;
the first operation module is used for calling a connection obtaining interface to create a first available connection when the fact manager is determined that the available connection does not exist in the fact manager, caching the first available connection into the fact manager, and injecting a first connection object corresponding to the first available connection into the first plug-in unit to operate a first plug-in unit node;
the connection marking module is used for acquiring the running state of the first plug-in, judging whether the first available connection is used or not when the first plug-in is determined to run successfully, setting a first mark for the first available connection if the first available connection is used, and returning the first available connection to the object manager;
the first connection processing module is configured to determine whether the first plugin node is a last plugin node in the integrated flow, if yes, obtain second available connections with the first mark from the transaction manager, and uniformly submit all the second available connections.
8. The plug-in transaction management device for a process orchestration engine according to claim 7, further comprising: a first connection processing module;
and the first connection processing module is used for acquiring second available connections with the first marks from the object manager when determining that the first plug-in fails to operate, and uniformly rolling back all the second available connections.
9. A terminal device comprising a processor, a memory and a computer program stored in the memory and configured to be executed by the processor, the processor implementing the plugin transaction management method applied to a flow orchestration engine according to any one of claims 1 to 6 when the computer program is executed.
10. A computer readable storage medium, characterized in that the computer readable storage medium comprises a stored computer program, wherein the computer program when run controls a device in which the computer readable storage medium is located to execute the plugin transaction management method applied to a process orchestration engine according to any one of claims 1 to 6.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202310817744.1A CN116860362B (en) | 2023-07-05 | 2023-07-05 | Plug-in transaction management method and device applied to flow programming engine |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202310817744.1A CN116860362B (en) | 2023-07-05 | 2023-07-05 | Plug-in transaction management method and device applied to flow programming engine |
Publications (2)
Publication Number | Publication Date |
---|---|
CN116860362A true CN116860362A (en) | 2023-10-10 |
CN116860362B CN116860362B (en) | 2024-03-19 |
Family
ID=88231670
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202310817744.1A Active CN116860362B (en) | 2023-07-05 | 2023-07-05 | Plug-in transaction management method and device applied to flow programming engine |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN116860362B (en) |
Citations (26)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20040049481A1 (en) * | 2002-05-01 | 2004-03-11 | Mike Blevins | Systems and methods for business process plug-in development |
US20070245356A1 (en) * | 2006-04-12 | 2007-10-18 | Sap Portals Israel Ltd. | Method and apparatus for a support platform |
EP2363806A1 (en) * | 2010-03-03 | 2011-09-07 | Software AG | Connection handler and method for providing applications with heterogeneous connection objects |
US20140067567A1 (en) * | 2012-08-31 | 2014-03-06 | Ncr Corporation | Techniques to custom define transaction sessions |
US20140324512A1 (en) * | 2013-04-29 | 2014-10-30 | International Business Machines Corporation | Automated business function implementation analysis and adaptive transaction integration |
CN105786913A (en) * | 2014-12-25 | 2016-07-20 | 北京仿真中心 | Cloud manufacturing platform oriented ERP integrated database service interface encapsulation system and method |
CN105912384A (en) * | 2016-04-01 | 2016-08-31 | 广东凯通软件开发有限公司 | Transaction processing method and device for workflow engine |
US20160380913A1 (en) * | 2015-06-26 | 2016-12-29 | International Business Machines Corporation | Transactional Orchestration of Resource Management and System Topology in a Cloud Environment |
US20170244611A1 (en) * | 2014-06-26 | 2017-08-24 | Zte Corporation | Service Orchestration Method and Apparatus in Software-Defined Networking, and Storage Medium |
KR20180104593A (en) * | 2015-09-09 | 2018-09-21 | 이준성 | Copyright database and copyright transaction method on the Internet |
US20180307514A1 (en) * | 2017-04-24 | 2018-10-25 | Sap Se | Transaction orchestration for microservice |
US10146629B1 (en) * | 2015-03-30 | 2018-12-04 | EMC IP Holding Company LLC | Extensible workflow manager for backing up and recovering microsoft shadow copy compatible applications |
CN111142867A (en) * | 2019-12-31 | 2020-05-12 | 谷云科技(广州)有限责任公司 | Service visual arrangement system and method under micro-service architecture |
US20210352077A1 (en) * | 2020-05-05 | 2021-11-11 | International Business Machines Corporation | Low trust privileged access management |
CN114240132A (en) * | 2021-12-14 | 2022-03-25 | 平安壹钱包电子商务有限公司 | Business process arrangement execution method and device, computer equipment and storage medium |
US11288274B1 (en) * | 2019-05-29 | 2022-03-29 | Yellowbrick Data, Inc. | System and method for storing data for, and providing, rapid database join functions and aggregation statistics |
CN114416305A (en) * | 2021-11-26 | 2022-04-29 | 北京中软国际信息技术有限公司 | Robot engine implementation method and system and electronic equipment |
CN114675957A (en) * | 2022-05-26 | 2022-06-28 | 广州市玄武无线科技股份有限公司 | Plug-in fusing method and device, terminal equipment and computer readable storage medium |
US11381638B1 (en) * | 2021-02-19 | 2022-07-05 | Oracle International Corporation | System and method for parallel execution of activites in an integration flow |
CN114971506A (en) * | 2021-02-26 | 2022-08-30 | ***通信集团广东有限公司 | System and method for separating process engine and business event processing |
CN115292010A (en) * | 2022-09-28 | 2022-11-04 | 中邮消费金融有限公司 | Method and system for automatically generating service through process configuration |
CA3177530A1 (en) * | 2021-07-14 | 2023-01-14 | Strong Force TX Portfolio 2018, LLC | Systems and methods with integrated gaming engines and smart contracts |
CN115964072A (en) * | 2022-12-28 | 2023-04-14 | 中锦技术(广东)有限公司 | Workflow management system based on Flowable process engine development |
US20230176895A1 (en) * | 2021-12-06 | 2023-06-08 | Sap Se | Transaction engine |
CN116244049A (en) * | 2023-01-09 | 2023-06-09 | 中信百信银行股份有限公司 | Lightweight distributed flow transaction controller and method |
CN116342057A (en) * | 2023-02-24 | 2023-06-27 | 成都新希望金融信息有限公司 | Face tag flow generation method and device, electronic equipment and storage medium |
-
2023
- 2023-07-05 CN CN202310817744.1A patent/CN116860362B/en active Active
Patent Citations (26)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20040049481A1 (en) * | 2002-05-01 | 2004-03-11 | Mike Blevins | Systems and methods for business process plug-in development |
US20070245356A1 (en) * | 2006-04-12 | 2007-10-18 | Sap Portals Israel Ltd. | Method and apparatus for a support platform |
EP2363806A1 (en) * | 2010-03-03 | 2011-09-07 | Software AG | Connection handler and method for providing applications with heterogeneous connection objects |
US20140067567A1 (en) * | 2012-08-31 | 2014-03-06 | Ncr Corporation | Techniques to custom define transaction sessions |
US20140324512A1 (en) * | 2013-04-29 | 2014-10-30 | International Business Machines Corporation | Automated business function implementation analysis and adaptive transaction integration |
US20170244611A1 (en) * | 2014-06-26 | 2017-08-24 | Zte Corporation | Service Orchestration Method and Apparatus in Software-Defined Networking, and Storage Medium |
CN105786913A (en) * | 2014-12-25 | 2016-07-20 | 北京仿真中心 | Cloud manufacturing platform oriented ERP integrated database service interface encapsulation system and method |
US10146629B1 (en) * | 2015-03-30 | 2018-12-04 | EMC IP Holding Company LLC | Extensible workflow manager for backing up and recovering microsoft shadow copy compatible applications |
US20160380913A1 (en) * | 2015-06-26 | 2016-12-29 | International Business Machines Corporation | Transactional Orchestration of Resource Management and System Topology in a Cloud Environment |
KR20180104593A (en) * | 2015-09-09 | 2018-09-21 | 이준성 | Copyright database and copyright transaction method on the Internet |
CN105912384A (en) * | 2016-04-01 | 2016-08-31 | 广东凯通软件开发有限公司 | Transaction processing method and device for workflow engine |
US20180307514A1 (en) * | 2017-04-24 | 2018-10-25 | Sap Se | Transaction orchestration for microservice |
US11288274B1 (en) * | 2019-05-29 | 2022-03-29 | Yellowbrick Data, Inc. | System and method for storing data for, and providing, rapid database join functions and aggregation statistics |
CN111142867A (en) * | 2019-12-31 | 2020-05-12 | 谷云科技(广州)有限责任公司 | Service visual arrangement system and method under micro-service architecture |
US20210352077A1 (en) * | 2020-05-05 | 2021-11-11 | International Business Machines Corporation | Low trust privileged access management |
US11381638B1 (en) * | 2021-02-19 | 2022-07-05 | Oracle International Corporation | System and method for parallel execution of activites in an integration flow |
CN114971506A (en) * | 2021-02-26 | 2022-08-30 | ***通信集团广东有限公司 | System and method for separating process engine and business event processing |
CA3177530A1 (en) * | 2021-07-14 | 2023-01-14 | Strong Force TX Portfolio 2018, LLC | Systems and methods with integrated gaming engines and smart contracts |
CN114416305A (en) * | 2021-11-26 | 2022-04-29 | 北京中软国际信息技术有限公司 | Robot engine implementation method and system and electronic equipment |
US20230176895A1 (en) * | 2021-12-06 | 2023-06-08 | Sap Se | Transaction engine |
CN114240132A (en) * | 2021-12-14 | 2022-03-25 | 平安壹钱包电子商务有限公司 | Business process arrangement execution method and device, computer equipment and storage medium |
CN114675957A (en) * | 2022-05-26 | 2022-06-28 | 广州市玄武无线科技股份有限公司 | Plug-in fusing method and device, terminal equipment and computer readable storage medium |
CN115292010A (en) * | 2022-09-28 | 2022-11-04 | 中邮消费金融有限公司 | Method and system for automatically generating service through process configuration |
CN115964072A (en) * | 2022-12-28 | 2023-04-14 | 中锦技术(广东)有限公司 | Workflow management system based on Flowable process engine development |
CN116244049A (en) * | 2023-01-09 | 2023-06-09 | 中信百信银行股份有限公司 | Lightweight distributed flow transaction controller and method |
CN116342057A (en) * | 2023-02-24 | 2023-06-27 | 成都新希望金融信息有限公司 | Face tag flow generation method and device, electronic equipment and storage medium |
Non-Patent Citations (4)
Title |
---|
ORANGECSONG: "手写实现一套流程编排&规则引擎", Retrieved from the Internet <URL:《https://zhuanlan.zhihu.com/p/194252128》> * |
京东云技术新知: "流程编排、如此简单-通用流程编排组件JDEasyFlow介绍", Retrieved from the Internet <URL:《https://segmentfault.com/a/1190000042898863》> * |
铂赛东: "别再用硬编码写业务流程了,试试这款轻量级流程编排框架", Retrieved from the Internet <URL:《https://segmentfault.com/a/1190000038796413》> * |
阿里云: "开源微服务编排框架:Netflix Conductor", Retrieved from the Internet <URL:《https://zhuanlan.zhihu.com/p/440578308》> * |
Also Published As
Publication number | Publication date |
---|---|
CN116860362B (en) | 2024-03-19 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN110069572B (en) | HIVE task scheduling method, device, equipment and storage medium based on big data platform | |
CN108280023B (en) | Task execution method and device and server | |
CN113032166B (en) | Inter-core communication method, processor, inter-core communication system, and computer-readable storage medium | |
CN113157411B (en) | Celery-based reliable configurable task system and device | |
CN111400011A (en) | Real-time task scheduling method, system, equipment and readable storage medium | |
US11169847B1 (en) | Method and device for processing distributed data solving problem of manual intervention by data analysts | |
CN112511596A (en) | Method and equipment for creating cloud resources in cloud platform | |
CN113722114A (en) | Data service processing method and device, computing equipment and storage medium | |
CN112559525B (en) | Data checking system, method, device and server | |
CN107734050B (en) | Load machine distribution method, computing equipment and load machine distribution system | |
CN116860362B (en) | Plug-in transaction management method and device applied to flow programming engine | |
CN112905306A (en) | Multi-cluster container management method and device, electronic equipment and storage medium | |
CN115829826A (en) | Model storage optimization method and electronic equipment | |
CN114880386B (en) | Task scheduling platform and task scheduling method | |
CN115268909A (en) | Method, system and terminal for establishing and running construction task at web front end | |
CN114610413A (en) | Method, device, equipment and storage medium for executing synchronous and asynchronous tasks based on Java | |
CN115374083A (en) | Data source switching method and device, electronic equipment and storage medium | |
CN109005067B (en) | Method and device for monitoring hardware resources of server cluster | |
CN112130849B (en) | Code automatic generation method and device | |
CN112052035B (en) | Version group package method and device based on bank back line system | |
CN114020604A (en) | Workflow-based automatic testing method and device | |
CN110019113B (en) | Database service processing method and database server | |
CN111782363A (en) | Method and flow system for supporting multi-service scene calling | |
CN111580938A (en) | Transaction processing method, device, equipment and medium for work unit | |
CN114785847B (en) | Network control software development configuration method, terminal and storage medium |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
GR01 | Patent grant | ||
GR01 | Patent grant |