WO2018120810A1 - Procédé et système de résolution de collision de données - Google Patents

Procédé et système de résolution de collision de données Download PDF

Info

Publication number
WO2018120810A1
WO2018120810A1 PCT/CN2017/094317 CN2017094317W WO2018120810A1 WO 2018120810 A1 WO2018120810 A1 WO 2018120810A1 CN 2017094317 W CN2017094317 W CN 2017094317W WO 2018120810 A1 WO2018120810 A1 WO 2018120810A1
Authority
WO
WIPO (PCT)
Prior art keywords
data
storage node
node
partial order
order relationship
Prior art date
Application number
PCT/CN2017/094317
Other languages
English (en)
Chinese (zh)
Inventor
钟延辉
Original Assignee
华为技术有限公司
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 华为技术有限公司 filed Critical 华为技术有限公司
Publication of WO2018120810A1 publication Critical patent/WO2018120810A1/fr

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/10File systems; File servers
    • G06F16/13File access structures, e.g. distributed indices
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/10File systems; File servers
    • G06F16/17Details of further file system functions
    • G06F16/178Techniques for file synchronisation in file systems
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/10File systems; File servers
    • G06F16/18File system types
    • G06F16/182Distributed file systems

Definitions

  • the present application relates to the field of communications technologies, and in particular, to a method and system for resolving data conflicts.
  • the current active or active system allows data to be written from two or more nodes, and the written data needs to be copied to other nodes so that the data on multiple nodes is consistent.
  • the write sequence is inconsistent due to the write sequence and the network, disk, etc., and data conflict occurs, so that when multiple nodes are successfully written, the data is in multiple
  • the nodes are in an inconsistent state, resulting in different data being read from different nodes. For example, three nodes modify C separately, and the final data of the three nodes is different because the writing order is inconsistent.
  • the first solution is to use distributed locks to solve the problem of data conflicts between multiple nodes.
  • When writing data to the node first apply for a lock to the distributed lock server, and then release the lock after writing the data.
  • This method can ensure that the modification of the same data is performed serially at different nodes, thereby ensuring that multi-node data inconsistency does not occur.
  • Node1, Node2, and Node3 all store data C.
  • Node1 first applies a lock to data C to the distributed lock server, and then all three nodes are modified to C1, and then When Node2 applies for the lock of data C to the distributed lock server, all three nodes are modified to C2.
  • Node3 applies the lock to C to the distributed lock server, and all three nodes are modified to C3.
  • the data in the last three nodes is consistent and both are C3.
  • this method will generate an invalid lock request without a write conflict, resulting in a decline in overall system performance.
  • the second solution is to use priority locks to resolve data conflicts between multiple nodes.
  • When writing data to the node first try to apply for a lock to the distributed lock server. After the trial lock application is successful, each node is determined. Write data concurrently.
  • the lock of the node with the lower priority is forcibly released according to the priority of each node, and the data corresponding to the node with the lower priority is rewritten after the node with the higher priority writes the data.
  • the lock application becomes a distributed lock in the cluster, which leads to the performance degradation of the system and the versatility is not good.
  • the application provides a method system for solving data conflicts.
  • a method for resolving data conflicts in a multi-active system includes an access node and a storage node, and the method includes: the access node receives the first data update request sent by the client, and the first data is received.
  • the update request generates a globally unique version number; the access node sends a second data update request to the storage node, where the second data update request carries the version number; and the storage node updates the corresponding data according to the second data update request, and the update is updated.
  • Sorting the relationship and returning the partial order relationship to the access node wherein the partial order relationship is used to record the sequence of the version numbers of the data update requests received by the storage node; the access node obtains the partial order returned by the storage node
  • the relationship determines whether there is a conflict in the data in the storage node; when there is a conflict in the data in the storage node, the access node adjusts the conflict.
  • the receiving node adjusts the conflict of data only when there is a conflict in the data in the storage node.
  • the receiving node performs the data update operation normally, which greatly improves the data updating efficiency.
  • the access node determines whether there is a conflict in the data in the storage node, specifically: when the acquired partial storage relationship of the storage node is inconsistent, the access node determines that the data in the storage node exists conflict.
  • the access node can determine whether the data in the storage node is consistent according to the partial order relationship, and can quickly identify the data conflict existing in the storage node and improve the performance of the system.
  • the access node determines whether there is a conflict in the data in the storage node, specifically: when the received storage node's partial order relationship is inconsistent, the access node reacquires the storage within a predetermined time period.
  • the partial order relationship of the nodes when the re-acquisition of the storage node's partial order relationship is inconsistent, the access node determines that there is a conflict in the data in the storage node.
  • the partial order relationship acquired at different times may be different. And when the partial order relationship of different storage nodes is different, there may be a receiving node that adjusts the data conflict, so a time period can be set, and the receiving node can obtain the partial order relationship of the storage node multiple times in the set time period. Compare them, instead of making adjustments as soon as the partial order relationship is inconsistent, to improve the efficiency of resolving data conflicts.
  • the access node adjusts the conflict by: the access node sends a third data update request to the storage node according to the conflict adjustment policy, where the third data update request includes a partial order relationship that needs to be adjusted; After receiving the third data update request, the node updates the data in the storage node according to the partial order relationship that needs to be adjusted.
  • the conflict adjustment strategy includes a storage node priority policy and a partial order relationship priority policy.
  • the storage node priority policy is to adjust the data in the storage node with lower priority by the partial order relationship of the storage node with higher priority.
  • the partial order relationship priority policy is to adjust the data in the storage node in order of the size of the version number in the partial order relationship.
  • a multi-active system in a second aspect, includes multiple access nodes and multiple storage nodes, and the access node is connected to the client, and the access node is configured to receive the first data sent by the client. Updating the request, and generating a globally unique version number for the first data update request; sending a second data update request to the storage node, where the second data update request carries the version number; and the storage node is configured to update the request according to the second data Updating the corresponding data, updating the partial order relationship, and returning the partial order relationship to the access node; wherein the partial order relationship is used to record the sequence of the version number of the data update request received by the storage node; Obtaining a partial order relationship returned by the storage node, determining whether there is a conflict in the data in the storage node; and adjusting the conflict when there is a conflict in the data in the storage node.
  • the determining, by the access node, whether the data in the storage node is in conflict is: determining, when the acquired partial storage relationship of the storage node is inconsistent, determining the There is a conflict in the data.
  • the access node is configured to determine whether the data in the storage node has a conflict: when the received storage node has a misaligned relationship, the access node reacquires the storage within a predetermined time period. a partial order relationship of the nodes, when the re-acquisition of the storage node's partial order relationship is inconsistent, determining the number in the storage node There are conflicts.
  • the access node is used to adjust the conflict specifically:
  • the conflict adjustment policy includes a storage node priority policy and a partial order relationship priority policy; After receiving the third data update request, the data in the storage node is updated according to a partial order relationship that needs to be adjusted.
  • the access node and the storage node are located in the same physical device.
  • a third aspect provides an apparatus for resolving data conflicts, including a processor, a communication bus, a memory, and a communication interface.
  • the processor is configured to perform the foregoing method for resolving data conflicts, which is not described herein.
  • FIG. 1 is a schematic structural diagram of a multi-active system according to an embodiment of the present application.
  • FIG. 2 is a schematic flowchart of a method for resolving data conflicts according to an embodiment of the present application
  • FIG. 3 is a schematic structural diagram of an apparatus for resolving data conflicts according to an embodiment of the present disclosure.
  • Embodiments of the present invention provide a method and system for resolving data conflicts, which can quickly identify data conflicts and resolve data conflicts, and the write performance of the system is higher.
  • the embodiment of the present invention relates to a dual-active or multi-active system.
  • a multi-active system is taken as an example for description.
  • the multi-active system 10 is divided into three logical layers: a client layer 11, an access node layer 12, and a storage node layer 13.
  • Client layer 11 The user inputs data through the client, and the client sends the data to the receiving node.
  • the receiving node layer 12 receives the data sent by the client and writes the received data into the storage node.
  • Storage node layer 13 stores data.
  • the physical client, the access node, and the storage node may be on the same physical device (for example, a node device), or may be on different physical devices, which is not limited in the embodiment of the present invention.
  • the write performance of the update operation is low.
  • the present invention it is first considered that most of the nodes do not have conflicts when performing update operations on data, and the probability that multiple nodes perform update operations on the same data at the same time is small. Therefore, when the data is updated in the multi-live system, the data is first written to the storage node, and after the data is written, the conflict is found and the data conflict is resolved.
  • the receiving node layer in the multi-active system includes the receiving node 1 and the receiving section.
  • the storage node layer includes a storage node 1 and a storage node 2.
  • the receiving node 1 can update the data in the storage node 1 and the storage node 2; the receiving node 2 can update the data in the storage node 1 and the storage node 2.
  • the number of receiving nodes and storage nodes in the embodiment of the present invention is merely an exemplary description, and the number of receiving nodes and storage nodes may be set according to services or user requirements.
  • data is already stored on the storage node 1.
  • V1 the data already stored in the storage node
  • K1 the key of the data V1
  • Ver1 the version number
  • the data in the storage node 1 in order to distinguish from the data of the subsequent update, record the data in the storage node 1 as K1 (V1, [Ver1]).
  • the data V1 stored in the storage node 2 is the same as the data V1 in the storage node 1, and is also recorded as K1 (V1, [Ver1]).
  • K1 V1, [Ver1]
  • K1 the data V1 stored in the storage node 3
  • K1 V1, [Ver1]
  • the version number is a globally unique version number assigned to the data when the receiving node receives the data operation instruction, and is stored in the storage node together with the data.
  • the version number can be used for different data update operations in the zone.
  • the version number is recorded as Ver1 for easy identification, and in actual applications, the version number may be a combination of multiple letters and/or numbers.
  • the calculation of the version number can be implemented by using an existing algorithm, which is not described in the embodiment of the present invention.
  • client 1 updates the data K1 pair, and the updated data is V2.
  • client 2 updates the data corresponding to the data K1, and the updated data is V3.
  • the method for resolving data conflicts provided by the embodiments of the present invention is as follows, as shown in FIG. 2.
  • Step 201 The access node receives a data update request sent by the client, and generates a globally unique version number for the data update operation.
  • the data update request sent by the client to the access node is referred to as a first data update request to distinguish it from other data update requests below.
  • This version number is used to identify the data update request. Since the version number is a globally unique version number, each data update request can be distinguished from other data update requests.
  • the access node 1 receives the data update request put(k1, V2) of the client 1, that is, updates the data of the data K1, and the updated data content is V2, and the access node 1 generates a global unique for the data update request. Version number Ver2.
  • the access node 2 receives the data update request put(k1, V3) of the client 2, that is, updates the data K1, and the updated data content is V3, and the access node generates a globally unique version for the data update request access. No. Ver3.
  • Step 203 The access node sends a data update request to the storage node, where the version update number includes the version number.
  • the content included in the data update request sent by the access node to the storage node is different.
  • the data update request is referred to as a second data update request.
  • the second data update request includes a version number generated by the access node for the first data update request.
  • the access node After receiving the first data update request sent by the client, the access node generates a globally unique version number for the first data update request, and sends a second data update request including the version number to the storage node.
  • a multi-active system will include multiple access nodes and multiple storage nodes, so the access node will send a second data update request to all storage nodes in the multi-active system to ensure data retention in these storage nodes. Consistent.
  • the access node 1 transmits a data update request put (K1, V2, Ver2) including a version number to the storage node 1, the storage node 2, and the storage node 3, respectively.
  • the access node 2 transmits data and data version number data update requests put(K1, V3, Ver3) to the storage node 1, the storage node 2, and the storage node 3, respectively.
  • Step 205 The storage node updates the corresponding data according to the second data update request, records the partial order relationship, and returns the partial order relationship to the access node.
  • the partial order relationship is used to record the sequence of the version numbers of the data update requests received by the storage node.
  • the storage node After receiving the data update request sent by the access node and including the version number, the storage node finds the corresponding data according to the key value in the data update request, and updates the data in the order of receiving the data update request, and records the data update.
  • the order of the requested version numbers that is, the partial order relationship, returns the partial order relationship to the access node.
  • the partial order relationship is used to record the sequence of the version numbers of the data update requests received by the storage node. After the storage node receives the data update request and updates the data once, the corresponding update is a partial order relationship. Therefore, the partial order relationships obtained at different times may be different.
  • the version number information in the partial order relationship may be aged according to a certain rule. For example, when the version number information in the partial order relationship reaches a certain number, the oldest version number information is deleted from the partial order relationship; or when all the systems are in the system. When the order of some version number information in the partial order relationship of the same data in the storage node is completely the same, the version number information of the same order may be deleted from the partial order relationship. In the embodiment of the present application, the aging of the partial order relationship is not involved, and thus will not be described in detail.
  • the order of data update requests received by the respective storage nodes for the same data may be the same, or may be the same. are different. Therefore, the partial order relationship of storage nodes may or may not be the same.
  • the storage node 1 first receives the data update request put(K1, V2, Ver2) for the data K1 sent by the access node 1, that is, the update operation of the data K1 is required, and the updated data content is V2, and the data update request is The version number is Ver2.
  • the version number of the data K1 already exists in the storage node 1 is Ver1
  • the update partial order relationship is [Ver2 ⁇ -Ver1]
  • the partial order relationship is [Ver2, Ver1].
  • the storage node 1 receives the data update request put (K1, V3, Ver3) for the data K1 sent by the access node 2, that is, the storage node 1 updates the data K1 with the operation data content V3, and the version number of the data update request is Ver3. After the storage node 1 updates the data K1 according to V3, the update partial order relationship is [Ver3 ⁇ -Ver2 ⁇ -Ver1], and the partial order relationship returned to the access node 2 is [Ver3, Ver2, Ver1].
  • the storage node 2 first receives the data update request put (K1, V3, Ver3) for the data K1 sent by the access node 2, that is, the storage node 2 updates the data K1 with the data content V3, and the data update request version number is Ver3. After the storage node 2 updates the data K1 according to V3, the update partial order relationship is [Ver3 ⁇ -Ver1], and the partial order relationship returned to the access node 2 is [Ver3, Ver1].
  • the storage node 2 receives the data update request put (K1, V2, Ver2) for the data K1 sent by the access node 1, that is, the update operation of the data K1 is required, the updated data content is V2, and the version number of the data update request is Ver2. After the storage node 2 updates the data K1 according to V3, the update partial order relationship is [Ver2 ⁇ -Ver3 ⁇ -Ver1], and the partial order relationship returned to the access node 1 is [Ver2, Ver3, Ver1].
  • Step 207 The access node acquires a partial order relationship returned by the storage node, and determines whether there is a conflict in the data in the storage node.
  • the storage node updates the partial order relationship after the data is updated, so the partial order relationship may reflect the update order of the same data in the storage node. Therefore, the receiving node can determine whether the same data in the plurality of storage nodes in the system has a conflict according to whether the partial order relationship of the same data returned by the plurality of storage nodes in the system is consistent.
  • the method for determining whether the partial order relationship returned by the storage node is consistent is as follows:
  • the storage node returns the same partial order relationship in the system, that is to say, the order of updating the same data by these storage nodes is the same. At this time, the contents of the same data stored in these storage nodes are the same, and there is no conflict.
  • a time period may be set, and the access is performed within the set time period.
  • the node obtains the partial order relationship of the storage node multiple times, and uses the last obtained partial order relationship to determine whether there is a conflict in the same data stored in the storage node.
  • the partial order relationships returned by the multiple storage nodes are different, it is further determined whether the first version number in the partial order relationship is the same, and when the first version number in the partial order relationship is the same, You can select a storage node with a small version number in the partial order relationship to obtain the partial order relationship again for comparison.
  • the partial order relationship of the data K1 returned by the storage node 1 received by the access node 1 is [Ver2, Ver1]
  • the partial order relationship of the data K1 returned by the storage node 2 received by the access node 1 is [Ver3, Ver1].
  • the access node 1 judges that the partial order relationship returned by the storage node 1 and the storage node 2 is different. At this time, it can be determined that the data K1 stored in the storage node 1 and the storage node 2 are inconsistent and conflict.
  • the acquisition time of the partial order relationship is set, if the time range of the partial order relationship acquisition time is also within, the access node 1 may obtain the partial order relationship of the data K1 from the storage node 1 and the storage node 2 again.
  • the partial order relationship acquired by the access node 1 from the storage node 1 is [Ver3, Ver2, Ver1]. At this time, if the partial order relationship returned by the storage node 2 has not been updated, or [Ver3, Ver1] ].
  • the access node 1 confirms that the partial order relationship returned by the storage node 1 and the storage node 2 is different. At this time, it can be determined that the data K1 stored in the storage node 1 and the storage node 2 are inconsistent and conflict.
  • the access node 1 determines that the partial order relationship between the storage node 1 and the storage node 2 is different, but at this time, the first version numbers of the two partial order relationships are the same, both are Ver3; and the storage node 2 is ordered. The number of version numbers in the relationship is small, and the access node 1 obtains the partial order relationship from the storage node 2. At this time, the partial order relationship of the storage node 2 is [Ver2 ⁇ -Ver3 ⁇ -Ver1], and the access node 1 confirms the storage. The partial order relationship returned by the node 1 and the storage node 2 is different. At this time, it can be determined that the data K1 stored in the storage node 1 and the storage node 2 are inconsistent and conflict.
  • the access node 1 determines that the partial order relationship between the storage node 1 and the storage node 2 is different. If the acquisition time of the partial order relationship is set, and the access node is also in the time period of the partial order relationship acquisition time, the access node 1 The partial order relationship of the data K1 can be read from the storage node 1 and the storage node 2. When the partial order relationship of the data K1 acquired by the access node 1 from the storage node 1 is [Ver3, Ver2, Ver1], the partial order relationship of the data K1 acquired from the storage node 2 is [Ver2, Ver3, Ver1]. At this time, the access node 1 judges that the data K1 stored on the storage node 1 is inconsistent with the data K1 stored on the storage node 2, and there is a conflict.
  • the determination of the partial order relationship received by the access node 2 from the storage node 1 and the storage node 2 is the same as that of the access node 1 described above, and will not be further described herein.
  • Step 209 When there is a conflict in the data in the storage node, the access node adjusts the conflict of the data.
  • the access node determines that there is a conflict between the same data stored on the storage node of the system, the conflict needs to be adjusted.
  • the embodiment of the present application provides two strategies for adjusting data conflicts as an exemplary description. In practical applications, it can also Other strategies are adopted as long as the access nodes in the system comply with each other.
  • the first is based on the storage node priority policy.
  • the data conflict is adjusted based on the data of the storage node with the highest priority. For example, as described above, the partial order relationship of the data K1 acquired by the access node 1 from the storage node 1 is [Ver2, Ver1], and the partial order relationship of the data K1 acquired from the storage node 2 is [Ver2, Ver3, Ver1].
  • the partial order relationship of the data K1 acquired by the access node 1 from the storage node 1 is different from the partial order relationship of the data K1 acquired from the storage node 2, and the first version in the partial order relationship
  • the number is Ver2, the access node 1 obtains the partial order relationship of the storage node 1, and obtains a new partial order relationship [Ver3, Ver2, Ver1]; the access node determines that the data K1 in the storage node 1 and the storage node 2 conflicts.
  • the priority of the storage node 1 is higher than the priority of the storage node 2, and the access node 1 adjusts the data in the storage node 2 with the data in the storage node 1.
  • the access node 1 transmits a data update request put (K1, V3, Ver3 ⁇ -Ver2) to the storage node 2, and the request carries a partial order relationship that needs to be adjusted.
  • the storage node 2 adjusts the stored data and updates the partial order relationship.
  • the access node 2 also acquires the partial order relationship of the data K1 from the storage node 1 and the storage node 2, and the processing method is the same as that of the access node 1.
  • the partial order relationship obtained by the access node 2 from the storage node 2 may be the adjusted partial order relationship of the access node 1, and the partial order relationship between the storage node 1 and the storage node 2 acquired by the access node 2 is the same, that is, There is no conflict between the data K1 in the storage node 1 and the storage node 2.
  • the processing method of the access node 2 is the same as that of the access node 1, and will not be further described.
  • the second type is the partial order relationship priority strategy, which is to adjust the conflict of data in the storage node in the order of the size of the version number in the partial order relationship. Since the partial order relationship indicates the order of the version numbers of the data update requests, the version number written by the storage node may be larger than the version written later. Under this strategy, data conflicts are adjusted based on the partial order relationship of the version numbers in the partial order relationship from large to small. For example, as described above, the partial order relationship of the data K1 acquired by the access node 1 from the storage node 1 is [Ver3, Ver2, Ver1], and the partial order relationship of the data K1 acquired from the storage node 2 is [Ver2, Ver3, Ver1] ].
  • the version numbers of the partial order relationship of the data K1 returned by the access node 1 from the storage node 1 are arranged from large to small, so that the data in the storage node 1 is unchanged, and according to the partial order relationship of the data K1 in the storage node 1.
  • the data K1 in the storage node 2 is adjusted so that the data in the storage node 1 and the storage node 2 are identical.
  • the access node 1 sends a data update request to the storage node 2, and the request carries a partial order relationship that needs to be adjusted. After receiving the data update request, the storage node 2 adjusts the stored data according to the partial order relationship that needs to be adjusted.
  • the processing method of the access node 2 is the same as that of the access node 1, and will not be further described.
  • the access node does not process and continues to process the service normally.
  • the embodiment of the present invention further provides a multi-active system for solving data conflicts.
  • the architecture of the multi-live system is as shown in FIG. 1.
  • the multi-active system is divided into three logical layers: a client layer 11, an access node layer 12, and a storage node layer 13.
  • Client layer 11 includes multiple clients. Two clients, client 1 and client 2, are exemplarily shown in FIG. The client is configured to send a first data update request to the receiving node.
  • Receive Node Layer 12 includes a plurality of receiving nodes. Two receiving nodes, receiving node 1 and receiving node 2 are exemplarily shown in FIG.
  • Storage node layer 13 includes a plurality of storage nodes, and two storage nodes, storage node 1 and storage node 2 are exemplarily shown in FIG.
  • the receiving node is configured to receive a first data update request sent by the client, generate a globally unique version number for the first data update request, and send a second data update request to the storage node, where the second data update request carries The version number.
  • the storage node is configured to update the corresponding data according to the second data update request, and update the partial order relationship, and return the partial order relationship to the receiving node; wherein the partial order relationship is used to record the data update request received by the storage node.
  • the order of the version numbers are configured to update the corresponding data according to the second data update request, and update the partial order relationship, and return the partial order relationship to the receiving node; wherein the partial order relationship is used to record the data update request received by the storage node.
  • the receiving node is further configured to obtain a partial order relationship returned by the storage node, determine whether there is a conflict in the data in the storage node, and adjust a conflict in the data when there is a conflict in the data in the storage node.
  • the receiving node adjusts the conflict of data only when there is a conflict in the data in the storage node.
  • the receiving node performs the data update operation normally, which greatly improves the data updating efficiency.
  • the access node is configured to determine whether the data in the storage node is in conflict. The access node determines that the data in the storage node conflicts.
  • the access node can determine whether the data in the storage node is consistent according to the partial order relationship, and can quickly identify the data conflict existing in the storage node and improve the performance of the system.
  • the access node is configured to determine whether the data in the storage node is in conflict, and may be: when the received storage node has a misaligned relationship, the access node is re-established within a predetermined time period. Acquiring a partial order relationship of the storage node, when the re-acquisition of the storage node's partial order relationship is inconsistent, the access node determines that the data in the storage node has a conflict.
  • the partial order relationship acquired at different times may be different. And when the partial order relationship of different storage nodes is different, there may be a receiving node that adjusts the data conflict, so a time period can be set, and the receiving node can obtain the partial order relationship of the storage node multiple times in the set time period. Compare them, instead of making adjustments as soon as the partial order relationship is inconsistent, to improve the efficiency of resolving data conflicts.
  • the length of the specific time period can be set according to the type of service, the load of the system, or the needs of the user.
  • the receiving node determines whether there is a conflict in the same in the storage node.
  • the access node is configured to adjust the conflict, where the access node is configured to send a third data update request to the storage node according to the conflict adjustment policy, where the third data update request includes a partial order relationship that needs to be adjusted;
  • the storage node is further configured to: after receiving the third data update request, update the data in the storage node according to the partial order relationship adjusted.
  • the conflict adjustment policy includes a storage node priority policy and a partial order relationship priority policy.
  • the storage node priority policy is to adjust the data in the storage node with lower priority by the partial order relationship of the storage node with higher priority.
  • the partial order relationship priority policy is to adjust the data in the storage node in order of size of the version number in the partial order relationship.
  • the access node and the storage node can be on the same physical device (such as a node device) or in different objects.
  • the device is not limited in the embodiment of the present invention.
  • the present application can be implemented in hardware or a combination of hardware and computer software in combination with the elements and method steps of the various examples described in the embodiments disclosed herein. Whether a function is implemented in hardware or computer software to drive hardware depends on the specific application and design constraints of the solution. A person skilled in the art can use different methods to implement the described functions for each particular application, but such implementation should not be considered to be beyond the scope of the present application.
  • FIG. 3 is a schematic diagram of a hardware structure of an apparatus for resolving data conflicts according to an embodiment of the present application.
  • the apparatus 300 for resolving data conflicts includes at least one processor 301, a communication bus 302, a memory 303, and at least one communication interface. 304.
  • the processor 301 can be a general-purpose central processing unit (CPU), a microprocessor, an application-specific integrated circuit (ASIC), or one or more programs for controlling the execution of the program of the present application. integrated circuit.
  • CPU central processing unit
  • ASIC application-specific integrated circuit
  • Communication bus 302 can include a path for communicating information between the components described above.
  • the communication interface 304 uses a device such as any transceiver for communicating with other devices or communication networks, such as Ethernet, Radio Access Network (RAN), Wireless Local Area Networks (WLAN), etc. .
  • a device such as any transceiver for communicating with other devices or communication networks, such as Ethernet, Radio Access Network (RAN), Wireless Local Area Networks (WLAN), etc. .
  • RAN Radio Access Network
  • WLAN Wireless Local Area Networks
  • the memory 303 can be a read-only memory (ROM) or other type of static storage device that can store static information and instructions, a random access memory (RAM) or other type that can store information and instructions.
  • the dynamic storage device can also be an Electrically Erasable Programmable Read-Only Memory (EEPROM), a Compact Disc Read-Only Memory (CD-ROM) or other optical disc storage, and a disc storage device. (including compact discs, laser discs, optical discs, digital versatile discs, Blu-ray discs, etc.), magnetic disk storage media or other magnetic storage devices, or can be used to carry or store desired program code in the form of instructions or data structures and can be Any other media accessed, but not limited to this.
  • the memory can exist independently and be connected to the processor via a bus.
  • the memory can also be integrated with the processor.
  • the memory 303 is used to store application code for executing the solution of the present application, and is controlled by the processor 301 for execution.
  • the processor 301 is configured to execute the application code stored in the memory 33, thereby implementing the method of allocating resources in the multi-CPU system described in the above embodiments.
  • processor 301 may include one or more CPUs, such as CPU0 and CPU1 in FIG.
  • apparatus 300 for resolving data conflicts may include multiple processors, such as processor 301 and processor 308 in FIG. Each of these processors can be a single-CPU processor or a multi-core processor.
  • a processor herein may refer to one or more devices, circuits, and/or processing cores for processing data, such as computer program instructions.
  • the apparatus 300 for resolving data conflicts may further include an output device 305 and an input device 306.
  • Output device 305 is in communication with processor 301 and can display information in a variety of ways.
  • the output device 305 can be a liquid crystal display (LCD), a light emitting diode (LED) display device, a cathode ray tube (CRT) display device, or a projector.
  • Input device 306 is in communication with processor 301 and can accept user input in a variety of ways.
  • input device 806 can be a mouse, keyboard, touch screen device, or sensing device, and the like.
  • the above device 300 for resolving data conflicts may be a general purpose server or a dedicated server.
  • the device 300 for resolving data conflicts may be a desktop computer, a portable computer, a network server, a personal digital assistant (PDA), a mobile phone, a tablet, a wireless terminal device, a communication device, an embedded device, or A device of similar construction in Figure 3.
  • PDA personal digital assistant
  • the embodiment of the present application does not limit the type of device 300 that resolves data conflicts.
  • the device for resolving data conflicts provided by the embodiment of the present application can be used to perform the foregoing method for allocating resources in a multi-CPU system. Therefore, the technical effects that can be obtained by reference to the foregoing method embodiments are not described herein. .
  • the embodiment of the present application further provides a computer storage medium for storing computer software instructions for the above-mentioned device for resolving data conflicts, which comprises a program designed to execute the foregoing method embodiments.
  • a method of resource allocation can be implemented in a multi-CPU system by executing a stored program.
  • the embodiment of the present application further provides a computer program, which includes instructions, when the computer program is executed by a computer, to enable the computer to execute the flow of the foregoing method embodiment.
  • embodiments of the present application can be provided as a method, apparatus (device), or computer program product.
  • the present application can take the form of an entirely hardware embodiment, an entirely software embodiment, or an embodiment in combination of software and hardware.
  • the application can take the form of a computer program product embodied on one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) including computer usable program code.
  • the computer program is stored/distributed in a suitable medium, provided with other hardware or as part of the hardware, or in other distributed forms, such as over the Internet or other wired or wireless telecommunication systems.
  • the computer program instructions can also be stored in a computer readable memory that can direct a computer or other programmable data processing device to operate in a particular manner, such that the instructions stored in the computer readable memory produce an article of manufacture comprising the instruction device.
  • the apparatus implements the functions specified in one or more blocks of a flow or a flow and/or block diagram of the flowchart.
  • These computer program instructions can also be loaded onto a computer or other programmable data processing device such that a series of operational steps are performed on a computer or other programmable device to produce computer-implemented processing for execution on a computer or other programmable device.
  • the instructions are provided for implementing one or more processes and/or block diagrams in the flowchart The steps of the function specified in the box or in multiple boxes.

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Data Mining & Analysis (AREA)
  • Databases & Information Systems (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)

