Data comparison method and apparatus

By replicating and asynchronously simulating data processing, and automatically comparing data from the old and new business systems, the high cost and operational impact of existing technologies are resolved, enabling low-cost and non-impact data verification.

CN114510532BActive Publication Date: 2025-12-05SHANGHAI SHUHE INFORMATION TECH CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202110442487.9
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2021-04-23
Publication Date
2025-12-05
Estimated Expiration
2041-04-23

AI Technical Summary

Technical Problem

Existing technologies, when redesigning downstream business systems, involve high time and manpower costs through gray-scale verification of business functions in the production environment and manual verification of data, which may affect the operation of online business systems.

Method used

By copying the interface request messages from the upstream business system to the second data system, the processing method of the first data system is asynchronously simulated, and the data is converted into second business data. The third data system is then called to obtain the return message, and the first and second business data and the return message are automatically compared to provide feedback on the comparison results.

Benefits of technology

Without altering upstream business systems, reduce time and manpower costs, ensure that new business systems and existing systems run in parallel online for comparison, automatically identify data discrepancies, and avoid impacting existing business processes.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN114510532B_ABST
    Figure CN114510532B_ABST
Patent Text Reader

Abstract

The present disclosure provides a data comparison method and device, comprising: transmitting first business data to a first data system based on an interface request message sent by an upstream business system, obtaining a first return message; copying the interface request message to a second data system, copying the first business data to the second data system; calling the second business data to a third data system based on a pre-set data calling interface, obtaining a second return message; comparing the first business data and the second business data respectively, and comparing the first return message and the second return message, and feeding back the comparison result to a target business object. The method provided by the present disclosure can run online comparison in parallel with the original system before the new business system is formally put into production, can find problems in advance and will not affect the operation of the real business system, and at the same time automatically analyzes and compares the data differences between the new and old systems, reducing the labor and time cost.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This disclosure relates to data processing technology, and more particularly to a data comparison method and apparatus. Background Technology

[0002] In recent years, with the rapid development of the Internet, microservice architecture has gradually replaced traditional single and complex business systems due to its advantages such as clear and simple functions, flexibility and scalability, and independent deployment. However, the independent decomposition of functions has also brought about the complexity of calls between systems. In particular, when downstream business systems are redesigned, it is inevitable to involve the impact on upstream call interfaces and returned data. Ensuring the accuracy of data in downstream new business systems is crucial. The current industry-standard data verification method is to perform gray-scale verification of business functions in the production environment and manually verify the data. This method has high time and manpower costs and may affect the normal operation of online business systems. Summary of the Invention

[0003] This disclosure provides a data comparison method and apparatus that can solve the problem of high time and labor costs associated with existing technologies that require gray-scale verification of business functions in a production environment and manual verification of data, even when the business system is redesigned and the upstream caller remains unchanged.

[0004] A first aspect of this disclosure provides a method, comprising: transmitting first business data to a first data system based on an interface request message sent by an upstream business system, and obtaining a first return message, wherein the first data system is configured as the currently used business system, and the first return message includes message information fed back by the first data system after the first business data transmission is completed;

[0005] The interface request message is copied to the second data system, and the first business data is copied to the second data system. The second data system is used to asynchronously simulate the processing method of the first data system on the first business data and convert the first business data into second business data.

[0006] Based on a pre-defined data call interface, the second business data is called to the third data system to obtain a second return message. The third data system is configured as a business system to be launched. The second return message includes message information fed back by the third data system after the second business data is transmitted.

[0007] The first business data and the second business data are compared respectively, as are the first return message and the second return message, and the comparison results are fed back to the target business object.

[0008] Optionally, the method by which the second data system asynchronously simulates the processing method of the first data system for the first business data and converts the first business data into second business data includes:

[0009] Based on the preset data playback interface in the second data system, the first business data is read asynchronously;

[0010] The first business data read asynchronously is stored in the playback application business database as the second business data.

[0011] Optionally, the method of calling the second business data to the third data system based on a pre-defined data calling interface includes:

[0012] Based on a pre-defined data access interface, the second business data is batch-retrieved and sent to the third data system via an adapter interface in a preset order.

[0013] The adaptation interface is used to convert the second business data into business data that is compatible with the format of the third data system.

[0014] Optionally, the method of comparing the first service data and the second service data, and comparing the first return message and the second return message, includes:

[0015] Business table data of the first data system and the third data system are obtained respectively, wherein the business table data is used to indicate the attribute data of the user's transaction business in the first data system and the third data system;

[0016] Store the business table data of the first data system and the third data system in a data storage warehouse;

[0017] Obtain offline table data from the data storage warehouse. Based on the business table data and the offline table data, and according to a preset field mapping rule, compare the first business data and the second business data, and compare the first return message and the second return message. The offline table data is used to indicate the attribute data of the transaction business in the offline state.

[0018] Optionally, the comparison result includes the first business data and the second business data, as well as the total number of differences between the first return message and the second return message, and field difference information.

[0019] A second aspect of this disclosure provides a data comparison apparatus, comprising:

[0020] The transmission unit is used to transmit first business data to the first data system based on the interface request message sent by the upstream business system and to obtain a first return message. The first data system is configured as the currently used business system, and the first return message includes message information fed back by the first data system after the first business data transmission is completed.

[0021] The copying unit is used to copy the interface request message to the second data system and copy the first service data to the second data system. The second data system is used to asynchronously simulate the processing method of the first data system on the first service data and convert the first service data into second service data.

[0022] The calling unit is used to call the second business data to the third data system based on a pre-set data calling interface and obtain the second return message. The third data system is configured as a business system to be launched. The second return message includes message information fed back by the third data system after the second business data is transmitted.

[0023] The comparison unit is used to compare the first service data and the second service data respectively, and to compare the first return message and the second return message, and to feed back the comparison results to the target service object.

[0024] Optionally, the replication unit is further configured to:

[0025] Based on the preset data playback interface in the second data system, the first business data is read asynchronously;

[0026] The first business data read asynchronously is stored in the playback application business database as the second business data.

[0027] Optionally, the calling unit is further configured to:

[0028] Based on a pre-defined data access interface, the second business data is batch-retrieved and sent to the third data system via an adapter interface in a preset order.

[0029] The adaptation interface is used to convert the second business data into business data that is compatible with the format of the third data system.

[0030] Optionally, the comparison unit is further configured to:

[0031] Business table data of the first data system and the third data system are obtained respectively, wherein the business table data is used to indicate the attribute data of the user's transaction business in the first data system and the third data system;

[0032] Store the business table data of the first data system and the third data system in a data storage warehouse;

[0033] Obtain offline table data from the data storage warehouse. Based on the business table data and the offline table data, and according to a preset field mapping rule, compare the first business data and the second business data, and compare the first return message and the second return message. The offline table data is used to indicate the attribute data of the transaction business in the offline state.

[0034] Optionally, the comparison result includes the first business data and the second business data, as well as the total number of differences between the first return message and the second return message, and field difference information.

[0035] The data comparison method provided in this disclosure includes transmitting first business data to a first data system based on an interface request message sent by an upstream business system, and obtaining a first return message;

[0036] When redesigning or planning to launch a new business system, using interface request messages sent by the upstream business system can ensure that the actual business process is not affected without requiring changes to the upstream business system, thus reducing time costs.

[0037] The interface request message is copied to the second data system, and the first service data is copied to the second data system; wherein, the second data system is used to asynchronously simulate the processing method of the first data system on the first service data, and convert the first service data into second service data;

[0038] By copying the interface request message and copying the first business data to the second data system, the first business data copied to the second data system can be consumed asynchronously offline. This simulates real data processing without affecting the real business process of the first data system. In addition, asynchronous consumption of the first business data ensures that no data blockage occurs during data transmission.

[0039] Based on the pre-defined data call interface, the second business data is called to the third data system to obtain the second return message;

[0040] By calling the second business data to the third data system, we can ensure that the actual business processes of the existing data system are not affected, while simultaneously conducting trial runs of the new system that is about to go live, and identifying problems in advance before the new system is officially put into production.

[0041] The first service data and the second service data are compared respectively, and the first return message and the second return message are compared respectively, and the comparison results are fed back to the target service object;

[0042] By comparing business data and returned messages, it is possible to ensure that the new business system runs in parallel online with the original system before it is officially put into production. At the same time, it can automatically perform data difference analysis and comparison between the new and old systems, reducing labor and time costs. Attached Figure Description

[0043] Figure 1 This is a flowchart illustrating the data comparison method in an embodiment of this application;

[0044] Figure 2 This is a logical schematic diagram of the data comparison method in an embodiment of this application;

[0045] Figure 3 This is a schematic diagram of the data comparison device according to an embodiment of this application. Detailed Implementation

[0046] To make the objectives, technical solutions, and advantages of the embodiments of this disclosure clearer, the technical solutions of the embodiments of this disclosure will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of this disclosure, and not all embodiments. Based on the embodiments of this disclosure, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of this disclosure.

[0047] The terms “first,” “second,” “third,” “fourth,” etc. (if present) in this disclosure, claims, and accompanying drawings are used to distinguish similar objects and are not necessarily used to describe a particular order or sequence. It should be understood that such use of data can be interchanged where appropriate so that the embodiments of this disclosure described herein can be implemented in orders other than those illustrated or described herein.

[0048] It should be understood that in the various embodiments of this disclosure, the sequence number of each process does not imply the order of execution. The execution order of each process should be determined by its function and internal logic, and should not constitute any limitation on the implementation process of the embodiments of this disclosure.

[0049] It should be understood that in this disclosure, "comprising" and "having," and any variations thereof, are intended to cover non-exclusive inclusion, for example, a process, method, system, product, or device that includes a series of steps or units is not necessarily limited to those steps or units that are explicitly listed, but may include other steps or units that are not explicitly listed or that are inherent to such process, method, product, or device.

[0050] It should be understood that in this disclosure, "multiple" refers to two or more. "And / or" is merely a description of the relationship between related objects, indicating that three relationships can exist. For example, "and / or B" can represent: A existing alone, A and B existing simultaneously, or B existing alone. The character " / " generally indicates that the preceding and following related objects are in an "or" relationship. "Contains A, B, and C", "Contains A, B, and C" means that all three A, B, and C are contained; "Contains A, B, or C" means that one of A, B, and C is contained; "Contains A, B, and / or C" means that any one, two, or three of A, B, and C are contained.

[0051] It should be understood that in this disclosure, "B corresponding to A", "B corresponding to A", "A corresponds to B", or "B corresponds to A" means that B is associated with A, and B can be determined based on A. Determining B based on A does not mean determining B solely based on A; B can also be determined based on A and / or other information. Matching A and B is defined as a similarity between A and B that is greater than or equal to a preset threshold.

[0052] Depending on the context, "if" as used here can be interpreted as "when," "when," "in response to determination," or "in response to detection."

[0053] The technical solutions of this disclosure will be described in detail below with specific embodiments. These specific embodiments can be combined with each other, and the same or similar concepts or processes may not be described again in some embodiments.

[0054] Figure 1 An exemplary flowchart of the data comparison method according to an embodiment of this application is shown, such as... Figure 1 As shown, the method includes:

[0055] Step S101: Based on the interface request message sent by the upstream business system, transmit the first business data to the first data system and obtain the first return message;

[0056] Wherein, the first data system is configured as the currently used business system, and the first return message includes message information fed back by the first data system after the first business data transmission is completed;

[0057] For example, the first data system may be the currently used business system, and the business data may include user coding information, specific business information, etc. The embodiments of this disclosure do not limit the type of business data.

[0058] Optionally, embodiments of this disclosure may develop an interface interception component based on aspect slicing technology and encapsulate it so that the data system can use it directly. The interface interception component may include synchronously copying interface messages requested by the upstream business system and sending them to the target business system.

[0059] After the upstream business system sends an interface request message, it can transmit the first business data to the first data system. After the first business data transmission is completed, the first data system sends back a first return message, the content of which can correspond to the interface request message.

