-
Notifications
You must be signed in to change notification settings - Fork 29k
[SPARK-28209][CORE][SHUFFLE] Proposed new shuffle writer API #25007
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Closed
Closed
Changes from 1 commit
Commits
Show all changes
33 commits
Select commit
Hold shift + click to select a range
1957e82
[SPARK-25299] Introduce the new shuffle writer API (#5) (#520)
mccheah 857552a
[SPARK-25299] Local shuffle implementation of the shuffle writer API …
mccheah d13037f
[SPARK-25299] Make UnsafeShuffleWriter use the new API (#536)
mccheah 8f5fb60
[SPARK-25299] Use the shuffle writer plugin for the SortShuffleWriter…
mccheah e17c7ea
[SPARK-25299] Shuffle locations api (#517)
mccheah 3f0c131
[SPARK-25299] Move shuffle writers back to being given specific parti…
mccheah f982df7
[SPARK-25299] Don't set map status twice in bypass merge sort shuffle…
mccheah 6891197
[SPARK-25299] Propose a new NIO transfer API for partition writing. (…
mccheah 7b44ed2
Remove shuffle location support.
mccheah df75f1f
Remove changes to UnsafeShuffleWriter
mccheah a8558af
Revert changes for SortShuffleWriter
mccheah 806d7bb
Revert a bunch of other stuff
mccheah 3167030
More reverts
mccheah 70f59db
Set task contexts in failing test
mccheah 3083d86
Fix style
mccheah 4c3d692
Check for null on the block manager as well.
mccheah 2421c92
Add task attempt id in the APIs
mccheah 982f207
Address comments
mccheah 594d1e2
Fix style
mccheah 66aae91
Address comments.
mccheah 8b432f9
Merge remote-tracking branch 'origin/master' into spark-shuffle-write…
mccheah 9f597dd
Address comments.
mccheah 86c1829
Restructure test
mccheah a7885ae
Add ShuffleWriteMetricsReporter to the createMapOutputWriter API.
mccheah 9893c6c
Add more documentation
mccheah cd897e7
REfactor reading records from file in test
mccheah 9f17b9b
Address comments
mccheah e53a001
Code tags
mccheah 56fa450
Add some docs
mccheah b8b7b8d
Change mockito format in BypassMergeSortShuffleWriterSuite
mccheah 2d29404
Remove metrics from the API.
mccheah 06ea01a
Address more comments.
mccheah 7dceec9
Args per line
mccheah File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Add some docs
- Loading branch information
commit 56fa450b4d703c7bc34f338e2ed0cd21fc82a98c
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actually I'm not sure this is true, if the goal is to actually provide an optimization. In that case, the default implementation is only sufficient if your stream is a
FileInputStream(just checked whatChannels.newChannel()does).Otherwise, the wrapper created will copy data into user memory, basically negating the optimization.
(Which maybe is an argument for returning
nullhere and falling back to the normal IO path when that happens.)There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What we're saying is that this kind of low-level optimization isn't the first place to look to improve performance most of the time, so to speak. So if one has to do the optimization, they should provide the proper override, but, the specific optimization isn't a critical factor to consider outside of the local disk implementation.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
So why not follow my suggestion and return
nullhere by default? It makes it much more clear that this implementation is not needed, and that by default the non-nio path is used.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It's primarily to avoid returning
nullfrom the API - in that case I'd rather returnOptional, thenOptional.empty.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sure. The main thing is returning something that indicates that this feature is not supported, instead of by default wrapping things a way that might actually hurt performance.