A method for executing a process instance, an electronic device

Through the process instance execution method, the backend server recognizes and executes customized nodes, obtains customized script code, solving the customization capabilities and efficiency problems of existing semiconductor manufacturing software, and achieving highly customized and efficient data processing.

CN119415189BActive Publication Date: 2025-08-05BEIJING DESIN DESHENG TECH CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202411452067.9
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-10-17
Publication Date
2025-08-05
Estimated Expiration
2044-10-17

AI Technical Summary

Technical Problem

Existing semiconductor manufacturing software has limitations in terms of customization capabilities, development difficulty, enclosure, execution efficiency and cost, and it is difficult to meet the needs of rapid adjustment and efficient processing of large-scale data.

Method used

Provides a process instance execution method, identifying customized execution nodes through the background server, obtaining customized configuration parameters, determining customization methods, obtaining customized script code, encapsulate it into executable scripts, and executing and transmitting result data through an interpreter, supporting distributed processing.

Benefits of technology

It realizes a high level of customization, reduces development difficulty, improves ease of use and popularization, supports distributed processing, ensures efficient data processing and analysis, and adapts to the production processes and processes of different manufacturers.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119415189B_ABST
    Figure CN119415189B_ABST
Patent Text Reader

Abstract

The present application provides a process instance execution method and electronic device, which include: a background server determines the current execution node of the process instance and determines whether the current execution node is a customized execution node; if it is a customized execution node, the background server obtains the customized configuration parameters of the customized execution node; based on the customized configuration parameters, determines the current customization mode: pre-insert execution, post-insert execution, overall logic execution, fixed-point execution; based on the current customization mode, the background server obtains the corresponding customized script code from the database; the background server encapsulates the customized script code to form a customized executable script; the background server starts an interpreter to execute the customized execution script and generate customized result data, and transmits the customized result data to the background server through the established interpreter communication interface; the background server executes the next execution node of the process instance based on the customized result data.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of semiconductor computing, and in particular to a process instance execution method and electronic equipment. Background Art

[0002] In the semiconductor or pan-semiconductor industry, the production and manufacturing process includes numerous steps, and the process for each step varies from manufacturer to manufacturer. In order to quickly adapt to changes in market demand, the production process needs to be able to be adjusted quickly and flexibly. This requires the software to not only have a high degree of customization capabilities, but also to be able to efficiently process large amounts of data. Traditional software solutions, such as the German SAP system, although they provide customization options to a certain extent, such as secondary development through the ABAP scripting language, have some limitations. The ABAP language is not widely used, developers are scarce, and development is difficult. In addition, ABAP's closed nature, functional limitations, dependence on hardware for execution efficiency, lack of support for distributed processing, and high costs make it difficult to fully meet industry needs. Summary of the Invention

[0003] In order to solve the above technical problems, the present application provides a process instance execution method and electronic device to at least solve or alleviate the problems existing in the above-mentioned prior art.

[0004] To achieve the above objectives, according to one aspect of the present application, a process instance execution method is provided, which includes:

[0005] The backend server determines the current execution node of the process instance and determines whether the current execution node is a customized execution node; if it is a customized execution node, the backend server obtains customized configuration parameters of the customized execution node;

[0006] Based on the customization configuration parameters, determine the current customization mode: pre-insertion execution, post-insertion execution, overall logic execution, fixed point execution;

[0007] Based on the current customization mode, the backend server obtains the corresponding customized script code from the database;

[0008] The backend server encapsulates the customized script code to form a customized executable script;

[0009] The backend server starts the interpreter to execute the customized execution script and generate customized result data, and transmits the customized result data to the backend server through the constructed interpreter communication interface;

[0010] The backend server executes the next execution node of the process instance based on the customized result data.

[0011] An electronic device comprising:

[0012] one or more processors;

[0013] A computer-readable medium is configured to store one or more programs, and when the one or more programs are executed by the one or more processors, the one or more processors implement the method described in any one of the embodiments of the present application.

[0014] The solution provided in the embodiments of this application has at least the following technical effects:

[0015] (1) Allowing the backend server to identify and execute customized execution nodes and determine the customization method by obtaining customized configuration parameters, thereby achieving a high degree of customization. This meets the industry's demand for software customization capabilities, enabling the software to adapt to the production processes and procedures of different manufacturers.

[0016] (2) Customized script code is retrieved from the database and executed, generating customized result data that is then transmitted to the backend server via a communication interface. This process ensures efficient data processing and analysis, supporting real-time decision-making and optimization.