Abstract

L'invention concerne un procédé permettant de résoudre une collision de données dans un système multi-activités. Le procédé comprend les étapes suivantes : un nœud d'accès reçoit une première demande de mise à jour de données envoyée par un client, puis génère un numéro de version unique global pour la première demande de mise à jour de données ; le nœud d'accès envoie une seconde demande de mise à jour de données à un nœud de stockage, la seconde demande de mise à jour de données comportant le numéro de version ; le nœud de stockage met à jour les données correspondantes ainsi qu'une relation d'ordre partiel en fonction de la seconde demande de mise à jour de données, puis renvoie la relation d'ordre partiel au nœud d'accès, la relation d'ordre partiel étant utilisée pour enregistrer la séquence de numéros de version des demandes de mise à jour de données reçues par le nœud de stockage ; le nœud d'accès acquiert la relation d'ordre partiel renvoyée par le noeud de stockage, puis détermine si une collision de données s'est produite dans le nœud de stockage ; et lorsqu'une collision de données s'est produite dans le nœud de stockage, le nœud d'accès règle la collision. Lorsqu'une collision de données s'est produite dans un nœud de stockage, un nœud d'accès règle la collision de données, ce qui permet d'améliorer sensiblement l'efficacité de mise à jour des données.
PCT/CN2017/094317 2016-12-30 2017-07-25 Procédé et système de résolution de collision de données WO2018120810A1 (fr)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201611257463.1A CN106802939B (zh) 2016-12-30 2016-12-30 一种解决数据冲突的方法和系统
CN201611257463.1 2016-12-30

