- Notifications
You must be signed in to change notification settings - Fork4.9k
Commit2a8b40e

Amit Kapila
Simplify determining logical replication worker types.
We deduce a LogicalRepWorker's type from the values of several differentfields ('relid' and 'leader_pid') whenever logic needs to know it.In fact, the logical replication worker type is already known at the timeof launching the LogicalRepWorker and it never changes for the lifetime ofthat process. Instead of deducing the type, it is simpler to just store itone time, and access it directly thereafter.Author: Peter SmithReviewed-by: Amit Kapila, Bharath RupireddyDiscussion:http://postgr.es/m/CAHut+PttPSuP0yoZ=9zLDXKqTJ=d0bhxwKaEaNcaym1XqcvDEg@mail.gmail.com1 parent3d8d217 commit2a8b40e
File tree
5 files changed
+43
-17
lines changed- src
- backend/replication/logical
- include/replication
- tools/pgindent
5 files changed
+43
-17
lines changedLines changed: 2 additions & 1 deletion
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
435 | 435 |
| |
436 | 436 |
| |
437 | 437 |
| |
438 |
| - | |
| 438 | + | |
| 439 | + | |
439 | 440 |
| |
440 | 441 |
| |
441 | 442 |
| |
|
Lines changed: 21 additions & 10 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
303 | 303 |
| |
304 | 304 |
| |
305 | 305 |
| |
306 |
| - | |
| 306 | + | |
| 307 | + | |
307 | 308 |
| |
308 | 309 |
| |
309 | 310 |
| |
| |||
315 | 316 |
| |
316 | 317 |
| |
317 | 318 |
| |
318 |
| - | |
319 |
| - | |
320 |
| - | |
321 |
| - | |
| 319 | + | |
| 320 | + | |
| 321 | + | |
| 322 | + | |
| 323 | + | |
| 324 | + | |
| 325 | + | |
| 326 | + | |
| 327 | + | |
| 328 | + | |
| 329 | + | |
| 330 | + | |
322 | 331 |
| |
323 | 332 |
| |
324 | 333 |
| |
| |||
393 | 402 |
| |
394 | 403 |
| |
395 | 404 |
| |
396 |
| - | |
| 405 | + | |
397 | 406 |
| |
398 | 407 |
| |
399 | 408 |
| |
| |||
427 | 436 |
| |
428 | 437 |
| |
429 | 438 |
| |
| 439 | + | |
430 | 440 |
| |
431 | 441 |
| |
432 | 442 |
| |
| |||
466 | 476 |
| |
467 | 477 |
| |
468 | 478 |
| |
469 |
| - | |
| 479 | + | |
470 | 480 |
| |
471 | 481 |
| |
472 | 482 |
| |
| |||
847 | 857 |
| |
848 | 858 |
| |
849 | 859 |
| |
850 |
| - | |
| 860 | + | |
851 | 861 |
| |
852 | 862 |
| |
853 | 863 |
| |
| |||
1180 | 1190 |
| |
1181 | 1191 |
| |
1182 | 1192 |
| |
1183 |
| - | |
| 1193 | + | |
| 1194 | + | |
1184 | 1195 |
| |
1185 | 1196 |
| |
1186 | 1197 |
| |
| |||
1290 | 1301 |
| |
1291 | 1302 |
| |
1292 | 1303 |
| |
1293 |
| - | |
| 1304 | + | |
1294 | 1305 |
| |
1295 | 1306 |
| |
1296 | 1307 |
| |
|
Lines changed: 2 additions & 1 deletion
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
587 | 587 |
| |
588 | 588 |
| |
589 | 589 |
| |
590 |
| - | |
| 590 | + | |
| 591 | + | |
591 | 592 |
| |
592 | 593 |
| |
593 | 594 |
| |
|
Lines changed: 17 additions & 5 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
27 | 27 |
| |
28 | 28 |
| |
29 | 29 |
| |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
30 | 38 |
| |
31 | 39 |
| |
32 | 40 |
| |
| 41 | + | |
| 42 | + | |
| 43 | + | |
33 | 44 |
| |
34 | 45 |
| |
35 | 46 |
| |
| |||
232 | 243 |
| |
233 | 244 |
| |
234 | 245 |
| |
235 |
| - | |
| 246 | + | |
| 247 | + | |
236 | 248 |
| |
237 | 249 |
| |
238 | 250 |
| |
| |||
315 | 327 |
| |
316 | 328 |
| |
317 | 329 |
| |
318 |
| - | |
| 330 | + | |
| 331 | + | |
319 | 332 |
| |
320 | 333 |
| |
321 | 334 |
| |
322 | 335 |
| |
323 |
| - | |
| 336 | + | |
324 | 337 |
| |
325 | 338 |
| |
326 | 339 |
| |
327 | 340 |
| |
328 | 341 |
| |
329 |
| - | |
330 |
| - | |
| 342 | + | |
331 | 343 |
| |
332 | 344 |
| |
333 | 345 |
| |
|
Lines changed: 1 addition & 0 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
1500 | 1500 |
| |
1501 | 1501 |
| |
1502 | 1502 |
| |
| 1503 | + | |
1503 | 1504 |
| |
1504 | 1505 |
| |
1505 | 1506 |
| |
|
0 commit comments
Comments
(0)