Data migration system and method

By using custom annotations during the data migration process to generate intermediate data and using the same business logic to process it in the second business system, the data omission problem is solved, ensuring the integrity and consistency of data migration.

CN117056281BActive Publication Date: 2025-08-29NETSUNION CLEARING CORP
View PDF 3 Cites 0 Cited by

Patent Information

Application Number
CN202210495227.2
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-05-07
Publication Date
2025-08-29
Estimated Expiration
2042-05-07

AI Technical Summary

Technical Problem

During the data migration process, the difference in the data storage area to be migrated may lead to data omission, affecting the integrity of the data after migration, and thus causing adverse effects on subsequent data processing.

Method used

By generating intermediate data in the first business system and recording processing types, methods and contents using custom annotations, binary data streams are generated to the second business system, and intermediate data is processed using the same service processing logic of the second business system to ensure data integrity and universality.

Benefits of technology

It realizes the integrity and universality of data migration between different systems, avoids data omissions, and ensures the accuracy and consistency of data after migration.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN117056281B_ABST
    Figure CN117056281B_ABST
Patent Text Reader

Abstract

The present application provides a data migration system and method, which are applied to the data migration system. The data migration system includes: the data migration system, which includes: a data storage component corresponding to a first business system, and a data migration component corresponding to a second business system; the method includes: the data storage component generates intermediate data of target data, and transmits the intermediate data to the data migration component; wherein, the target data is business data that needs to be processed by the first business system, and the first processing result obtained by the processing needs to be migrated; after receiving the intermediate data, the data migration component processes the intermediate data to obtain a second processing result, and stores the second processing result as migration data corresponding to the first processing result.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of data processing, and in particular to a data migration system and method. Background Art

[0002] Data migration refers to the transfer of data from one storage device to another. Data migration is involved in many technical fields, including cloud computing.

[0003] The data to be migrated is usually stored in different areas of the data source node's storage device. During data migration, the different storage areas of the data to be migrated may cause data omissions, thereby affecting the integrity of the migrated data.

[0004] Once the integrity of the migrated data is destroyed, it will have an adverse impact on subsequent data processing. Summary of the Invention

[0005] The purpose of this application is to provide a data migration system and method for ensuring data integrity when migrating data between different systems.

[0006] The present application provides a data migration system, comprising: a data storage component arranged corresponding to a first business system, and a data migration component arranged corresponding to a second business system; the data storage component is used to generate intermediate data of target data and transmit the intermediate data to the data migration component; wherein the target data is business data that needs to be processed by the first business system and a first processing result obtained by the processing needs to be migrated; the data migration component is used to process the intermediate data after receiving the intermediate data to obtain a second processing result, and store the second processing result as migration data corresponding to the first processing result.

[0007] Optionally, the data migration component is configured to generate and store the intermediate data of the target data when the first processing result passes verification.

[0008] Optionally, the data storage component is used to generate the intermediate data through custom annotations preset in the first business system.

[0009] Optionally, the data storage component is used to record the processing type, processing method and processing content performed by the first business system through the custom annotation, and generate the intermediate data based on the recorded content; wherein the processing method includes: the first business processing method; the processing content includes: the target data.

[0010] Optionally, the data migration component is used to perform a restore operation on the intermediate data, obtain the target data based on the intermediate data, and determine a second business processing method in the second business system corresponding to the first business processing method; the data migration component is also used to process the target data using the second business processing method to obtain the second processing result.

[0011] Optionally, the data storage component is used to directly convert the processing content into a corresponding binary data stream when the processing type is writing business data from a file; the data storage component is also used to convert the processing content into JSON format data and then convert the JSON format data into a corresponding binary data stream when the processing type is entering business data from a page; wherein, the intermediate data is stored and transmitted in the form of a binary data stream.

[0012] Optionally, the data migration component is used to generate and display a data migration task based on the received intermediate data; the data migration component is specifically used to process the target data using the second business processing method to obtain the second processing result when the data migration task passes the review.

[0013] Optionally, the data migration component is used to generate a migration success message after obtaining the second processing result, and transmit the migration success message to the data storage component; the data storage component is also used to mark the migration status of the intermediate data as a non-migratable state after receiving the migration success message; wherein, the intermediate data marked as a non-migratable state cannot be transmitted to the data migration component to generate migration data.

[0014] Optionally, the intermediate data contains a data identifier, and the second processing result contains the data identifier in the corresponding intermediate data; the data migration component is used to obtain the corresponding intermediate data according to the data identifier contained in the retry request, generate a retry result using the second business system and the obtained intermediate data, and replace the second processing result with the retry result.

[0015] The present application also provides a data migration method, which is applied to the data migration system provided above, including: the data storage component generates intermediate data of target data and transmits the intermediate data to the data migration component; wherein, the target data is business data that needs to be processed by a first business system, and the first processing result obtained by the processing needs to be migrated; after receiving the intermediate data, the data migration component processes the intermediate data to obtain a second processing result, and stores the second processing result as migration data corresponding to the first processing result.

[0016] Optionally, the data storage component generates intermediate data of the target data and transmits the intermediate data to the data migration component, including: the data migration component generates and stores the intermediate data of the target data when the first processing result passes the verification.

[0017] Optionally, the data storage component generates intermediate data of the target data and transmits the intermediate data to the data migration component, including: the data storage component generates the intermediate data through a custom annotation preset in the first business system.

[0018] Optionally, the data storage component generates intermediate data of the target data and transmits the intermediate data to the data migration component, including: the data storage component records the processing type, processing method and processing content performed by the first business system through the custom annotation, and generates the intermediate data according to the recorded content; wherein, the processing method includes: the first business processing method; the processing content includes: the target data.

[0019] Optionally, after receiving the intermediate data, the data migration component processes the intermediate data to obtain a second processing result, and stores the second processing result as migration data corresponding to the first processing result, including: the data migration component performs a restore operation on the intermediate data, obtains the target data based on the intermediate data, and determines the second business processing method in the second business system corresponding to the first business processing method; the data migration component is also used to process the target data using the second business processing method to obtain the second processing result.

[0020] Optionally, the data storage component generates intermediate data of the target data and transmits the intermediate data to the data migration component, including: when the processing type is writing business data from a file, the data storage component directly converts the processing content into a corresponding binary data stream; the data storage component is also used to, when the processing type is entering business data from a page, convert the processing content into JSON format data, and then convert the JSON format data into a corresponding binary data stream; wherein, the intermediate data is stored and transmitted in the form of a binary data stream.

[0021] Optionally, the data migration component processes the intermediate data after receiving it to obtain a second processing result, and stores the second processing result as migration data corresponding to the first processing result, including: the data migration component generates and displays a data migration task based on the received intermediate data; the data migration component is specifically used to use the second business processing method to process the target data to obtain the second processing result when the data migration task passes the review.

[0022] Optionally, after receiving the intermediate data, the data migration component processes the intermediate data to obtain a second processing result, and stores the second processing result as migration data corresponding to the first processing result. The method also includes: after obtaining the second processing result, the data migration component generates a migration success message and transmits the migration success message to the data storage component; the data storage component is also used to mark the migration status of the intermediate data as a non-migratable state after receiving the migration success message; wherein, the intermediate data marked as a non-migratable state cannot be transmitted to the data migration component to generate migration data.

[0023] Optionally, the intermediate data contains a data identifier, and the second processing result contains the data identifier in the corresponding intermediate data; after receiving the intermediate data, the data migration component processes the intermediate data to obtain a second processing result, and stores the second processing result as migration data corresponding to the first processing result. The method also includes: the data migration component obtains the corresponding intermediate data according to the data identifier contained in the retry request, generates a retry result using the second business system and the obtained intermediate data, and replaces the second processing result with the retry result.

[0024] The present application also provides a computer program product, comprising a computer program / instruction, which implements the steps of any of the above-mentioned data migration methods when executed by a processor.

[0025] The present application also provides an electronic device, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein when the processor executes the program, the steps of any of the above-described data migration methods are implemented.

[0026] The present application also provides a computer-readable storage medium having a computer program stored thereon, which implements the steps of any of the above-mentioned data migration methods when executed by a processor.

[0027] The data migration system and method provided in this application transfers the target data to a second business system when the processing results of the target data by the first business processing method in the first business system meet expectations. The target data is then processed by the second business processing method in the second business system to obtain a second processing result, thereby achieving data migration. Because the second business processing method and the first business processing method have the same business processing logic, the processing results of the target data by the second business processing method are consistent with the processing results of the target data by the first target business processing method, thereby ensuring the integrity and universality of data migration between different systems. BRIEF DESCRIPTION OF THE DRAWINGS

[0028] In order to more clearly illustrate the technical solutions in the present application or the prior art, the following briefly introduces the drawings required for use in the embodiments or the description of the prior art. Obviously, the drawings described below are some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without any creative work.

[0029] Figure 1 This is one of the structural diagrams of the data migration system provided by this application;

[0030] Figure 2 It is a flowchart of the data migration method provided by this application;

[0031] Figure 3 This is the data migration timing diagram provided by this application;

[0032] Figure 4 This is the second structural diagram of the data migration system provided by this application;

[0033] Figure 5 It is a structural diagram of the electronic device provided in this application. DETAILED DESCRIPTION

[0034] To make the objectives, technical solutions, and advantages of this application more clear, the technical solutions of this application will be clearly and completely described below in conjunction with the accompanying drawings. Obviously, the embodiments described are only part of the embodiments of this application, not all of them. Based on the embodiments of this application, all other embodiments obtained by ordinary technicians in this field without making any creative efforts are within the scope of protection of this application.

[0035] The terms "first," "second," and the like in the specification and claims of this application are used to distinguish similar objects, and are not used to describe a specific order or precedence. It should be understood that the terms used in this manner are interchangeable where appropriate, so that the embodiments of this application can be implemented in an order other than that illustrated or described herein, and that the objects distinguished by "first," "second," and the like are generally of the same type, and do not limit the number of objects; for example, the first object can be one or more. In addition, the term "and / or" in the specification and claims refers to at least one of the connected objects, and the character " / " generally indicates that the objects connected are in an "or" relationship.

[0036] The data migration methods in the prior art are mainly divided into the following types: a data migration method implemented at the storage layer, a data migration method implemented at the application layer, and a data migration method based on data table snapshots.

[0037] like Figure 1 As shown, migrating data from the storage layer of environment A to the storage layer of environment B requires parsing the database's incremental logs and migrating the database or data table from one storage device to another. The drawbacks of this approach are: the granularity of the copied data is coarse; it cannot guarantee that related data will be completely copied at the same time; and once replication is initiated, the replication of incremental data is automatically triggered, making it impossible to implement reasonable manual control and intervention.

[0038] like Figure 1 As shown, migrating data from the application layer of environment A to the application layer of environment B requires developing a separate data migration application. The application layer needs to be aware of data relationships and ensure data integrity. Customized migration logic is required for each scenario. This approach has the advantage of ensuring business data integrity and enabling customized checks. However, it has the disadvantage of limited versatility and scalability.

[0039] Data migration methods based on table snapshots are primarily used for relatively static data (data that changes infrequently) to be migrated. During implementation, a snapshot of the data to be migrated is created at a fixed point in time after a data change. This specific version of the snapshot is then stored in the data source environment. When migration is required, the migration action is triggered. This method has the advantage of ensuring data integrity and versatility. However, its disadvantage is that the snapshots may occupy excessive storage space and require subsequent cleanup.

[0040] In view of the shortcomings of the data migration methods in the prior art, the present invention provides a data migration method.

[0041] The data migration method provided in the embodiment of the present application is described in detail below through specific embodiments and their application scenarios in conjunction with the accompanying drawings.

[0042] like Figure 2 As shown, an embodiment of the present application provides a data migration method, which is applied to a data migration system. The data migration system includes: a first business system and a second business system, wherein the first business system is correspondingly provided with a data storage component; the second business system is correspondingly provided with a data migration component; the method may include the following steps 201 and 102:

[0043] Step 201: The data storage component generates intermediate data of target data and transmits the intermediate data to the data migration component.

[0044] The target data needs to be processed using a first business system, and a first processing result obtained by the processing needs to be migrated.

[0045] Exemplarily, the target data is business data that needs to be migrated after the first business system processes the data and obtains a first processing result.

[0046] Exemplarily, the above-mentioned data storage component is the execution entity that specifically executes the various steps in the data migration method executed by the first business system in the embodiment of the present application in the first business system; the above-mentioned data migration component is the execution entity that specifically executes the various steps in the data migration method executed by the second business system in the embodiment of the present application in the second business system.

[0047] Illustratively, the target data may be business data processed by the first business processing method in the first business system; and the intermediate data may be intermediate data transferred between the first business system and the second business system.

[0048] Specifically, the first business system obtains target data processed by the first business processing method, and when the processing result of the target data by the first business processing method meets expectations, converts the target data into intermediate data and transmits it to the second business system.

[0049] The first business processing method is a method used by the first business system for data processing.