Publications (1)

Publication Number Publication Date
WO2018120810A1 true WO2018120810A1 (fr) 2018-07-05

Family

ID=58985182

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2017/094317 WO2018120810A1 (fr) 2016-12-30 2017-07-25 Procédé et système de résolution de collision de données

Country Status (2)

Country Link
CN (1) CN106802939B (fr)
WO (1) WO2018120810A1 (fr)

Families Citing this family (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106802939B (zh) * 2016-12-30 2020-04-03 华为技术有限公司 一种解决数据冲突的方法和系统
CN109213769B (zh) * 2017-06-30 2022-04-29 华为技术有限公司 一种数据对象的数据冲突识别方法
KR102406666B1 (ko) 2017-09-20 2022-06-08 삼성전자주식회사 스냅샷 기능을 지원하는 키-밸류 스토리지 장치 및 상기 키-밸류 스토리지 장치의 동작 방법
CN112115304A (zh) * 2019-06-20 2020-12-22 百度(中国)有限公司 偏序数据的处理方法、装置、系统及存储介质
CN110851243B (zh) * 2019-11-05 2022-04-12 东软集团股份有限公司 流程访问控制方法、装置、存储介质及电子设备
CN111078659B (zh) * 2019-12-20 2023-04-21 腾讯科技(深圳)有限公司 模型更新方法、装置、计算机可读存储介质和计算机设备
CN115794853B (zh) * 2023-02-03 2023-06-23 天翼云科技有限公司 政务数据资源目录的更新方法、装置、电子设备及介质

Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US7467265B1 (en) * 2005-06-30 2008-12-16 Symantec Operating Corporation System and method for block conflict resolution within consistency interval marker based replication
CN103036717A (zh) * 2012-12-12 2013-04-10 北京邮电大学 分布式数据的一致性维护系统和方法
CN104394195A (zh) * 2014-10-31 2015-03-04 杭州华为企业通信技术有限公司 数据更新方法及装置
CN104750738A (zh) * 2013-12-30 2015-07-01 中国移动通信集团公司 一种更新数据信息的方法、数据节点、管理节点及系统
US9208167B1 (en) * 2014-09-04 2015-12-08 Edifire LLC Distributed data synchronization and conflict resolution
CN106250322A (zh) * 2016-08-12 2016-12-21 华为技术有限公司 一种写数据的方法和装置
CN106802939A (zh) * 2016-12-30 2017-06-06 华为技术有限公司 一种解决数据冲突的方法和系统

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US7467265B1 (en) * 2005-06-30 2008-12-16 Symantec Operating Corporation System and method for block conflict resolution within consistency interval marker based replication
CN103036717A (zh) * 2012-12-12 2013-04-10 北京邮电大学 分布式数据的一致性维护系统和方法
CN104750738A (zh) * 2013-12-30 2015-07-01 中国移动通信集团公司 一种更新数据信息的方法、数据节点、管理节点及系统
US9208167B1 (en) * 2014-09-04 2015-12-08 Edifire LLC Distributed data synchronization and conflict resolution
CN104394195A (zh) * 2014-10-31 2015-03-04 杭州华为企业通信技术有限公司 数据更新方法及装置
CN106250322A (zh) * 2016-08-12 2016-12-21 华为技术有限公司 一种写数据的方法和装置
CN106802939A (zh) * 2016-12-30 2017-06-06 华为技术有限公司 一种解决数据冲突的方法和系统

Also Published As

Publication number Publication date
CN106802939B (zh) 2020-04-03
CN106802939A (zh) 2017-06-06

Similar Documents

Publication Publication Date Title
WO2018120810A1 (fr) Procédé et système de résolution de collision de données
US10394847B2 (en) Processing data in a distributed database across a plurality of clusters
US10375167B2 (en) Low latency RDMA-based distributed storage
US10540119B2 (en) Distributed shared log storage system having an adapter for heterogenous big data workloads
AU2012304549B2 (en) Clustered client failover
TW409215B (en) Parallel file system and method for multiple node file access
US11882011B2 (en) Distributed workload reassignment following communication failure
JP2019212336A (ja) 分散キャッシュクラスタ管理
US8671151B2 (en) Maintaining item-to-node mapping information in a distributed system
US20100049922A1 (en) Distributed shared memory
WO2014169649A1 (fr) Méthode et dispositif de traitement de données, et système informatique
US10970311B2 (en) Scalable snapshot isolation on non-transactional NoSQL
US20130332435A1 (en) Partitioning optimistic concurrency control and logging
US11018860B2 (en) Highly available and reliable secret distribution infrastructure
JP2023541298A (ja) トランザクション処理方法、システム、装置、機器、及びプログラム
US10082978B2 (en) Distributed shared log storage system having an adapter for heterogenous big data workloads
WO2016101759A1 (fr) Procédé d'acheminement de données, dispositif de gestion de données et système de stockage distribué
US8732346B2 (en) Coordination of direct I/O with a filter
US9311379B2 (en) Utilization of data structures to synchronize copies of a resource
US20150372946A1 (en) Acquiring resource lease using multiple lease servers
US8341368B2 (en) Automatic reallocation of structured external storage structures
CN111475279B (zh) 用于备份的智能数据负载平衡的系统和方法
CN107102898B (zh) 一种基于numa架构的内存管理、构建数据结构的方法及装置
CN115033350A (zh) 一种分布式事务的执行方法及装置
CN117785020A (zh) 一种数据存储方法、装置和系统

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 17885461

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 17885461

Country of ref document: EP

Kind code of ref document: A1