Commit ed66505
committed
ccl/cdc: change when drop column is detected in schema feed
Previously, before automatic schema_locked toggle was added in the
declarative schema changer, we had a guarantee that schema_locked would
be unset before any column mutations are added. Unfortunately, the
automatic toggle logic will disable schema_locked at the same time as
the column is removed. This doesn't play nice with the existing schema
feed logic. To address this, this patch detects the mutation once the
new primary index is backfilled, so that is separate from the
schema_locked being disabled. This is still valid behavior because the
schema change is still in flight at this point, and doesn't have a
usable new primary index.
Informs: #150003
Release note (bug fix): Addressed a bug on schema_locked tables when a
column is dropped, and schema_locked is toggled for the user.1 parent 99d44a0 commit ed66505
File tree
3 files changed
+86
-6
lines changed- pkg/ccl/changefeedccl
- schemafeed
- testdata
3 files changed
+86
-6
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2180 | 2180 | | |
2181 | 2181 | | |
2182 | 2182 | | |
| 2183 | + | |
| 2184 | + | |
| 2185 | + | |
| 2186 | + | |
| 2187 | + | |
| 2188 | + | |
| 2189 | + | |
| 2190 | + | |
| 2191 | + | |
| 2192 | + | |
| 2193 | + | |
| 2194 | + | |
| 2195 | + | |
| 2196 | + | |
| 2197 | + | |
| 2198 | + | |
| 2199 | + | |
| 2200 | + | |
| 2201 | + | |
| 2202 | + | |
| 2203 | + | |
| 2204 | + | |
| 2205 | + | |
| 2206 | + | |
| 2207 | + | |
| 2208 | + | |
| 2209 | + | |
| 2210 | + | |
| 2211 | + | |
| 2212 | + | |
| 2213 | + | |
| 2214 | + | |
| 2215 | + | |
| 2216 | + | |
| 2217 | + | |
| 2218 | + | |
| 2219 | + | |
| 2220 | + | |
| 2221 | + | |
| 2222 | + | |
| 2223 | + | |
| 2224 | + | |
| 2225 | + | |
| 2226 | + | |
| 2227 | + | |
| 2228 | + | |
| 2229 | + | |
| 2230 | + | |
2183 | 2231 | | |
2184 | 2232 | | |
2185 | 2233 | | |
| |||
3203 | 3251 | | |
3204 | 3252 | | |
3205 | 3253 | | |
3206 | | - | |
| 3254 | + | |
3207 | 3255 | | |
3208 | 3256 | | |
3209 | 3257 | | |
| |||
3256 | 3304 | | |
3257 | 3305 | | |
3258 | 3306 | | |
3259 | | - | |
| 3307 | + | |
3260 | 3308 | | |
3261 | 3309 | | |
3262 | 3310 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
188 | 188 | | |
189 | 189 | | |
190 | 190 | | |
| 191 | + | |
| 192 | + | |
| 193 | + | |
| 194 | + | |
| 195 | + | |
| 196 | + | |
| 197 | + | |
| 198 | + | |
| 199 | + | |
| 200 | + | |
| 201 | + | |
| 202 | + | |
| 203 | + | |
| 204 | + | |
| 205 | + | |
| 206 | + | |
| 207 | + | |
| 208 | + | |
| 209 | + | |
| 210 | + | |
191 | 211 | | |
192 | 212 | | |
193 | 213 | | |
| |||
212 | 232 | | |
213 | 233 | | |
214 | 234 | | |
215 | | - | |
| 235 | + | |
| 236 | + | |
| 237 | + | |
| 238 | + | |
| 239 | + | |
| 240 | + | |
| 241 | + | |
216 | 242 | | |
217 | 243 | | |
218 | 244 | | |
| |||
273 | 299 | | |
274 | 300 | | |
275 | 301 | | |
276 | | - | |
| 302 | + | |
| 303 | + | |
| 304 | + | |
| 305 | + | |
| 306 | + | |
| 307 | + | |
| 308 | + | |
277 | 309 | | |
278 | 310 | | |
279 | 311 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
12 | 12 | | |
13 | 13 | | |
14 | 14 | | |
15 | | - | |
| 15 | + | |
16 | 16 | | |
17 | 17 | | |
18 | 18 | | |
19 | | - | |
| 19 | + | |
20 | 20 | | |
21 | 21 | | |
22 | 22 | | |
| |||
0 commit comments