[0050] Exemplarily, the first business system and the second business system have the same business processing logic, and the first business system and the second business system are business systems in different environments.

[0051] Exemplarily, the first business system and the second business system may be two systems running on the same electronic device, for example, different systems running different microservices on the same electronic device, or two systems running on different electronic devices.

[0052] Specifically, the first business system can be a business system in a verification environment, and the second business system can be a business system in a production environment. The verification environment verifies the business processing method by replaying formal business requests or simulating business requests. Once verification is passed, changes are made to the production environment, and the verified data also needs to be migrated to the production environment to complete the final changes.

[0053] It should be noted that in related technologies, verified data is usually directly migrated to the production environment. This data migration method has many problems. However, the data migration method provided in the embodiment of the present application does not directly migrate verified data, but migrates the original data, that is, the target data mentioned above.

[0054] Specifically, the above step 201 may include the following steps 201a:

[0055] Step 201a: When the first processing result passes verification, the data migration component generates and stores the intermediate data of the target data.

[0056] Exemplarily, the target data is data processed by the first business processing method, and the processing result being in accordance with expectations can be understood as: the processing result of the target data by the first business processing method meets the design requirements of the first business processing method.

[0057] In a possible implementation, in order to obtain the above-mentioned target data, the target data processed by the first business processing method may be recorded by custom annotation.

[0058] Illustratively, the above step 201 may include the following step 201b:

[0059] Step 201b: The data storage component generates the intermediate data through the custom annotations preset in the first business system.

[0060] Exemplarily, the first business system records the data processed by the first business processing method and the method name of the first business processing method through custom annotations, and obtains the intermediate data based on the recording results.

[0061] Furthermore, the above step 201b may further include the following step 201b1:

[0062] Step 201b1: The data storage component records the processing type, processing method, and processing content performed by the first business system through the custom annotation, and generates the intermediate data according to the recorded content.

[0063] Among them, the processing method includes: a first business processing method; the processing content includes: the target data.

[0064] It should be noted that annotations can be understood as special tags in the code. These tags can be read and processed during compilation, class loading, and runtime. Through annotations, developers can embed supplementary information in the source code without changing the original code and logic.

[0065] Exemplarily, by adding a custom annotation @TaskMethod before the function corresponding to the first business processing method of the first business system, all data processed by the first business processing method can be recorded, and the above-mentioned target data can be obtained.

[0066] For example, as shown in Table 1 below, the content of the custom annotation record of the first business system includes:

[0067] ID Processing Type Name of the processing method Processing content Creation time Update Time ……

[0068] Table 1

[0069] Illustratively, after receiving the intermediate data, the second business system restores the intermediate data to the data shown in Table 1.

[0070] Exemplarily, the second business system determines the second business processing method corresponding to the first business processing method in the first business system according to the name of the processing method in Table 1, and processes the target data obtained after restoration through the second business processing method to obtain the same processing result as the first business processing method, thereby realizing the migration of verified data.

[0071] Exemplarily, in order to avoid repeated migration of data, the intermediate data contains a data identifier, and the second processing result contains the data identifier corresponding to the intermediate data.

[0072] For example, the above step 202 may include the following step 202c:

[0073] Step 202c: The data migration component obtains corresponding intermediate data according to the data identifier included in the retry request, generates a retry result using the second business system and the obtained intermediate data, and replaces the second processing result with the retry result.

[0074] For example, after receiving the retry request from the first business system, the second business system determines the target data and the second business processing method based on the data identifier included in the retry request, and determines whether the target data has already been processed using the second business processing method in the second business system. If so, the operation is abandoned; otherwise, the data migration operation is performed according to step 202 above.

[0075] It should be noted that in order to ensure the idempotence of the operation when storing the above second processing result in the database, it can also be achieved in the following way:

[0076] 1. Use the unique key of the database to filter duplicate data and reject duplicate requests.

[0077] 2. Use the directionality of state flow to filter duplicate data, generally implemented using row-level locks in the database.

[0078] 3. Change the operation to an idempotent operation. For example, adding 2 to the data 1 can be directly defined as updating the data to 3.

[0079] 4. Use distributed tables to filter duplicate requests.

[0080] In this way, the first business system can obtain the original data recorded by all the above-mentioned business processing methods of the first business system when performing business processing, and if the business processing verification is passed, the verified original data and the method name of the corresponding business processing method will be transmitted to the second business system to facilitate the second business system to process it.

