IP Library Granted Patent US 9,672,266
Granted Patent B2
US 9,672,266 · App. 14/213,508 · Granted Jun 6, 2017

Method and apparatus for ensuring consistent outcomes in updates to distributed databases

Inventors: James Webber (London, GB); Ian S. Robinson (London, GB); Mats Tobias Lindaaker (Malmo, SE); Alistair Philip Campbell Jones (London, GB)
Assignee: Neo Technology, Inc.
G06F17/30581
View Patent ↗
Loading inventors, assignments & file history…
Monitor This Case
Get email alerts when status or documents change.
Order Certified Copies
Most orders are placed with the USPTO same day — all within 24 business hours.
Order via The Patent Place →
Pre-filled with this patent's details
Quick Facts
Patent No.
US 9,672,266
App. No.
14/213,508
Granted
Jun 6, 2017
Kind
B2
Abstract

Methods of conducting database transactions. One such method comprises receiving data to be written to a database; identifying a set of shard replicas corresponding to the database to which the data is to be written; transmitting, to each of the replicas in the set, a request to write the data thereto; receiving votes back from the replicas in the set, each vote representing whether the respective replica commits to a writing of the data thereto; determining whether to commit to the writing of the data to the database according to whether a majority of the replicas of every shard having replicas in the set has transmitted a vote committing to the writing of the data thereto; and transmitting an outcome of the determining to each of the replicas in the set.

Claims (33)

1. A method of updating a database, comprising: receiving data to be written to a database;

identifying a set of shard replicas corresponding to the database to which the data is to be written;

transmitting, to each of the replicas in the set, a request to write the data thereto; receiving votes back from the replicas in the set, each vote representing whether the respective replica commits to a writing of the data thereto;

determining whether to commit to the writing of the data to the database according to whether, for each shard having replicas in the set, a majority but less than all of the replicas of the each shard which also belong to the set has transmitted a vote committing to the writing of the data thereto;

if at least one of the shards having replica in the set fails to achieve the majority but less than all of the replica, not committing the writing; and

transmitting an outcome of the determining to each of the replicas in the set.

2. The method of claim 1 , wherein the transmitting an outcome further comprises transmitting a commit instruction to each of the replicas in the set upon receiving the vote committing to the writing of the data from, for each shard having replicas in the set, a majority of the replicas of that shard which also belong to the set.

3. The method of claim 1 , wherein the transmitting an outcome further comprises transmitting a cancel instruction to each of the replicas in the set upon receiving votes committing to the writing of the data from less than half of the replicas of a shard having replicas in the set after a predetermined time period.

4. The method of claim 1 , wherein the transmitting, to each of the replicas in the set, a request to write the data thereto further comprises transmitting at least a portion of the data that is to be written.

5. A method of updating a database, comprising

transmitting a request to execute a database transaction, the request transmitted to a set of database members, the set being a set of shard replicas;

receiving responses from the members of the set, each response representing whether the corresponding member commits to the transaction;

committing to the transaction if, for each shard having replicas in the set, a majority but less than all of its respective replicas of the set of shard replicas has committed to the transaction; and

if at least one of the shards having replica in the set fails to achieve the majority but less than all of the replica, not committing the writing.

6. The method of claim 5 , further comprising cancelling the transaction if, for at least one shard having replicas in the set, only a minority of its respective replicas has transmitted a response representing commitment to the transaction after a predetermined time period.

7. The method of claim 5 , wherein the transmitting a request further comprises transmitting data to be written to the database in the transaction.

8. One or more non-transitory computer-readable media, the memories collectively storing instructions for executing a method of updating a database, the method comprising:

receiving data to be written to a database;

identifying a set of shard replicas corresponding to the database to which the data is to be written;

transmitting, to each of the replicas in the set, a request to write the data thereto; receiving votes back from the replicas in the set, each vote representing whether the respective shard or replica commits to a writing of the data thereto;

determining whether to commit to the writing of the data to the database according to whether, for each shard having replicas in the set, a majority but less than all of the replicas of the each shard which also belong to the set has transmitted a vote committing to the writing of the data thereto;

if at least one of the shards having replica in the set fails to achieve the majority but less than all of the replica, not committing the writing; and

transmitting an outcome of the determining to each of the replicas in the set.

9. The one or more non-transitory computer-readable media of claim 8 , wherein the transmitting an outcome further comprises transmitting a commit instruction to each of the replicas in the set upon receiving the vote committing to the writing of the data from, for each shard having replicas in the set, a majority of the replicas of that shard which also belong to the set.

10. The one or more non-transitory computer-readable media of claim 8 , wherein the transmitting an outcome further comprises transmitting a cancel instruction to each of the replicas in the set upon receiving votes committing to the writing of the data from less than half of the replicas of a shard having replicas in the set after a predetermined time period.

11. The one or more non-transitory computer-readable media of claim 8 , wherein the transmitting, to each of the shards and the replicas in the set, a request to write the data thereto further comprises transmitting at least a portion of the data that is to be written.

12. One or more non-transitory computer-readable media, the memories collectively storing instructions for executing a method of updating a database, the method comprising:

transmitting a request to execute a database transaction, the request transmitted to a set of database members, the set being a set of shard replicas;

receiving responses from the members of the set, each response representing whether the corresponding member commits to the transaction;

committing to the transaction if, for each shard having replicas in the set, a majority but less than all of its respective replicas of the set of shard replicas has committed to the transaction; and

if at least one of the shards having replica in the set fails to achieve the majority but less than all of the replica, not committing the writing.

13. The one or more non-transitory computer-readable media of claim 12 , further comprising cancelling the transaction if, for at least one shard having replicas in the set, only a minority of its respective replicas has transmitted a response representing commitment to the transaction after a predetermined time period.

14. The one or more non-transitory computer-readable media of claim 12 , wherein the transmitting a request further comprises transmitting data to be written to the database in the transaction.

Assignments (4)
SECURITY INTEREST Recorded Mar 31, 2026
From: NEO4J, INC.; NEO4J SWEDEN AB
To: HERCULES CAPITAL, INC., AS AGENT
Reel/Frame 074237/0314 →
ASSIGNMENT OF ASSIGNOR'S INTEREST Recorded Nov 21, 2019
From: NEO4J, INC.
To: NEO4J SWEDEN AB
Reel/Frame 051076/0241 →
CHANGE OF NAME Recorded Sep 19, 2017
From: NEO TECHNOLOGY, INC.
To: NEO4J, INC.
Reel/Frame 043900/0108 →
ASSIGNMENT OF ASSIGNOR'S INTEREST Recorded Sep 3, 2014
From: WEBBER, JAMES; ROBINSON, IAN SCOTT; LINDAAKER, MATS TOBIAS; JONES, ALISTAIR PHILIP CAMPBELL
To: NEO TECHNOLOGY, INC.
Reel/Frame 033662/0336 →
Continuity (2)
Provisional Application 61801753 · Mar 15, 2013
Related Publication 20140289197A1 · Sep 25, 2014