(Republishing, or using this info in a commercial product/website, is prohibited without permission. All other uses are permitted. If in doubt, please ask.)
This wait type is when a thread is waiting for the remote log block copy to a synchronous availability group replica as part of flushing a log block to disk on the primary replica. The local flush and the remote copy are initiated at the same time, and then the thread waits for the remote copy (incurring HADR_SYNC_COMMIT) and then waits on the local flush, if it hasn’t already completed (incurring WRITELOG). This is described in this CSS post. Note that this wait does NOT include replaying the transaction log on the replica.
(Books Online description: “Waiting for transaction commit processing for the synchronized secondary databases to harden the log. This wait is also reflected by the Transaction Delay performance counter. This wait type is expected for synchronized availability groups and indicates the time to send, write, and acknowledge log to the secondary databases.”)
Questions/comments on this wait type? Click here to send Paul an email, especially if you have any information to add to this topic.
Added in SQL Server version:
Removed in SQL Server version:
Extended Events wait_type value:
The map_key value in sys.dm_xe_map_values is 776 in 2012 and 794 in 2014 RTM. After 2014 RTM, you must check the DMV to get the latest value as some map_key values have changed in later builds.
If this wait type becomes prevalent, the bottleneck is the remote log block copy during a log block flush. Check for networking issues and performance issues on the synchronous replica, especially around the I/O performance of the replica’s log file.
Known occurrences in SQL Server (list number matches call stack list):
Abbreviated call stacks (list number matches known occurrences list):