IP Library › Granted Patent US 11,507,596
Granted Patent B2
US 11,507,596 · App. 16/818,496 · Granted Nov 22, 2022

Live migration of distributed databases

Inventors: Greg William Schaefer (Minneapolis, MN); Anand Nair (Atlanta, GA); Shengyong Li (Redwood City, CA); MengXin Ye (Redwood City, CA); Xin Feng Zhang (Shanghai, CN); Miao Xiong (Shanghai, CN); Jian Zhou (Shanghai, CN)
Assignee: Electronic Arts Inc.
G06F16/27
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 11,507,596
App. No.
16/818,496
Granted
Nov 22, 2022
Kind
B2
Abstract

An example method of live migration of distributed databases may include implementing a first database access mode with respect to a distributed database to be migrated from an original set of storage servers to a destination set of storage servers, wherein, in the first database access mode, database read requests are routed to the original set of storage servers and database update requests are routed to both the original set of storage servers and the destination set of storage servers. The method may further include copying a plurality of records of the distributed database from the original set of storage servers to the destination set of storage servers. The method may further include switching to a second database access mode, in which database read requests are routed to the destination set of storage servers and database update requests are routed to both the original set of storage servers and the destination set of storage servers. The method may further include switching to a post-migration database access mode, in which database read and update requests are routed to the destination set of storage servers.

Claims (51)

1. A method, comprising:

copying, in a first database access mode, a plurality of records of a distributed database from an original set of storage servers comprising a first number of storage servers to a destination set of storage servers comprising a second number of storage servers, wherein the second number exceeds the first number;

receiving, in the first database access mode, a database access request comprising a primary key;

identifying, by dividing a numeric value of the primary key by the first number of storage servers, a storage server of the original set of storage servers;

routing the database access request to the identified storage server;

switching, by a processing device, to a second database access mode, in which database read requests are routed to the destination set of storage servers and database update requests are routed to both the original set of storage servers and the destination set of storage servers; and

switching, by the processing device, to a post-migration database access mode, in which database read and update requests are routed to the destination set of storage servers.

2. The method of claim 1 , wherein switching to the second database access mode is performed responsive to completing the copying operation.

3. The method of claim 1 , wherein switching to the post-migration database access mode is performed responsive to successfully evaluating a data stabilization condition with respect to the destination set of storage servers.

4. The method of claim 1 , wherein the distributed database is provided by a horizontally partitioned database.

5. The method of claim 1 , further comprising:

deleting the plurality of records of the distributed database from the original set of storage servers.

6. The method of claim 1 , wherein copying the plurality of records of the distributed database further comprises:

acquiring a lock with respect to a record of the plurality of records;

copying the record to a first storage server of the destination set of storage servers; and

releasing the lock with respect to the record.

7. The method of claim 1 , wherein the distributed database comprises a plurality of logical database partitions that are evenly distributed over the destination set of storage servers.

8. A system, comprising:

a memory to store a distributed database configuration;

a processing device, operatively coupled to the memory, the processing device to:

copy, in a first database access mode, a plurality of records of a distributed database from an original set of storage servers comprising a first number of storage servers to a destination set of storage servers comprising a second number of storage servers, wherein the second number exceeds the first number;

receive, in the first database access mode, a database access request comprising a primary key;

identify, by dividing a numeric value of the primary key by the first number of storage servers, a storage server of the original set of storage servers;

route the database access request to the identified storage server;

switch to a second database access mode, in which database read requests are routed to the destination set of storage servers and database update requests are routed to both the original set of storage servers and the destination set of storage servers; and

switch to a post-migration database access mode, in which database read and update requests are routed to the destination set of storage servers.

9. The system of claim 8 , wherein switching to the second database access mode is performed responsive to completing the copying operation.

10. The system of claim 8 , wherein switching to the post-migration database access mode is performed responsive to successfully evaluating a data stabilization condition with respect to the destination set of storage servers.

11. The system of claim 8 , wherein the distributed database is provided by a horizontally partitioned database.

12. The system of claim 8 , wherein the processing device is further to:

delete the plurality of records of the distributed database from the original set of storage servers.

13. The system of claim 8 , wherein copying the plurality of records of the distributed database further comprises:

acquiring a lock with respect to a record of the plurality of records;

copying the record to a first storage server of the destination set of storage servers; and

releasing the lock with respect to the record.

14. The system of claim 8 , wherein the distributed database comprises a plurality of logical database partitions that are evenly distributed over the destination set of storage servers.

15. A computer-readable non-transitory storage medium comprising executable instructions that, when executed by a processing device, cause the processing device to:

copy, in a first database access mode, a plurality of records of a distributed database from an original set of storage servers comprising a first number of storage servers to a destination set of storage servers comprising a second number of storage servers, wherein the second number exceeds the first number;

receive, in the first database access mode, a database access request comprising a primary key;

identify, by dividing a numeric value of the primary key by the first number of storage servers, a storage server of the original set of storage servers;

routing the database access request to the identified storage server;

switch to a second database access mode, in which database read requests are routed to the destination set of storage servers and database update requests are routed to both the original set of storage servers and the destination set of storage servers; and

switch to a post-migration database access mode, in which database read and update requests are routed to the destination set of storage servers.

16. The computer-readable non-transitory storage medium of claim 15 , wherein switching to the second database access mode is performed responsive to completing the copying operation.

17. The computer-readable non-transitory storage medium of claim 15 , wherein switching to the post-migration database access mode is performed responsive to successfully evaluating a data stabilization condition with respect to the destination set of storage servers.

18. The computer-readable non-transitory storage medium of claim 15 , wherein the distributed database is provided by a horizontally partitioned database.

19. The computer-readable non-transitory storage medium of claim 15 , wherein copying the plurality of records of the distributed database further comprises:

acquiring a lock with respect to a record of the plurality of records;

copying the record to a first storage server of the destination set of storage servers; and

releasing the lock with respect to the record.

20. The computer-readable non-transitory storage medium of claim 15 , wherein a plurality of logical database partitions are evenly distributed over the destination set of storage servers.

Assignments (1)
ASSIGNMENT OF ASSIGNOR'S INTEREST Recorded Mar 13, 2020
From: SCHAEFER, GREG WILLIAM; NAIR, ANAND; LI, SHENGYONG; YE, MENGXIN; ZHANG, XIN FENG; XIONG, MIAO; ZHOU, JIAN
To: ELECTRONIC ARTS INC.
Reel/Frame 052111/0020 →
Continuity (2)
Continuation 15173103 · Jun 3, 2016
Related Publication 20200218732A1 · Jul 9, 2020