-
Notifications
You must be signed in to change notification settings - Fork 119
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Terminate
Riemann::Tools::HttpCheck
threads between tests
Under normal operation, we have a single instance of the `Riemann::Tools::HttpCheck` class for the lifetime of the monitoring process. But when testing, we create a new instance for each test, each with its resolvers and worker thread pools. The test process will have more and more threads, until it eventually hit the OS limit of the maximum number of threads for a process and cause an exception: > ThreadError: can't create Thread: Resource temporarily unavailable Make sure that the threads are terminated at the end of each test to avoid running out of resources if they are limited.
- Loading branch information
Showing
2 changed files
with
30 additions
and
2 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