forked frompostgres/postgres
- Notifications
You must be signed in to change notification settings - Fork6
Commit4216858
committed
When WalSndCaughtUp, sleep only in WalSndWaitForWal().
Before sleeping, WalSndWaitForWal() sends a keepalive if MyWalSnd->write< sentPtr. That is important in logical replication. When the latestphysical LSN yields no logical replication messages (a common case),that keepalive elicits a reply, and processing the reply updatespg_stat_replication.replay_lsn. WalSndLoop() lacks that; whenWalSndLoop() slept, replay_lsn advancement could stall untilwal_receiver_status_interval elapsed. This sometimes stalledsrc/test/subscription/t/001_rep_changes.pl for up to 10s.Discussion:https://postgr.es/m/20200406063649.GA3738151@rfd.leadboat.com1 parent969f9d0 commit4216858
1 file changed
+8
-13
lines changedLines changed: 8 additions & 13 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
1428 | 1428 |
| |
1429 | 1429 |
| |
1430 | 1430 |
| |
1431 |
| - | |
1432 |
| - | |
| 1431 | + | |
| 1432 | + | |
| 1433 | + | |
| 1434 | + | |
1433 | 1435 |
| |
1434 | 1436 |
| |
1435 | 1437 |
| |
| |||
2314 | 2316 |
| |
2315 | 2317 |
| |
2316 | 2318 |
| |
2317 |
| - | |
2318 |
| - | |
2319 |
| - | |
2320 |
| - | |
2321 |
| - | |
2322 |
| - | |
| 2319 | + | |
| 2320 | + | |
2323 | 2321 |
| |
2324 |
| - | |
| 2322 | + | |
2325 | 2323 |
| |
2326 | 2324 |
| |
2327 | 2325 |
| |
2328 | 2326 |
| |
2329 | 2327 |
| |
2330 |
| - | |
| 2328 | + | |
2331 | 2329 |
| |
2332 | 2330 |
| |
2333 | 2331 |
| |
2334 | 2332 |
| |
2335 | 2333 |
| |
2336 | 2334 |
| |
2337 | 2335 |
| |
2338 |
| - | |
2339 |
| - | |
2340 |
| - | |
2341 | 2336 |
| |
2342 | 2337 |
| |
2343 | 2338 |
| |
|
0 commit comments
Comments
(0)