Transaction data processing method and device, storage medium and electronic equipment

The writing strategy of transaction data is determined by serving the dual write switch and the target list, and combined with data anti-corrosion processing and consistency verification, the parallel processing and consistency of transaction data between the host and the distributed platform system is solved, the transaction failure rate is reduced, and efficient and secure data processing is achieved.

CN119831745AActive Publication Date: 2025-04-15INDUSTRIAL AND COMMERCIAL BANK OF CHINA
View PDF 19 Cites 0 Cited by

Patent Information

Application Number
CN202411974363.5
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-12-30
Publication Date
2025-04-15
Estimated Expiration
2044-12-30

AI Technical Summary

Technical Problem

In the prior art, it is difficult for transaction data in financial services to maintain parallel processing and consistency between the host and the distributed platform system, resulting in a high transaction failure rate.

Method used

Determine the writing strategy of transaction data by serving the dual write switch and target list, realize the dual write of data between the host and the distributed platform system, and perform data anti-corrosion processing and consistency verification to ensure the consistency and accuracy of the data.

Benefits of technology

It effectively solves the problem of abnormal processing of transaction data between heterogeneous systems, reduces the transaction failure rate, and realizes efficient and secure data processing between heterogeneous systems.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119831745A_ABST
    Figure CN119831745A_ABST
Patent Text Reader

Abstract

The invention discloses a transaction data processing method and device, a storage medium and electronic equipment, and relates to the field of financial science and technology and the technical field of big data. The method comprises the following steps: determining to write transaction data into a host and / or a distributed platform system according to a service double-write switch and a target list; and after the transaction data is written into the host and / or the distributed platform system, carrying out data anti-corrosion processing on the transaction data stored in the host and / or the transaction data stored in the distributed platform system. In the prior art, for information security, two sets of heterogeneous ecosystems of a host and a distributed platform system are adopted as a whole for external service for transaction data, but at present, data input and data output are still maintained respectively for each system, so that parallel processing and consistency of data are difficult to maintain, and the transaction efficiency is high. And the transaction data is easy to process abnormally, so that the transaction failure rate is relatively high.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the fields of financial technology and big data technology, and specifically, to a method, device, storage medium and electronic device for processing transaction data. Background Art

[0002] For many years, mainframes have been widely used in large-scale commercial core systems due to their stability, high availability, and high throughput. However, in recent years, due to the traditional centralized architecture concept, relatively closed technology ecosystem, and high expansion costs, various industries have found it increasingly difficult to adapt to the digital transformation trend of the new era and the requirements for autonomous control in key core areas. Faced with the above challenges, various industries have explored migrating core businesses to open ecosystems to make full use of new technologies to accelerate financial innovation; at the same time, they have expanded the application of open technology products, broken through the external closed technology ecosystem, achieved autonomous control of key information infrastructure, and achieved long-term sustainable development.

[0003] Therefore, for financial business, it is necessary to actively promote the migration of mainframe business and use two heterogeneous ecosystems of mainframe and distributed platform system as a whole to provide external services for transaction data. However, the migration of mainframe business has many characteristics such as wide scope, large investment, long construction period, complex scheme, large internal and external impact, and extremely high overall implementation risk. Therefore, data input and data output are still maintained for each system separately, making it difficult to maintain parallel processing and consistency of data. This will always lead to abnormal processing of transaction data, which in turn causes a high transaction failure rate.

[0004] To address the above-mentioned problems, no effective solution has been proposed yet. Summary of the invention

[0005] The main purpose of the present application is to provide a transaction data processing method, device, storage medium and electronic device, so as to at least solve the problem that in the prior art, for information security reasons, two heterogeneous ecosystems, namely a host and a distributed platform system, are used as a whole to provide external services for transaction data, but currently data input and data output are still maintained separately for each system, so it is difficult to maintain parallel processing and consistency of data, which makes it easy for transaction data to be processed abnormally, resulting in a high transaction failure rate.

[0006] In order to achieve the above-mentioned purpose, according to one aspect of an embodiment of the present application, a method for processing transaction data is provided, including: determining to write transaction data to a host and / or a distributed platform system based on a service double-write switch and a target list, wherein the target list is used to record transaction objects for which transaction risks have been eliminated, and the service double-write switch is used to determine data write selection based on transaction attributes of the transaction data; after the transaction data is written to the host and / or the distributed platform system, performing data anti-corrosion processing on the transaction data stored in the host and / or the transaction data stored in the distributed platform system, wherein the data anti-corrosion processing is used to determine to use the transaction data stored in the host as an output result, or to use the transaction data stored in the distributed platform system as an output result.

[0007] Optionally, the method for processing transaction data also includes: when the transaction data is written to the host and the distributed platform system at the same time, performing a consistency check on the transaction data stored in the host and the transaction data stored in the distributed platform system to obtain a check result; when it is found that the transaction data stored in the host and the transaction data stored in the distributed platform system are inconsistent, marking the state of the protocol routing state table as a target state, wherein the protocol routing state table is used to record the state of the transaction protocol related to the transaction data, and the protocol routing state table in the target state is used to control all subsequent transaction requests using the transaction protocol to be processed by the host and not sent to the distributed platform system.

[0008] Optionally, a consistency check is performed on the transaction data stored in the host and the transaction data stored in the distributed platform system, including: obtaining a key field value returned by the host after the transaction data is written to the host; obtaining a key field value returned by the distributed platform system after the transaction data is written to the distributed platform system; when it is detected that the key field value returned by the host is the same as the key field value returned by the distributed platform system, determining that the transaction data stored in the host and the transaction data stored in the distributed platform system are consistent; when it is detected that the key field value returned by the host is different from the key field value returned by the distributed platform system, determining that the transaction data stored in the host and the transaction data stored in the distributed platform system are inconsistent.

[0009] Optionally, determining whether to write transaction data to the host and / or distributed platform system is based on the service double-write switch and the target list, including: when it is detected that the transaction object of the transaction data is the transaction object in the target list, writing the transaction data to the host and the distributed platform system; when it is detected that the transaction object of the transaction data is not the transaction object in the target list, detecting whether the dependent transaction attribute of the service double-write switch matches the transaction attribute of the transaction data, wherein the dependent transaction attribute is a prerequisite for turning on the service double-write switch, and the service double-write switch is used to write the transaction data to the host and the distributed platform system at the same time after it is turned on; when the transaction attribute of the transaction data matches the dependent transaction attribute, the transaction data is written to the host and the distributed platform system by turning on the service double-write switch; when the transaction attribute of the transaction data does not match the dependent transaction attribute, turning on the service double-write switch is prohibited, and the transaction data is written to the host.

[0010] Optionally, the dependent transaction attributes include at least one of the following three attributes: a preset transaction area; a preset transaction outlet; a preset transaction channel.

[0011] Optionally, detecting whether the dependent transaction attributes of the service double-write switch match the transaction attributes of the transaction data includes: when the transaction attributes of the transaction data satisfy all attributes included in the dependent transaction attributes, determining that the dependent transaction attributes of the service double-write switch match the transaction attributes of the transaction data; when the transaction attributes of the transaction data do not satisfy any attribute included in the dependent transaction attributes, determining that the dependent transaction attributes of the service double-write switch do not match the transaction attributes of the transaction data.

[0012] Optionally, before performing data anti-corrosion processing on the transaction data stored in the host and / or the transaction data stored in the distributed platform system, the transaction data processing method also includes: when the transaction data in the host and / or the distributed platform system is updated, copying the updated data to the data lake; detecting the primary key, version and time information corresponding to each data received by the data lake; and performing a filtering operation on the multiple data received by the data lake according to the primary key, version and time information corresponding to each data, wherein the filtering operation is used to filter out the data with the latest update time and the target version from multiple data with the same primary key but different versions for retention, and the target version of the data represents the data on which the deletion operation has been performed.

[0013] Optionally, data anti-corrosion processing is performed on the transaction data stored in the host and / or the transaction data stored in the distributed platform system, including: in response to an output instruction for the transaction data, querying the transaction data from the host and the distributed platform system respectively; when it is found that the transaction data exists in the host but not in the distributed platform system, using the transaction data in the host as the output result; when it is found that the transaction data exists in both the host and the distributed platform system, using the transaction data in the host as the output result; when it is found that the transaction data does not exist in the host but exists in the distributed platform system, using the transaction data in the distributed platform system as the output result.

[0014] Optionally, the method for processing transaction data also includes: when a transaction corresponding to the transaction data fails and data rollback is required, determining a data source involved in the data rollback based on a service double-write switch and a target list, wherein the data source includes a host and / or a distributed platform system; and performing a data rollback operation on the transaction data in the data source.

[0015] In order to achieve the above-mentioned purpose, according to another aspect of an embodiment of the present application, a transaction data processing device is also provided, including: a determination unit, which determines to write the transaction data into a host and / or a distributed platform system according to a service double-write switch and a target list, wherein the target list is used to record transaction objects for which transaction risks have been eliminated, and the service double-write switch is used to determine the data write selection according to the transaction attributes of the transaction data; a processing unit, which performs data anti-corrosion processing on the transaction data stored in the host and / or the transaction data stored in the distributed platform system after the transaction data is written to the host and / or the distributed platform system, wherein the data anti-corrosion processing is used to determine to use the transaction data stored in the host as an output result, or to use the transaction data stored in the distributed platform system as an output result.

[0016] According to another aspect of an embodiment of the present application, there is also provided an electronic device, comprising one or more processors and a memory, wherein the memory is used to store one or more programs, wherein when the one or more programs are executed by the one or more processors, the one or more processors execute the above-mentioned method for processing transaction data.

[0017] According to another aspect of an embodiment of the present application, a computer-readable storage medium is provided, in which a computer program is stored. When the computer program is executed, the device where the computer-readable storage medium is located executes the above-mentioned method for processing transaction data.

[0018] According to another aspect of an embodiment of the present application, a computer program product is also provided, including computer instructions, which implement the steps of the above-mentioned transaction data processing method when executed by a processor.

[0019] In an embodiment of the present application, first, it is determined based on the service double-write switch and the target list whether the transaction data is written to the host and / or the distributed platform system, wherein the target list is used to record the transaction objects for which the transaction risks have been eliminated, and the service double-write switch is used to determine the data write selection based on the transaction attributes of the transaction data. Then, after the transaction data is written to the host and / or the distributed platform system, data anti-corrosion processing is performed on the transaction data stored in the host and / or the transaction data stored in the distributed platform system, wherein the data anti-corrosion processing is used to determine whether the transaction data stored in the host is used as the output result, or whether the transaction data stored in the distributed platform system is used as the output result.

[0020] From the above content, it can be seen that the core of this application is to determine whether the transaction data is written to both the host and the distributed platform system, or only to one of them, based on the service double write switch and the target list. The service double write switch determines the data writing strategy based on the transaction attributes of the transaction data (such as transaction area, outlets, channels, etc.), while the target list records the transaction objects that have been excluded from transaction risks, providing additional protection for high-risk transactions.

[0021] Secondly, after the transaction data is written, data consistency verification and data anti-corruption processing methods are provided to ensure that the transaction data in the host and distributed platform systems remain consistent. This includes daily incremental verification of transaction data in the dual systems, and when inconsistencies are found, the correct output results are selected according to preset rules, and abnormal transaction protocols are marked for subsequent analysis and governance.

[0022] It can be seen that through the technical solution of the present application, the purpose of efficiently and securely processing transaction data between heterogeneous systems is achieved, thereby realizing the technical effect of using two sets of heterogeneous ecosystems, namely the host and the distributed platform system, as a whole to provide external services for transaction data, thereby solving the problem in the prior art that for information security reasons, two sets of heterogeneous ecosystems, namely the host and the distributed platform system, are used as a whole to provide external services for transaction data, but currently data input and data output are still maintained separately for each system, making it difficult to maintain parallel processing and consistency of data, resulting in transaction data being prone to processing exceptions, which in turn causes the technical problem of a high transaction failure rate. BRIEF DESCRIPTION OF THE DRAWINGS

[0023] The drawings described herein are used to provide a further understanding of the present application and constitute a part of the present application. The illustrative embodiments of the present application and their descriptions are used to explain the present application and do not constitute an improper limitation on the present application. In the drawings:

[0024] Figure 1 A hardware structure block diagram of a computer terminal for implementing a method for processing transaction data is shown;

[0025] Figure 2 is a flowchart of an optional transaction data processing method according to an embodiment of the present application;

[0026] Figure 3 is a schematic diagram of routing states of an optional transaction data processing method according to an embodiment of the present application;

[0027] Figure 4 is a schematic diagram of checking errors of an optional transaction data processing method according to an embodiment of the present application;

[0028] Figure 5 is a schematic diagram of double-write switch parameters of an optional transaction data processing method according to an embodiment of the present application;

[0029] Figure 6 is a dual write switch priority determination flow chart of an optional transaction data processing method according to an embodiment of the present application;

[0030] Figure 7 It is a flow chart of logically merging host and platform table data in an optional transaction data processing method according to an embodiment of the present application;

[0031] Figure 8 is a data anti-corrosion flow chart of an optional transaction data processing method according to an embodiment of the present application;

[0032] Fig. 9 is a data rollback operation flow chart of an optional transaction data processing method according to an embodiment of the present application;

[0033] Fig.10 is a flowchart of an optional transaction data processing method according to an embodiment of the present application;

[0034] Fig.11 is a schematic diagram of a transaction data processing device provided according to an embodiment of the present application;

[0035] Fig.12 It is a structural block diagram of an electronic device according to an embodiment of the present application. DETAILED DESCRIPTION

[0036] In order to enable those skilled in the art to better understand the present application, the technical solutions in the embodiments of the present application will be clearly and completely described below in conjunction with the drawings in the embodiments of the present application. Obviously, the described embodiments are only part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without creative work should fall within the scope of protection of this application.

[0037] It should be noted that the terms "first", "second", etc. in the specification and claims of the present application and the above-mentioned drawings are used to distinguish similar objects, and are not necessarily used to describe a specific order or sequence. It should be understood that the data used in this way can be interchangeable where appropriate, so that the embodiments of the present application described herein can be implemented in an order other than those illustrated or described herein. In addition, the terms "including" and "having" and any of their variations are intended to cover non-exclusive inclusions, for example, a process, method, system, product or device comprising a series of steps or units is not necessarily limited to those steps or units clearly listed, but may include other steps or units that are not clearly listed or inherent to these processes, methods, products or devices.

[0038] It should also be noted that the collected information (including but not limited to user device information, user personal information, etc.) and data (including but not limited to data for display, data for analysis, etc.) involved in this application are information and data authorized by the user or fully authorized by all parties, and the collection, storage, use, processing, transmission, provision, disclosure and application of relevant data are in compliance with relevant laws, regulations and standards, necessary confidentiality measures are taken, and public order and good customs are not violated, and corresponding operation entrances are provided for users to choose to authorize or refuse. For example, an interface is set up between this system and relevant users or institutions to provide users with corresponding operation entrances for users to choose to agree or refuse the results of automated decision-making; if the user chooses to refuse, the expert decision-making process will be entered.

[0039] According to an embodiment of the present application, a method embodiment of a method for processing transaction data is provided. It should be noted that the steps shown in the flowchart of the accompanying drawings can be executed in a computer system such as a set of computer executable instructions, and although a logical order is shown in the flowchart, in some cases, the steps shown or described can be executed in an order different from that shown here.

