PSR object design process version rollback method and device, equipment and medium
By obtaining and utilizing the original process design data and database operation log of the target process design change time period of the PSR object, the accurate fallback of the PSR object design process version is achieved, and the version fallback stability and accuracy in the existing technology is solved. The problem improves the controllability of user operations.
Patent Information
- Application Number
- CN202411049976.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-08-01
- Publication Date
- 2024-11-26
AI Technical Summary
The existing PSR object design version fallback method When designing multiple objects, the stability and accuracy of version fallback are poor, making it difficult for users to quickly roll back to historical versions, which easily leads to the inability to restore the design results.
By obtaining the change time period of the target process design, the original process design data and database operation log matching the PSR object and the target process design are obtained, and version fallback is performed based on these data to achieve accurate fallback of the process design.
Improve the stability and accuracy of version fallback. Users can specify the target process design for version fallback, avoid relying on memory reconfiguration, and enhance the controllability and accuracy of the design.
Smart Images

Figure CN119025079A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of computer technology, and in particular to a PSR object design process version rollback method, apparatus, computer equipment, computer-readable storage medium and computer program product. Background Art
[0002] With the development of computer technology, a technical solution for product design based on PSR objects, namely product-service-resource objects, has emerged. Process design in PSR object design is particularly important, as it is an important link in determining whether the PSR object can be successfully loaded on the existing network.
[0003] In traditional technology, when users are designing processes for multiple PSR objects at the same time, if there is a problem with the configured process, they cannot specify to quickly roll back the process design of a certain PSR object to a historical version, and can only reconfigure it based on memory. This design process version rollback method may cause the process design results to be unable to be rolled back and restored if the user forgets. Therefore, the stability and accuracy of the version rollback of the existing PSR object design version rollback method are poor. Summary of the invention
[0004] Based on this, it is necessary to provide a PSR object design process version rollback method, apparatus, computer equipment, computer-readable storage medium and computer program product that can improve the stability and accuracy of version rollback in response to the above-mentioned technical problems.
[0005] In a first aspect, the present application provides a PSR object design process version rollback method, comprising:
[0006] In response to a version rollback request initiated for a target process design of a PSR object, obtaining a target process design change time period associated with the design process version rollback request;
[0007] Obtaining original process design data and database operation logs that match the PSR object, the target process design, and the target process design change time period from a pre-built storage medium;
[0008] Based on the original process design data and the database operation log, version rollback is performed on the target process design of the PSR object.
[0009] In one of the embodiments, before responding to the version rollback request initiated for the target process design of the PSR object, it also includes: responding to the process design data change request initiated for the target process design of the PSR object, determining the isolation space associated with the process design data change request, and storing the original process design data corresponding to the process design data change request in the isolation space; responding to the process design data change operation initiated for the process design data change request, generating a database operation log corresponding to the process design data change request according to the process design data change operation, and storing the generated database operation log in the isolation space; responding to the process design data save operation initiated for the process design data change request, obtaining the process design change time period corresponding to the process design data change request, and storing the process design change time period, the space information of the isolation space, the original process design data stored in the isolation space and the database operation log in the storage medium; wherein the space information is used to characterize the correspondence between the PSR object and the target process design and the isolation space.
[0010] In one of the embodiments, the isolation space is set in a space isolation module; the response to the process design data change request initiated for the target process design of the PSR object, determining the isolation space associated with the process design data change request, includes: in response to the process design data change request, obtaining the object identifier of the PSR object and the process design identifier of the target process design; based on the object identifier and the process design identifier, detecting whether an isolation space identifier associated with the object identifier and the process design identifier is pre-stored in the space isolation module; in the case where the isolation space identifier is pre-stored in the space isolation module, using the isolation space corresponding to the isolation space identifier as the isolation space associated with the process design data change request; in the case where the isolation space identifier is not pre-stored in the space isolation module, creating an isolation space in the space isolation module, and using the created isolation space as the isolation space associated with the process design data change request.
[0011] In one of the embodiments, after creating the isolation space in the space isolation module, it also includes: generating an object design process identifier based on the object identifier and the process design identifier; the object design process identifier is used to uniquely identify the target process design of the PSR object; obtaining the isolation space identifier of the isolation space created in the space isolation module; and constructing a correspondence between the object design process identifier and the isolation space identifier in the space isolation module.
[0012] In one of the embodiments, the object design process identifier is generated based on the object identifier and the process design identifier, including: obtaining the request trigger time of the process design data change request, and the operating environment identifier associated with the process design data change request; processing the request trigger time through a snowflake algorithm to obtain random number information; and concatenating the operating environment identifier, the object identifier, the process design identifier and the random number information to generate the object design process identifier.
[0013] In one of the embodiments, in response to the process design data save operation initiated for the process design data change request, obtaining the process design change time period corresponding to the process design data change request includes: in response to the process design data save operation, obtaining the save trigger time of the process design data save operation; obtaining the request trigger time of the process design data change request, and determining the process design change time period according to the request trigger time and the save trigger time.
[0014] In one of the embodiments, in response to a version rollback request initiated for a target process design of a PSR object, obtaining a target process design change time period associated with the design process version rollback request includes: in response to the version rollback request, obtaining an object identifier of the PSR object and a process design identifier of the target process design, and obtaining from the storage medium at least one candidate process design change time period associated with the object identifier and the process design identifier; displaying each of the candidate process design change time periods; and in response to a selection operation on the displayed candidate process design change time period, using the selected candidate process design change time period as the target process design change time period.
[0015] In a second aspect, the present application also provides a PSR object design process version rollback device, including:
[0016] A change time acquisition module, used to respond to a version rollback request initiated for a target process design of a PSR object, and acquire a target process design change time period associated with the design process version rollback request;
[0017] A rollback information acquisition module, used to acquire original process design data and database operation logs matching the PSR object, the target process design, and the target process design change time period from a pre-built storage medium;
[0018] The version rollback processing module is used to perform version rollback processing on the target process design of the PSR object based on the original process design data and the database operation log.
[0019] In a third aspect, the present application further provides a computer device, comprising a memory and a processor, wherein the memory stores a computer program, and when the processor executes the computer program, the steps of the method described in any one of the embodiments of the first aspect are implemented.
[0020] In a fourth aspect, the present application further provides a computer-readable storage medium having a computer program stored thereon, and when the computer program is executed by a processor, the steps of the method described in any one of the embodiments in the first aspect are implemented.
[0021] In a fifth aspect, the present application further provides a computer program product, including a computer program, which, when executed by a processor, implements the steps of the method described in any one of the embodiments of the first aspect.
[0022] The above-mentioned PSR object design process version rollback method, apparatus, computer equipment, computer-readable storage medium and computer program product obtain the target process design change time period associated with the design process version rollback request by responding to the version rollback request initiated for the target process design of the PSR object; obtain the original process design data and database operation log that match the PSR object, the target process design, and the target process design change time period from a pre-built storage medium; and perform version rollback processing on the target process design of the PSR object based on the original process design data and the database operation log. When receiving a version rollback request initiated for a target process design of a PSR object, the present application can obtain the target process design change time period associated with the request, and then can obtain the original process design data and database operation log that match the PSR object, the target process design, and the target process design change time period from the storage medium to perform version rollback. Since the original process design data and database operation log for version rollback are bound to the PSR object, the target process design, and the process design change time period, the user can specify the target process design of the PSR object for version rollback, and the user does not need to rely on memory to reconfigure, further improving the stability and accuracy of version rollback. BRIEF DESCRIPTION OF THE DRAWINGS
[0023] In order to more clearly illustrate the technical solutions in the embodiments of the present application or related technologies, the drawings required for use in the embodiments of the present application or related technical descriptions will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technicians in this field, other related drawings can be obtained based on these drawings without paying creative work.
[0024] Figure 1 A schematic diagram of a process flow of a PSR object design process version rollback method in one embodiment;
[0025] Figure 2 A schematic diagram of a process for initiating data changes for a process design of a PSR object in one embodiment;
[0026] Figure 3 A schematic diagram of a process for determining an isolation space associated with a change in process design data in one embodiment;
[0027] Figure 4 A schematic diagram of a process for generating an object design process identifier in one embodiment;
[0028] Figure 5 A schematic diagram of a process for obtaining a target process design change time period in an embodiment;
[0029] Figure 6 A structural block diagram of a PSR object design process version rollback device in one embodiment;
[0030] Figure 7 FIG. 4 is a diagram showing the internal structure of a computer device in one embodiment. DETAILED DESCRIPTION
[0031] In order to make the purpose, technical solution and advantages of the present application more clearly understood, the present application is further described in detail below in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present application and are not used to limit the present application.
[0032] In one embodiment, Figure 1 As shown, a PSR object design process version rollback method is provided. This embodiment uses the method applied to a server as an example for illustration. It can be understood that the method can also be applied to a terminal, and can also be applied to a system including a terminal and a server, and is implemented through the interaction between the terminal and the server. In this embodiment, the method includes the following steps:
[0033] Step S101, in response to a version rollback request initiated for a target process design of a PSR object, obtain a target process design change time period associated with the design process version rollback request.
[0034] The version rollback request is initiated by the user and is used to initiate a version rollback request for the target process design of the PSR object. In this embodiment, a PSR object can correspond to multiple process designs, and a process design can also correspond to multiple time periods for changing the process design, that is, multiple process design change time periods. The target process design is the process design selected by the user when initiating the version rollback request, and the target process design change time period refers to the process design change time period selected by the user when initiating the version rollback request.
[0035] Specifically, when a user initiates a version rollback request, he or she can also select a PSR object and the process design of the PSR object, and can also select from multiple process design change time periods of the process design. At this time, the server can respond to the version rollback request, and use the process design selected by the user for the PSR object as the target process design, and the process design change time period selected by the user as the target process design change time period.
[0036] Step S102, obtaining original process design data and database operation logs that match the PSR object, the target process design, and the target process design change time period from a pre-built storage medium.
[0037] The original process design data refers to the process design data before the target process design is designed, for example, before the process design data of the target process design is changed, and may include: basic information of the process (process name, process code, process alias), process link information (start link, processing link, branch link, merge link, end link, etc.), process routing information (routing name, routing rules), etc., while the database operation log is the change operation log data of the process design data, which may be a Binlog operation log, which may record the process design data change operations of the target process design of the PSR object, such as insert, update, delete, etc. The above original process design data and database operation logs may be persistently stored in a pre-built storage medium.
[0038] Specifically, after the server determines the PSR object, the target process design, and the target process design change time period, it can uniquely determine the matching original process design data and database operation log from the storage medium.
[0039] Step S103: Based on the original process design data and the database operation log, a version rollback is performed on the target process design of the PSR object.
[0040] After obtaining the original process design data and database operation logs, the server can parse the database operation logs and the original process design data, reversely parse and execute related database operations, and thus roll back the process design results to a certain historical version.
[0041] In the above-mentioned PSR object design process version rollback method, by responding to the version rollback request initiated for the target process design of the PSR object, the target process design change time period associated with the design process version rollback request is obtained; the original process design data and database operation log that match the PSR object, the target process design, and the target process design change time period are obtained from the pre-built storage medium; based on the original process design data and the database operation log, the target process design of the PSR object is subjected to version rollback processing. This application can obtain the target process design change time period associated with the request when receiving the version rollback request initiated for the target process design of the PSR object, and then obtain the original process design data and database operation log that match the PSR object, the target process design, and the target process design change time period from the storage medium to perform version rollback. Since the original process design data and the database operation log are bound to the PSR object, the target process design, and the process design change time period, the user can specify the target process design of the PSR object for version rollback, and the user does not need to reconfigure by memory, which further improves the stability and accuracy of version rollback.
[0042] In one embodiment, Figure 2 As shown, before step S101, the following steps may also be included:
[0043] Step S201, in response to a process design data change request initiated for a target process design of a PSR object, determining an isolation space associated with the process design data change request, and storing original process design data corresponding to the process design data change request into the isolation space.
[0044] A process design data change request refers to a request initiated by a process design user to change the process design data of a target process design of a PSR object. For example, it may be a request from a process design user to edit or add process design data of a target process design. The isolation space is a storage space used to isolate process design data of different PSR objects. The isolation space is associated with the process design of the PSR object whose process design data needs to be changed, and is therefore associated with the process design data change request. The original process design data is the original data before the actual information of the process is changed when the process design data change request is made.
[0045] Specifically, when a process design user initiates a request to change the process design data of the target process design of a PSR object, the terminal can determine the isolation space associated with the process design data change request based on the target process design of the PSR object to be changed, and obtain the process design data of the current target process design of the PSR object, and store it in the isolation space as the original process design data corresponding to the process design data change request.
[0046] Step S202, in response to the process design data change operation initiated for the process design data change request, generates a database operation log corresponding to the process design data change request according to the process design data change operation, and stores the generated database operation log in the isolation space.
[0047] The process design data change operation is used to change the process design data, for example, it may include insert, update, delete and other operations, and the database operation log may refer to the Binlog operation log. When the process design user initiates a process design data change request for the target process design of the PSR object, the process design data of the target process design can be inserted, updated, deleted and other operations can be performed. At this time, the server can record the above operations to generate a database operation log, and then store the generated database operation log in the isolation space.
[0048] Step S203, in response to the process design data save operation initiated for the process design data change request, obtain the process design change time period corresponding to the process design data change request, and store the process design change time period, the spatial information of the isolation space, the original process design data stored in the isolation space, and the database operation log into the storage medium; wherein the spatial information is used to characterize the correspondence between the PSR object and the target process design and the isolation space.
[0049] The process design data save operation is used to trigger the saving of the changed process design data. This operation can be achieved by the process design user triggering the save button, and the process design change time period is the time period from the process design user initiating the process design data change request to the completion of the process design data change and saving. The spatial information of the isolation space is used to characterize the correspondence between the PSR object and the target process design, and the isolation space.
[0050] Specifically, when the process design user initiates a process design data save operation, the server can record the process design change time period corresponding to the process design data change request, and store the above process design change time period, together with the space information of the isolation space, the original process design data stored in the isolation space, and the database operation log in the storage medium to achieve persistent storage. After that, the above isolation space can be released to achieve the liberation of the isolation space.
[0051] For example, when a process design user initiates a process design data change request for the target process design 1 of PSR object A, if the isolation space corresponding to the target process design 1 of PSR object A is isolation space A1, the server can store the process design data of the current target process design 1 of PSR object A as the original process design data A1 into the isolation space A1, and record the process design user's process design data change operation for the target process design 1 of PSR object A, thereby generating a corresponding database operation log A1, and storing it in the isolation space A1. When the process design user completes the process design data change and saves it, the server The server can record the process design change time period A1, and store the space information of the isolation space A1, that is, the information indicating that the isolation space corresponds to the target process design 1 of the PSR object A, as well as the original process design data A1 and the database operation log A1 stored in the isolation space A1 in the storage medium. When the process version is rolled back later, if the PSR object of the version rollback request is the PSR object A, the target process design is the target process design 1, and the target process design change time period is the process design change time period A1, then the server can use the original process design data A1 and the database operation log A1 to perform version rollback.
[0052] Similarly, if the process design user initiates a process design data change request for the target process design 1 of PSR object A and the target process design 2 of PSR object B at the same time, the server can use the isolation space A1 as the isolation space associated with the target process design 1 of PSR object A, and use the isolation space B2 as the isolation space associated with the target process design 2 of PSR object B, and store the original process design data A1 of the current target process design 1 of PSR object A into the isolation space A1, and store the original process design data B2 of the current target process design 2 of PSR object B into the isolation space B2. Afterwards, when the process design user performs a process design data change operation, if the change operation is a change operation for the process design data of the target process design 1 of PSR object A, then a database operation log A1 can be generated according to the change operation and stored in the isolation space A1. Similarly, if the change operation is a change operation for the process design data of the target process design 2 of PSR object B, then a database operation log B2 can be generated according to the change operation and stored in the isolation space B2. When saving, the process design change time period, the space information of the isolation space A1, and the original process design data A1 and the database operation log A1 stored in the isolation space A1 can be stored in the storage medium, and the process design change time period, the space information of the isolation space B2, and the original process design data B2 and the database operation log B2 stored in the isolation space B2 can also be stored in the storage medium. When the process version is rolled back later, if the PSR object of the version rollback request is PSR object A, the target process design is target process design 1, and the target process design change time period is the process design change time period, then the server can use the original process design data A1 and the database operation log A1 to perform version rollback, and if the PSR object of the version rollback request is PSR object B, the target process design is target process design 2, and the target process design change time period is the process design change time period, then the server can use the original process design data B2 and the database operation log B2 to perform version rollback.
[0053] In this embodiment, when the process design data is changed, the process design data of different PSR objects can be isolated through the isolation space, so that different original process design data and database operation logs can be stored through different isolation spaces. Therefore, when saving, the original process design data and database operation logs of different PSR objects and different process designs can be distinguished. In this way, the process design data of each PSR object can be managed independently in the isolation space, effectively preventing data confusion and conflict, and ensuring the accuracy and integrity of the backed-up process design.
[0054] Furthermore, the isolation space is arranged in a space isolation module; Figure 3As shown, step S201 may further include:
[0055] Step S301, in response to a process design data change request, obtain an object identifier of a PSR object and a process design identifier of a target process design.
[0056] The object identifier refers to the identification information used to identify the PSR object, and the process design identifier refers to the identification information used to identify the target process design. In this embodiment, when the server receives a process design data change request, it can first obtain the object identifier of the PSR object associated with the process design data change request, and the process design identifier of the target process design.
[0057] Step S302: Based on the object identifier and the process design identifier, it is detected whether an isolation space identifier associated with the object identifier and the process design identifier is pre-stored in the space isolation module.
[0058] The spatial isolation module refers to a module used to set up isolation space, and the isolation space identifier is identification information used to uniquely identify each isolation space. In this embodiment, after obtaining the object identifier and the process design identifier, the object identifier and the process design identifier can be used to retrieve whether the spatial isolation module has pre-stored isolation space identifiers associated with the above object identifier and process design identifier.
[0059] Step S303: When an isolation space identifier is pre-stored in the space isolation module, the isolation space corresponding to the isolation space identifier is used as the isolation space associated with the process design data change request.
[0060] If an isolation space identifier is pre-stored in the space isolation module, which means that an isolation space associated with the process design data change request initiated for the target process design of the PSR object has been pre-set, then the server can use the isolation space corresponding to the isolation space identifier as the isolation space associated with the process design data change request.
[0061] This situation usually occurs in the scenario where the process design user changes the process design data of different target process designs of multiple PSR objects at the same time. For example, the process design user first changes the process design data of the target process design 1 of PSR object A. At this time, an isolation space associated with the target process design 1 of PSR object A is constructed, and at the same time, the object identifier of PSR object A, and the correspondence between the process design identifier and the isolation space identifier of the target process design 1 are constructed. After that, the process design user may switch to the target process design of other PSR objects to change the design data, and then switch back to change the design data of the target process design 1 of PSR object A. At this time, the process design data change request initiated for the target process design of the PSR object has already been constructed with the object identifier of PSR object A, the process design identifier and the isolation space identifier of the target process design 1. Therefore, the isolation space can be directly used as the isolation space associated with the process design data change request.
[0062] Step S304: if the isolation space identifier is not pre-stored in the space isolation module, an isolation space is created in the space isolation module, and the created isolation space is used as the isolation space associated with the process design data change request.
[0063] However, if the isolation space identifier is not pre-stored in the space isolation module, that is, if there is no pre-set isolation space associated with the process design data change request initiated for the target process design of the PSR object, the server needs to create an isolation space in the space isolation module and use the created isolation space as the isolation space associated with the process design data change request.
[0064] For example, when a process design user makes a process design data change to the target process design 1 of PSR object A for the first time, and the isolation space identifier is not pre-stored in the space isolation module, then in this case, the server needs to create a new isolation space in the space isolation module, and use the created isolation space as the isolation space associated with the process design data change request.
[0065] In this embodiment, it is also possible to detect whether the spatial isolation module stores an isolation space identifier associated with the above identifier based on the object identifier of the PSR object and the process design identifier of the target process design. If so, the isolation space corresponding to the isolation space identifier is used as the isolation space associated with the process design data change request. If not, an isolation space can be created in the spatial isolation module and used as the isolation space associated with the process design data change request. In this way, the efficiency of determining the isolation space can be improved.
[0066] In addition, after step S304, it may also include: generating an object design process identifier based on the object identifier and the process design identifier; the object design process identifier is used to uniquely identify the target process design of the PSR object; obtaining the isolation space identifier of the isolation space created in the space isolation module; and constructing a correspondence between the object design process identifier and the isolation space identifier in the space isolation module.
[0067] The object design process identifier refers to identification information of a target process design used to uniquely identify a PSR object. For example, the object design process identifier may be generated by combining the object identifier of the PSR object and the process design identifier of the target process design.
[0068] Specifically, after creating the isolation space, the server needs to create the target process design of the PSR object and the association relationship with the isolation space. Therefore, the server can first generate an object design process identifier based on the object identifier and the process design identifier, and construct a correspondence between the object design process identifier and the isolation space identifier of the generated isolation space. In this way, the target process design of the PSR object is bound to the isolation space.
[0069] In this embodiment, after creating the isolation space, a correspondence can be established between the object design process identifier used to uniquely identify the target process design of the PSR object and the isolation space identifier of the created isolation space. In this way, the construction of the association relationship between the target process design of the PSR object and the isolation space can be improved.
[0070] Furthermore, if Figure 4 As shown, generating an object design process identifier according to the object identifier and the process design identifier may further include:
[0071] Step S401, obtaining the request trigger time of the process design data change request and the operating environment identifier associated with the process design data change request.
[0072] The request trigger time refers to the trigger time of initiating the process design data change request, and the operating environment identifier refers to the identification information used to identify the operating environment corresponding to the process design data change request. Specifically, when the server generates the object design process identifier, it first needs to obtain the request trigger time of the process design data change request, and the operating environment identifier associated with the process design data change request.
[0073] Step S402, processing the request trigger time by using a snowflake algorithm to obtain random number information;
[0074] Step S403, concatenate the operating environment identifier, the object identifier, the process design identifier and the random number information to generate an object design process identifier.
[0075] In this embodiment, the object design process identifier is composed of four parts. In addition to the object identifier of the PSR object and the process design identifier of the target process design, it also includes the operating environment identifier and random number information, wherein the random number information is obtained by performing snowflake algorithm processing on the request trigger time.
[0076] Specifically, after obtaining the request trigger time, the server can also process the request trigger time through the snowflake algorithm to generate corresponding random number information, and then the operating environment identifier, object identifier, process design identifier and random number information can be spliced to generate the final object design process identifier.
[0077] In this embodiment, the request trigger time of the process design data change request and its associated operating environment identifier can also be obtained, and the random number information corresponding to the request trigger time can also be obtained through the snowflake algorithm, so as to splice the operating environment identifier, object identifier, process design identifier and random number information to generate the final object design process identifier. In this way, the accuracy of the object design process identifier generation can be improved.
[0078] In one embodiment, step S203 may further include: in response to the process design data saving operation, obtaining the save trigger time of the process design data saving operation; obtaining the request trigger time of the process design data change request, and determining the process design change time period according to the request trigger time and the save trigger time.
[0079] The save trigger time refers to the time when the process design user initiates the save operation, that is, the save trigger time of the process design data save operation, and the request trigger time of the process design data change request refers to the trigger time of the process design data change request. In this embodiment, the server can record the save trigger time of the process design data save operation and the request trigger time of the process design data change request, so as to determine the process design change time period based on the above save trigger time and request trigger time.
[0080] Specifically, the number of process design data change requests initiated for the target process design of the PSR object can be one or more times. If the number of times the process design data change request is triggered is one, that is, the process design user continues to make design data changes to the target process design of the PSR object, after the server obtains the trigger time of the process design data change request, it can save the time difference between the trigger time and the request trigger time as the process design change time period.
[0081] If the process design data change request is triggered multiple times, for example, the process design user switches the process design of the PSR object for design data change multiple times, the server can record the request trigger time of each process design data change request, that is, the trigger time of each switch, and thus save the time difference between the trigger time and the earliest request trigger time as the process design change time period.
[0082] In this embodiment, the process design change time period can also be obtained by recording the request trigger time of the process design data change request and the save trigger time of the process design data save operation. In this way, the efficiency of determining the process design change time period can be improved.
[0083] In one embodiment, Figure 5 As shown, step S101 may further include:
[0084] Step S501, in response to a version rollback request, obtain the object identifier of the PSR object and the process design identifier of the target process design, and obtain at least one candidate process design change time period associated with the object identifier and the process design identifier from a storage medium.
[0085] Among them, the candidate process design change time period is any process design change time period associated with the object identifier and the process design identifier. In this embodiment, when the design data of the target process design for the PSR object is changed, the object identifier of the PSR object and the process design identifier of the target process design can be associated with the time period of the process design data change and stored in the storage medium. Therefore, the storage medium can store each candidate process design change time period corresponding to the object identifier and the process design identifier. When the user initiates a version rollback request and completes the selection of the PSR object and the target process design, the server can query the storage medium based on the object identifier of the PSR object and the process design identifier of the target process design, and the various candidate process design change time periods associated with the above object identifier and process design identifier.
[0086] Step S502, displaying each candidate process design change time period;
[0087] Step S503 , in response to the selection operation on the displayed candidate process design change time period, the selected candidate process design change time period is used as the target process design change time period.
[0088] After obtaining the above-mentioned candidate process design change time period, the server can display the candidate process design change time period on the user terminal connected to the server, and then the user can select the displayed candidate process design change time period, so that the server can use the candidate process design change time period selected by the user as the target process design change time period.
[0089] In this embodiment, after initiating a version rollback request, the server can obtain the corresponding candidate process design change time period based on the object identifier of the PSR object selected by the user and the process design identifier of the target process design, and display them for user selection. Afterwards, the candidate process design change time period selected by the user can be used as the target process design change time period. This method can facilitate users to select the target process design change time period and improve the efficiency of obtaining the target process design change time period.
[0090] In one embodiment, a system for rolling back a PSR object process design version based on space isolation and Binlog is also provided. The system may include a space isolation module, a version snapshot module, and a version rollback module.
[0091] Space isolation module:
[0092] The space isolation module is mainly used to isolate the process design data of different PSR objects. When the process designer adds or edits the process design of multiple PSR objects, the space isolation module will identify one by one which object the currently processed process design belongs to and verify whether the current object already has the corresponding Value identification field in the space isolation module. The specific form of the Value identification field is as follows: current environment identification-unique identification of the object to which the process design belongs-process design identification-random number generated by the snowflake algorithm, as shown below: prod-cfs5gSlicingLine_install_api-prod5gSlicingLine_install_api_process-1788838115869138944. If the Value identification field does not exist, the isolation space is created in the space isolation module according to the unique identification of the object to which the currently processed process design belongs to generate the Value value, and form a key-value pair with the unique identification of the object, for example: unique identification of the object: isolation space Value; if the Value identification field exists, the current isolation space is activated, and the process design information is bound and associated with the isolation space. After the space isolation module completes the processing, the relevant information such as the process design, the object to which it belongs, and the isolation space is passed to the version snapshot module.
[0093] Version snapshot module:
[0094] The version snapshot module is mainly used to persist the data change information of the PSR object process design data and database operation information within a period of time. When the version snapshot module receives the message from the space isolation module, it will immediately record the original data of the current PSR object process design. The original data contains the following information: basic information of the process (process name, process code, process alias), process link information (start link, processing link, branch link, merge link, end link, etc.), process routing information (route name, routing rule), etc. At the same time, it will trigger the Binlog operation mode to record all database operations of the process designer in this time period in real time, including insertion, update, deletion, etc. These original data and operation binary logs will be bound and associated with the isolation space to which the current object belongs. When the designer switches back and forth between multiple objects to design the process, the system will record the process design data of different objects separately through the Value identification field of the isolation space. When the designer completes the process design of all PSR objects, click the Save button, and the isolation space, PSR object process information, original data, operation binary log and other information will be persisted to the storage medium to form a process design version snapshot, which includes the time period of process design information change, original content before change, database operation steps, isolation space information, etc. All persistent version snapshot information will be passed to the version rollback module.
[0095] Version rollback module:
[0096] The version rollback module is mainly used to roll back the process design of the PSR object based on the business data and Binlog operation logs persisted by the version snapshot module; in the version rollback module, the historical version of the process design of the specified PSR object can be filtered out in the storage medium through the unique identifier of the PSR object. The historical version contains the following information: the original process design data, the Binlog database operation log within the specified time, etc. When the process designer chooses to roll back to a certain historical version, the version rollback module will parse the Binlog database operation log and the original process design data, reversely parse and perform related database operations, so that the process design result rolls back to a certain historical version.
[0097] Through the system for rolling back the process design version of the PSR object based on space isolation and Binlog provided by this embodiment, the space isolation module in the system can realize the refined isolation of data, that is, to ensure that the process design data of each PSR object is managed independently in the isolated space. This refined isolation mechanism can effectively prevent data confusion and conflict, and ensure the accuracy and integrity of the backup process design. The version snapshot module can realize real-time data retention and operation records. When receiving the process design change information, it can instantly record the original process design data and the Binlog log of all database operations. This real-time data retention mechanism not only records each link and routing information of the process, but also ensures the traceability of all operations, providing a reliable data basis for subsequent version rollback. The version rollback module can accurately and efficiently roll back the version. Through the persistent original process data and Binlog operation log, it can accurately reverse the database operation and realize the rollback of the process design. This mechanism ensures the accuracy and efficiency of the rollback, can restore the process design state to the specified historical version, and effectively reduce the risks and losses caused by design errors. Therefore, this embodiment can support the rollback of process design data of a PSR object within a specified time period, which is more flexible in design and use. The precise version rollback strategy is more comprehensive and efficient than the existing technology, and can provide more accurate backtracking and rollback functions.
[0098] It should be understood that, although the various steps in the flowcharts involved in the above-mentioned embodiments are displayed in sequence according to the indication of the arrows, these steps are not necessarily executed in sequence according to the order indicated by the arrows. Unless there is a clear explanation in this article, the execution of these steps does not have a strict order restriction, and these steps can be executed in other orders. Moreover, at least a part of the steps in the flowcharts involved in the above-mentioned embodiments can include multiple steps or multiple stages, and these steps or stages are not necessarily executed at the same time, but can be executed at different times, and the execution order of these steps or stages is not necessarily to be carried out in sequence, but can be executed in turn or alternately with other steps or at least a part of the steps or stages in other steps.
[0099] Based on the same inventive concept, the embodiment of the present application also provides a PSR object design process version rollback device for implementing the PSR object design process version rollback method involved above. The implementation scheme for solving the problem provided by the device is similar to the implementation scheme recorded in the above method, so the specific limitations in one or more PSR object design process version rollback device embodiments provided below can refer to the limitations on the PSR object design process version rollback method above, and will not be repeated here.
[0100] In one embodiment, Figure 6As shown, a PSR object design process version rollback device is provided, including: a change time acquisition module 601, a rollback information acquisition module 602 and a version rollback processing module 603, wherein:
[0101] A change time acquisition module 601 is used to respond to a version rollback request initiated for a target process design of a PSR object and acquire a target process design change time period associated with the design process version rollback request;
[0102] The rollback information acquisition module 602 is used to acquire the original process design data and database operation log that match the PSR object, the target process design, and the target process design change time period from a pre-built storage medium;
[0103] The version rollback processing module 603 is used to perform version rollback processing on the target process design of the PSR object based on the original process design data and the database operation log.
[0104] In one embodiment, the PSR object design process version rollback device also includes: a storage medium storage module, which is used to respond to a process design data change request initiated for the target process design of the PSR object, determine the isolation space associated with the process design data change request, and store the original process design data corresponding to the process design data change request in the isolation space; respond to a process design data change operation initiated for the process design data change request, generate a database operation log corresponding to the process design data change request according to the process design data change operation, and store the generated database operation log in the isolation space; respond to a process design data save operation initiated for the process design data change request, obtain the process design change time period corresponding to the process design data change request, and store the process design change time period, the space information of the isolation space, the original process design data stored in the isolation space and the database operation log in the storage medium; wherein the space information is used to characterize the correspondence between the PSR object and the target process design and the isolation space.
[0105] In one embodiment, the isolation space is set in a space isolation module; the storage medium storage module is further used to obtain the object identifier of the PSR object and the process design identifier of the target process design in response to the process design data change request; based on the object identifier and the process design identifier, detect whether the space isolation module has pre-stored an isolation space identifier associated with the object identifier and the process design identifier; in the case where the isolation space identifier is pre-stored in the space isolation module, use the isolation space corresponding to the isolation space identifier as the isolation space associated with the process design data change request; in the case where the isolation space identifier is not pre-stored in the space isolation module, create an isolation space in the space isolation module, and use the created isolation space as the isolation space associated with the process design data change request.
[0106] In one embodiment, the storage medium storage module is also used to generate an object design process identifier based on the object identifier and the process design identifier; the object design process identifier is used to uniquely identify the target process design of the PSR object; obtain the isolation space identifier of the isolation space created in the space isolation module; and construct a correspondence between the object design process identifier and the isolation space identifier in the space isolation module.
[0107] In one embodiment, the storage medium storage module is also used to obtain the request trigger time of the process design data change request and the operating environment identifier associated with the process design data change request; process the request trigger time through a snowflake algorithm to obtain random number information; and concatenate the operating environment identifier, the object identifier, the process design identifier and the random number information to generate the object design process identifier.
[0108] In one embodiment, the storage medium storage module is further used to obtain the save trigger time of the process design data save operation in response to the process design data save operation; obtain the request trigger time of the process design data change request, and determine the process design change time period according to the request trigger time and the save trigger time.
[0109] In one embodiment, the change time acquisition module 601 is further used to obtain the object identifier of the PSR object and the process design identifier of the target process design in response to the version rollback request, and obtain at least one candidate process design change time period associated with the object identifier and the process design identifier from the storage medium; display each of the candidate process design change time periods; and in response to a selection operation on the displayed candidate process design change time period, use the selected candidate process design change time period as the target process design change time period.
[0110] Each module in the above-mentioned PSR object design process version rollback device can be implemented in whole or in part by software, hardware and their combination. The above-mentioned modules can be embedded in or independent of the processor in the computer device in the form of hardware, or can be stored in the memory in the computer device in the form of software, so that the processor can call and execute the operations corresponding to the above modules.
[0111] In one embodiment, a computer device is provided. The computer device may be a server, and its internal structure diagram may be as follows: Figure 7 As shown. The computer device includes a processor, a memory, an input / output interface (Input / Output, referred to as I / O) and a communication interface. The processor, the memory and the input / output interface are connected through a system bus, and the communication interface is connected to the system bus through the input / output interface. The processor of the computer device is used to provide computing and control capabilities. The memory of the computer device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system, a computer program and a database. The internal memory provides an environment for the operation of the operating system and the computer program in the non-volatile storage medium. The database of the computer device is used to store original process design data. The input / output interface of the computer device is used to exchange information between the processor and an external device. The communication interface of the computer device is used to communicate with an external terminal through a network connection. When the computer program is executed by the processor, a PSR object design process version rollback method is implemented.
[0112] Those skilled in the art will understand that Figure 7 The structure shown in the figure is only a block diagram of a part of the structure related to the solution of the present application, and does not constitute a limitation on the computer device to which the solution of the present application is applied. The specific computer device may include more or fewer components than those shown in the figure, or combine certain components, or have a different arrangement of components.
[0113] In one embodiment, a computer device is further provided, including a memory and a processor, wherein a computer program is stored in the memory, and the processor implements the steps in the above method embodiments when executing the computer program.
[0114] In one embodiment, a computer-readable storage medium is provided, on which a computer program is stored. When the computer program is executed by a processor, the steps in the above-mentioned method embodiments are implemented.
[0115] In one embodiment, a computer program product is provided, including a computer program, which implements the steps in the above method embodiments when executed by a processor.
[0116] It should be noted that the user information (including but not limited to user device information, user personal information, etc.) and data (including but not limited to data used for analysis, stored data, displayed data, etc.) involved in this application are all information and data authorized by the user or fully authorized by all parties, and the collection, use and processing of relevant data must comply with relevant regulations.
[0117] A person of ordinary skill in the art can understand that all or part of the processes in the above-mentioned embodiment method can be completed by instructing the relevant hardware through a computer program, and the computer program can be stored in a non-volatile computer-readable storage medium. When the computer program is executed, it can include the processes of the embodiments of the above-mentioned methods. Among them, any reference to the memory, database or other medium used in the embodiments provided in the present application can include at least one of non-volatile memory and volatile memory. Non-volatile memory can include read-only memory (ROM), magnetic tape, floppy disk, flash memory, optical memory, high-density embedded non-volatile memory, resistive random access memory (ReRAM), magnetic random access memory (MRAM), ferroelectric random access memory (FRAM), phase change memory (PCM), graphene memory, etc. Volatile memory can include random access memory (RAM) or external cache memory, etc. As an illustration and not limitation, RAM can be in various forms, such as static random access memory (SRAM) or dynamic random access memory (DRAM). The database involved in each embodiment provided in this application may include at least one of a relational database and a non-relational database. Non-relational databases may include distributed databases based on blockchains, etc., but are not limited to this. The processor involved in each embodiment provided in this application may be a general-purpose processor, a central processing unit, a graphics processor, a digital signal processor, a programmable logic device, a data processing logic device based on quantum computing, an artificial intelligence (AI) processor, etc., but are not limited to this.
[0118] The technical features of the above embodiments may be combined arbitrarily. To make the description concise, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this application.
[0119] The above-described embodiments only express several implementation methods of the present application, and the descriptions thereof are relatively specific and detailed, but they cannot be construed as limiting the scope of the present application. It should be noted that, for a person of ordinary skill in the art, several modifications and improvements can be made without departing from the concept of the present application, and these all belong to the protection scope of the present application. Therefore, the protection scope of the present application shall be subject to the attached claims.
Claims
1. A PSR object design process version rollback method, characterized in that: The method comprises: In response to a version rollback request initiated for a target process design of a PSR object, obtaining a target process design change time period associated with the design process version rollback request; Obtaining original process design data and database operation logs that match the PSR object, the target process design, and the target process design change time period from a pre-built storage medium; Based on the original process design data and the database operation log, version rollback is performed on the target process design of the PSR object.
2. The method according to claim 1, characterized in that Before the version rollback request initiated in response to the target process design of the PSR object, the method further includes: In response to a process design data change request initiated for a target process design of the PSR object, determining an isolation space associated with the process design data change request, and storing original process design data corresponding to the process design data change request in the isolation space; In response to a process design data change operation initiated for the process design data change request, generating a database operation log corresponding to the process design data change request according to the process design data change operation, and storing the generated database operation log in the isolation space; In response to a process design data save operation initiated for the process design data change request, the process design change time period corresponding to the process design data change request is obtained, and the process design change time period, the spatial information of the isolation space, the original process design data stored in the isolation space, and the database operation log are stored in the storage medium; wherein the spatial information is used to characterize the correspondence between the PSR object and the target process design and the isolation space.
3. The method according to claim 2, characterized in that The isolation space is arranged in a space isolation module; The step of determining, in response to a process design data change request initiated for a target process design of the PSR object, an isolation space associated with the process design data change request comprises: In response to the process design data change request, obtaining the object identifier of the PSR object and the process design identifier of the target process design; Based on the object identifier and the process design identifier, detecting whether an isolation space identifier associated with the object identifier and the process design identifier is pre-stored in the space isolation module; In the case where the isolation space identifier is pre-stored in the space isolation module, the isolation space corresponding to the isolation space identifier is used as the isolation space associated with the process design data change request; In the case that the isolation space identifier is not pre-stored in the space isolation module, an isolation space is created in the space isolation module, and the created isolation space is used as the isolation space associated with the process design data change request.
4. The method according to claim 3, characterized in that After creating the isolated space in the space isolation module, the method further includes: Generate an object design process identifier according to the object identifier and the process design identifier; the object design process identifier is used to uniquely identify the target process design of the PSR object; Obtaining an isolation space identifier of the isolation space created in the space isolation module; A correspondence between the object design process identifier and the isolation space identifier is constructed in the space isolation module.
5. The method according to claim 4, characterized in that The step of generating an object design process identifier according to the object identifier and the process design identifier includes: Obtaining a request trigger time of the process design data change request and an operating environment identifier associated with the process design data change request; The request trigger time is processed by a snowflake algorithm to obtain random number information; The operating environment identifier, the object identifier, the process design identifier and the random number information are concatenated to generate the object design process identifier.
6. The method according to claim 2, characterized in that The step of obtaining the process design change time period corresponding to the process design data change request in response to the process design data save operation initiated for the process design data change request includes: In response to the process design data saving operation, obtaining a saving trigger time of the process design data saving operation; The request trigger time of the process design data change request is obtained, and the process design change time period is determined according to the request trigger time and the save trigger time.
7. The method according to claim 1, characterized in that The step of obtaining, in response to a version rollback request initiated for a target process design of a PSR object, a target process design change time period associated with the design process version rollback request comprises: In response to the version rollback request, obtaining an object identifier of the PSR object and a process design identifier of the target process design, and obtaining at least one candidate process design change time period associated with the object identifier and the process design identifier from the storage medium; Displaying the time period for design changes of each candidate process; In response to a selection operation on the displayed candidate process design change time period, the selected candidate process design change time period is used as the target process design change time period.
8. A PSR object design process version rollback device, characterized in that: The device comprises: A change time acquisition module, used to respond to a version rollback request initiated for a target process design of a PSR object, and acquire a target process design change time period associated with the design process version rollback request; A rollback information acquisition module, used to acquire original process design data and database operation logs matching the PSR object, the target process design, and the target process design change time period from a pre-built storage medium; The version rollback processing module is used to perform version rollback processing on the target process design of the PSR object based on the original process design data and the database operation log.
9. A computer device comprising a memory and a processor, wherein the memory stores a computer program, wherein: When the processor executes the computer program, the steps of the method according to any one of claims 1 to 7 are implemented.
10. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the steps of the method according to any one of claims 1 to 7 are implemented.
11. A computer program product, comprising a computer program, characterized in that When the computer program is executed by a processor, the steps of the method according to any one of claims 1 to 7 are implemented.