[0017] (3) By encapsulating customized logic in scripts and executing them through an interpreter, the development difficulty is reduced. When language developers are scarce, customized scripts can also be written in more popular programming languages, which improves ease of use and popularity.

[0018] (4) The database and interpreter communication interface indicates that the system supports open standards and APIs, which facilitates integration with other systems and functional expansion. This overcomes the problems of closedness and functional limitations in traditional solutions.

[0019] (5) By separating the backend server from the interpreter, this method supports a distributed processing architecture. The interpreter can run on different servers, improving execution efficiency and reliability. BRIEF DESCRIPTION OF THE DRAWINGS

[0020] The drawings that constitute part of this application are used to provide a further understanding of this application and make other features, objects and advantages of this application more apparent. The illustrative embodiment drawings of this application and their descriptions are used to explain this application and do not constitute an improper limitation of this application. In the drawings:

[0021] Figure 1 This is a flow chart of a method for executing a process instance according to an embodiment of the present application. DETAILED DESCRIPTION

[0022] In order to enable those skilled in the art to better understand the present invention, the following will provide a clear and complete description of the technical solutions in the embodiments of the present invention in conjunction with the accompanying drawings. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative work should fall within the scope of protection of the present invention.

[0023] Figure 1 This is a flow chart of a method for executing a process instance according to an embodiment of the present application. Figure 1 As shown, it includes:

[0024] The backend server determines the current execution node of the process instance and determines whether the current execution node is a customized execution node; if it is a customized execution node, the backend server obtains customized configuration parameters of the customized execution node;

[0025] Based on the customization configuration parameters, determine the current customization mode: pre-insertion execution, post-insertion execution, overall logic execution, fixed point execution;

[0026] Based on the current customization mode, the backend server obtains the corresponding customized script code from the database;

[0027] The backend server encapsulates the customized script code to form a customized executable script;

[0028] The backend server starts the interpreter to execute the customized execution script and generate customized result data, and transmits the customized result data to the backend server through the constructed interpreter communication interface;

[0029] The backend server executes the next execution node of the process instance based on the customized result data.

[0030] The solutions provided in the above embodiments of the present application have at least the following technical effects:

[0031] (1) Allowing the backend server to identify and execute customized execution nodes and determine the customization method by obtaining customized configuration parameters, thereby achieving a high degree of customization. This meets the industry's demand for software customization capabilities, enabling the software to adapt to the production processes and procedures of different manufacturers.

[0032] (2) Obtain customized script code from the database and execute it to generate customized result data, which is then transmitted to the backend server through the communication interface. This process ensures that functions can be flexibly customized according to needs.

[0033] (3) By encapsulating customized logic in scripts and executing them through an interpreter, the development difficulty is reduced.

[0034] (4) The database and interpreter communication interface indicates that the system supports open standards and APIs, which facilitates integration with other systems and functional expansion. This overcomes the problems of closedness and functional limitations in traditional solutions.

[0035] (5) Through the separation design of the background server and the interpreter, it supports concurrent execution of multiple threads, improving execution efficiency and reliability.

[0036] Optionally, the backend server determines a current execution node of the process instance and determines whether the current execution node is a customized execution node, including:

[0037] The background server obtains the process execution status data, parses the process execution status data to determine the current execution node of the process instance, and parses the process instance request corresponding to the current execution node to extract the node label of the current execution node, so as to determine whether the current execution node is a customized execution node based on the node label.

[0038] To this end, the background server determines the current execution node of the process instance and determines whether the current execution node is the preferred solution for the customized execution node, which has the following technical advantages:

[0039] (1) By determining whether the current execution node is a customized execution node, the system can flexibly handle different business processes. Customized execution nodes allow customized processing based on specific needs, improving the adaptability and flexibility of business processes.

[0040] (2) This solution enables the system to easily add or modify customized nodes without requiring major adjustments to the entire process. This greatly enhances the scalability of the system, allowing it to better adapt to new needs or changes that may arise in the future.

[0041] (3) By analyzing process execution status data and determining the current execution node, the system can allocate and manage resources more accurately. Customized execution node identification enables the system to utilize resources more efficiently, ensuring that critical or complex business processes receive appropriate attention and processing.

[0042] (4) The introduction of customized execution nodes enables the system to better meet the specific needs of users, thereby improving the user experience. Users can customize specific process nodes according to their business needs, making the business process more in line with actual work needs.

