-
Notifications
You must be signed in to change notification settings - Fork 1.6k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Remove the watcher's dependency on SIGHUP / unix
Right now the watcher is broken/unimplemented for Windows and a large part of the reason for that might be how it works: * the watcher subscribes to filesystem events (crate: notify) * the watcher raises a unix signal (SIGHUP) on detecting changes * the signal handler (again, unix only) reacts to SIGHUP with an internal reload signal * (vector magically reloads/compares the configs) With these changes that unix signal dependency is removed * the watcher clones a SignalTx to emit its very own signals * the watcher sends an internal reload signal on detecting changes * (vector magically reloads/compares the configs) All of this _should_ also work on Windows, has nothing to do with unix signals anymore. I slightly modified the tests to not just wait for any Ok, but to state explicitly what signal we expect to receive. Cargo fmt
- Loading branch information
Showing
2 changed files
with
38 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