GitHub user JoshRosen opened a pull request:

    https://github.com/apache/spark/pull/15104

    [SPARK-17547] Ensure temp shuffle data file is cleaned up after error

    SPARK-8029 (#9610) modified shuffle writers to first stage their data to a 
temporary file in the same directory as the final destination file and then to 
atomically rename this temporary file at the end of the write job. However, 
this change introduced the potential for the temporary output file to be leaked 
if an exception occurs during the write because the shuffle writers' existing 
error cleanup code doesn't handle deletion of the temp file.
    
    This patch avoids this potential cause of disk-space leaks by adding 
`finally` blocks to ensure that temp files are always deleted if they haven't 
been renamed.
    
    /cc @davies @ericl @srinathshankar

You can merge this pull request into a Git repository by running:

    $ git pull https://github.com/JoshRosen/spark 
cleanup-tmp-data-file-in-shuffle-writer

Alternatively you can review and apply these changes as the patch at:

    https://github.com/apache/spark/pull/15104.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

    This closes #15104
    
----
commit ac90c397064a2067b5d11f40e95a31f842308fbd
Author: Josh Rosen <joshro...@databricks.com>
Date:   2016-09-14T21:45:27Z

    Ensure temp shuffle data file is cleaned up after error

----


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---

---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org
For additional commands, e-mail: reviews-h...@spark.apache.org

Reply via email to