1. A method comprising: receiving, at a database server from a client application, a first client write request for writing first data to persistent data storage and an indication that the first write request is designated as asynchronous; receiving, at a replication server, a first write request from the database server for writing first data to persistent data storage; determining, by the replication server, that the first write request is designated as asynchronous; in response to determining that the first write request is asynchronous, saving the first data to local cache at the replication server and sending an acknowledgement to the database server, wherein the local cache stores second data to be written to persistent data storage when the first data is saved to the local cache; and writing the first data and the second data from the local cache to the persistent data storage in a batch operation; receiving, at the database server from the client application, a second client write request for writing second data to persistent data storage and an indication that the second write request is designated as synchronous; receiving, at the replication server, a second write request from the database server for writing third data to persistent data storage; determining, by the replication server, that the second write request is designated as synchronous; and in response to determining that the second write request is synchronous, writing the third data to persistent data storage and sending an acknowledgement to the database server after writing the third data to persistent storage.