Skip to content
Snippets Groups Projects
Commit 4261e834 authored by Aaron Davidson's avatar Aaron Davidson
Browse files

Use flag instead of name check.

parent 596f1847
No related branches found
No related tags found
No related merge requests found
......@@ -523,8 +523,7 @@ private[spark] class BlockManager(
val file = diskBlockManager.createBlockFile(blockId, filename, allowAppending = true)
val writer = new DiskBlockObjectWriter(blockId, file, serializer, bufferSize, compressStream)
writer.registerCloseEventHandler(() => {
if (blockId.name != filename) {
// Avoid producing mappings if we're using unique filenames for blocks.
if (shuffleBlockManager.consolidateShuffleFiles) {
diskBlockManager.mapBlockToFileSegment(blockId, writer.fileSegment())
}
val myInfo = new BlockInfo(StorageLevel.DISK_ONLY, false)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment