-
Notifications
You must be signed in to change notification settings - Fork 247
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Replaced os.Exit with RemoteWeavelet Wait method. (#531)
Recall that a RemoteWeavelet maintains (1) an RPC server to serve remote component method calls from other weavelets and (2) a connection to the envelope. Before this PR, a RemoteWeavelet would os.Exit if either (1) or (2) went down. This made testing failure scenarios impossible, as the process would simply exit. This PR removes the calls to os.Exit. Instead, I added a Wait method to the RemoteWeavelet that blocks until the weavelet has shut down and returns any errors encountered during shutdown. With this new Wait method, I was able to add a unit test to test the behavior of a weavelet when its connection to the envelope breaks.
- Loading branch information
1 parent
958fbf7
commit e11bbb2
Showing
9 changed files
with
107 additions
and
48 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
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.