[0043] (5) The solution supports both standardization of business processes and customization based on standardization. This coexistence of standardization and customization helps enterprises maintain consistency in business processes while also meeting the special needs of different departments or projects.

[0044] Optionally, parsing the process instance request corresponding to the current execution node to extract the node label of the current execution node includes: parsing the process instance request corresponding to the current execution node to determine request header content therefrom and parsing the request header content to extract the node label of the current execution node therefrom;

[0045] The determining, based on the node label, whether the current execution node is a customized execution node includes: determining whether the node label of the current execution node includes a name of a customized executable code, which includes at least one of customized built-in names of pre-insert execution, post-insert execution, overall logic execution, and fixed-point execution; if so, determining that the current execution node is a customized execution node;

[0046] The backend server obtains the customized configuration parameters of the customized execution node, including: obtaining the customized configuration parameters corresponding to the name from the request header content, the customized configuration parameters being the names in the customized script code.

[0047] To this end, the above solution has the following technical advantages:

[0048] (1) By parsing the process instance request and paying special attention to the request header content, the system can more quickly and accurately extract the node label of the currently executing node. This method improves the efficiency of data processing and ensures the correct execution of subsequent processes.

[0049] (2) By determining whether the node label contains the name of the customized executable code, the system can accurately identify the customized execution node. This clear identification mechanism helps the system distinguish and process different types of nodes, thereby improving the flexibility and adaptability of the process.

[0050] (3) The identification of customized execution nodes enables the system to allocate and manage resources more accurately. For customized nodes, the system can allocate corresponding resources based on their specific configuration parameters and requirements, thereby ensuring that critical or complex business processes receive appropriate attention and processing.

[0051] (4) Users can customize specific process nodes according to their business needs and achieve personalized needs through node labels and customized configuration parameters. This customization capability enables the system to better meet the specific needs of users, thereby improving user experience and satisfaction.

[0052] Optionally, based on the customized configuration parameters, the current customization mode is determined: pre-insert execution, post-insert execution, overall logic execution, fixed-point execution, including: if the customized configuration parameter name is pre_script, it is pre-insert execution, and the corresponding customized script code will be executed before the process instance node is executed; if the customized configuration parameter name is suf_script, it is post-insert execution, and the corresponding customized script code will be executed after the process instance node is executed; if the customized configuration parameter name is target_script, it is overall logic execution, and the corresponding customized script code will be responsible for all execution logic of the process instance node; the process instance node determines whether there is a fixed-point execution customized configuration, and if so, it goes to the database to query the corresponding customized script and executes it.

[0053] To this end, the above solution has the following technical advantages:

[0054] (1) The system provides a variety of customization methods, such as pre-insertion execution, post-insertion execution, overall logic execution, and fixed-point execution, so that users can choose the most appropriate customization method according to actual needs, thereby improving the flexibility and adaptability of the system.

[0055] (2) Through different customization methods, users can precisely control the execution timing of customized script code. For example, pre-insert execution allows the customized script to be executed before the process instance node is executed, while post-insert execution allows the customized script to be executed after the process instance node is executed. This fine-grained control helps meet complex business needs.

[0056] (3) The system allows users to specify customization methods by customizing configuration parameters without modifying the underlying code. This design improves the scalability and maintainability of the system, making it easier for the system to adapt to future changes.

[0057] (4) By precisely controlling the timing and method of executing custom scripts, the system can better optimize resource utilization. For example, executing custom scripts only when needed can avoid unnecessary resource waste.

[0058] Optionally, based on the current customization mode, the backend server obtains corresponding customized script code from the database, including:

[0059] The customized built-in name is read from the customized configuration parameters, and the parameter content of the customized built-in name is used to search the background database for a customized script code whose script code name is equal to the parameter content. If the search fails, the execution of the current customized method is ignored.

[0060] To this end, the above solution has the following technical advantages:

[0061] (1) By customizing the parameter content of the built-in name, the system can accurately search for matching customized script code in the background database. This method ensures the accurate correspondence between customized script code and business requirements, avoiding incorrect execution or execution of irrelevant script code.

[0062] (2) Searching for customized script codes with names equal to customized built-in names allows for quick location of the script to be executed, reducing unnecessary database queries and script execution time. This precise location method improves system execution efficiency, enabling customized functions to respond to business needs more quickly.

[0063] (3) If the search for the customized script code in the database fails, the system can ignore the execution of the current customized method. This mechanism prevents system crashes or anomalies caused by missing or incorrect script code, and enhances the robustness and stability of the system.

[0064] (4) Managing script code through customized built-in names makes script maintenance and management much simpler. Administrators can easily add, delete, or modify script code and reflect these changes by updating the customized built-in names. This management approach reduces the complexity of maintenance work and improves the maintainability of the system.

[0065] Optionally, the backend server encapsulates the customized script code to form a customized executable script, including:

[0066] Obtaining the environment variables and configuration file paths required for the customized executable script to run, initializing the database connection, and preparing input parameters to create an execution context;

[0067] Generate corresponding startup code for the execution context;

[0068] An execution body is generated according to the execution context, the startup code, and the customized script code, and the execution body is encapsulated into a constructed function to form a customized executable script.

[0069] To this end, the above solution has the following technical advantages:

[0070] (1) By encapsulating the customized script code through the backend server to form a customized executable script, the preparation work and initialization time for script execution can be reduced. During the encapsulation process, the system has obtained the environment variables, configuration file paths, database connections, etc. required for script execution, allowing the script to directly utilize these resources during execution, thereby improving execution efficiency.

[0071] (2) During the packaging process, the system creates an execution context for the customized script code and generates the corresponding startup code. This provides a more stable and reliable environment for script execution, reducing the risk of script execution failure due to environmental differences or configuration errors.

[0072] (3) By encapsulating customized script code into executable scripts, the system can more easily manage and maintain scripts. Administrators can easily deploy, update, or delete scripts without having to worry about the specific implementation details of the scripts. This management method reduces the complexity of maintenance work and improves the maintainability of the system.

[0073] (4) During the encapsulation process, the system can generate an executable body based on the execution context, startup code, and customized script code, and encapsulate the executable body into the constructed function. This approach promotes code reuse and modularization, allowing the same script code to be reused in different business scenarios, improving code reusability and maintainability.

[0074] (5) This technical solution enables the system to flexibly respond to different customized requirements. By encapsulating customized script code, the system can easily add new scripts or modify existing scripts to support new business processes or functions. This flexibility promotes the scalability of the system, allowing the system to better adapt to future business needs.

[0075] Optionally, the backend server starts an interpreter to execute the customized execution script and generate customized result data, and transmits the customized result data to the backend server through the established interpreter communication interface, including:

[0076] Reading a customized built-in name from the customized configuration parameters, and loading a corresponding customized execution script onto the interpreter based on the parameter content of the customized built-in name to execute the customized execution script and generate customized result data;

[0077] The customized result data is transmitted to the backend server through the constructed interpreter communication interface.

[0078] To this end, the above technical solution has the following technical advantages:

[0079] (1) The backend server can quickly load and execute the corresponding script according to the parameter content of the customized built-in name. This efficient script loading and execution mechanism ensures a quick response to customized requirements and improves the overall execution efficiency of the system.

[0080] (2) By loading different customized execution scripts, the backend server can flexibly handle various customized requirements. This flexibility enables the system to easily respond to changing business needs without requiring extensive code modifications or refactoring.

[0081] (3) Through the established interpreter communication interface, customized result data can be stably and reliably transmitted to the backend server. This reliable data transmission mechanism ensures the accuracy and completeness of customized results, providing a solid foundation for subsequent business processing.

[0082] (4) This technical solution simplifies the overall system architecture by executing customized scripts through an interpreter and transmitting the resulting data to a backend server. This simplified architecture makes the system easier to maintain and expand, reducing system complexity and maintenance costs.

[0083] (5) Since the backend server can dynamically load and execute different customized scripts, the system has strong scalability. When new customized functions need to be added, it is only necessary to develop the corresponding script and deploy it on the server, without the need for large-scale modification or reconstruction of the system.

[0084] Optionally, executing the customized execution script and generating customized result data includes:

[0085] The customized execution script is parsed based on the interpreter to obtain an execution context, which includes at least a request header, a request body, and environment variables, and the customized logic in the customized execution script loads the execution context to execute the customized execution script and generate customized result data.

[0086] To this end, the above solution has the following technical advantages:

[0087] (1) The interpreter can accurately parse customized execution scripts and obtain the execution context, which includes key information such as request headers, request bodies, and environment variables. This precise parsing ensures that the required data and status can be accurately obtained when the script is executed, providing a solid foundation for subsequent logical processing.

[0088] (2) By customizing the logic in the execution script, the system can flexibly load and execute different business logic. This flexibility enables the system to easily cope with various complex business needs without tedious code modification or reconstruction.

[0089] (3) After obtaining the execution context, the customized execution script can be executed efficiently and generate customized result data. This efficient execution mechanism ensures that the system can quickly respond to business needs and improve overall execution efficiency.

[0090] (4) Because the interpreter can parse and execute different customized execution scripts, the system has strong scalability. When adding new functions or modifying existing functions, it is only necessary to develop or modify the corresponding scripts, without the need for large-scale modification or reconstruction of the system. At the same time, this modular design also makes system maintenance simpler and more efficient.

[0091] Optionally, the backend server executes the next execution node of the process instance based on the customized result data, including:

[0092] The background server obtains customized result data and a signal of whether to continue executing the next execution node of the process instance from the customized execution script to determine whether to jump from the current execution node to the next execution node and transmit the customized result data.

[0093] To this end, the above technical solution has the following technical advantages:

[0094] (1) The backend server can obtain a signal from the customized execution script indicating whether to continue executing the next execution node of the process instance. This design makes process control more flexible. The system can dynamically decide whether to jump to the next execution node based on customized result data, thus meeting complex business process requirements.

[0095] (2) By obtaining customized result data from the customized execution script, the backend server can use this data as part of the process instance execution for subsequent business logic processing or decision making. This effective use of customized results improves the overall execution efficiency and business processing capabilities of the system.

[0096] (3) This technical solution ensures the continuity of process instances during execution. The backend server can determine whether to jump from the current execution node to the next execution node based on the customized result data and the execution node signal, and transmit the necessary data. This continuity ensures the smooth progress of business processes and the accurate transmission of data.

[0097] (4) By embedding process control logic into customized execution scripts, which are then parsed and executed by the backend server, the system simplifies the complexity of process management. Administrators can more easily define and modify business processes without having to deeply understand the implementation details of the underlying system.

[0098] (5) This technical solution enables the system to be easily expanded and adapted to new business processes or customized requirements. When adding new execution nodes or modifying existing nodes, it is only necessary to update the customized execution script and deploy it to the backend server, without the need for large-scale modification or reconstruction of the system.

[0099] Optionally, the backend server determines a current execution node of the process instance and determines whether the current execution node is a customized execution node, including:

[0100] If the current execution node is a process instance request parsing node, it is determined whether the generated process instance request includes customized configuration parameters. If so, it is determined that the current execution node is a customized execution node.

[0101] Optionally, the determination of whether the generated process instance request includes customized configuration parameters includes determining whether the generated process instance request includes a pre-insert execution identifier. If included, determining that the current execution node is a pre-insert execution node, so as to immediately execute the pre-insert execution business logic after the process instance request is parsed.

[0102] Optionally, the determination of whether the generated process instance request includes customized configuration parameters includes determining whether the generated process instance request includes a post-insert execution identifier. If so, determining that the current execution node is a post-insert execution node, so as to immediately execute the post-insert execution business logic after the last process instance standardized execution node.

[0103] Optionally, the determination of whether the generated process instance request includes customized configuration parameters includes determining whether the generated process instance request includes an overall logic execution identifier. If included, determining that the current execution node is an overall logic execution node, so that after the process instance request is parsed, all business logic points of the process instance are immediately replaced with the overall replacement execution business logic.

[0104] Optionally, the determination of whether the generated process instance request includes customized configuration parameters includes determining whether there is a fixed-point execution node before or after the current execution node. If so, the fixed-point execution business logic is executed immediately before or after the execution of the current execution node.

[0105] To this end, the above technical solution has the following technical advantages:

[0106] (1) By determining whether the process instance request includes a pre-insert execution flag, a post-insert execution flag, an overall logic execution flag, and a fixed-point execution node, the system can flexibly control the execution of the business process. This flexibility enables the system to dynamically adjust the execution logic of the process instance according to different business needs to meet complex business scenarios.

[0107] (2) When a process instance request contains specific customized configuration parameters, the system can immediately execute the corresponding customized business logic. For example, if a pre-insert execution flag is included, the relevant logic is immediately executed at the pre-insert execution node; if a post-insert execution flag is included, the relevant logic is executed after the last standardized execution node. This immediate execution mechanism ensures that customized business logic can be accurately inserted into the execution process of the process instance, improving business processing flexibility.

[0108] (3) If the process instance request contains the overall logic execution identifier, the system can replace all business logic points of the process instance with the overall replacement execution business logic. This replacement mechanism enables the system to uniformly optimize and transform the entire business process, improving the execution efficiency and consistency of the business process.

[0109] (4) By determining whether there are fixed execution nodes before or after the current execution node, the system can accurately execute fixed business logic at specific points. This precise execution mechanism ensures the stability and reliability of business processes at key nodes and improves the overall execution quality of the business.

[0110] (5) This technical solution enables the system to be easily expanded and adapted to new business processes or customized requirements by providing a variety of customized configuration parameters and corresponding execution logic. When adding a new execution node or modifying an existing node, it is only necessary to include the corresponding customized configuration parameters in the process instance request, without the need for large-scale modification or reconstruction of the system.

[0111] The four customization modes provided in the above embodiment are explained in exemplary application scenarios as follows:

[0112] (1) Pre-insert execution:

[0113] For any request initiated by the frontend, custom logic can intervene and perform necessary interventions before the request enters the standard processing flow. This approach is suitable for scenarios where request parameters need to be verified, allowing parameters to be pre-processed or validated before the request is officially processed.

[0114] (2) Post-insert execution:

[0115] Custom logic can intercept and intervene in requests initiated by the frontend after the request has completed the standard processing flow. This approach is suitable for scenarios where subsequent processing or manipulation of the request results is required, allowing for additional manipulation or modification of the results after the request has been processed.

[0116] (3) Overall logic replacement execution:

[0117] All requests initiated by the frontend are intercepted and processed entirely by custom logic. This approach is suitable for scenarios where request implementation undergoes significant changes and requires reimplementation. Unlike pre- and post-insert execution, full logic replacement completely abandons the standard processing flow and reimplements the entire request processing logic using custom logic.

[0118] (3) Fixed point execution:

[0119] The standard processing of specific logic typically involves multiple steps. Fixed-point execution allows custom logic to fine-tune each of these steps, thereby influencing the overall processing outcome. This approach provides finer granularity than pre- and post-insertion execution. By providing callback interfaces for each processing step, custom logic can be given processing opportunities at each step.

[0120] Considering existing technologies, software development languages can be divided into two broad categories: compiled execution languages (such as C, C++, Objective-C, and Go) and interpreted execution languages (such as Java, Python, Perl, Lua, and JavaScript). Software developed with compiled execution languages requires compilation into machine code, resulting in high execution efficiency. However, the source code is not visible, and users cannot modify or customize any functionality. Software developed with interpreted execution languages does not require compilation and requires an interpreter to translate symbols into machine code at runtime before running. This results in lower execution efficiency, but users can see the source code and fine-tune functionality according to their needs. Therefore, no existing software development language can meet the requirements of both high customization and high-performance big data processing.

[0121] To this end, in the above embodiment, it is creatively proposed that the background server is developed based on C++, and the customized script is developed based on Python. Through this combination, C++ is responsible for high-performance data processing, and Python is responsible for the user's highly customized needs, thereby achieving both highly customizable and high-performance processing of big data.

[0122] To this end, when implementing the above solution, the Python code (as customized script code) is saved in a file to form a Python script (as a customized executable script), and then the Python script is executed by the Python interpreter. The execution of the Python code is independent of the C++ process of the background server. The advantage is that it can support multi-threaded concurrent execution. At the same time, even if there are bugs in the Python code, it will not cause the C++ process to crash, and the system is more robust and reliable.

[0123] The following uses the application in the query link as an example to illustrate the above-mentioned solution of the present application. However, it should be noted here that the above-mentioned solution of the present application is not limited to being applied only to the query link. For this reason, the solution of the embodiment of the solution of the present application is exemplarily divided into four stages: front-end request, request routing management, Python script, and request standard processing.

[0124] In one scenario, both pre-insert execution and post-insert execution exist. Therefore, it is referred to as pre-insert execution and post-insert execution, which includes the following processing:

[0125] Step 1. The user clicks the query button;

[0126] Step 2: Construct an HTTP POST request and add the following parameters to the request: the pre-insert execution identifier and the name of the customized executable code corresponding to the pre-insert execution as the customized configuration parameter name pre_script, the name of the method used by the customized executable code pre_func, the post-insert execution identifier and the name of the customized executable code corresponding to the post-insert execution as the customized configuration parameter name suf_script, and the name of the method used by the customized executable code suf_func;

[0127] Step 3: Determine whether the HTTP POST request includes the name of the customized configuration parameter pre_script corresponding to the pre-insertion execution, and the name of the method pre_func used by the customized executable code corresponding to the pre-insertion execution;

