- Notifications
You must be signed in to change notification settings - Fork4.9k
Commit4cf948c
committed
For inplace update, send nontransactional invalidations.
The inplace update survives ROLLBACK. The inval didn't, so anotherbackend's DDL could then update the row without incorporating theinplace update. In the test this fixes, a mix of CREATE INDEX and ALTERTABLE resulted in a table with an index, yet relhasindex=f. That is asource of index corruption. Back-patch to v12 (all supported versions).The back branch versions don't change WAL, because those branches justadded end-of-recovery SIResetAll(). All branches change the ABI ofextern function PrepareToInvalidateCacheTuple(). No PGXN extensioncalls that, and there's no apparent use case in extensions.Reviewed by Nitin Motiani and (in earlier versions) Andres Freund.Discussion:https://postgr.es/m/20240523000548.58.nmisch@google.com1 parentda99504 commit4cf948c
File tree
11 files changed
+289
-117
lines changed- src
- backend
- access
- heap
- transam
- catalog
- replication/logical
- utils/cache
- include/utils
- test/isolation
- expected
- specs
11 files changed
+289
-117
lines changedLines changed: 36 additions & 7 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
6142 | 6142 |
| |
6143 | 6143 |
| |
6144 | 6144 |
| |
| 6145 | + | |
| 6146 | + | |
| 6147 | + | |
| 6148 | + | |
| 6149 | + | |
| 6150 | + | |
| 6151 | + | |
| 6152 | + | |
| 6153 | + | |
| 6154 | + | |
| 6155 | + | |
| 6156 | + | |
| 6157 | + | |
| 6158 | + | |
| 6159 | + | |
| 6160 | + | |
| 6161 | + | |
| 6162 | + | |
6145 | 6163 |
| |
6146 | 6164 |
| |
6147 | 6165 |
| |
| |||
6185 | 6203 |
| |
6186 | 6204 |
| |
6187 | 6205 |
| |
| 6206 | + | |
| 6207 | + | |
| 6208 | + | |
| 6209 | + | |
| 6210 | + | |
| 6211 | + | |
| 6212 | + | |
| 6213 | + | |
| 6214 | + | |
| 6215 | + | |
| 6216 | + | |
| 6217 | + | |
6188 | 6218 |
| |
| 6219 | + | |
6189 | 6220 |
| |
6190 |
| - | |
| 6221 | + | |
6191 | 6222 |
| |
6192 | 6223 |
| |
6193 |
| - | |
6194 |
| - | |
6195 |
| - | |
6196 |
| - | |
6197 |
| - | |
6198 |
| - | |
| 6224 | + | |
| 6225 | + | |
| 6226 | + | |
| 6227 | + | |
6199 | 6228 |
| |
6200 | 6229 |
| |
6201 | 6230 |
| |
|
Lines changed: 18 additions & 8 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
1247 | 1247 |
| |
1248 | 1248 |
| |
1249 | 1249 |
| |
1250 |
| - | |
1251 |
| - | |
1252 |
| - | |
1253 |
| - | |
1254 |
| - | |
1255 |
| - | |
1256 |
| - | |
1257 |
| - | |
| 1250 | + | |
| 1251 | + | |
| 1252 | + | |
| 1253 | + | |
| 1254 | + | |
| 1255 | + | |
| 1256 | + | |
| 1257 | + | |
| 1258 | + | |
| 1259 | + | |
| 1260 | + | |
| 1261 | + | |
| 1262 | + | |
| 1263 | + | |
| 1264 | + | |
| 1265 | + | |
| 1266 | + | |
| 1267 | + | |
1258 | 1268 |
| |
1259 | 1269 |
| |
1260 | 1270 |
| |
|
Lines changed: 9 additions & 2 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
2881 | 2881 |
| |
2882 | 2882 |
| |
2883 | 2883 |
| |
2884 |
| - | |
| 2884 | + | |
2885 | 2885 |
| |
2886 | 2886 |
| |
2887 | 2887 |
| |
2888 | 2888 |
| |
2889 |
| - | |
| 2889 | + | |
| 2890 | + | |
| 2891 | + | |
| 2892 | + | |
| 2893 | + | |
| 2894 | + | |
| 2895 | + | |
| 2896 | + | |
2890 | 2897 |
| |
2891 | 2898 |
| |
2892 | 2899 |
| |
|
Lines changed: 11 additions & 15 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
463 | 463 |
| |
464 | 464 |
| |
465 | 465 |
| |
466 |
| - | |
467 |
| - | |
468 |
| - | |
| 466 | + | |
| 467 | + | |
| 468 | + | |
| 469 | + | |
| 470 | + | |
| 471 | + | |
| 472 | + | |
| 473 | + | |
469 | 474 |
| |
470 |
| - | |
471 |
| - | |
472 |
| - | |
473 |
| - | |
474 |
| - | |
475 |
| - | |
476 |
| - | |
| 475 | + | |
| 476 | + | |
| 477 | + | |
477 | 478 |
| |
478 |
| - | |
479 |
| - | |
480 |
| - | |
481 |
| - | |
482 |
| - | |
483 | 479 |
| |
484 | 480 |
| |
485 | 481 |
| |
|
Lines changed: 4 additions & 3 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
2128 | 2128 |
| |
2129 | 2129 |
| |
2130 | 2130 |
| |
2131 |
| - | |
| 2131 | + | |
| 2132 | + | |
2132 | 2133 |
| |
2133 | 2134 |
| |
2134 | 2135 |
| |
| |||
2169 | 2170 |
| |
2170 | 2171 |
| |
2171 | 2172 |
| |
2172 |
| - | |
| 2173 | + | |
2173 | 2174 |
| |
2174 | 2175 |
| |
2175 | 2176 |
| |
| |||
2178 | 2179 |
| |
2179 | 2180 |
| |
2180 | 2181 |
| |
2181 |
| - | |
| 2182 | + | |
2182 | 2183 |
| |
2183 | 2184 |
| |
2184 | 2185 |
| |
|
0 commit comments
Comments
(0)