Skip to content
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

When running in parallel/fork mode, properly clean temporary directories #152

Merged
merged 16 commits into from
Oct 18, 2017

Conversation

kpaulisse
Copy link
Contributor

@kpaulisse kpaulisse commented Oct 11, 2017

This PR addresses the problem reported in #146 by eliminating the use of at_exit within parallelized/forked processes. The new design ensures that the temporary directories are properly cleaned, whether parallelization is enabled or not.

Serial execution:

  • (TASK: (create temp dir) (do its thing) (remove temp dir at exit))
  • (TASK: (create temp dir) (do its thing) (remove temp dir at exit))
  • (TASK: (create temp dir) (do its thing) (remove temp dir at exit))
  • at_exit: Remove temp dirs

Parallel execution:

  • Create temp dir
  • Parallel/fork:
    • Task that uses temp dir
    • Task that uses temp dir
    • Task that uses temp dir
  • Clean up temp dir

@kpaulisse kpaulisse mentioned this pull request Oct 18, 2017
@kpaulisse kpaulisse merged commit c444859 into master Oct 18, 2017
@kpaulisse kpaulisse deleted the kpaulisse-parallel-tmpdir-cleans branch October 18, 2017 13:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant