CN110795443A - Method, device, equipment and computer readable medium for data synchronization - Google Patents

Method, device, equipment and computer readable medium for data synchronization Download PDF

Info

Publication number
CN110795443A
CN110795443A CN201910948896.9A CN201910948896A CN110795443A CN 110795443 A CN110795443 A CN 110795443A CN 201910948896 A CN201910948896 A CN 201910948896A CN 110795443 A CN110795443 A CN 110795443A
Authority
CN
China
Prior art keywords
data
synchronization
service request
request message
operation type
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN201910948896.9A
Other languages
Chinese (zh)
Inventor
欧明辉
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
China Construction Bank Corp
Original Assignee
China Construction Bank Corp
CCB Finetech Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by China Construction Bank Corp, CCB Finetech Co Ltd filed Critical China Construction Bank Corp
Priority to CN201910948896.9A priority Critical patent/CN110795443A/en
Publication of CN110795443A publication Critical patent/CN110795443A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/20Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
    • G06F16/23Updating
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/20Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
    • G06F16/27Replication, distribution or synchronisation of data between databases or within a distributed database system; Distributed database system architectures therefor

Abstract

The invention discloses a method, a device, equipment and a computer readable medium for data synchronization, and relates to the technical field of computers. One embodiment of the method comprises: receiving and analyzing a service request message sent by a client to obtain an operation type and synchronous data; after the synchronous data are updated in a database, identifying the synchronous data and generating a data record of the synchronous data; adding the data record into a service request message, and identifying the operation type in the service request message; and sending a service request message comprising the data record and the operation type. The embodiment can synchronize the data required by the business in real time and accurately, thereby meeting the requirements of banking business.

Description

Method, device, equipment and computer readable medium for data synchronization
Technical Field
The present invention relates to the field of computer technologies, and in particular, to a method, an apparatus, a device, and a computer-readable medium for data synchronization.
Background
With the development of social informatization and bank science and technology, more and more banking businesses are transferred from a traditional counter to various electronic channels such as websites, mobile phones and self-service terminals, so that huge transaction amount and massive data are brought to a bank system.
Besides expanding channels, banking businesses are also refined and personalized continuously, so that functions of a bank information system are more and more complex, and the processing pressure of the system is increased. Social informatization increases the dependence of people on information, and the security of the information becomes very sensitive. Especially, the information security of finance and fund class is related to the economic life line of people and the country.
Therefore, a large bank system needs to be deployed in a distributed manner, and multiple centers are built in different places to perform disaster recovery deployment. Different centers are in an independent state, and storage, a database and the like are not shared.
In the process of implementing the invention, the inventor finds that at least the following problems exist in the prior art: some banking businesses depend on transaction context, and the traditional data synchronization mode is based on data table synchronization and cannot meet the requirements of the banking businesses.
Disclosure of Invention
In view of this, embodiments of the present invention provide a method, an apparatus, a device, and a computer readable medium for data synchronization, which can synchronize data required by a business accurately in real time, so as to meet the requirements of banking business.
To achieve the above object, according to an aspect of an embodiment of the present invention, there is provided a data synchronization method, including:
receiving and analyzing a service request message sent by a client to obtain an operation type and synchronous data;
after the synchronous data are updated in a database, identifying the synchronous data and generating a data record of the synchronous data;
adding the data record into a service request message, and identifying the operation type in the service request message;
and sending a service request message comprising the data record and the operation type.
The identifying the synchronization data and generating a data record of the synchronization data includes:
and identifying the synchronous data through a screening condition, and generating a data record of the synchronous data, wherein the data record comprises the screening condition.
The identifying the synchronization data and generating a data record of the synchronization data includes:
and identifying the synchronous data through a specified field, and generating a data record of the synchronous data, wherein the data record comprises the specified field.
The operation types include: added, modified, or deleted.
The method further comprises the following steps:
receiving a response message of data synchronization failure, returning updated synchronization data, and feeding back the data synchronization failure;
or the like, or, alternatively,
receiving a response message of data synchronization failure, keeping updated synchronous data, and feeding back that local data is updated successfully;
or the like, or, alternatively,
and receiving and feeding back a response message of successful data synchronization.
According to a second aspect of the embodiments of the present invention, there is provided a method of data synchronization, including:
receiving and analyzing a service request message, wherein the service request message comprises a data record and an operation type;
identifying synchronous data according to the data records, and synchronizing the synchronous data in a database according to the operation type;
the feedback includes a response message of the data synchronization result.
The data record is generated by screening conditions to identify the synchronization data.
The data record is generated by identifying the synchronization data by a specified field.
The operation types include: added, modified, or deleted.
According to a third aspect of the embodiments of the present invention, there is provided an apparatus for data synchronization, including:
the receiving module is used for receiving and analyzing a service request message sent by a client to obtain an operation type and synchronous data;
the identification module is used for identifying the synchronous data after the synchronous data is updated in the database and generating a data record of the synchronous data;
the processing module is used for adding the data record into a service request message and identifying the operation type in the service request message;
and the sending module is used for sending the service request message comprising the data record and the operation type.
According to a fourth aspect of the embodiments of the present invention, there is provided an apparatus for data synchronization, including:
the receiving module is used for receiving and analyzing a service request message, and the service request message comprises a data record and an operation type;
the identification module is used for identifying synchronous data according to the data record and synchronizing the synchronous data in a database according to the operation type;
and the sending module is used for feeding back a response message comprising a data synchronization result.
According to a fifth aspect of the embodiments of the present invention, there is provided an electronic device for data synchronization, including:
one or more processors;
a storage device for storing one or more programs,
when executed by the one or more processors, cause the one or more processors to implement the method as described above.
According to a sixth aspect of embodiments of the present invention, there is provided a computer readable medium, on which a computer program is stored, which when executed by a processor, implements the method as described above.
One embodiment of the above invention has the following advantages or benefits: because the service request message sent by the client is received and analyzed, the operation type and the synchronous data are obtained; after the synchronous data are updated in the database, identifying the synchronous data and generating a data record of the synchronous data; adding the data record into the service request message, and marking the operation type in the service request message; and sending a service request message comprising the data record and the operation type. And performing data synchronization through a service request message comprising data records and operation types. The database receiving the service request message can synchronize the data required by the service accurately in real time without synchronizing the data through a data table, so that the requirement of banking services can be met.
Further effects of the above-mentioned non-conventional alternatives will be described below in connection with the embodiments.
Drawings
The drawings are included to provide a better understanding of the invention and are not to be construed as unduly limiting the invention. Wherein:
FIG. 1 is a schematic diagram of data synchronization between databases according to an embodiment of the present invention;
FIG. 2 is a schematic diagram of the main flow of a method of data synchronization according to an embodiment of the present invention;
FIG. 3 is a schematic diagram of the main flow of another method of data synchronization according to an embodiment of the present invention;
FIG. 4 is a schematic diagram of data synchronization between two databases according to an embodiment of the present invention;
FIG. 5 is a schematic diagram of a main flow of data synchronization between two databases according to an embodiment of the present invention;
FIG. 6 is a schematic diagram of the main structure of an apparatus for data synchronization according to an embodiment of the present invention;
fig. 7 is a schematic diagram of the main structure of another apparatus for data synchronization according to an embodiment of the present invention;
FIG. 8 is an exemplary system architecture diagram in which embodiments of the present invention may be employed;
fig. 9 is a schematic structural diagram of a computer system suitable for implementing a terminal device or a server according to an embodiment of the present invention.
Detailed Description
Exemplary embodiments of the present invention are described below with reference to the accompanying drawings, in which various details of embodiments of the invention are included to assist understanding, and which are to be considered as merely exemplary. Accordingly, those of ordinary skill in the art will recognize that various changes and modifications of the embodiments described herein can be made without departing from the scope and spirit of the invention. Also, descriptions of well-known functions and constructions are omitted in the following description for clarity and conciseness.
The large-scale bank system needs distributed deployment, and multiple centers are built in different places to carry out disaster recovery deployment. Different centers are in an independent state, and storage, a database and the like are not shared.
As one example, the user's data may be stored based on the bank where the bank user's account is made. And if the bank of the user A is in Beijing, all the data of the user A is stored in the Beijing server.
In the Shanghai where user A is, money transfers to the Shandong user are needed, since user A's data is not stored in the Shanghai server. The data of the user a needs to be used in the transfer service, and thus the data of the user a needs to be synchronized by the shanghai server.
Wherein, the synchronization can adopt a data table mode. When the data table synchronization takes a long time, the requirements of banking business cannot be met.
In order to solve the technical problem of long time consumption for data synchronization, the following technical scheme in the embodiment of the invention can be adopted.
Referring to fig. 1, fig. 1 is a schematic diagram of data synchronization between databases according to an embodiment of the present invention. In fig. 1, database a and application server a are located in city a, and database B and application server B are located in city B. The database A and the database B are in an independent state and do not share data.
In the embodiment of the invention, the application server A receives a service request message sent by a client. After the synchronization data is updated in the database a, a data record of the synchronization data is generated. And sending the data record and the operation type of the synchronous data to an application server B through a service request message.
And after receiving the service request message, the application server B synchronizes the synchronous data in the database according to the data record and the operation type of the synchronous data.
The technical solution in the embodiment of the present invention is exemplarily described below with reference to fig. 2 and fig. 3.
Referring to fig. 2, fig. 2 is a schematic diagram of a main flow of a method for data synchronization according to an embodiment of the present invention, and the technical solution in fig. 2 may be applied to a server that initiates data synchronization. Such as: application server a in fig. 1. As shown in fig. 2, the method specifically includes the following steps:
s201, receiving and analyzing a service request message sent by a client, and obtaining an operation type and synchronous data.
The client sends a service request message to the application server. The purpose of sending the service request message is: and (6) data synchronization. The service request message is a message involved in an interaction between banks. As an example, the service request message may be an extensible markup language (XML) format message or a fixed-length format message.
The application server analyzes a service request message sent by the client, wherein the service request message can comprise a service function code. The requested service is known by the service function code. And combining the requested service according to the service rule to further obtain the operation type and the synchronous data. As an example, the service requested by the service request message includes: the user requests information of the transfer. The application server may obtain the operation type and the synchronization data based on information and business rules of the user requested transfer.
Synchronous data is data that a client requires synchronization in relation to a service. As an example, user A may need to transfer money to a different bank of accounts, and may need to use the data related to user A's account. The data related to the user a is synchronous data.
The operation type may include addition, modification, or deletion. Wherein the adding is adding the synchronization data in the database. The modification is a modification of the synchronization data in the database. Deletion is the deletion of the synchronization data in the database.
S202, after the synchronous data are updated in the database, the synchronous data are identified, and data records of the synchronous data are generated.
Data relating to a plurality of customers is included in the database. Updates may be made in the database according to the synchronization data. Wherein updating may include deleting data, modifying data, or deleting data.
As one example, the database includes data that is related to customer A, customer B, and customer C. And after receiving the service request message sent by the client B, modifying the synchronous data of the client B in the database.
In consideration of the need to update the synchronization data in another database, the synchronization data needs to be identified so that the update of the synchronization data can be implemented in another database. Then the synchronized data can be identified and a data record of the synchronized data generated. Data recording of synchronization data is a way to mark the synchronization data.
In one embodiment of the present invention, in consideration of the large data volume of the synchronization data itself, the data records of the synchronization data may be generated by screening the condition identification synchronization data. Wherein the data records include screening conditions. As one example, the screening conditions may include: client a is running information before 31 days 1 month 2010.
The screening condition is adopted to identify the synchronous data, so that the data records of the synchronous data can be put into the service request message, and the application server receiving the service request message can further operate the data meeting the screening condition.
The screening criteria may be expressed in a variety of computer languages. As one example, the screening condition may be a Structured Query Language (SQL) conditional approach.
In one embodiment of the invention, the data record of the synchronized data may also be generated by identifying the synchronized data by a specified field. Wherein the data record includes specified fields. As one example, the designated field may include a customer identification.
S203, adding the data record into the service request message, and identifying the operation type in the service request message.
The application server may send the data record and the operation type via a service request message. In particular, the application server may add a data record to the service request message and identify the operation type in the service request message.
Because the service request message is the existing message related to the interaction between banks, the data record and the operation type can be transmitted through the existing message, and the real-time interaction can be carried out between banks. Therefore, data can be synchronously monitored according to the existing interactive mode without additionally adding communication, message analysis and monitoring equipment.
And S204, sending a service request message comprising the data record and the operation type.
After the application server adds the data record to the service request message and identifies the operation type in the service request message, the application server may send the service request message to another application server to synchronize the data.
In the embodiment of the invention, the application servers belong to different wide area networks. The application server may preset the manner of data synchronization. The data synchronization mode includes a synchronous mode or an asynchronous mode.
And an asynchronous mode is preset, and the application server ignores a result which does not need to wait for a response. And presetting a synchronization mode, and waiting for a response result by the application server. Specifically, after the application server sends a service request message of a data record and an operation type, there are the following three cases:
the first condition is as follows:
and receiving a response message of data synchronization failure, returning the updated synchronization data, and feeding back the data synchronization failure.
It can be understood that another application server fails to synchronize data, and sends a response message of data synchronization failure to the application server, the application server rolls back the synchronized data after the database is updated, that is, the database is restored to the state before the database is not updated, and then feeds back the data synchronization failure.
Case two:
and receiving a response message of data synchronization failure, keeping the updated synchronous data, and feeding back that the local data is updated successfully.
It can be understood that another application server fails to synchronize data, and sends a response message of data synchronization failure to the application server, the application server keeps the updated synchronization data, i.e. the database keeps the state after updating, and then feeds back that the local data of the data is updated successfully.
It should be noted that, when the data synchronization of another application server fails, the application server may be preset in the application server in the first or second manner. As an example, the manner one or the manner two may be preset based on the service type.
Case three:
and receiving and feeding back a response message of successful data synchronization.
It is understood that if the data synchronization of another application server is successful, a response message that the data synchronization is successful is sent to the application server. After receiving the response message of successful data synchronization, the application server may feed back the response message of successful data synchronization.
In the above embodiment, the conventional message response mode is suitable for the data synchronization requirement with small data volume and frequent times. By synchronizing the data records and the operation types of the data, the data required by the service can be synchronized accurately in real time by adopting a traditional message request response mode, the response time is shorter than that of synchronizing the data by using a data table, the data synchronization method is suitable for the data synchronization across the wide area network in different places, and the requirements of banking services can be met.
Referring to fig. 3, fig. 3 is a schematic diagram of a main flow of another data synchronization method according to an embodiment of the present invention, and the technical solution in fig. 3 may be applied to a server receiving data synchronization. Such as: application server B in fig. 1. As shown in fig. 3, the method specifically includes the following steps:
s301, receiving and analyzing a service request message, wherein the service request message comprises a data record and an operation type.
And the application server receives the service request message and analyzes the service request message to obtain the data record and the operation type.
In one embodiment of the invention, the data records are generated by screening the conditional identification synchronization data. It will be appreciated that the data records do not require the synchronization data itself, but rather identify the synchronization data in the screening criteria.
In one embodiment of the invention, the data record is generated by identifying the synchronization data by a specified field.
S302, synchronizing data according to the data record identification, and synchronizing the synchronizing data in the database according to the operation type.
In the embodiment of the present invention, the database corresponding to the application server that sends the service request packet is referred to as a source database. And the database corresponding to the application server for receiving the service request message is called a target database. If the data in the source database and the target database may not be consistent, then the synchronization data is identified according to the data record, and the synchronization data is synchronized in the database according to the operation type.
Specifically, the target database needs to be checked according to the operation type, and the operation to be executed finally is obtained by combining the actual situation of the target database.
TABLE 1
Figure BDA0002225094900000101
In table 1, in the case where the data record of the synchronized data is the filtering condition, the operation type is: adding, records in the database can be directly added. The operation types are: and modifying the records which are in accordance with the screening conditions and exist in the database. The operation types are: and deleting the records which meet the screening conditions and exist in the database.
In table 1, in the case where the data record of the sync data is a designated field, the operation type is: and adding, namely adding a record according to the specified field. If the unique key conflicts, the existing record is updated according to the unique key. And the unique key is used for ensuring that the data in the corresponding field is unique. The operation types are as follows: modifying, namely finding the specified record according to the primary key and modifying the existing record; and if the specified record is not found by pressing the main key, adding a new record. A primary key is a column or combination of columns whose value uniquely identifies each row in the table. The operation types are as follows: and deleting the existing record according to the unique key.
And S303, feeding back a response message comprising a data synchronization result.
And feeding back a response message to the application server sending the service request message, wherein the response message comprises a data synchronization result. The data synchronization result includes a failure or success.
In the above embodiment, the conventional message response mode is suitable for the data synchronization requirement with small data volume and frequent times. The data required by the service can be synchronized accurately in real time by adopting the traditional message request response mode, the response time is shorter than that of data synchronization by using a data table, the data synchronization across the wide area network in different places is suitable, and the demand of banking services can be met.
Referring to fig. 4, fig. 4 is a schematic diagram of data synchronization between two databases according to an embodiment of the present invention, and fig. 4 includes application servers and databases involved in city a and city B. The database A and the database B are in an independent state and do not share data.
In city a, database a is coupled to application server a1, application server a2, and application server A3, respectively. In city B, database B is coupled to application server B1, application server B2, and application server B3, respectively.
Referring to fig. 5, fig. 5 is a schematic diagram of a main flow of data synchronization between two databases according to an embodiment of the present invention, which specifically includes the following steps:
s501, receiving a service request message sent by a client.
The application server a1 of city a receives the service request message sent by the client.
And S502, updating the database A.
The application server a1 parses the service request message, obtains the operation type and the synchronization data, and updates the database a.
S503, generating the data record of the synchronous data.
The application server a1 identifies the synchronized data, generating a data record of the synchronized data.
S504, sending a service request message.
The application server a1 adds the data record to the service request message, identifies the operation type in the service request message, and sends the service request message to the application server B3 of the city B.
And S505, updating the database B.
After receiving the service request message, the application server B3 parses the service request message to obtain the data record and the operation type. And updating the record in the database B according to the data record and the operation type, completing data synchronization, and returning the success of data synchronization to the application server A1.
After receiving the response message of successful synchronization, the application server a1 returns a response message to the client. If the server A1 receives the response message of synchronization failure, the server A selects the update of the rollback database A1 according to the service requirement, and returns the data synchronization failure to the client. Alternatively, ignoring the data synchronization failure, keeping database a1 updated, and returning a local data update success to the client.
Fig. 6 is a schematic diagram of a main structure of a data synchronization apparatus according to an embodiment of the present invention, where the data synchronization apparatus may implement a data synchronization method, and as shown in fig. 6, the data synchronization apparatus specifically includes:
the receiving module 601 is configured to receive and analyze a service request packet sent by a client, and obtain an operation type and synchronization data.
The identification module 602 is configured to identify the synchronization data after the synchronization data is updated in the database, and generate a data record of the synchronization data.
The processing module 603 is configured to add the data record to the service request message, and identify the operation type in the service request message.
A sending module 604, configured to send a service request packet including a data record and an operation type.
In an embodiment of the present invention, the identifying module 602 is specifically configured to identify the synchronous data through a filtering condition, and generate a data record of the synchronous data, where the data record includes the filtering condition.
In an embodiment of the present invention, the identifying module 602 is specifically configured to identify the synchronous data by a specified field, and generate a data record of the synchronous data, where the data record includes the specified field.
In one embodiment of the invention, the operation types include: added, modified, or deleted.
In an embodiment of the present invention, the receiving module 601 is further configured to receive a response message of data synchronization failure, rollback updated synchronization data, and feed back data synchronization failure;
or the like, or, alternatively,
receiving a response message of data synchronization failure, keeping updated synchronous data, and feeding back that local data is updated successfully;
or the like, or, alternatively,
and receiving and feeding back a response message of successful data synchronization.
Fig. 7 is a schematic diagram of a main structure of another data synchronization apparatus according to an embodiment of the present invention, where the data synchronization apparatus may implement a data synchronization method, and as shown in fig. 7, the data synchronization apparatus specifically includes:
the receiving module 701 is configured to receive and analyze a service request packet, where the service request packet includes a data record and an operation type.
And the identification module 702 is configured to identify the synchronization data according to the data record, and synchronize the synchronization data in the database according to the operation type.
A sending module 703, configured to feed back a response message including a data synchronization result.
In one embodiment of the invention, the data records are generated by screening the conditional identification synchronization data.
In one embodiment of the invention, the data record is generated by identifying the synchronization data by a specified field.
In one embodiment of the invention, the operation types include: added, modified, or deleted.
Fig. 8 shows an exemplary system architecture 800 of a data synchronization method or apparatus to which embodiments of the invention may be applied.
As shown in fig. 8, the system architecture 800 may include terminal devices 801, 802, 803, a network 804, and a server 805. The network 804 serves to provide a medium for communication links between the terminal devices 801, 802, 803 and the server 805. Network 804 may include various types of connections, such as wire, wireless communication links, or fiber optic cables, to name a few.
A user may use the terminal devices 801, 802, 803 to interact with a server 805 over a network 804 to receive or send messages or the like. The terminal devices 801, 802, 803 may have installed thereon various communication client applications, such as shopping-like applications, web browser applications, search-like applications, instant messaging tools, mailbox clients, social platform software, etc. (by way of example only).
The terminal devices 801, 802, 803 may be various electronic devices having a display screen and supporting web browsing, including but not limited to smart phones, tablet computers, laptop portable computers, desktop computers, and the like.
The server 805 may be a server that provides various services, such as a back-office management server (for example only) that supports shopping-like websites browsed by users using the terminal devices 801, 802, 803. The backend management server may analyze and perform other processing on the received data such as the product information query request, and feed back a processing result (for example, target push information, product information — just an example) to the terminal device.
It should be noted that the method for data synchronization provided by the embodiment of the present invention is generally performed by the server 805, and accordingly, a device for data synchronization is generally disposed in the server 805.
It should be understood that the number of terminal devices, networks, and servers in fig. 8 is merely illustrative. There may be any number of terminal devices, networks, and servers, as desired for implementation.
Referring now to FIG. 9, shown is a block diagram of a computer system 900 suitable for use with a terminal device implementing an embodiment of the present invention. The terminal device shown in fig. 9 is only an example, and should not bring any limitation to the functions and the scope of use of the embodiments of the present invention.
As shown in fig. 9, the computer system 900 includes a Central Processing Unit (CPU)901 that can perform various appropriate actions and processes in accordance with a program stored in a Read Only Memory (ROM)902 or a program loaded from a storage section 908 into a Random Access Memory (RAM) 903. In the RAM 903, various programs and data necessary for the operation of the system 900 are also stored. The CPU 901, ROM 902, and RAM 903 are connected to each other via a bus 904. An input/output (I/O) interface 905 is also connected to bus 904.
The following components are connected to the I/O interface 905: an input portion 906 including a keyboard, a mouse, and the like; an output section 907 including components such as a Cathode Ray Tube (CRT), a Liquid Crystal Display (LCD), and the like, and a speaker; a storage portion 908 including a hard disk and the like; and a communication section 909 including a network interface card such as a LAN card, a modem, or the like. The communication section 909 performs communication processing via a network such as the internet. The drive 910 is also connected to the I/O interface 905 as necessary. A removable medium 911 such as a magnetic disk, an optical disk, a magneto-optical disk, a semiconductor memory, or the like is mounted on the drive 910 as necessary, so that a computer program read out therefrom is mounted into the storage section 908 as necessary.
In particular, according to the embodiments of the present disclosure, the processes described above with reference to the flowcharts may be implemented as computer software programs. For example, embodiments of the present disclosure include a computer program product comprising a computer program embodied on a computer readable medium, the computer program comprising program code for performing the method illustrated in the flow chart. In such an embodiment, the computer program may be downloaded and installed from a network through the communication section 909, and/or installed from the removable medium 911. The above-described functions defined in the system of the present invention are executed when the computer program is executed by a Central Processing Unit (CPU) 901.
It should be noted that the computer readable medium shown in the present invention can be a computer readable signal medium or a computer readable storage medium or any combination of the two. A computer readable storage medium may be, for example, but not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any combination of the foregoing. More specific examples of the computer readable storage medium may include, but are not limited to: an electrical connection having one or more wires, a portable computer diskette, a hard disk, a Random Access Memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing. In the present invention, a computer readable storage medium may be any tangible medium that can contain, or store a program for use by or in connection with an instruction execution system, apparatus, or device. In the present invention, however, a computer readable signal medium may include a propagated data signal with computer readable program code embodied therein, for example, in baseband or as part of a carrier wave. Such a propagated data signal may take many forms, including, but not limited to, electro-magnetic, optical, or any suitable combination thereof. A computer readable signal medium may also be any computer readable medium that is not a computer readable storage medium and that can communicate, propagate, or transport a program for use by or in connection with an instruction execution system, apparatus, or device. Program code embodied on a computer readable medium may be transmitted using any appropriate medium, including but not limited to: wireless, wire, fiber optic cable, RF, etc., or any suitable combination of the foregoing.
The flowchart and block diagrams in the figures illustrate the architecture, functionality, and operation of possible implementations of systems, methods and computer program products according to various embodiments of the present invention. In this regard, each block in the flowchart or block diagrams may represent a module, segment, or portion of code, which comprises one or more executable instructions for implementing the specified logical function(s). It should also be noted that, in some alternative implementations, the functions noted in the block may occur out of the order noted in the figures. For example, two blocks shown in succession may, in fact, be executed substantially concurrently, or the blocks may sometimes be executed in the reverse order, depending upon the functionality involved. It will also be noted that each block of the block diagrams or flowchart illustration, and combinations of blocks in the block diagrams or flowchart illustration, can be implemented by special purpose hardware-based systems which perform the specified functions or acts, or combinations of special purpose hardware and computer instructions.
The modules described in the embodiments of the present invention may be implemented by software or hardware. The described modules may also be provided in a processor, which may be described as: a processor includes a transmitting unit, an obtaining unit, a determining unit, and a first processing unit. The names of these units do not in some cases constitute a limitation to the unit itself, and for example, the sending unit may also be described as a "unit sending a picture acquisition request to a connected server".
As another aspect, the present invention also provides a computer-readable medium that may be contained in the apparatus described in the above embodiments; or may be separate and not incorporated into the device. The computer readable medium carries one or more programs which, when executed by a device, cause the device to comprise:
receiving and analyzing a service request message sent by a client to obtain an operation type and synchronous data;
after the synchronous data are updated in a database, identifying the synchronous data and generating a data record of the synchronous data;
adding the data record into a service request message, and identifying the operation type in the service request message;
and sending a service request message comprising the data record and the operation type.
According to the technical scheme of the embodiment of the invention, the service request message sent by the client is received and analyzed to obtain the operation type and the synchronous data; after the synchronous data are updated in the database, identifying the synchronous data and generating a data record of the synchronous data; adding the data record into the service request message, and marking the operation type in the service request message; and sending a service request message comprising the data record and the operation type. And performing data synchronization through a service request message comprising data records and operation types. The database receiving the service request message can synchronize the data required by the service accurately in real time without synchronizing the data through a data table, so that the requirement of banking services can be met.
The above-described embodiments should not be construed as limiting the scope of the invention. Those skilled in the art will appreciate that various modifications, combinations, sub-combinations, and substitutions can occur, depending on design requirements and other factors. Any modification, equivalent replacement, and improvement made within the spirit and principle of the present invention should be included in the protection scope of the present invention.