[0060] Specifically, if the interface request message includes information such as the target user's order number and billing details, the first response message can return the corresponding content based on the content of the interface request message.

[0061] When redesigning or planning to launch a new business system, using interface request messages sent by the upstream business system can ensure that the actual business process is not affected without requiring changes to the upstream business system, thus reducing time costs.

[0062] Step S102: Copy the interface request message to the second data system, and copy the first service data to the second data system;

[0063] The second data system is used to asynchronously simulate the processing method of the first data system on the first business data, and to convert the first business data into the second business data.

[0064] To ensure the normal operation of the existing data system, the data transmitted to the existing data system can be copied, and the copied data can be simulated in actual operation in order to identify any problems.

[0065] Specifically, the aforementioned interface interception component can copy the interface request message to the second data system and copy the first business data to the second data system.

[0066] Optionally, the second data system may include a Kafka system, which is a distributed, partitioned, multi-replica, multi-subscriber distributed log system (also known as a message queue) coordinated by ZooKeeper. It is commonly used for web / nginx logs, access logs, message services, etc. Kafka provides message persistence with time complexity, guaranteeing constant-time access performance even for terabyte-level data; it has high throughput, achieving 100K messages per second transmission on a single machine even on very inexpensive commercial machines; it supports message partitioning and distributed consumption among Kafka Servers, while ensuring the sequential transmission of messages within each partition; and it supports both offline and real-time data processing.

[0067] In one optional implementation, the method by which the second data system asynchronously simulates the processing method of the first data system for the first business data and converts the first business data into second business data includes:

[0068] Based on the preset data playback interface in the second data system, the first business data is read asynchronously;

[0069] The first business data read asynchronously is stored in the playback application business database as the second business data.

[0070] For example, a data replay interface can be preset in the second data system to replay data asynchronously consumed by the application from the Kafka system and stored in the replay application's business database. Consuming data can include reading data stored in the Kafka system to simulate how external systems or processes handle data. Furthermore, asynchronous data consumption can prevent data congestion.

[0071] By copying the interface request message and copying the first business data to the second data system, the first business data copied to the second data system can be consumed asynchronously offline. This simulates real data processing without affecting the real business process of the first data system. In addition, asynchronous consumption of the first business data ensures that no data blockage occurs during data transmission.

[0072] Step S103: Based on the pre-set data call interface, call the second business data to the third data system and obtain the second return message;

[0073] The third data system is configured as a business system to be launched, and the second return message includes message information fed back by the third data system after the second business data transmission is completed.

[0074] For example, the third data system can be configured as a business system that will be launched.

[0075] In one optional implementation, the method of calling the second business data to the third data system based on a pre-defined data call interface includes:

[0076] Based on a pre-defined data access interface, the second business data is batch-retrieved and sent to the third data system via an adapter interface in a preset order.

[0077] The adaptation interface is used to convert the second business data into business data that is compatible with the format of the third data system.

[0078] The data call interface can include the antitic-playback interface, which can schedule engine JOBs to retrieve stored message data in batches in sequence and adapt and transform request messages of new business systems through developed interfaces.

[0079] By calling the second business data to the third data system, we can ensure that the actual business processes of the existing data system are not affected, while simultaneously conducting trial runs of the new system that is about to go live, and identifying problems in advance before the new system is officially put into production.

[0080] Step S104: Compare the first service data and the second service data, and compare the first return message and the second return message, and feed back the comparison results to the target service object.

[0081] In one optional implementation, the method of comparing the first service data and the second service data, and comparing the first return message and the second return message, includes:

[0082] Business table data of the first data system and the third data system are obtained respectively, wherein the business table data is used to indicate the attribute data of the user's transaction business in the first data system and the third data system;

[0083] Store the business table data of the first data system and the third data system in a data storage warehouse;

[0084] Obtain offline table data from the data storage warehouse. Based on the business table data and the offline table data, and according to a preset field mapping rule, compare the first business data and the second business data, and compare the first return message and the second return message. The offline table data is used to indicate the attribute data of the transaction business in the offline state.

