Commit c7aeecd
[SPARK-3948][Shuffle]Fix stream corruption bug in sort-based shuffle
Kernel 2.6.32 bug will lead to unexpected behavior of transferTo in copyStream, and this will corrupt the shuffle output file in sort-based shuffle, which will somehow introduce PARSING_ERROR(2), deserialization error or offset out of range. Here fix this by adding append flag, also add some position checking code. Details can be seen in [SPARK-3948](https://issues.apache.org/jira/browse/SPARK-3948).
Author: jerryshao <[email protected]>
Closes #2824 from jerryshao/SPARK-3948 and squashes the following commits:
be0533a [jerryshao] Address the comments
a82b184 [jerryshao] add configuration to control the NIO way of copying stream
e17ada2 [jerryshao] Fix kernel 2.6.32 bug led unexpected behavior of transferTo1 parent d1966f3 commit c7aeecd
File tree
2 files changed
+28
-6
lines changed- core/src/main/scala/org/apache/spark/util
- collection
2 files changed
+28
-6
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
269 | 269 | | |
270 | 270 | | |
271 | 271 | | |
272 | | - | |
| 272 | + | |
| 273 | + | |
| 274 | + | |
| 275 | + | |
273 | 276 | | |
274 | 277 | | |
275 | | - | |
| 278 | + | |
| 279 | + | |
276 | 280 | | |
277 | 281 | | |
278 | 282 | | |
279 | | - | |
| 283 | + | |
| 284 | + | |
280 | 285 | | |
281 | 286 | | |
282 | 287 | | |
| 288 | + | |
283 | 289 | | |
284 | 290 | | |
285 | 291 | | |
286 | 292 | | |
287 | 293 | | |
288 | 294 | | |
| 295 | + | |
| 296 | + | |
| 297 | + | |
| 298 | + | |
| 299 | + | |
| 300 | + | |
| 301 | + | |
| 302 | + | |
| 303 | + | |
| 304 | + | |
| 305 | + | |
| 306 | + | |
| 307 | + | |
| 308 | + | |
| 309 | + | |
289 | 310 | | |
290 | 311 | | |
291 | 312 | | |
| |||
727 | 748 | | |
728 | 749 | | |
729 | 750 | | |
730 | | - | |
| 751 | + | |
731 | 752 | | |
732 | 753 | | |
733 | 754 | | |
| |||
Lines changed: 3 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
93 | 93 | | |
94 | 94 | | |
95 | 95 | | |
| 96 | + | |
96 | 97 | | |
97 | 98 | | |
98 | 99 | | |
| |||
705 | 706 | | |
706 | 707 | | |
707 | 708 | | |
708 | | - | |
| 709 | + | |
709 | 710 | | |
710 | 711 | | |
711 | | - | |
| 712 | + | |
712 | 713 | | |
713 | 714 | | |
714 | 715 | | |
| |||
0 commit comments