[0040] It should be noted that a transaction data processing system can be used as the execution subject of the transaction data processing method of the embodiment of the present application. It is understandable that the transaction data processing method provided in the embodiment of the present application can also be executed by other systems or devices, and the embodiment of the present application does not specifically limit this.

[0041] The method embodiments provided in the embodiments of the present application can be executed in a mobile terminal, a computer terminal or a similar computing device. Figure 1 The hardware structure block diagram of a computer terminal (or mobile device) for implementing a method for processing transaction data is shown. Figure 1As shown, the computer terminal 10 (or mobile device) may include one or more (102a, 102b, ..., 102n are used to illustrate) processors 102 (the processor 102 may include but is not limited to a processing device such as a microprocessor MCU or a programmable logic device FPGA), a memory 104 for storing data, and a transmission device 106 for communication functions. In addition, it may also include: a display, an input / output interface (I / O interface), a universal serial bus (USB) port (which may be included as one of the ports of the BUS bus), a network interface, a power supply and / or a camera. It can be understood by those skilled in the art that Figure 1 The structure shown is only for illustration and does not limit the structure of the above electronic device. Figure 1 More or fewer components as shown, or with Figure 1 Different configurations are shown.

[0042] It should be noted that the one or more processors 102 and / or other data processing circuits described above may generally be referred to herein as "data processing circuits". The data processing circuit may be embodied in whole or in part as software, hardware, firmware, or any other combination thereof. In addition, the data processing circuit may be a single independent processing module, or may be fully or partially integrated into any of the other components in the computer terminal 10 (or mobile device). As in the method for processing transaction data involved in the embodiments of the present application, the data processing circuit serves as a processor control (e.g., selection of a variable resistor terminal path connected to an interface).

[0043] The memory 104 can be used to store software programs and modules of application software, such as program instructions / data storage devices corresponding to the method for processing transaction data in the embodiment of the present application. The processor 102 executes various functional applications and data processing by running the software programs and modules stored in the memory 104, that is, realizing the above-mentioned method for processing transaction data. The memory 104 may include a high-speed random access memory, and may also include a non-volatile memory, such as one or more magnetic storage devices, flash memory, or other non-volatile solid-state memory. In some examples, the memory 104 may further include a memory remotely arranged relative to the processor 102, and these remote memories may be connected to the computer terminal 10 via a network. Examples of the above-mentioned network include, but are not limited to, the Internet, an intranet, a local area network, a mobile communication network, and combinations thereof.

[0044] The transmission device 106 is used to receive or send data via a network. The specific example of the above network may include a wireless network provided by a communication provider of the computer terminal 10. In one example, the transmission device 106 includes a network adapter (Network Interface Controller, NIC), which can be connected to other network devices through a base station so as to communicate with the Internet. In one example, the transmission device 106 can be a radio frequency (RF) module, which is used to communicate with the Internet wirelessly.

[0045] The display may be, for example, a touch screen liquid crystal display (LCD) that enables a user to interact with a user interface of the computer terminal 10 (or mobile device).

[0046] Under the above operating environment, this application provides Figure 2 The method of processing transaction data shown. Figure 2 FIG. 1 is a flowchart of an optional transaction data processing method according to an embodiment of the present application. Figure 2 As shown, the method comprises the following steps:

[0047] Step S201, determining to write transaction data into a host and / or distributed platform system according to a service dual-write switch and a target list.

[0048] In step S201, the target list is used to record the transaction objects that have been free of transaction risks, and the service dual write switch is used to determine the data writing selection according to the transaction attributes of the transaction data.

[0049] Optionally, the transaction data processing system determines to write the transaction data into the host and / or distributed platform system according to the coordinated action of the service dual-write switch and the target list.

[0050] Optionally, the service dual write switch can dynamically decide whether the transaction data should be written to both the host system and the distributed platform system, or only one of them, based on the inherent transaction attributes of the transaction data (such as the geographic location of the transaction, the attributes of the outlets, the channel type, etc.). This ensures efficient storage and access to data, and at the same time, provides a stable data processing environment considering the complexity during system migration and parallel operation.

[0051] Optionally, the target list is used to record entities or transaction objects that have passed strict risk assessment and are considered to have low risk at the transaction level. The target list not only speeds up the processing of low-risk transactions, but also ensures the safe writing path of high-risk transaction data through the judgment of the service double write switch, that is, it is preferentially or only written to the host system for processing, thereby effectively avoiding potential systemic risks.

[0052] Step S202: after the transaction data is written into the host and / or the distributed platform system, data anti-corrosion processing is performed on the transaction data stored in the host and / or the transaction data stored in the distributed platform system.

[0053] In step S202, data anti-corrosion processing is used to determine whether to use the transaction data stored in the host as the output result, or to use the transaction data stored in the distributed platform system as the output result.

[0054] Optionally, data anti-corrosion processing is used to determine whether the transaction data stored in the host is used as the output result, or whether the transaction data stored in the distributed platform system is used as the output result, so as to scientifically determine the data source of the system output result.

[0055] Optionally, in a complex environment where host and distributed platform systems coexist, the selection of output results must take into account multiple factors, including the timeliness and consistency of the data and the stability of the system operation, and use data anti-corrosion processing to select output results.

[0056] It can be seen from the contents of steps S201 to S202 that in an embodiment of the present application, first, it is determined based on the service double-write switch and the target list whether the transaction data is written to the host and / or the distributed platform system, wherein the target list is used to record the transaction objects for which transaction risks have been eliminated, and the service double-write switch is used to determine the data write selection based on the transaction attributes of the transaction data. Then, after the transaction data is written to the host and / or the distributed platform system, data anti-corrosion processing is performed on the transaction data stored in the host and / or the transaction data stored in the distributed platform system, wherein the data anti-corrosion processing is used to determine whether the transaction data stored in the host is used as the output result, or whether the transaction data stored in the distributed platform system is used as the output result.

[0057] From the above content, it can be seen that the core of this application is to determine whether the transaction data is written to both the host and the distributed platform system, or only to one of them, based on the service double write switch and the target list. The service double write switch determines the data writing strategy based on the transaction attributes of the transaction data (such as transaction area, outlets, channels, etc.), while the target list records the transaction objects that have been excluded from transaction risks, providing additional protection for high-risk transactions.

[0058] Secondly, after the transaction data is written, data consistency verification and data anti-corruption processing methods are provided to ensure that the transaction data in the host and distributed platform systems remain consistent. This includes daily incremental verification of transaction data in the dual systems, and when inconsistencies are found, the correct output results are selected according to preset rules, and abnormal transaction protocols are marked for subsequent analysis and governance.

[0059] It can be seen that through the technical solution of the present application, the purpose of efficiently and securely processing transaction data between heterogeneous systems is achieved, thereby realizing the technical effect of using two sets of heterogeneous ecosystems, namely the host and the distributed platform system, as a whole to provide external services for transaction data, thereby solving the problem in the prior art that for information security reasons, two sets of heterogeneous ecosystems, namely the host and the distributed platform system, are used as a whole to provide external services for transaction data, but currently data input and data output are still maintained separately for each system, making it difficult to maintain parallel processing and consistency of data, resulting in transaction data being prone to processing exceptions, which in turn causes the technical problem of a high transaction failure rate.

[0060] In an optional embodiment, the transaction data processing system first performs a consistency check on the transaction data stored in the host and the transaction data stored in the distributed platform system when the transaction data is simultaneously written to the host and the distributed platform system to obtain a check result, and then, when it is found that the transaction data stored in the host and the transaction data stored in the distributed platform system are inconsistent, the state of the protocol routing state table is marked as a target state, wherein the protocol routing state table is used to record the state of the transaction protocol related to the transaction data, and the protocol routing state table in the target state is used to control all subsequent transaction requests using the transaction protocol to be processed by the host and not sent to the distributed platform system.

[0061] Optionally, in a heterogeneous system parallel writing environment, the consistency check operation of transaction data lays the foundation for data integrity. When transaction data is written to the host and the distributed platform system at the same time, the transaction data stored in the host is compared with the corresponding data stored in the distributed platform system to detect whether there is a difference between the two, identify the consistency status of the data, and output detailed verification results.

[0062] Optionally, when it is verified that the transaction data stored in the host is inconsistent with the transaction data stored in the distributed platform system, the transaction data processing system will automatically adjust the status mark in the protocol routing status table to the target state, which is a predefined emergency state indicating that all subsequent transaction requests involving the transaction protocol should be processed directly by the host system instead of being sent in parallel to the distributed platform system.

[0063] Optionally, the protocol status related to the transaction data is recorded through the protocol routing status table, so that in the event of data inconsistency, prompt action can be taken to ensure accurate processing of business requests and prevent potential business interruptions or data errors from affecting bank operations.

[0064] Optionally, there is an optional transaction data processing method routing status technical table, recording the product protocol routing status, such as Figure 3As shown: PRTOEX indicates the protocol number of the participant, and the data type is VARCHAR(34); STATUS indicates the routing status, and the data type is TINYINT. When STATUS is 0, it indicates that the routing status is normal, and when STATUS is 1, it indicates that the status is switched back to the host; LST_DATE indicates the last update date, and the data type is DATE; ROUTE_KEY indicates the routing field, and the data type is VARCHAR(34). When the host platform data verification fails, the status of the corresponding product protocol record is updated to "switch back to the host", and all subsequent transactions initiated by the corresponding product protocol record are only on the host; the host dual-write public component adds a check on the corresponding record status of the product protocol routing status technical table in the dual-write (platform-based) stage. If the status is "switch back to the host", only the host branch is called (the platform branch is not called).

[0065] From the above content, it can be seen that the transaction data processing system performs output verification in parallel on two machines to ensure the consistency of system output and supports manual switching back to the host when the data is inconsistent. This reflects the strict requirements for data integrity and highlights the foresight and innovation of the banking system in business continuity and data consistency management in the context of digital transformation.

[0066] In an optional embodiment, the transaction data processing system first obtains the key field value returned by the host after the transaction data is written to the host, and then obtains the key field value returned by the distributed platform system after the transaction data is written to the distributed platform system. Then, when it is detected that the key field value returned by the host is the same as the key field value returned by the distributed platform system, it is determined that the transaction data stored in the host and the transaction data stored in the distributed platform system are consistent. Finally, when it is detected that the key field value returned by the host is different from the key field value returned by the distributed platform system, it is determined that the transaction data stored in the host and the transaction data stored in the distributed platform system are inconsistent.

[0067] Optionally, the transaction data processing system obtains key field values ​​returned by the host after the transaction data is written to the host, ensuring complete capture of all key field values ​​and laying a solid foundation for subsequent consistency verification.

[0068] Optionally, the transaction data processing system obtains key field values ​​returned by the distributed platform system after the transaction data is written into the distributed platform system, thereby ensuring real-time synchronization and comparison of data responses in a dual-machine parallel architecture.

[0069] Optionally, when the key field values ​​returned by the host system and the distributed platform system are completely consistent, the transaction data processing system will automatically confirm that the transaction data status of the two remain synchronized, that is, the data consistency is scientifically verified. When the key field value returned by the host is different from the key field value returned by the distributed platform system, the system will immediately determine that the transaction data status stored by the host and the platform are inconsistent.

[0070] Optionally, there is an optional transaction data processing method error checking technical table, recording the product protocol routing status, such as Figure 4 As shown: PRTOEX represents the protocol number of the participant, and the data type is VARCHAR(34); MAINFRAME_OUTPUT represents the communication area returned by the host, and the data type is TEXT; PLATFORM_OUTPUT represents the communication area returned by the platform, and the data type is TEXT; CHECK_NAME represents the difference field name, and the data type is TEXT; LST_DATE represents the last updated date, and the data type is DATE; ROUTE_KEY represents the routing field, and the data type is VARCHAR(34). The host double-write public component adds the logic of checking the communication area returned by the two machines in the double-write (platform-based, host-based) stage. According to the important field information and checking rules configured by the application, the values ​​returned by the platform / host are compared one by one to see if they are consistent. When the checking is inconsistent, the relevant information is output to a separate log file, and the application is supported to register and check the inconsistent information in the error register by itself. When the application service needs to be switched back, the corresponding record status of the product protocol routing status technical table is updated to "switch back to the host".

[0071] From the above content, it can be seen that the transaction data processing system provides an efficient and reliable transaction data consistency verification method to ensure the accuracy of the data. It can also take quick measures when the data status is abnormal to prevent system risks caused by data inconsistency.

[0072] In an optional embodiment, the transaction data processing system first writes the transaction data into the host and the distributed platform system when it is detected that the transaction object of the transaction data is a transaction object in the target list. Then, when it is detected that the transaction object of the transaction data is not a transaction object in the target list, the transaction data processing system detects whether the dependent transaction attribute of the service double-write switch matches the transaction attribute of the transaction data, wherein the dependent transaction attribute is a prerequisite for turning on the service double-write switch. After the service double-write switch is turned on, it is used to write the transaction data to the host and the distributed platform system at the same time. Then, when the transaction attribute of the transaction data matches the dependent transaction attribute, the transaction data is written to the host and the distributed platform system by turning on the service double-write switch. Finally, when the transaction attribute of the transaction data does not match the dependent transaction attribute, the service double-write switch is prohibited from being turned on, and the transaction data is written to the host.

[0073] Optionally, the target list is a scientifically screened and risk-assessed database that records all entities or objects that are considered to have eliminated transaction risks.

[0074] Optionally, the transaction data processing system detects whether the dependent transaction attributes of the service double-write switch match the transaction attributes of the transaction data. The matching process not only takes into account basic attributes such as time, place and channel of the transaction, but also covers more complex business logic and risk assessment rules, providing a scientific basis for the dynamic opening of the service double-write switch.

[0075] Optionally, when the transaction attribute of the transaction data is completely consistent with the dependent transaction attribute of the service dual write switch, the transaction data processing system turns on the service dual write switch and executes the dual-machine parallel writing process. When it is detected that the transaction attribute of the transaction data does not match the dependent transaction attribute, the transaction data is written to the host.

[0076] Optionally, there is an optional double write switch priority determination flow chart of a transaction data processing method, such as Figure 5 As shown: Support system applications to set target lists based on customer information number, media number, agreement account number and other information. The target list information is set in the application database; for customer transaction requests that belong to the target list, bypass the service double-write switch judgment and directly process according to the double-write process (the specific processing rules can be customized by the application). For customer transaction requests that do not belong to the target list, obtain the switch of transaction area + transaction outlet + transaction channel; if the above switch is not set, obtain the regional switch of transaction area + 0 outlet + 0 channel; if the above switch is not set, obtain the total switch of 0 area + 0 outlet + 0 channel; if the total switch is not set, the default switch is to call the host only (service-based process).

[0077] From the above content, it can be seen that the transaction data processing system matches the transaction data through the target list and the dependent transaction attributes, thereby achieving efficient and secure transaction data processing.

[0078] In an optional embodiment, the dependent transaction attribute includes at least one of the following three attributes: a preset transaction area; a preset transaction outlet; a preset transaction channel.

[0079] Optionally, the transaction data processing system provides accurate decision-making basis for data processing under the dual-machine parallel architecture according to the settings of three dimensions: preset transaction areas, preset transaction outlets, and preset transaction channels.

[0080] Optionally, the preset transaction area attribute takes into account the geographical location information where the transaction occurs, the preset transaction outlet attribute focuses on the specific location of the transaction, and the preset transaction channel attribute covers the execution method of the transaction.

[0081] Optionally, there is an optional double-write switch parameter table of a transaction data processing method, which supports the system application to set the service double-write switch according to the region, outlet, and channel, and the service double-write switch parameters are set in the application database, such as Figure 6 As shown: ZONE_NO indicates the area code, 0 indicates that it is effective for the entire area; BR_NO indicates the branch number, 0 indicates that it is effective for all branches in the area; CHAN_TYPE indicates the channel type, 0 indicates that it is effective for all channels; PARAM_VALUE indicates the parameter value, 1-only on the host, 2-double write-based on the host, 3-double write-based on the platform, 4-only on the platform.

[0082] From the above content, it can be seen that the transaction data processing system can accurately analyze and judge the characteristics of each transaction data according to the settings of preset transaction areas, preset transaction outlets and preset transaction channels, ensuring that the decision to turn on the service double-write switch is not only in line with business logic, but also can effectively avoid potential risks.

[0083] In an optional embodiment, the transaction data processing system first determines that the dependent transaction attributes of the service double-write switch match the transaction attributes of the transaction data when the transaction attributes of the transaction data satisfy all attributes included in the dependent transaction attributes, and then determines that the dependent transaction attributes of the service double-write switch do not match the transaction attributes of the transaction data when the transaction attributes of the transaction data do not satisfy any attribute included in the dependent transaction attributes.

[0084] Optionally, the transaction data processing system conducts a comprehensive comparative analysis of attributes such as the transaction area, transaction outlets and transaction channels of the transaction data, and when it is found that the transaction attributes of the transaction data are completely consistent with all preset conditions in the dependent transaction attributes, it is determined that the dependent transaction attributes of the service double-write switch match the transaction attributes of the transaction data.

[0085] Optionally, in the matching determination of the transaction attribute and the dependent transaction attribute, the transaction data processing system considers the situation where any attribute condition is not satisfied. When the transaction attribute of the transaction data fails to completely match any preset condition in the dependent transaction attribute, the system will immediately identify and determine the mismatch between the dependent transaction attribute and the transaction attribute of the transaction data.

[0086] Optionally, there is an example of detecting whether the dependent transaction attribute of the service double write switch matches the transaction attribute of the transaction data: Method 1: The dependent transaction attribute is limited to: A transaction area, B transaction outlet, C transaction channel; then the transaction data just meets A transaction area, B transaction outlet, C transaction channel, then it matches, otherwise it does not match. Method 2: The dependent transaction attribute is only limited to: C transaction channel; then transaction data 1 meets A transaction area, B transaction outlet, C transaction channel, then it matches; transaction data 2 meets A1 transaction area, B1 transaction outlet, C transaction channel, and also matches, but transaction data 3 meets A transaction area, B transaction outlet, D transaction channel, then it does not match.

[0087] From the above content, it can be seen that the transaction data processing system realizes intelligent decision-making and dynamic control of the service double-write switch by matching transaction attributes with dependent transaction attributes, reflecting the application value of data science in transaction data processing.

[0088] In an optional embodiment, before performing data anti-corrosion processing on transaction data stored in the host and / or transaction data stored in the distributed platform system, the transaction data processing system first copies the updated data to the data lake when the transaction data in the host and / or distributed platform system is updated, then detects the primary key, version and time information corresponding to each data received by the data lake, and then performs a filtering operation on the multiple data received by the data lake according to the primary key, version and time information corresponding to each data, wherein the filtering operation is used to filter out the data with the latest update time and the target version from multiple data with the same primary key but different versions for retention, and the target version of the data represents the data on which the deletion operation has been performed.

[0089] Optionally, when any data update occurs in the transaction data in the host or distributed platform system, the transaction data processing system will accurately copy the updated data to the data lake, ensuring data synchronization in a heterogeneous system environment and providing a solid data foundation for subsequent data consistency verification and processing.

[0090] Optionally, the transaction data processing system detects the primary key, version, and time information corresponding to each data received by the data lake, and can perform a comprehensive attribute analysis on each data received by the data lake.

[0091] Optionally, the filtering operation is used to filter out the data with the latest update time and the target version from multiple data with the same primary key but different versions, and retain them. The target version of the data represents the data on which the deletion operation has been performed, thereby improving the efficiency of data processing.

[0092] Optionally, in the process of switching the flow from the host to the platform, there may be a back-and-forth switch between the host and platform tables. In order to shield the impact on the downstream data, a layer of processing is performed on the source data generation side to realize the logical merging of the host and platform table data so that downstream users can use the data service normally. There is an optional example of the logical merging of the host and platform table data flow:

[0093] (1) When the source application database performs DML operations, the data records are entered into the lake through data replication (such as high-efficiency DRP replication or end-of-day file entry into the lake).

[0094] (2) For the original table entering the lake, the data lake will determine that after the data for the day is completed, the data will be filtered from this table through the Hive data warehouse SQL stored procedure to enter the data external service table (the filtering conditions vary depending on the table, and the general principle is to take the last record that is not D for the records with the same primary key, based on the business date field workdate, etc.).

[0095] (3) After the hive data warehouse SQL stored procedure is run in the data lake to process and filter the records, determine whether anti-corrosion treatment is required based on the configuration table BDP_ANTI_CONFIG: If anti-corrosion treatment is required, perform data backup and back up the data generated by the processing to the external service table to the ANTI backup table (temporarily retained for 1 month, and the table can be accessed later to check the problem); then execute the hive data warehouse SQL stored procedure

[0096] _ANTI completes the anti-corrosion process; this step is intended to decide whether to use the original host table a data or the platform table A data.

[0097] Optionally, there is an optional transaction data processing method in which the host and platform tables are logically merged into a data flow chart, such as Figure 7 As shown: for the host table a, let the end-of-day file enter the data lake to obtain the host source table a'; for the platform table A, according to drp, get the FRN_temporary table (96 partitions), and then get 050.hql, and then determine whether it needs anti-corrosion. If necessary, back up the data to A", and perform anti-corrosion on the host source table a' and / or A", and finally get the platform source table A'; if anti-corrosion is not required, directly get the platform source table A'.

[0098] From the above content, it can be seen that before the transaction data processing system performs data anti-corrosion processing, a layer of processing is performed on the source data generation side to achieve a logical merger of the host and platform table data, shielding the impact on downstream data, and improving the response speed and accuracy of the data lake when processing complex data update events.

[0099] In an optional embodiment, the transaction data processing system first responds to an output instruction for the transaction data, queries the transaction data from the host and the distributed platform system respectively, and then, when it is found that the transaction data exists in the host but not in the distributed platform system, uses the transaction data in the host as the output result; and then, when it is found that the transaction data exists in both the host and the distributed platform system, uses the transaction data in the host as the output result; finally, when it is found that the transaction data does not exist in the host but exists in the distributed platform system, uses the transaction data in the distributed platform system as the output result.

[0100] Optionally, in response to output instructions for transaction data, the transaction data processing system queries the transaction data from the host and distributed platform systems respectively, thereby ensuring the efficiency and synchronization of the query process.

[0101] Optionally, during the query process, if it is found that the specified transaction data does not exist in the distributed platform system, but the corresponding data records are stored in the host, the transaction data in the host will be used as the output result to ensure that in the event of missing distributed platform data, a complete and accurate service response can be provided based on the data backup of the host system.