[0085] For example, the Big Data MySQL to Hive technology can be used to extract business table data from the first data system and the third data system into a data storage warehouse, and then the offline table data in the data storage warehouse can be scheduled through AirFlow technology.

[0086] The business table data may include attribute data of the transaction business such as the type of transaction business, the transaction date, and the transaction amount; the offline table data is the attribute data of the transaction business in the offline state. This embodiment of the disclosure does not limit the types of business table data and offline table data.

[0087] Data storage warehouses can include ODS (Operational Data Store) data storage warehouses. ODS data storage warehouses can serve as a transition from databases to data warehouses. The data structure of ODS is generally consistent with the data source, which helps to reduce the complexity of the work. Moreover, the data cycle of ODS is generally relatively short.

[0088] Based on business table data and offline table data, and according to preset field mapping rules, the first business data and the second business data are compared, as are the first return message and the second return message.

[0089] The preset field mapping rules can include the core field mapping rules for the first and third data systems. In practical applications, although the specific data in the first and third data systems will not change, the meaning or attributes represented by the data may change. The field mapping rules can ensure that the data corresponds to each other, thus preventing errors in subsequent data comparisons.

[0090] In one optional implementation, the comparison result includes the first service data and the second service data, as well as the total number of differences between the first return message and the second return message, and field difference information.

[0091] For example, in this embodiment of the disclosure, the comparison result may be stored in the form of a daily partitioned table, containing the total number of differences between the first business data and the second business data, as well as the total number of differences between the first return message and the second return message, and the field difference information, and the comparison result is notified to the target business object. It should be noted that this embodiment of the disclosure does not limit the form of the comparison result.

[0092] By comparing business data and returned messages, it is possible to ensure that the new business system runs in parallel online with the original system before it is officially put into production. At the same time, it can automatically perform data difference analysis and comparison between the new and old systems, reducing labor and time costs.

[0093] The data comparison method provided in this disclosure can, when redesigning or planning to launch a new business system, ensure that the actual business process is not affected without requiring changes to the upstream business system, thus reducing time costs. By copying the interface request message and copying the first business data to the second data system, the first business data copied to the second data system can be consumed asynchronously offline, thereby simulating real data processing without affecting the actual business process of the first data system. In addition, asynchronous consumption of the first business data ensures that data congestion does not occur during data transmission. By calling the second business data to the third data system, the actual business process of the existing data system can be ensured without affecting the trial run of the new system to be launched, and problems can be discovered in advance before the new system is officially put into production. By comparing business data and return messages, the new business system can be compared with the original system in parallel online operation before the official launch, and the differences between the data of the new and old systems can be automatically analyzed and compared, reducing labor and time costs.

[0094] Figure 2 An exemplary logical diagram of the data comparison method according to an embodiment of this application is shown, such as... Figure 2 As shown, the method may include:

[0095] External systems can send interface request messages to the old system (i.e., the system currently in use);

[0096] An interface interception component, antitic-aspect, can be developed in the old system based on aspect slicing technology and encapsulated as a starter for easy use by applications.

[0097] The interface interception component can synchronously copy the interface message from the upstream request and send it to the middleware KAFFA system; in addition to continuing to flow to the old system normally, the interface request message initiated by the upstream business system will be copied by antitic-aspect and sent to and stored in the KAFFA system.

[0098] In addition, the antitic-playback application can be deployed to asynchronously consume data stored in the KAFKA system and store it in the playback application's business database;

[0099] The antic-playback application is configured with a timed scheduling engine JOB to retrieve stored message data in batches in sequence, and adapt and transform request messages from the new business system through the developed interface, thereby requesting the new business system.

[0100] Based on the interface request, both new and old applications generate their own business data and return messages, and store the data in the business MySQL database.

[0101] The big data MySQL to Hive technology is used to extract business table data from both new and old business systems to a data storage warehouse, and Airflow is used to schedule the offline tables of the data storage warehouse ods-loan.

[0102] According to the mapping rules of the old and new core fields, compare the business data and the messages returned by the interface to the upstream, and save the total number of differences and detailed field difference information in the table according to the daily partition, and notify the relevant business parties by email or other means.