Claims (13)

1. A method of data synchronization, comprising:
receiving and analyzing a service request message sent by a client to obtain an operation type and synchronous data;
after the synchronous data are updated in a database, identifying the synchronous data and generating a data record of the synchronous data;
adding the data record into a service request message, and identifying the operation type in the service request message;
and sending a service request message comprising the data record and the operation type.
2. The method of data synchronization of claim 1, wherein said identifying said synchronization data, generating a data record of said synchronization data, comprises:
and identifying the synchronous data through a screening condition, and generating a data record of the synchronous data, wherein the data record comprises the screening condition.
3. The method of data synchronization of claim 1, wherein said identifying said synchronization data, generating a data record of said synchronization data, comprises:
and identifying the synchronous data through a specified field, and generating a data record of the synchronous data, wherein the data record comprises the specified field.
4. The method of data synchronization of claim 1, wherein the operation type comprises: added, modified, or deleted.
5. The method of data synchronization of claim 1, further comprising:
receiving a response message of data synchronization failure, returning updated synchronization data, and feeding back the data synchronization failure;
or the like, or, alternatively,
receiving a response message of data synchronization failure, keeping updated synchronous data, and feeding back that local data is updated successfully;
or the like, or, alternatively,
and receiving and feeding back a response message of successful data synchronization.
6. A method of data synchronization, comprising:
receiving and analyzing a service request message, wherein the service request message comprises a data record and an operation type;
identifying synchronous data according to the data records, and synchronizing the synchronous data in a database according to the operation type;
the feedback includes a response message of the data synchronization result.
7. The method of data synchronization of claim 6, wherein the data record is generated by screening conditions to identify the synchronization data.
8. The method of data synchronization of claim 6, wherein the data record is generated by identifying the synchronization data via a specified field.
9. The method of data synchronization of claim 6, wherein the operation type comprises: added, modified, or deleted.
10. An apparatus for data synchronization, comprising:
the receiving module is used for receiving and analyzing a service request message sent by a client to obtain an operation type and synchronous data;
the identification module is used for identifying the synchronous data after the synchronous data is updated in the database and generating a data record of the synchronous data;
the processing module is used for adding the data record into a service request message and identifying the operation type in the service request message;
and the sending module is used for sending the service request message comprising the data record and the operation type.
11. An apparatus for data synchronization, comprising:
the receiving module is used for receiving and analyzing a service request message, and the service request message comprises a data record and an operation type;
the identification module is used for identifying synchronous data according to the data record and synchronizing the synchronous data in a database according to the operation type;
and the sending module is used for feeding back a response message comprising a data synchronization result.
12. An electronic device for monitoring data, comprising:
one or more processors;
a storage device for storing one or more programs,
when executed by the one or more processors, cause the one or more processors to implement the method of any one of claims 1-9.
13. A computer-readable medium, on which a computer program is stored, which, when being executed by a processor, carries out the method according to any one of claims 1-9.
CN201910948896.9A 2019-10-08 2019-10-08 Method, device, equipment and computer readable medium for data synchronization Pending CN110795443A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201910948896.9A CN110795443A (en) 2019-10-08 2019-10-08 Method, device, equipment and computer readable medium for data synchronization

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201910948896.9A CN110795443A (en) 2019-10-08 2019-10-08 Method, device, equipment and computer readable medium for data synchronization