[0081] In one possible implementation, in order to facilitate data transmission between the first business system and the second business system, the intermediate data may be a binary data stream, that is, the custom annotation record content may be converted into a binary data stream and then sent to the second business system.

[0082] Exemplarily, the above-mentioned processing type is the input type of target data input by the user into the first business system; that is, the above-mentioned target data can be business data manually entered by the user of the first business system through business, or it can be business data imported into the first business system by the user of the first business system through files.

[0083] For example, before step 201, the data migration method provided in the embodiment of the present application may further include the following step 203 or step 204:

[0084] Step 203: When the processing type is writing business data from a file, the data storage component directly converts the processing content into a corresponding binary data stream.

[0085] Step 204 : When the processing type is to enter business data from a page, the data storage component converts the processing content into data in JSON format, and then converts the data in JSON format into a corresponding binary data stream.

[0086] Exemplarily, the above steps 203 and 204 are steps for generating the above intermediate data; the above intermediate data is stored and transmitted in the form of a binary data stream.

[0087] In this way, the intermediate data can be transmitted from the first business system to the second business system in the form of binary data stream.

[0088] Step 202: After receiving the intermediate data, the data migration component processes the intermediate data to obtain a second processing result, and stores the second processing result as migration data corresponding to the first processing result.

[0089] For example, after receiving the intermediate data, the second business system needs to perform a restore operation on the intermediate data to obtain the target data, and determine a second business processing method corresponding to the first business processing method. Thereafter, the target data is processed using the second business processing method to obtain a second processing result.

[0090] Specifically, the above step 202 may include the following steps 202a1 and 202a2:

[0091] Step 202a1: The data migration component performs a restore operation on the intermediate data, obtains the target data according to the intermediate data, and determines a second business processing method in the second business system corresponding to the first business processing method.

[0092] Step 202a2: The data migration component processes the target data using the second business processing method to obtain the second processing result.

[0093] The second business processing method is a method used by the second business system for data processing. The first business processing method and the second business processing method have the same business processing logic. The second processing result is data that needs to be migrated from the first business system to the second business system.

[0094] Exemplarily, after receiving the target data sent by the first business system, the second business system processes the target data based on a second business processing method having the same business processing logic as the first business processing method, and obtains the same processing result as the first business processing method.

[0095] It is understandable that since the second business processing method has the same business processing logic as the first business processing method, when the original input data (i.e., the target data) is the same, the processing results obtained are also the same. Based on this, the purpose of migrating the verified data in the first business system to the second business system is achieved.

[0096] Optionally, in an embodiment of the present application, the second business system further provides a manual review step to facilitate users to review each data migration.

[0097] For example, before processing the target data by the second business processing method and obtaining the second processing result in step 202, the data migration method provided in the embodiment of the present application may further include the following steps 205 and 206:

[0098] Step 205: The data migration component generates and displays a data migration task based on the received intermediate data.

[0099] Step 206: If the data migration task passes the review, the data migration component uses the second business processing method to process the target data to obtain the second processing result.

[0100] Exemplarily, after obtaining the target data through a restoration operation and determining the second business processing method, the second business system generates a data task to be processed according to the target data and displays the data task to be processed in a list of tasks to be processed.

[0101] Illustratively, after receiving the target data, the second business system may display the synchronization operation on a synchronization operation review page for review by a reviewer.

[0102] Exemplarily, based on the above steps 205 and 206, the above step 202 may further include the following step 202b:

[0103] Step 202b: After receiving the confirmation input from the auditor, the second business system processes the target data using a second business processing method and obtains a second processing result.

[0104] Illustratively, after receiving the confirmation input from the auditor, the second business system performs this data synchronization operation, processes the target data, and obtains the second processing result.

[0105] Optionally, in an embodiment of the present application, in order to avoid the first business system from repeatedly performing data migration operations on the same data, the second business system needs to feed back the data migration results to the first business system after completing the data migration.

[0106] For example, after step 202, the data migration method provided in the embodiment of the present application may further include the following steps 207 and 208:

[0107] Step 204: After obtaining the second processing result, the data migration component generates a migration success message and transmits the migration success message to the data storage component.

[0108] Step 205: After receiving the migration success message, the data storage component marks the migration status of the target data as a non-migration status;

[0109] The data marked as non-migratable cannot be transmitted to the data migration component to generate migration data, that is, the data migration operation cannot be performed.