[0128] If yes, execute step 4, trigger the backend server to obtain the customized script code corresponding to the pre-insert execution from the database according to the customized configuration parameter name pre_script corresponding to the pre-insert execution and the method name pre_func used by the customized executable code to encapsulate it into a customized executable script;

[0129] If not, skip to step 8 and perform standard processing on the HTTP POST request;

[0130] Step 5: The backend server starts the interpreter to execute the corresponding customized execution script in the front end;

[0131] Step 6: Transmitting the customized result data corresponding to the pre-insertion execution from the front end to the back end server through the constructed interpreter communication interface;

[0132] Step 7: Wait for the pre-insert execution to be completed;

[0133] Step 8: Generate a notification that the pre-insert process is complete, and jump to step 9;

[0134] Step 9: Request standard processing;

[0135] Step 10: Return the standard processing result;

[0136] Step 11: Determine whether the HTTP POST request includes the name of the customized configuration parameter suf_script to be executed after the post-insertion, and the name of the method suf_func to be used for the customized executable code to be executed after the post-insertion;

[0137] If yes, execute step 12, trigger the backend server to obtain the customized script code corresponding to the post-insert execution from the database according to the name of the customized configuration parameter pre_script corresponding to the post-insert execution and the name of the method used by the customized executable code pre_func to encapsulate it into a customized executable script;

[0138] Step 13: The backend server starts the interpreter to execute the corresponding customized execution script in the front end;

[0139] Step 14: Transmitting the customized result data corresponding to the post-insertion execution from the front end to the back end server through the constructed interpreter communication interface;

[0140] Step 15: Wait for the post-insert execution to be completed;

[0141] Step 16: Generate a notification that the post-insert execution process is completed;

[0142] Step 17: Return the result of the HTTP POST request.

[0143] Step 18: User browses data.

[0144] In another scenario, the overall logic is executed, which includes the following processing:

[0145] Step 1. The user clicks the query button;

[0146] Step 2: Construct an HTTP POST request and add the following parameters to the request: the overall logic execution identifier and the name of the customized executable code corresponding to the overall logic execution as the customized configuration parameter name target_script, and the name of the method used by the customized executable code target_func;

[0147] Step 3: Determine whether the HTTP POST request includes the name of the customized configuration parameter target_script corresponding to the overall logic execution and the name of the method used by the customized executable code target_func corresponding to the overall logic execution;

[0148] If yes, execute step 4, trigger the backend server to obtain the customized script code corresponding to the overall logic execution from the database according to the corresponding customized configuration parameter name target_script and the method name target_func used by the customized executable code, and encapsulate it into a customized executable script;

[0149] If not, skip to step 8 and perform standard processing on the HTTP POST request;

[0150] Step 5: The backend server starts the interpreter to execute the customized execution script corresponding to the overall logic execution at the front end;

[0151] Step 6: Transmit the customized result data corresponding to the overall logic execution from the front end to the back end server through the constructed interpreter communication interface;

[0152] Step 7: Wait for the overall logic execution to be completed;

[0153] Step 8: Generate a notification that the overall logic execution is complete and jump to step 10;

[0154] Step 9: Return the result of the HTTP POST request;

[0155] Step 10: User browses data.

[0156] In another scenario, the fixed-point execution includes the following processing steps:

[0157] Step 1. The user clicks the query button;

[0158] Step 2: Construct an HTTP POST request.

[0159] Step 3: The first standard processing step of HTTP POST request;

[0160] Step 4: Check whether there are primary and secondary functions and customized configuration parameters;

[0161] If yes, execute step 5, judge and read the customized built-in name from the customized configuration parameter, and use the parameter content of the customized built-in name to search the background database for a customized script code whose script code name is equal to the parameter content;

[0162] If not, jump to step 13 and perform standard processing on the HTTP POST request;

[0163] Step 6: The backend server starts the interpreter to execute the corresponding customized execution script at the fixed point on the front end;

[0164] Step 7: Transmitting the customized result data corresponding to the fixed-point execution from the front end to the backend server through the constructed interpreter communication interface;

[0165] Step 8: Wait for the fixed point to be processed;

[0166] Step 9: Generate a notification that the fixed point execution process is completed and jump to step 11;

[0167] Step 10: The second standard processing step of the HTTP POST request - the Nth standard processing step;

[0168] Step 11: Return the result of the HTTP POST request.

