Skip to content

Commit 591b005

Browse files
committed
update the review suggestions
1 parent 842369e commit 591b005

File tree

1 file changed

+10
-7
lines changed

1 file changed

+10
-7
lines changed

articles/postgresql/high-availability/concepts-high-availability.md

Lines changed: 10 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -291,29 +291,32 @@ When using logical replication or logical decoding with High Availability (HA) i
291291
### PostgreSQL 16 and earlier
292292
In PostgreSQL 16 and earlier, logical replication slots aren't automatically preserved on the standby server after a failover. To maintain logical replication across failover, you must:
293293
- Enable the `pg_failover_slots` extension
294-
- Configure required settings such as `hot_standby_feedback = on`
294+
- Configure required settings such as:
295+
- `hot_standby_feedback = on`
295296

296297
Without these configurations, logical replication might stop working after a failover because replication slots aren't available on the new primary.
297298

298299
### PostgreSQL 17 and later
299300
Starting with PostgreSQL 17, logical replication slot synchronization is supported natively. When correctly configured, replication slots are automatically synchronized to the standby server.
301+
300302
To enable this behavior:
301303
- Set `sync_replication_slots = on`
302304
- Set `hot_standby_feedback = on`
303305

304-
With these settings, logical replication slots are preserved during failover, and replication can continue without requiring extensions. For setup steps and prerequisites, refer to the [PG_Failover_Slots extension](../extensions/concepts-extensions-versions.md#pg_failover_slots) documentation.
306+
With these settings, logical replication slots are preserved during failover, and replication can continue without requiring extensions. For details, refer to the [PG_Failover_Slots extension](../extensions/concepts-extensions-versions.md#pg_failover_slots) documentation.
305307

306308
### Important considerations
307-
- Logical replication slots are managed on the primary server, but **must also exist** on the standby to ensure logical works post HA failover.
308-
- System views (for example, querying `pg_replication_slots`) only show the state on the primary and don't confirm whether slots are synchronized to the standby. A system can appear healthy on the primary but still not be failover-ready.
309+
- Logical replication slots are managed on the primary server, but **must also exist** on the standby to ensure logical replication continues after HA failover.
310+
- System views (for example, querying `pg_replication_slots`) only show the state on the primary and don't confirm whether slots are synchronized to the standby. A system can appear healthy on the primary but still not be failover-ready to preserve logical replication slots on the standby.
309311

310312
### Monitor logical replication failover readiness
311313
To help validate failover readiness, you can use the Azure Monitor metric `logical_replication_slot_sync_status` (Preview).
312-
This metric indicates whether logical replication slots are synchronized across the HA primary and standby:
314+
315+
This metric indicates whether logical replication slots are synchronized between the HA primary and standby:
313316
- `1` indicates that slots are synchronized across primary and standby.
314317
- `0` indicates that slots aren't synchronized on the standby.
315318

316319
If the metric value is 0, logical replication might continue to function on the current primary, but it might not continue after a failover. For more details, refer to the [Logical replication monitoring](../monitor/concepts-monitoring.md#logical-replication).
317320

318-
> [!NOTE]
319-
> This synchronization state reflects the status across HA nodes and can't be verified using system views on the primary server alone. Consider using this metric with alerts to detect when logical replication isn't failover-ready, especially before planned maintenance or failover events.
321+
> [!NOTE]
322+
> This synchronization state reflects the status across HA nodes and can't be verified using system views on the primary alone. Consider using this metric with alerts to detect when logical replication isn't failover-ready, especially before planned maintenance or failover events. Consider configuring alerts when this metric remains 0 for a sustained period.

0 commit comments

Comments
 (0)