Publications (1)

Publication Number Publication Date
CN110795443A true CN110795443A (en) 2020-02-14

Family

ID=69438928

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201910948896.9A Pending CN110795443A (en) 2019-10-08 2019-10-08 Method, device, equipment and computer readable medium for data synchronization

Country Status (1)

Country Link
CN (1) CN110795443A (en)

Cited By (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111858749A (en) * 2020-06-15 2020-10-30 武汉旷视金智科技有限公司 Bottom library synchronization method, device and electronic system
CN112187916A (en) * 2020-09-27 2021-01-05 中国银联股份有限公司 Cross-system data synchronization method and device
CN112559638A (en) * 2021-02-20 2021-03-26 恒生电子股份有限公司 Data synchronization method, device, equipment and storage medium
CN113572850A (en) * 2021-07-29 2021-10-29 上海浦东发展银行股份有限公司 Data synchronization method, device, server and storage medium
CN113760871A (en) * 2020-08-17 2021-12-07 北京沃东天骏信息技术有限公司 Template synchronization method and device
CN113572850B (en) * 2021-07-29 2024-05-03 上海浦东发展银行股份有限公司 Data synchronization method, device, server and storage medium

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US6643669B1 (en) * 2000-03-14 2003-11-04 Telefonaktiebolaget Lm Ericsson (Publ) Method for optimization of synchronization between a client's database and a server database
CN106254456A (en) * 2016-08-03 2016-12-21 深圳市商汤科技有限公司 A kind of method of data synchronization and data synchronous system
CN107819795A (en) * 2016-09-12 2018-03-20 北京金山云网络技术有限公司 A kind of major-minor server data synchronous method of DNS, apparatus and system
CN109325030A (en) * 2018-09-03 2019-02-12 平安国际融资租赁有限公司 Message processing method, device, computer equipment and storage medium

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US6643669B1 (en) * 2000-03-14 2003-11-04 Telefonaktiebolaget Lm Ericsson (Publ) Method for optimization of synchronization between a client's database and a server database
CN106254456A (en) * 2016-08-03 2016-12-21 深圳市商汤科技有限公司 A kind of method of data synchronization and data synchronous system
CN107819795A (en) * 2016-09-12 2018-03-20 北京金山云网络技术有限公司 A kind of major-minor server data synchronous method of DNS, apparatus and system
CN109325030A (en) * 2018-09-03 2019-02-12 平安国际融资租赁有限公司 Message processing method, device, computer equipment and storage medium

Cited By (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111858749A (en) * 2020-06-15 2020-10-30 武汉旷视金智科技有限公司 Bottom library synchronization method, device and electronic system
CN113760871A (en) * 2020-08-17 2021-12-07 北京沃东天骏信息技术有限公司 Template synchronization method and device
CN113760871B (en) * 2020-08-17 2024-04-16 北京沃东天骏信息技术有限公司 Template synchronization method and device
CN112187916A (en) * 2020-09-27 2021-01-05 中国银联股份有限公司 Cross-system data synchronization method and device
CN112187916B (en) * 2020-09-27 2023-12-05 中国银联股份有限公司 Cross-system data synchronization method and device
CN112559638A (en) * 2021-02-20 2021-03-26 恒生电子股份有限公司 Data synchronization method, device, equipment and storage medium
CN113572850A (en) * 2021-07-29 2021-10-29 上海浦东发展银行股份有限公司 Data synchronization method, device, server and storage medium
CN113572850B (en) * 2021-07-29 2024-05-03 上海浦东发展银行股份有限公司 Data synchronization method, device, server and storage medium

Similar Documents

Publication Publication Date Title
CN110795443A (en) Method, device, equipment and computer readable medium for data synchronization
CN109413127B (en) Data synchronization method and device
CN109150929B (en) Data request processing method and device under high concurrency scene
CN110321544B (en) Method and device for generating information
US10866778B2 (en) Cross device display synchronization
CN110334145A (en) The method and apparatus of data processing
CN110019539A (en) A kind of method and apparatus that the data of data warehouse are synchronous
CN111881329A (en) Account balance management method and system
CN111753019A (en) Data partitioning method and device applied to data warehouse
US8843531B2 (en) Bookkeeping of download timestamps
CN111241189A (en) Method and device for synchronizing data
CN112948498A (en) Method and device for generating global identification of distributed system
CN115496544A (en) Data processing method and device
CN110781238B (en) Client view caching method and device based on combination of Redis and Hbase
CN114357280A (en) Information pushing method and device, electronic equipment and computer readable medium
CN112836201A (en) Method, device, equipment and computer readable medium for multi-platform information intercommunication
CN110705935B (en) Logistics document processing method and device
CN113761075A (en) Method, device, equipment and computer readable medium for switching databases
CN109446183B (en) Global anti-duplication method and device
CN113761051A (en) Message pushing method, data acquisition method, device, system, equipment and medium
CN113778959B (en) Method, apparatus, device and computer readable medium for data processing
CN112965946B (en) Method, device, equipment and computer readable medium for processing document
CN113360689B (en) Image retrieval system, method, related device and computer program product
CN115408360A (en) Method, device, equipment and computer readable medium for storing data
CN115033573A (en) Data checking method, device, electronic equipment and medium

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
TA01 Transfer of patent application right

Effective date of registration: 20220923

Address after: 25 Financial Street, Xicheng District, Beijing 100033

Applicant after: CHINA CONSTRUCTION BANK Corp.

Address before: 25 Financial Street, Xicheng District, Beijing 100033

Applicant before: CHINA CONSTRUCTION BANK Corp.

Applicant before: Jianxin Financial Science and Technology Co.,Ltd.

TA01 Transfer of patent application right