[0102] Optionally, there is a data anti-corrosion flow chart of an optional transaction data processing method, such as Figure 8 As shown: In BDP, according to the field comparison relationship between the host lake table A and the platform lake table B, the primary key is merged and processed in EDI. Among them, if the host has it but the platform does not, it is a scenario of no flow switching or emergency back-cutting, and the host shall prevail; if the host does not have it but the platform does, it is a scenario of disconnected host, and the platform shall prevail; if the host has it but the platform does, it is a dual-write scenario, and the host shall prevail. After the processing is completed, if the structure in the result table B' is consistent with the platform table, data anti-corrosion is performed, and then the anti-corrosion data can be logically processed in downstream applications.

[0103] From the above content, it can be seen that the transaction data processing system achieves accurate, consistent and timely response of transaction data output results by performing anti-corrosion processing on the data.

[0104] In an optional embodiment, when a transaction corresponding to the transaction data fails and data rollback is required, the transaction data processing system first determines the data source involved in the data rollback based on the service double-write switch and the target list, wherein the data source includes a host and / or a distributed platform system, and then performs a data rollback operation on the transaction data in the data source.

[0105] Optionally, when a transaction corresponding to the transaction data encounters a failure and the system determines that a data rollback is required to repair possible data anomalies, the transaction data is restored to a state before the failure, thereby eliminating possible data anomalies and system risks.

[0106] Optionally, there is a data rollback operation flow chart of an optional transaction data processing method, such as Fig. 9 As shown: For FMTA, in the grayscale case, when the switch of the flow-cutting area is turned on, for the platform, according to the FMTA service interface, the platform program is entered. If the transaction is successful, the host value is returned through the host. If the transaction fails, the platform value is directly returned; for the host, according to the FMTA service interface, the platform program is entered. Regardless of whether the transaction is successful or not, the host value is returned according to the host. When the switch of the flow-cutting area is turned off, according to the FMTA service interface, the host value is returned directly according to the host. In the non-grayscale case, when the switch of the flow-cutting area is turned off, according to the FMTA service interface, the host value is returned directly according to the host.

[0107] Optionally, in addition to the data rollback operation, there is an example of adding a host dual-write base class AbstractACSBaseService to implement the following unified scheduling, including:

[0108] (1) Input parameter check (dataCheck): The application implements specific parameter checking logic on its own.

[0109] (2) Read the service double write switch (getDoubleSwitch): Get the double write switch according to a unified rule.

[0110] (3) Preprocessing (preCheck): implemented by the application itself.

[0111] (4) Host processing flow (mainFrameDeal): The application calls the specific host interface to implement business processing.

[0112] (5) Platform processing flow (platformDeal): The application implements the platform business logic processing by itself.

[0113] (6) Host compensation processing flow (mainFrameDealRollBack): The application calls the specific host interface to implement the compensation process.

[0114] (7) Platform Compensation Process (platformDealRollBack): The application implements the platform business logic compensation process by itself.

[0115] (8) Sub-transaction positive transaction method, according to the service double write switch, execution process:

[0116] 1) The switch value is MAINFRAME_ONLY, that is, only the host process is called (service-oriented transformation), only mainFrameDeal is called to implement host process processing, and the result is returned according to the host processing;

[0117] 2) The switch value is DOUBLE_WRITE_MAINFRAME, which means double write - based on the host, first call platformDeal to implement platform business logic processing, then call mainFrameDeal to implement host process processing. Platform business logic error does not affect the host processing process, and the host return result is used as the service return result;

[0118] 3) The switch value is DOUBLE_WRITE_PLATFORM, which means double write - subject to the platform.

[0119] 4) The switch value is PLATFORM_ONLY, which means that only the platform process is called (disconnecting the host), and only platformDeal is called to implement the platform business logic processing, and the result is returned according to the platform processing result.

[0120] (9) Sub-transaction compensation method, according to the service double write switch, execution process:

[0121] 1) The switch value is MAINFRAME_ONLY, only mainFrameDealRollBack is called to implement the compensation processing of the host process, and the result is returned according to the host processing result;

[0122] 2) The switch value is DOUBLE_WRITE_MAINFRAME, which implements the compensation processing of the host process. Regardless of the compensation result of the platform, it returns according to the compensation result of the host;

[0123] 3) The switch value is DOUBLE_WRITE_PLATFORM. First, call platformDealRollBack to implement the compensation processing of the platform business logic, then call mainFrameDealRollBack to implement the host process processing, and return according to the platform compensation result.

[0124] (10) The switch value is PLATFORM_ONLY, which means that only platformDealRollBack is called to implement the compensation processing of the platform business logic and returns according to the platform compensation result.

[0125] From the above content, it can be seen that the transaction data processing system builds an intelligent data backtracking and repair framework to ensure data consistency and system stability by determining the data rollback source of failed transactions and scientifically rolling back transaction data in the data source, reflecting the application value of data science in transaction failure scenarios.

[0126] It can be seen from the above content that according to the technical solution of this application, at least the following technical effects can be achieved:

[0127] 1. It realizes the requirements of a super-large core system to provide normal, stable and efficient external services during the host migration process, and meets the requirements of implementing business promotion and business innovation projects in parallel within the system, providing sufficient guarantees for the stability and robustness of the core system to prevent systemic risks from being introduced during the host migration process.

[0128] 2. It realizes the security requirement of migrating massive system data and business data as they move down with the host; it ensures the safe migration of massive customer business data while providing normal data services to the outside world.

[0129] 3. It ensures the daily business operations of a large number of customers and the normal business operations of hundreds of thousands of partners.

[0130] In an optional embodiment, Fig.10 A flowchart of an optional transaction data processing method according to an embodiment of the present application is shown, which can more clearly understand the process of transaction data processing. Among them, a dual-machine parallel control device is deployed in the channel access part outside the system to realize the unified external service of the dual-machine system and gradually switch the control system at different stages of the host migration, thereby reducing the risk of the migration process to the business operation; a device for system output verification outside the dual-machine parallel system is proposed to ensure that the dual-machine system is transparent to the outside at different stages of the host migration, and the overall system output is not affected; a device for incremental data verification and data synchronization at the end of each day is proposed to ensure that the system data and business system can provide services to the outside normally at different stages of the host migration. The specific process is as follows: First, the channel is connected to the dual-machine parallel entrance, mainly including the main machine system and the distributed platform. Then, according to the data replication technology, the main machine source data and the platform source data are checked, and then the data anti-corrosion treatment is performed, and the anti-corrosion data is directly applied to the external application of the system. If the data does not need to be anti-corrosion treated, it can be directly output to the external application of the system through output verification.

[0131] According to another aspect of the embodiment of the present application, a device for processing transaction data is also provided, wherein: Fig.11 is a schematic diagram of an optional transaction data processing device according to an embodiment of the present application, such as Fig.11 As shown, the transaction data processing device includes: a determination unit 1101 and a processing unit 1102.

[0132] The determination unit 1101 determines to write the transaction data into the host and / or the distributed platform system according to the service double-write switch and the target list, wherein the target list is used to record the transaction objects for which the transaction risks have been eliminated, and the service double-write switch is used to determine the data writing selection according to the transaction attributes of the transaction data; the processing unit 1102 performs data anti-corrosion processing on the transaction data stored in the host and / or the transaction data stored in the distributed platform system after the transaction data is written into the host and / or the distributed platform system, wherein the data anti-corrosion processing is used to determine to use the transaction data stored in the host as the output result, or to use the transaction data stored in the distributed platform system as the output result.

[0133] Optionally, the transaction data processing device further includes: a checking unit and a second processing unit. The checking unit is used to check the consistency of the transaction data stored in the host and the transaction data stored in the distributed platform system when the transaction data is written to the host and the distributed platform system at the same time, and obtain a checking result; the second processing unit is used to mark the state of the protocol routing state table as the target state when the transaction data stored in the host and the transaction data stored in the distributed platform system are found to be inconsistent, wherein the protocol routing state table is used to record the state of the transaction protocol related to the transaction data, and the protocol routing state table in the target state is used to control all subsequent transaction requests using the transaction protocol to be processed by the host and not sent to the distributed platform system.