[0110] For example, after the second business system completes the data migration, it may send a migration success message to the first business system so that the first business system does not perform multiple data migration operations on the same data.

[0111] For example, after step 202, the data migration method provided in the embodiment of the present application may further include the following steps 206 and 207:

[0112] Step 206: After obtaining the second processing result, the data migration component generates a migration failure message and transmits the migration failure message to the data storage component.

[0113] Step 207: After receiving the migration failure message, the data storage component marks the migration status of the target data as unmigrated.

[0114] The data marked as not migrated can be migrated.

[0115] For example, when the second business system fails in performing a data migration operation, a migration failure message may be sent to the first business system, so that the first business system can perform the data migration operation again for the data that needs to be migrated this time.

[0116] For example, Figure 3 The data migration timing diagram shown illustrates the data migration method involved in the embodiment of the present application. After the user imports and enters the original data (i.e., the above-mentioned target data) in the A environment (i.e., the above-mentioned first business system), the application layer records the above-mentioned original data through custom annotations and records (converts) the above-mentioned original data into a binary data stream. When the business verification of the A environment passes and the business data is obtained, the above-mentioned binary data stream is transmitted to the B environment (i.e., the above-mentioned second business system). After the B environment obtains the binary data stream of the A environment, the data that needs to be synchronized is displayed on the data synchronization page. At the same time, the operator performs a synchronization operation on the binary data stream of the A environment, and the reviewer reviews the synchronization operation.

[0117] After the auditor approves the data, the application layer of environment B processes the acquired data using the same business processing logic as environment A, and obtains the same business data as environment A (i.e., the second processing result described above), thus completing the migration of the business data of environment A. To complete the data migration, environment B also needs to write the acquired business data to the storage layer, record the write results, and feed the results back to environment A.

[0118] The data migration method provided in an embodiment of the present application transfers the target data to a second business system when the processing result of the target data by the first business processing method in the first business system meets expectations. The target data is then processed by the second business processing method in the second business system to obtain a second processing result, thereby achieving data migration. Because the second business processing method and the first business processing method have the same business processing logic, the processing result of the target data by the second business processing method is consistent with the processing result of the target data by the first target business processing method, thereby ensuring the integrity and universality of data migration between different systems.

[0119] It should be noted that the data migration methods shown in the figures in the embodiments of this application are each illustrated by way of example in conjunction with one of the figures in the embodiments of this application. In specific implementations, the data migration methods shown in the figures in the figures in the above methods may also be implemented in conjunction with any other combinable figures shown in the above embodiments, and will not be further described here.

[0120] Figure 4 This is a structural diagram of a data migration system provided in one embodiment of the present application. Figure 4 As shown, it specifically includes: a first business system 401 and a second business system 402:

[0121] Among them, the first business system is correspondingly provided with a data storage component, and the second business system is correspondingly provided with a data migration component; the data storage component is used to generate intermediate data of the target data and transmit the intermediate data to the data migration component; wherein, the target data is business data that needs to be processed by the first business system, and the first processing result obtained by the processing needs to be migrated; the data migration component is used to process the intermediate data after receiving the intermediate data, obtain a second processing result, and store the second processing result as migration data corresponding to the first processing result.

[0122] Optionally, the data migration component is configured to generate and store the intermediate data of the target data when the first processing result passes verification.

[0123] Optionally, the data storage component is used to generate the intermediate data through custom annotations preset in the first business system.

[0124] Optionally, the data storage component is used to record the processing type, processing method and processing content performed by the first business system through the custom annotation, and generate the intermediate data based on the recorded content; wherein the processing method includes: the first business processing method; the processing content includes: the target data.

[0125] Optionally, the data migration component is used to perform a restore operation on the intermediate data, obtain the target data based on the intermediate data, and determine a second business processing method in the second business system corresponding to the first business processing method; the data migration component is also used to process the target data using the second business processing method to obtain the second processing result.

[0126] Optionally, the data storage component is used to directly convert the processing content into a corresponding binary data stream when the processing type is writing business data from a file; the data storage component is also used to convert the processing content into JSON format data and then convert the JSON format data into a corresponding binary data stream when the processing type is entering business data from a page; wherein, the intermediate data is stored and transmitted in the form of a binary data stream.

[0127] Optionally, the data migration component is used to generate and display a data migration task based on the received intermediate data; the data migration component is specifically used to process the target data using the second business processing method to obtain the second processing result when the data migration task passes the review.

