Commit 5a25b05
[SPARK-54358][SDP] Checkpoint dirs collide when streaming tables in different schemas have same name
### What changes were proposed in this pull request?
Updates the per-streaming table checkpoint path to use the fully qualified table path, instead of just its name.
### Why are the changes needed?
A streaming table is a table fed by a stream. Streaming tables have checkpoint directories underneath their pipeline's storage root. These directories don't currently take the table namespace into account, which means that two tables with different schemas but the same name will be mapped to the same checkpoint directory. This could be very bad and cause data loss.
### Does this PR introduce _any_ user-facing change?
Yes, but for an unreleased feature.
### How was this patch tested?
Added a test for the collision case. Verified that it fails with the prior logic and now passes.
### Was this patch authored or co-authored using generative AI tooling?
Closes #53070 from sryza/collide.
Authored-by: Sandy Ryza <sandy.ryza@databricks.com>
Signed-off-by: Dongjoon Hyun <dongjoon@apache.org>
(cherry picked from commit e09c999)
Signed-off-by: Dongjoon Hyun <dongjoon@apache.org>1 parent 724ef24 commit 5a25b05
File tree
2 files changed
+37
-4
lines changed- sql/pipelines/src
- main/scala/org/apache/spark/sql/pipelines/graph
- test/scala/org/apache/spark/sql/pipelines/graph
2 files changed
+37
-4
lines changedLines changed: 3 additions & 3 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
40 | 40 | | |
41 | 41 | | |
42 | 42 | | |
43 | | - | |
| 43 | + | |
44 | 44 | | |
45 | 45 | | |
46 | 46 | | |
47 | | - | |
| 47 | + | |
48 | 48 | | |
49 | 49 | | |
50 | | - | |
| 50 | + | |
51 | 51 | | |
52 | 52 | | |
53 | 53 | | |
| |||
Lines changed: 34 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
227 | 227 | | |
228 | 228 | | |
229 | 229 | | |
| 230 | + | |
| 231 | + | |
| 232 | + | |
| 233 | + | |
| 234 | + | |
| 235 | + | |
| 236 | + | |
| 237 | + | |
| 238 | + | |
| 239 | + | |
| 240 | + | |
| 241 | + | |
| 242 | + | |
| 243 | + | |
| 244 | + | |
| 245 | + | |
| 246 | + | |
| 247 | + | |
| 248 | + | |
| 249 | + | |
| 250 | + | |
| 251 | + | |
| 252 | + | |
| 253 | + | |
| 254 | + | |
| 255 | + | |
| 256 | + | |
| 257 | + | |
| 258 | + | |
| 259 | + | |
| 260 | + | |
| 261 | + | |
230 | 262 | | |
231 | 263 | | |
232 | 264 | | |
| |||
242 | 274 | | |
243 | 275 | | |
244 | 276 | | |
| 277 | + | |
245 | 278 | | |
246 | | - | |
| 279 | + | |
247 | 280 | | |
248 | 281 | | |
249 | 282 | | |
| |||
0 commit comments