US 12,169,506 B1
Utilizing asynchronous double-writes to migrate data between databases
Jiaqi Guo, Spring, TX (US); Valentina Josefina Trujillo Di Base, Vancouver (CA); and Shigeki Hirose, Des Moines, WA (US)
Assigned to Chime Financial, Inc., San Francisco, CA (US)
Filed by Chime Financial, Inc., San Francisco, CA (US)
Filed on Nov. 1, 2023, as Appl. No. 18/499,467.
Int. Cl. G06F 16/21 (2019.01); G06F 16/27 (2019.01)
CPC G06F 16/275 (2019.01) [G06F 16/219 (2019.01)] 20 Claims
OG exemplary drawing
 
1. A computer-implemented method comprising:
establishing a database system comprising a primary database that hosts a plurality of data tables, wherein the database system comprises an initial sync direction between a first data table in the primary database and a second data table in a secondary database;
receiving a work unit that generates a write command of a unit of data to the first data table in the primary database, wherein receiving the work unit generates a trigger to schedule, with a sync record service, an asynchronous write command of the unit of data to the second data table in the secondary database based on the initial sync direction;
writing, by the sync record service, the unit of data to the second data table in the secondary database based on the asynchronous write command causing the unit of data to be synchronized between the first data table in the primary database and the second data table in the secondary database;
changing the initial sync direction to a reversed sync direction based on receiving a reverse sync direction command;
receiving an additional work unit that generates an additional write command of an additional unit of data to the second data table in the secondary database, wherein receiving the additional work unit generates an additional trigger to schedule, with the sync record service, an additional asynchronous write command of the additional unit of data to the first data table in the primary database based on the reversed sync direction; and
writing, by the sync record service, the additional unit of data to the primary database based on the additional asynchronous write command causing the unit of data to be synchronized between the second data table in the secondary database and the first data table in the primary database.