[0128] Optionally, the data migration component is used to generate a migration success message after obtaining the second processing result, and transmit the migration success message to the data storage component; the data storage component is also used to mark the migration status of the intermediate data as a non-migratable state after receiving the migration success message; wherein, the intermediate data marked as a non-migratable state cannot be transmitted to the data migration component to generate migration data.

[0129] Optionally, the intermediate data contains a data identifier, and the second processing result contains the data identifier in the corresponding intermediate data; the data migration component is used to obtain the corresponding intermediate data according to the data identifier contained in the retry request, generate a retry result using the second business system and the obtained intermediate data, and replace the second processing result with the retry result.

[0130] The data migration system provided in this application transfers the target data to a second business system when the processing results of the target data by the first business processing method of the first business system meet expectations. The target data is then processed by the second business processing method in the second business system to obtain a second processing result, thereby achieving data migration. Because the second business processing method and the first business processing method have the same business processing logic, the processing results of the target data by the second business processing method are consistent with the processing results of the target data by the first business processing method, thereby ensuring the integrity and universality of data migration between different systems.

[0131] Figure 5 An example of a physical structure diagram of an electronic device is shown below. Figure 5 As shown, the electronic device may include: a processor 510, a communications interface 520, a memory 530, and a communications bus 540, wherein the processor 510, the communications interface 520, and the memory 530 communicate with each other via the communications bus 540. The processor 510 may call logic instructions in the memory 530 to execute a data migration method, which includes: the data storage component generates intermediate data of target data and transmits the intermediate data to the data migration component; wherein the target data is business data that needs to be processed using a first business system, and the first processing result obtained by the processing needs to be migrated; after receiving the intermediate data, the data migration component processes the intermediate data to obtain a second processing result, and stores the second processing result as migration data corresponding to the first processing result.

[0132] In addition, the logic instructions in the above-mentioned memory 530 can be implemented in the form of a software functional unit and can be stored in a computer-readable storage medium when sold or used as an independent product. Based on this understanding, the technical solution of the present application is essentially or the part that contributes to the prior art or the part of the technical solution can be embodied in the form of a software product, and the computer software product is stored in a storage medium, including a number of instructions for enabling a computer device (which can be a personal computer, a server, or a network device, etc.) to execute all or part of the steps of the method described in each embodiment of the present application. The aforementioned storage medium includes: various media that can store program codes, such as a USB flash drive, a mobile hard disk, a read-only memory (ROM), a random access memory (RAM), a magnetic disk or an optical disk.

[0133] On the other hand, the present application also provides a computer program product, which includes a computer program stored on a computer-readable storage medium, and the computer program includes program instructions. When the program instructions are executed by a computer, the computer can execute the data migration method provided by the above methods, which is applied to a data migration system. The data migration system includes: a first business system and a second business system. The method includes: the data storage component generates intermediate data of the target data and transmits the intermediate data to the data migration component; wherein, the target data is business data that needs to be processed by the first business system, and the first processing result obtained by the processing needs to be migrated; after receiving the intermediate data, the data migration component processes the intermediate data to obtain a second processing result, and stores the second processing result as migration data corresponding to the first processing result.

[0134] On the other hand, the present application also provides a computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, is implemented to execute the above-mentioned data migration methods, and is applied to a data migration system, wherein the data migration system includes: a first business system and a second business system, and the method includes: the data storage component generates intermediate data of the target data, and transmits the intermediate data to the data migration component; wherein the target data is business data that needs to be processed by the first business system, and the first processing result obtained by the processing needs to be migrated; after receiving the intermediate data, the data migration component processes the intermediate data to obtain a second processing result, and stores the second processing result as migration data corresponding to the first processing result.

[0135] The data migration system embodiment described above is merely illustrative. The units described as separate components may or may not be physically separate, and the components shown as units may or may not be physical units, i.e., they may be located in one location or distributed across multiple network units. Some or all of the modules may be selected based on actual needs to achieve the objectives of this embodiment. Persons of ordinary skill in the art will be able to understand and implement the present invention without inventive effort.

[0136] Through the description of the above embodiments, those skilled in the art can clearly understand that each embodiment can be implemented by means of software plus a necessary general hardware platform, or of course, by hardware. Based on this understanding, the essence of the above technical solution or the part that contributes to the existing technology can be embodied in the form of a software product. The computer software product can be stored in a computer-readable storage medium, such as ROM / RAM, a magnetic disk, an optical disk, etc., and includes a number of instructions for enabling a computer device (which can be a personal computer, a server, or a network device, etc.) to execute the methods described in each embodiment or certain parts of the embodiments.