[0103] Figure 3 An exemplary schematic diagram of the data comparison device according to an embodiment of this application is shown, such as... Figure 3 As shown, the device includes:

[0104] Transmission unit 31 is used to transmit first business data to the first data system based on the interface request message sent by the upstream business system and to obtain a first return message, wherein the first data system is configured as the currently used business system and the first return message includes message information fed back by the first data system after the first business data transmission is completed.

[0105] The copying unit 32 is used to copy the interface request message to the second data system and copy the first service data to the second data system. The second data system is used to asynchronously simulate the processing method of the first data system on the first service data and convert the first service data into second service data.

[0106] Calling unit 33 is used to call the second business data to the third data system based on a pre-set data calling interface and obtain a second return message. The third data system is configured as a business system to be launched. The second return message includes message information fed back by the third data system after the second business data is transmitted.

[0107] The comparison unit 34 is used to compare the first service data and the second service data respectively, and to compare the first return message and the second return message, and to feed back the comparison results to the target service object.

[0108] In an optional implementation, the copying unit 32 is further configured to:

[0109] Based on the preset data playback interface in the second data system, the first business data is read asynchronously;

[0110] The first business data read asynchronously is stored in the playback application business database as the second business data.

[0111] In an optional implementation, the calling unit 33 is further configured to:

[0112] Based on a pre-defined data access interface, the second business data is batch-retrieved and sent to the third data system via an adapter interface in a preset order.

[0113] The adaptation interface is used to convert the second business data into business data that is compatible with the format of the third data system.

[0114] In an optional implementation, the comparison unit 34 is further configured to:

[0115] Business table data of the first data system and the third data system are obtained respectively, wherein the business table data is used to indicate the attribute data of the user's transaction business in the first data system and the third data system;

[0116] Store the business table data of the first data system and the third data system in a data storage warehouse;

[0117] Obtain offline table data from the data storage warehouse. Based on the business table data and the offline table data, and according to a preset field mapping rule, compare the first business data and the second business data, and compare the first return message and the second return message. The offline table data is used to indicate the attribute data of the transaction business in the offline state.

[0118] In one optional implementation, the comparison result includes the first service data and the second service data, as well as the total number of differences between the first return message and the second return message, and field difference information.

[0119] This disclosure also provides a program product including executable instructions stored in a readable storage medium. At least one processor of the device can read the executable instructions from the readable storage medium, and the at least one processor executes the executable instructions to cause the device to implement the methods provided in the various embodiments described above.

[0120] The readable storage medium can be a computer storage medium or a communication medium. A communication medium includes any medium that facilitates the transfer of computer programs from one location to another. A computer storage medium can be any available medium accessible to a general-purpose or special-purpose computer. For example, a readable storage medium is coupled to a processor, enabling the processor to read information from and write information to the readable storage medium. Of course, the readable storage medium can also be a component of the processor. The processor and the readable storage medium can reside in an Application-Specific Integrated Circuit (ASIC). Alternatively, the ASIC can be located in a user equipment. Of course, the processor and the readable storage medium can also exist as discrete components in a communication device. The readable storage medium can be a read-only memory (ROM), random access memory (RAM), CD-ROM, magnetic tape, floppy disk, and optical data storage device, etc.

[0121] In the above-described terminal or server embodiments, it should be understood that the processor can be a Central Processing Unit (CPU), or other general-purpose processors, digital signal processors (DSPs), application-specific integrated circuits (ASICs), etc. A general-purpose processor can be a microprocessor or any conventional processor. The steps of the methods disclosed in this disclosure can be directly manifested as being executed by a hardware processor, or executed by a combination of hardware and software modules within the processor.

[0122] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of this disclosure, and are not intended to limit them. Although this disclosure has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that modifications can still be made to the technical solutions described in the foregoing embodiments, or equivalent substitutions can be made to some or all of the technical features therein. Such modifications or substitutions do not cause the essence of the corresponding technical solutions to deviate from the scope of the technical solutions of the embodiments of this disclosure.

Claims

