-
Notifications
You must be signed in to change notification settings - Fork 22
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Use a fiber rather than a thread to implement
clean_fork
It has several advantages, first we only need to copy fiber locals, actual thread local variables are preserved. Additionally any code using `Thread.current` as a hash key won't be impacted. And finally, native gems using APIs such a `pthread_atfork(3)` won't be impacted either, as the native thread will remain the same in the child.
- Loading branch information
Showing
2 changed files
with
10 additions
and
12 deletions.
There are no files selected for viewing
This file contains 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
This file contains 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