[0169] Step 12: User browses data.

[0170] In this embodiment, the specific processing logic of the first standard processing link, the second standard processing link, and the Nth standard processing link is not limited and can be determined according to the application scenario.

[0171] An embodiment of the present application further provides an electronic device, comprising:

[0172] one or more processors;

[0173] A computer-readable medium is configured to store one or more programs, and when the one or more programs are executed by the one or more processors, the one or more processors implement the method described in any one of the embodiments of the present application.

[0174] The above description is merely a preferred embodiment of the present application and an illustration of the technical principles employed. Those skilled in the art should understand that the scope of the invention involved in this application is not limited to the technical solutions formed by the specific combination of the above-mentioned technical features, but also encompasses other technical solutions formed by any combination of the above-mentioned technical features or their equivalents without departing from the above-mentioned inventive concept. For example, a technical solution formed by replacing the above-mentioned features with (but not limited to) technical features with similar functions disclosed in this application.

Claims

1. A process instance execution method, characterized in that: include: The backend server determines the current execution node of the process instance and determines whether the current execution node is a customized execution node; If it is a customized execution node, the backend server obtains customized configuration parameters of the customized execution node; Based on the customization configuration parameters, determine the current customization mode: pre-insertion execution, post-insertion execution, overall logic execution, fixed point execution; Based on the current customization mode, the backend server obtains the corresponding customized script code from the database; The backend server encapsulates the customized script code to form a customized executable script; The backend server starts the interpreter to execute the customized executable script and generate customized result data, and transmits the customized result data to the backend server through the constructed interpreter communication interface; The backend server executes the next execution node of the process instance based on the customized result data; The backend server determines the current execution node of the process instance and determines whether the current execution node is a customized execution node, including: If the current execution node is a process instance request parsing node, determining whether the generated process instance request includes customized configuration parameters; if so, determining that the current execution node is a customized execution node; The determination of whether the generated process instance request includes customized configuration parameters includes: determining whether the generated process instance request includes a pre-insert execution identifier, and if so, determining that the current execution node is a pre-insert execution node, so as to immediately execute the pre-insert execution business logic after the process instance request is parsed; determining whether the generated process instance request includes a post-insert execution identifier, and if so, determining that the current execution node is a post-insert execution node, so as to immediately execute the post-insert execution business logic after the last process instance standardized execution node; determining whether the generated process instance request includes an overall logic execution identifier, and if so, determining that the current execution node is an overall logic execution node, so as to immediately replace all business logic points of the process instance with the overall replacement execution business logic after the process instance request is parsed; determining whether the generated process instance request includes a fixed-point execution identifier, and if so, determining whether it is before or after the execution of the current execution node, so as to immediately execute the fixed-point execution business logic.

2. The method according to claim 1, characterized in that The backend server determines the current execution node of the process instance and determines whether the current execution node is a customized execution node, including: The background server obtains the process execution status data, parses the process execution status data to determine the current execution node of the process instance, and parses the process instance request corresponding to the current execution node to extract the node label of the current execution node, so as to determine whether the current execution node is a customized execution node based on the node label.

3. The method according to claim 1, characterized in that Based on the customized configuration parameters, the current customization mode is determined: pre-insert execution, post-insert execution, overall logic execution, and fixed-point execution, including: if the customized configuration parameter name is pre_script, it is pre-insert execution, and the corresponding customized script code will be executed before the process instance node is executed; if the customized configuration parameter name is suf_script, it is post-insert execution, and the corresponding customized script code will be executed after the process instance node is executed; if the customized configuration parameter name is target_script, it is overall logic execution, and the corresponding customized script code will be responsible for all execution logic of the process instance node; the process instance node determines whether there is a fixed-point execution customized configuration, and if so, it goes to the database to query the corresponding customized script and executes it.

4. The method according to claim 1, wherein The backend server executes the next execution node of the process instance based on the customized result data, including: The backend server obtains customized result data and a signal of whether to continue executing the next execution node of the process instance from the customized executable script to determine whether to jump from the current execution node to the next execution node and transmit the customized result data.

5. An electronic device comprising: one or more processors; A computer-readable medium configured to store one or more programs, wherein when the one or more programs are executed by the one or more processors, the one or more processors implement the method according to any one of claims 1 to 4.

Citation Information

Patent Citations

  • Business node control method, system and device and storage medium

    CN112487056A

  • Business processing method and device, electronic equipment and storage medium

    CN115564322A