- Notifications
You must be signed in to change notification settings - Fork5
Commit31d9658
committed
Fix base backup streaming xlog from standby
When backing up from a standby server, the backup processwill not automatically switch xlog segment. So we mustaccept a partially transferred xlog file in this case, butrename it into position anyway.In passing, merge the two callbacks for segment end andstop stream into a single callback, since their implementationswere close to identical, and rename this callback toreflect that it stops streaming rather than continues it.Patch by Magnus Hagander, review by Fujii Masao1 parentd226e23 commit31d9658
File tree
4 files changed
+34
-45
lines changed- src/bin/pg_basebackup
4 files changed
+34
-45
lines changedLines changed: 4 additions & 5 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
78 | 78 |
| |
79 | 79 |
| |
80 | 80 |
| |
81 |
| - | |
| 81 | + | |
82 | 82 |
| |
83 | 83 |
| |
84 | 84 |
| |
| |||
129 | 129 |
| |
130 | 130 |
| |
131 | 131 |
| |
132 |
| - | |
133 |
| - | |
| 132 | + | |
134 | 133 |
| |
135 | 134 |
| |
136 | 135 |
| |
137 | 136 |
| |
138 | 137 |
| |
139 | 138 |
| |
140 | 139 |
| |
141 |
| - | |
| 140 | + | |
142 | 141 |
| |
143 | 142 |
| |
144 | 143 |
| |
| |||
231 | 230 |
| |
232 | 231 |
| |
233 | 232 |
| |
234 |
| - | |
| 233 | + | |
235 | 234 |
| |
236 | 235 |
| |
237 | 236 |
| |
|
Lines changed: 5 additions & 14 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
43 | 43 |
| |
44 | 44 |
| |
45 | 45 |
| |
46 |
| - | |
| 46 | + | |
47 | 47 |
| |
48 | 48 |
| |
49 | 49 |
| |
| |||
69 | 69 |
| |
70 | 70 |
| |
71 | 71 |
| |
72 |
| - | |
| 72 | + | |
73 | 73 |
| |
74 |
| - | |
| 74 | + | |
75 | 75 |
| |
76 | 76 |
| |
77 | 77 |
| |
78 |
| - | |
79 |
| - | |
80 |
| - | |
81 |
| - | |
82 |
| - | |
83 |
| - | |
84 |
| - | |
85 |
| - | |
86 |
| - | |
87 | 78 |
| |
88 | 79 |
| |
89 | 80 |
| |
| |||
268 | 259 |
| |
269 | 260 |
| |
270 | 261 |
| |
271 |
| - | |
272 |
| - | |
| 262 | + | |
| 263 | + | |
273 | 264 |
| |
274 | 265 |
| |
275 | 266 |
| |
|
Lines changed: 19 additions & 14 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
113 | 113 |
| |
114 | 114 |
| |
115 | 115 |
| |
| 116 | + | |
| 117 | + | |
| 118 | + | |
| 119 | + | |
| 120 | + | |
| 121 | + | |
116 | 122 |
| |
117 |
| - | |
| 123 | + | |
118 | 124 |
| |
119 | 125 |
| |
120 | 126 |
| |
| |||
141 | 147 |
| |
142 | 148 |
| |
143 | 149 |
| |
144 |
| - | |
| 150 | + | |
145 | 151 |
| |
146 |
| - | |
| 152 | + | |
147 | 153 |
| |
148 | 154 |
| |
149 | 155 |
| |
| |||
199 | 205 |
| |
200 | 206 |
| |
201 | 207 |
| |
202 |
| - | |
203 |
| - | |
204 |
| - | |
205 |
| - | |
206 |
| - | |
| 208 | + | |
| 209 | + | |
| 210 | + | |
| 211 | + | |
207 | 212 |
| |
208 | 213 |
| |
209 | 214 |
| |
| |||
214 | 219 |
| |
215 | 220 |
| |
216 | 221 |
| |
217 |
| - | |
| 222 | + | |
218 | 223 |
| |
219 | 224 |
| |
220 | 225 |
| |
| |||
288 | 293 |
| |
289 | 294 |
| |
290 | 295 |
| |
291 |
| - | |
| 296 | + | |
292 | 297 |
| |
293 | 298 |
| |
294 | 299 |
| |
295 |
| - | |
| 300 | + | |
296 | 301 |
| |
297 | 302 |
| |
298 | 303 |
| |
| |||
486 | 491 |
| |
487 | 492 |
| |
488 | 493 |
| |
489 |
| - | |
| 494 | + | |
490 | 495 |
| |
491 | 496 |
| |
492 | 497 |
| |
493 | 498 |
| |
494 | 499 |
| |
495 | 500 |
| |
496 |
| - | |
| 501 | + | |
497 | 502 |
| |
498 | 503 |
| |
499 | 504 |
| |
500 | 505 |
| |
501 | 506 |
| |
502 |
| - | |
| 507 | + | |
503 | 508 |
| |
504 | 509 |
| |
505 | 510 |
| |
|
Lines changed: 6 additions & 12 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
1 | 1 |
| |
2 | 2 |
| |
3 | 3 |
| |
4 |
| - | |
5 |
| - | |
| 4 | + | |
| 5 | + | |
6 | 6 |
| |
7 |
| - | |
8 |
| - | |
9 |
| - | |
10 |
| - | |
11 |
| - | |
12 |
| - | |
13 |
| - | |
| 7 | + | |
14 | 8 |
| |
15 | 9 |
| |
16 | 10 |
| |
17 | 11 |
| |
18 | 12 |
| |
19 | 13 |
| |
20 |
| - | |
21 |
| - | |
22 |
| - | |
| 14 | + | |
| 15 | + | |
| 16 | + |
0 commit comments
Comments
(0)