1. A data comparison method, characterized in that, include: Based on the interface request message sent by the upstream business system, the first business data is transmitted to the first data system and the first return message is obtained. The first data system is configured as the currently used business system, and the first return message includes message information fed back by the first data system after the first business data is transmitted. The interface request message is copied to the second data system, and the first business data is copied to the second data system. The second data system is used to asynchronously simulate the processing method of the first data system on the first business data and convert the first business data into second business data. Based on a pre-defined data call interface, the second business data is called to the third data system to obtain a second return message. The third data system is configured as a business system to be launched. The second return message includes message information fed back by the third data system after the second business data is transmitted. The first service data and the second service data are compared respectively, and the first return message and the second return message are compared respectively, and the comparison results are fed back to the target service object; The method by which the second data system asynchronously simulates the processing method of the first data system for the first business data and converts the first business data into second business data includes: Based on the preset data playback interface in the second data system, the first business data is read asynchronously; The first business data read asynchronously is stored in the playback application business database as the second business data; The method for calling the second business data to the third data system based on a pre-defined data call interface includes: Based on a pre-defined data access interface, the second business data is batch-retrieved and sent to the third data system via an adapter interface in a preset order. The adaptation interface is used to convert the second business data into business data that is compatible with the format of the third data system.

2. The method according to claim 1, characterized in that, The method for comparing the first service data and the second service data, and for comparing the first return message and the second return message, includes: Business table data of the first data system and the third data system are obtained respectively, wherein the business table data is used to indicate the attribute data of the user's transaction business in the first data system and the third data system; Store the business table data of the first data system and the third data system in a data storage warehouse; Obtain offline table data from the data storage warehouse. Based on the business table data and the offline table data, and according to a preset field mapping rule, compare the first business data and the second business data, and compare the first return message and the second return message. The offline table data is used to indicate the attribute data of the transaction business in the offline state.

3. The method according to claim 1, characterized in that, The comparison results include the first business data and the second business data, as well as the total number of differences and field difference information between the first return message and the second return message.

4. A data comparison device, characterized in that, include: The transmission unit is used to transmit first business data to the first data system based on the interface request message sent by the upstream business system and to obtain a first return message. The first data system is configured as the currently used business system, and the first return message includes message information fed back by the first data system after the first business data transmission is completed. The copying unit is used to copy the interface request message to the second data system and copy the first service data to the second data system. The second data system is used to asynchronously simulate the processing method of the first data system on the first service data and convert the first service data into second service data. The calling unit is used to call the second business data to the third data system based on a pre-set data calling interface and obtain the second return message. The third data system is configured as a business system to be launched. The second return message includes message information fed back by the third data system after the second business data is transmitted. The comparison unit is used to compare the first service data and the second service data respectively, and to compare the first return message and the second return message, and to feed back the comparison results to the target service object; The replication unit is also used for: Based on the preset data playback interface in the second data system, the first business data is read asynchronously; The first business data read asynchronously is stored in the playback application business database as the second business data; The calling unit is also used for: Based on a pre-defined data access interface, the second business data is batch-retrieved and sent to the third data system via an adapter interface in a preset order. The adaptation interface is used to convert the second business data into business data that is compatible with the format of the third data system.

5. The apparatus according to claim 4, characterized in that, The comparison unit is also used for: Business table data of the first data system and the third data system are obtained respectively, wherein the business table data is used to indicate the attribute data of the user's transaction business in the first data system and the third data system; Store the business table data of the first data system and the third data system in a data storage warehouse; Obtain offline table data from the data storage warehouse. Based on the business table data and the offline table data, and according to a preset field mapping rule, compare the first business data and the second business data, and compare the first return message and the second return message. The offline table data is used to indicate the attribute data of the transaction business in the offline state.

6. The apparatus according to claim 4, characterized in that, The comparison results include the first business data and the second business data, as well as the total number of differences and field difference information between the first return message and the second return message.

Citation Information

Patent Citations

  • Test method and system of distributed system, and message production and consumption module

    CN112217886A

  • Log playback test method and device for high-simulation securities industry transaction system

    CN112256581A