- Notifications
You must be signed in to change notification settings - Fork5.3k
Commitbeba3c2
Fix timing-dependent failure in recovery test 004_timeline_switch
The test introduced by17b2d5e verifies that a WAL receiversurvives across a timeline jump by searching the server logs fortermination messages. However, it called restart() before the timelineswitch, which kills the WAL receiver and may log the exact message beingchecked, hence failing the test. As TAP tests reuse the same log fileacross restarts, a rotate_logfile() is used before the restart so as thelog matching check is not impacted by log entries generated by aprevious shutdown.Recent changes to file handle inheritance altered I/O timing enough tomake this fail consistently while testing another patch.While on it, this adds an extra check based on a PID comparison. Thistest may lead to false positives as it could be possible that the WALreceiver has processed a timeline jump before the initial PID isgrabbed, but it should be good enough in most cases.Like17b2d5e, backpatch down to v13.Author: Bryan Green <dbryan.green@gmail.com>Co-authored-by: Xuneng Zhou <xunengzhou@gmail.com>Discussion:https://postgr.es/m/9d00b597-d64a-4f1e-802e-90f9dc394c70@gmail.comBackpatch-through: 131 parent0418716 commitbeba3c2
1 file changed
+20
-1
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
7 | 7 | | |
8 | 8 | | |
9 | 9 | | |
10 | | - | |
| 10 | + | |
11 | 11 | | |
12 | 12 | | |
13 | 13 | | |
| |||
58 | 58 | | |
59 | 59 | | |
60 | 60 | | |
| 61 | + | |
| 62 | + | |
| 63 | + | |
61 | 64 | | |
62 | 65 | | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
| 73 | + | |
63 | 74 | | |
64 | 75 | | |
65 | 76 | | |
| |||
80 | 91 | | |
81 | 92 | | |
82 | 93 | | |
| 94 | + | |
| 95 | + | |
| 96 | + | |
| 97 | + | |
| 98 | + | |
| 99 | + | |
| 100 | + | |
| 101 | + | |
83 | 102 | | |
84 | 103 | | |
85 | 104 | | |
| |||
0 commit comments
Comments
(0)