[0134] Optionally, the checking unit includes: a first acquisition subunit, a second acquisition subunit, a first determination subunit, and a second determination subunit. The first acquisition subunit is used to acquire the key field value returned by the host after the transaction data is written to the host; the second acquisition subunit is used to acquire the key field value returned by the distributed platform system after the transaction data is written to the distributed platform system; the first determination subunit is used to determine that the transaction data stored in the host and the transaction data stored in the distributed platform system are consistent when it is detected that the key field value returned by the host is the same as the key field value returned by the distributed platform system; the second determination subunit is used to determine that the transaction data stored in the host and the transaction data stored in the distributed platform system are inconsistent when it is detected that the key field value returned by the host is different from the key field value returned by the distributed platform system.

[0135] Optionally, the determination unit 1101 includes: a first processing subunit, a first detection subunit, a second processing subunit, and a third processing subunit. The first processing subunit is used to write the transaction data into the host and the distributed platform system when it is detected that the transaction object of the transaction data is the transaction object in the target list; the first detection subunit is used to detect whether the dependent transaction attribute of the service double write switch matches the transaction attribute of the transaction data when it is detected that the transaction object of the transaction data is not the transaction object in the target list, wherein the dependent transaction attribute is a precondition for turning on the service double write switch, and the service double write switch is used to write the transaction data into the host and the distributed platform system at the same time after it is turned on; the second processing subunit is used to write the transaction data into the host and the distributed platform system by turning on the service double write switch when the transaction attribute of the transaction data matches the dependent transaction attribute; the third processing subunit is used to prohibit turning on the service double write switch when the transaction attribute of the transaction data does not match the dependent transaction attribute, and write the transaction data into the host.

[0136] Optionally, the dependent transaction attributes include at least one of the following three attributes: a preset transaction area; a preset transaction outlet; a preset transaction channel.

[0137] Optionally, the first detection subunit includes: a first determination module and a second determination module. The first determination module is used to determine that the dependent transaction attribute of the service dual-write switch matches the transaction attribute of the transaction data when the transaction attribute of the transaction data satisfies all attributes included in the dependent transaction attribute; the second determination module is used to determine that the dependent transaction attribute of the service dual-write switch does not match the transaction attribute of the transaction data when the transaction attribute of the transaction data does not satisfy any attribute included in the dependent transaction attribute.

[0138] Optionally, the transaction data processing device further includes: a third processing unit, a detection unit, and a screening unit. The third processing unit is used to copy the updated data to the data lake when the transaction data in the host and / or distributed platform system is updated; the detection unit is used to detect the primary key, version and time information corresponding to each data received by the data lake; the screening unit is used to perform a screening operation on the multiple data received by the data lake according to the primary key, version and time information corresponding to each data, wherein the screening operation is used to screen out the data with the latest update time and the target version from multiple data with the same primary key but different versions for retention, and the target version of the data represents the data on which the deletion operation has been performed.

[0139] Optionally, the processing unit 1102 includes: a first query subunit, a fourth processing subunit, a fifth processing subunit, and a sixth processing subunit. The first query subunit is used to query the transaction data from the host and the distributed platform system respectively in response to the output instruction of the transaction data; the fourth processing subunit is used to use the transaction data in the host as the output result when it is found that the transaction data exists in the host but not in the distributed platform system; the fifth processing subunit is used to use the transaction data in the host as the output result when it is found that the transaction data exists in both the host and the distributed platform system; the sixth processing subunit is used to use the transaction data in the distributed platform system as the output result when it is found that the transaction data does not exist in the host but exists in the distributed platform system.

[0140] Optionally, the transaction data processing device further includes: a second determination unit and a fourth processing unit. The second determination unit is used to determine the data source involved in the data rollback according to the service dual write switch and the target list when the transaction corresponding to the transaction data fails and data rollback is required, wherein the data source includes a host and / or a distributed platform system; and the fourth processing unit is used to perform a data rollback operation on the transaction data in the data source.

[0141] An embodiment of the present application may provide an electronic device, Fig.12 is a structural block diagram of an electronic device according to an embodiment of the present application. Fig.12 As shown, the electronic device may include: one or more ( Fig.12 Only one is shown) a processor, a memory, a storage controller, and a peripheral interface, wherein the peripheral interface is connected to a radio frequency module, an audio module, and a display.

[0142] Among them, the memory can be used to store software programs and modules, such as program instructions / modules corresponding to the methods and devices in the embodiments of the present application, and the processor executes various functional applications and data processing by running the software programs and modules stored in the memory, that is, realizing the above-mentioned method. The memory may include a high-speed random access memory, and may also include a non-volatile memory, such as one or more magnetic storage devices, flash memory, or other non-volatile solid-state memory. In some instances, the memory may further include a memory remotely arranged relative to the processor, and these remote memories may be connected to the terminal via a network. Examples of the above-mentioned network include, but are not limited to, the Internet, an intranet, a local area network, a mobile communication network, and combinations thereof.

[0143] It can be understood by those skilled in the art that Fig.12The structure shown is for illustration only, and the electronic device may also be a smart phone (such as an Android phone, an iOS phone, etc.), a tablet computer, a PDA, a mobile Internet device (Mobile Internet Devices, MID), a PAD, or other terminal devices. Fig.12 The structure of the electronic device is not limited. Fig.12 More or fewer components (such as network interfaces, display devices, etc.) shown in, or having Fig.12 Different configurations are shown.

[0144] A person of ordinary skill in the art can understand that all or part of the steps in the various methods of the above embodiments can be completed by instructing the hardware related to the terminal device through a program, and the program can be stored in a computer-readable storage medium, and the storage medium may include: a flash drive, a read-only memory (ROM), a random access memory (RAM), a magnetic disk or an optical disk, etc.

[0145] According to another aspect of the present application, a computer-readable storage medium is provided, wherein a computer program is stored in the computer-readable storage medium, wherein when the computer program runs, the device where the computer-readable storage medium is located executes the above-mentioned transaction data processing method.

[0146] According to another aspect of the present application, a computer program product is also provided, wherein the computer program product includes computer instructions, wherein when the computer instructions are executed, the device where the computer program product is located executes the above-mentioned transaction data processing method.

[0147] The above-mentioned embodiments or examples disclosed in the present application are not exhaustive, but are only illustrative of some embodiments or examples, and are not intended to be specific limitations on the scope of protection disclosed in the present application. In the absence of contradiction, each step in a certain embodiment or example in the present application can be implemented as an independent example, and the steps can be combined arbitrarily. For example, the scheme after removing some steps in a certain embodiment or example can also be implemented as an independent example, and the order of the steps in a certain embodiment or example can be arbitrarily exchanged. In addition, the optional methods or optional examples in a certain embodiment or example can be combined arbitrarily; in addition, the various embodiments or examples can be combined arbitrarily, for example, some or all steps of different embodiments or examples can be combined arbitrarily, and a certain embodiment or example can be combined arbitrarily with the optional methods or optional examples of other embodiments or examples.

[0148] The serial numbers of the above-mentioned embodiments of the present application are for description only and do not represent the advantages or disadvantages of the embodiments.

[0149] In the above embodiments of the present application, the description of each embodiment has its own emphasis. For parts that are not described in detail in a certain embodiment, please refer to the relevant description of other embodiments.

[0150] In the several embodiments provided in this application, it should be understood that the disclosed technical content can be implemented in other ways. Among them, the device embodiments described above are only schematic. For example, the division of the units can be a logical function division. There may be other division methods in actual implementation. For example, multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be through some interfaces, indirect coupling or communication connection of units or modules, which can be electrical or other forms.

