CPC G06F 16/275 (2019.01) [G06F 11/2023 (2013.01); G06F 16/2322 (2019.01); G06F 16/2379 (2019.01); G06F 16/2455 (2019.01); G06F 2201/80 (2013.01)] | 20 Claims |
1. A computer-implemented method comprising:
receiving, from a client system, a request to establish a new session at a logical replica database of a standby database server;
wherein the logical replica database is kept in synch with data of a primary database through logical replication of changes to the primary database;
wherein the new session is a failover session of an original session at the primary database of a primary database server;
prior to receiving the request to establish the new session:
the primary database server receiving a set of one or more commands in the original session, which, if completed in the original session, would cause performance of:
a first server operation that commits a transaction that includes the set of one or more commands,
a second server operation that generates and executes an SQL-based command for storing a commit-indication that indicates that the transaction was committed,
wherein the commit-indication is not stored until after the first server operation has committed the transaction and completed the set of commands,
replicating and executing the SQL-based command on the logical replica database, and thereby storing the commit-indication that indicates that the transaction was committed on the logical replica database;
receiving by the standby database server in the new session, from the client system, a request for an outcome of the set of one or more commands that were previously sent by the client system in the original session;
wherein the request, for the outcome, received by the standby database server includes the commit-indication to identify the set of one or more commands;
in response to the request for the outcome, determining, by the standby database server, based, at least in part, on existence of the commit-indication on the logical replica databases, whether the set of one or more commands has committed on the primary database and, thereby, successfully replicated to the logical replica database.
|