[0137] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present application, rather than to limit them. Although the present application has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that they can still modify the technical solutions described in the aforementioned embodiments, or make equivalent replacements for some of the technical features therein. However, these modifications or replacements do not deviate the essence of the corresponding technical solutions from the spirit and scope of the technical solutions of the embodiments of the present application.

Claims

1. A data migration system, characterized in that: include: A data storage component corresponding to the first business system, and a data migration component corresponding to the second business system; The first business system and the second business system have the same business processing logic, and the first business system and the second business system are business systems in different environments; The data storage component is configured to generate intermediate data of target data and transmit the intermediate data to the data migration component; wherein the target data is business data that needs to be processed by the first business system and the first processing result obtained by the processing needs to be migrated; The data migration component is configured to process the intermediate data after receiving the intermediate data to obtain a second processing result, and store the second processing result as migration data corresponding to the first processing result; The data storage component is configured to record the processing type, processing method, and processing content performed by the first business system through custom annotations, and generate the intermediate data based on the recorded content; wherein the processing method includes: the first business processing method; the processing content includes: the target data; The data migration component is configured to perform a restore operation on the intermediate data, obtain the target data based on the intermediate data, and determine a second business processing method in the second business system corresponding to the first business processing method; The data migration component is further configured to process the target data using the second business processing method to obtain the second processing result.

2. The system according to claim 1, wherein: The data migration component is configured to generate and store the intermediate data of the target data when the first processing result passes verification.

3. The system according to claim 1, wherein: The data storage component is used to directly convert the processing content into a corresponding binary data stream when the processing type is writing business data from a file; The data storage component is further configured to, when the processing type is to input business data from a page, convert the processing content into data in JSON format and then convert the data in JSON format into a corresponding binary data stream; The intermediate data is stored and transmitted in the form of binary data stream.

4. The system according to claim 1, wherein: The data migration component is used to generate and display data migration tasks based on the received intermediate data; The data migration component is specifically configured to process the target data using the second business processing method to obtain the second processing result when the data migration task passes the review.

5. The system according to claim 1, wherein: The data migration component is configured to generate a migration success message after obtaining the second processing result, and transmit the migration success message to the data storage component; The data storage component is further configured to mark the migration state of the intermediate data as a non-migratable state after receiving the migration success message; The intermediate data marked as non-migratable cannot be transmitted to the data migration component to generate migration data.

6. The system according to claim 5, characterized in that The intermediate data contains a data identifier, and the second processing result contains the data identifier corresponding to the intermediate data; The data migration component is used to obtain corresponding intermediate data according to the data identifier included in the retry request, generate a retry result using the second business system and the obtained intermediate data, and replace the second processing result with the retry result.

7. A data migration method, characterized in that: Applied to a data migration system, the data migration system comprising: a data storage component corresponding to a first business system, and a data migration component corresponding to a second business system; the first business system and the second business system have the same business processing logic, and the first business system and the second business system are business systems in different environments; The method comprises: The data storage component generates intermediate data of target data and transmits the intermediate data to the data migration component; wherein the target data is business data that needs to be processed by the first business system and the first processing result obtained by the processing needs to be migrated; After receiving the intermediate data, the data migration component processes the intermediate data to obtain a second processing result, and stores the second processing result as migration data corresponding to the first processing result; The data storage component generates intermediate data of the target data and transmits the intermediate data to the data migration component, including: The data storage component records the processing type, processing method, and processing content performed by the first business system through custom annotations, and generates the intermediate data based on the recorded content; wherein the processing method includes: the first business processing method; the processing content includes: the target data; After receiving the intermediate data, the data migration component processes the intermediate data to obtain a second processing result, and stores the second processing result as migration data corresponding to the first processing result, including: The data migration component performs a restore operation on the intermediate data, obtains the target data according to the intermediate data, and determines a second business processing method in the second business system corresponding to the first business processing method; The data migration component processes the target data using the second business processing method to obtain the second processing result.

Citation Information

Patent Citations

  • Data migration method and device

    CN105354314A

  • Data migration method and device, equipment, medium and program product

    CN114116678A

  • Data migration method and device, equipment and storage medium

    CN114218188A