[0151] The units described as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed on multiple units. Some or all of the units may be selected according to actual needs to achieve the purpose of the present embodiment.

[0152] In addition, each functional unit in each embodiment of the present application may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit. The above-mentioned integrated unit may be implemented in the form of hardware or in the form of software functional units.

[0153] If the integrated unit is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present application, in essence, or the part that contributes to the prior art or all or 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 to enable a computer device (which can be a personal computer, a server or a network device, etc.) to perform all or part of the steps of the method described in each embodiment of the present application. The aforementioned storage medium includes: U disk, read-only memory (ROM, Read-Only Memory), random access memory (RAM, Random Access Memory), mobile hard disk, disk or optical disk and other media that can store program codes.

[0154] The above is only a preferred implementation of the present application. It should be pointed out that for ordinary technicians in this technical field, several improvements and modifications can be made without departing from the principles of the present application. These improvements and modifications should also be regarded as the scope of protection of the present application.

Claims

1. A method for processing transaction data, characterized in that: include: Determining to write the transaction data into the host and / or distributed platform system according to the service dual write switch and the target list, wherein the target list is used to record the transaction objects that have been excluded from transaction risks, and the service dual write switch is used to determine the data writing selection according to the transaction attributes of the transaction data; After the transaction data is written into the host and / or the distributed platform system, data anti-corrosion processing is performed on the transaction data stored in the host and / or the transaction data stored in the distributed platform system, wherein the data anti-corrosion processing is used to determine whether to use the transaction data stored in the host as the output result, or to use the transaction data stored in the distributed platform system as the output result.

2. The method for processing transaction data according to claim 1, characterized in that: The transaction data processing method further includes: In the case where the transaction data is written into the host and the distributed platform system at the same time, performing consistency check on the transaction data stored in the host and the transaction data stored in the distributed platform system to obtain a check result; When it is verified that the transaction data stored in the host is inconsistent with the transaction data stored in the distributed platform system, the state of the protocol routing state table is marked as the target state, wherein the protocol routing state table is used to record the state of the transaction protocol related to the transaction data, and the protocol routing state table in the target state is used to control all subsequent transaction requests using the transaction protocol to be processed by the host and not sent to the distributed platform system.

3. The method for processing transaction data according to claim 2, characterized in that: Performing consistency check on the transaction data stored in the host and the transaction data stored in the distributed platform system, including: Obtaining a key field value returned by the host after writing the transaction data to the host; Obtaining a key field value returned by the distributed platform system after writing the transaction data into the distributed platform system; In the case where it is detected that the key field value returned by the host is the same as the key field value returned by the distributed platform system, determining that the transaction data stored in the host is consistent with the transaction data stored in the distributed platform system; When it is detected that the key field value returned by the host is different from the key field value returned by the distributed platform system, it is determined that the transaction data stored in the host and the transaction data stored in the distributed platform system are inconsistent.

4. The method for processing transaction data according to claim 1, characterized in that: Determine whether to write transaction data to the host and / or distributed platform system based on the service dual-write switch and target list, including: When it is detected that the transaction object of the transaction data is a transaction object in the target list, writing the transaction data into the host and the distributed platform system; In the case where it is detected that the transaction object of the transaction data is not a transaction object in the target list, detecting whether the dependent transaction attribute of the service dual-write switch matches the transaction attribute of the transaction data, wherein the dependent transaction attribute is a precondition for turning on the service dual-write switch, and after the service dual-write switch is turned on, the transaction data is simultaneously written into the host and the distributed platform system; When the transaction attribute of the transaction data matches the dependent transaction attribute, writing the transaction data into the host and the distributed platform system by turning on the service dual-write switch; In the case where the transaction attribute of the transaction data does not match the dependent transaction attribute, it is prohibited to turn on the service dual-write switch to write the transaction data into the host.

5. The method for processing transaction data according to claim 4, characterized in that: The dependent transaction attribute includes at least one of the following three attributes: Default trading area; Preset transaction outlets; Preset transaction channels.

6. The method for processing transaction data according to claim 4, characterized in that: Detecting whether the dependent transaction attribute of the service dual-write switch matches the transaction attribute of the transaction data includes: When the transaction attributes of the transaction data satisfy all attributes included in the dependent transaction attributes, determining that the dependent transaction attributes of the service dual-write switch match the transaction attributes of the transaction data; When the transaction attribute of the transaction data does not satisfy any attribute included in the dependent transaction attribute, it is determined that the dependent transaction attribute of the service dual-write switch does not match the transaction attribute of the transaction data.

7. The method for processing transaction data according to claim 1, characterized in that: Before performing data anti-corrosion processing on the transaction data stored in the host and / or the transaction data stored in the distributed platform system, the transaction data processing method further includes: When transaction data in the host and / or the distributed platform system is updated, the updated data is copied to the data lake; Detecting the primary key, version, and time information corresponding to each data received by the data lake; A filtering operation is performed on the multiple data received from the data lake according to the primary key, version and time information corresponding to each data, wherein the filtering operation is used to filter out the data with the latest update time and the target version from multiple data with the same primary key but different versions, and retain the data, and the target version of the data represents the data on which the deletion operation has been performed.

8. The method for processing transaction data according to claim 1, characterized in that: Performing data anti-corrosion processing on the transaction data stored in the host and / or the transaction data stored in the distributed platform system, including: In response to the output instruction of the transaction data, query the transaction data from the host and the distributed platform system respectively; In the case where it is found that the transaction data exists in the host but does not exist in the distributed platform system, the transaction data in the host is used as the output result; In the case where it is found that the transaction data exists in both the host and the distributed platform system, the transaction data in the host is used as the output result; When it is found that the transaction data does not exist in the host but exists in the distributed platform system, the transaction data in the distributed platform system is used as the output result.

9. The method for processing transaction data according to claim 1, characterized in that: The transaction data processing method further includes: When a transaction corresponding to the transaction data fails and data rollback is required, determining a data source involved in the data rollback according to the service dual-write switch and the target list, wherein the data source includes the host and / or the distributed platform system; Perform a data rollback operation on the transaction data in the data source.

10. A transaction data processing device, characterized in that: include: a determination unit, determining to write the transaction data into the host and / or distributed platform system according to the service dual write switch and the target list, wherein the target list is used to record the transaction objects that have been excluded from the transaction risk, and the service dual write switch is used to determine the data writing selection according to the transaction attribute of the transaction data; A processing unit performs data anti-corrosion processing on the transaction data stored in the host and / or the transaction data stored in the distributed platform system after the transaction data is written into the host and / or the distributed platform system, wherein the data anti-corrosion processing is used to determine whether to use the transaction data stored in the host as an output result, or to use the transaction data stored in the distributed platform system as an output result.

11. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores a computer program, wherein when the computer program is executed, the device where the computer-readable storage medium is located executes the transaction data processing method according to any one of claims 1 to 9.

12. An electronic device, characterized in that: It includes one or more processors and a memory, wherein the memory is used to store one or more programs, wherein when the one or more programs are executed by the one or more processors, the one or more processors execute the transaction data processing method described in any one of claims 1 to 9.

13. A computer program product comprising computer instructions, characterized in that: When the computer instructions are executed by a processor, the steps of the transaction data processing method described in any one of claims 1 to 9 are implemented.

Citation Information

Patent Citations

  • Network data security exchange method and system

    CN107172020A

  • Cross-platform collaborative transaction data processing method and related system

    CN110400214A

  • Distributed time sequence database system, electronic equipment and storage medium

    CN113641763A

  • New and old system migration test method and device

    CN113742212A

  • Data desensitization method and device, equipment and medium

    CN114139199A