-
Notifications
You must be signed in to change notification settings - Fork 290
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Provides ExitCode Shutdowner Option; and Wait method to receive it. (#…
…989) This PR provides an option for those who take dependencies on the `Shutdowner` interface to call the `Shutdown` method with an `ExitCode` option, in addition it add a `Wait` method to the application to allow for main programs to wait for the application to be shutdown and to exit with a given exit code. Please note that this PR refactors the existing signal relay functionality, and alters application lifecycle slightly. Now `Done` will not receive an `os.Signal` on the channel it returns _unless_ a given FX application has been started. Co-authored-by: Sung Yoon Whang <[email protected]>
- Loading branch information
1 parent
94f1a09
commit b379e13
Showing
7 changed files
with
377 additions
and
39 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
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
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
Oops, something went wrong.