forked frompostgres/postgres
- Notifications
You must be signed in to change notification settings - Fork6
Commit5deb563
committed
Expand assertion check for query ID reporting in executor
As formulated, the assertion added in the executor by24f5205 tocheck that a query ID is set had two problems:- track_activities may be disabled while compute_query_id is enabled,causing the query ID to not be reported to pg_stat_activity.- debug_query_string may not be set in some context. The only pathwhere this would matter is visibly autovacuum, should parallel workersbe enabled there at some point. This is not the case currently.There was no test showing the interactions between the query ID andtrack_activities, so let's add one based on a scan of pg_stat_activity.This assertion is still an experimentation at this stage, but let's seeif this shows more paths where query IDs are not properly set while theyshould.Discussion:https://postgr.es/m/Zvn5616oYXmpXyHI@paquier.xyz1 parent102de3b commit5deb563
File tree
3 files changed
+48
-3
lines changed- src
- backend/executor
- test/regress
- expected
- sql
3 files changed
+48
-3
lines changedLines changed: 15 additions & 3 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
71 | 71 |
| |
72 | 72 |
| |
73 | 73 |
| |
| 74 | + | |
| 75 | + | |
| 76 | + | |
| 77 | + | |
| 78 | + | |
| 79 | + | |
| 80 | + | |
| 81 | + | |
| 82 | + | |
| 83 | + | |
| 84 | + | |
| 85 | + | |
74 | 86 |
| |
75 | 87 |
| |
76 | 88 |
| |
| |||
297 | 309 |
| |
298 | 310 |
| |
299 | 311 |
| |
300 |
| - | |
| 312 | + | |
301 | 313 |
| |
302 | 314 |
| |
303 | 315 |
| |
| |||
408 | 420 |
| |
409 | 421 |
| |
410 | 422 |
| |
411 |
| - | |
| 423 | + | |
412 | 424 |
| |
413 | 425 |
| |
414 | 426 |
| |
| |||
471 | 483 |
| |
472 | 484 |
| |
473 | 485 |
| |
474 |
| - | |
| 486 | + | |
475 | 487 |
| |
476 | 488 |
| |
477 | 489 |
| |
|
Lines changed: 21 additions & 0 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
824 | 824 |
| |
825 | 825 |
| |
826 | 826 |
| |
| 827 | + | |
| 828 | + | |
| 829 | + | |
| 830 | + | |
| 831 | + | |
| 832 | + | |
| 833 | + | |
| 834 | + | |
| 835 | + | |
| 836 | + | |
| 837 | + | |
| 838 | + | |
| 839 | + | |
| 840 | + | |
| 841 | + | |
| 842 | + | |
| 843 | + | |
| 844 | + | |
| 845 | + | |
| 846 | + | |
| 847 | + | |
827 | 848 |
| |
828 | 849 |
| |
829 | 850 |
| |
|
Lines changed: 12 additions & 0 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
319 | 319 |
| |
320 | 320 |
| |
321 | 321 |
| |
| 322 | + | |
| 323 | + | |
| 324 | + | |
| 325 | + | |
| 326 | + | |
| 327 | + | |
| 328 | + | |
| 329 | + | |
| 330 | + | |
| 331 | + | |
| 332 | + | |
| 333 | + | |
322 | 334 |
| |
323 | 335 |
| |
324 | 336 |
| |
|
0 commit comments
Comments
(0)