发明名称 Method and apparatus for maintaining replica sets
摘要 Provided are systems and methods for managing asynchronous replication in a distributed database environment, wherein a cluster of nodes are assigned roles for processing database requests. In one embodiment, the system provides a node with a primary role to process write operations against its database, generate an operation log reflecting the processed operations, and permit asynchronous replication of the operations to at least one secondary node. In another embodiment, the primary node is the only node configured to accept write operations. Both primary and secondary nodes can process read operations. Although in some settings read requests can be restricted to secondary nodes or the primary node. In one embodiment, the systems and methods provide for automatic failover of the primary node role, can include a consensus election protocol for identifying the next primary node. Further, the systems and methods can be configured to automatically reintegrate a failed primary node.
申请公布号 US9317576(B2) 申请公布日期 2016.04.19
申请号 US201314064705 申请日期 2013.10.28
申请人 MongoDB, Inc. 发明人 Merriman Dwight;Horowitz Eliot
分类号 G06F17/30;G06F11/14 主分类号 G06F17/30
代理机构 Wolf, Greenfield & Sacks, P.C. 代理人 Wolf, Greenfield & Sacks, P.C.
主权项 1. A computer-implemented method for asynchronous replication in a distributed database system, the method comprising the acts of: establishing a primary node within a plurality of nodes, wherein the plurality of nodes service data requests based on data request received from client computer systems; restricting processing of write operations received from the client computer systems to the primary node; replicating, asynchronously, from the primary node the write operations received from the client computer systems to a plurality of secondary nodes which host a replica of the primary node database from the plurality of nodes, such that all write operations are executed at least under a default consistency model for data replication in a database, wherein the default consistency model comprises an eventual consistency model; identifying, by the primary node, that at least one write operation includes a user requirement, such that the at least one write operation is executed with additional requirements over the default consistency model; recording, by the primary node, replication status reflecting at least that the at least one write has occurred for the at least one write from the plurality of secondary nodes; and confirming, by the primary node, the at least one write operation responsive to determining that that at least one write operation has been replicated to a threshold number of the plurality of secondary nodes.
地址 New York NY US