-
Notifications
You must be signed in to change notification settings - Fork 110
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
node: perform DNS lookup with timeout
Passed the hostname_resolution_timeout down to the functions responsible for DNS resolution logic. Created a pub(crate) error type to distinguish between errors that can occur during hostname resolution. Notice: it's pub(crate) since the users of this API only emit logs in case of error. The errors are not passed to public API. Created a `lookup_host_with_timeout` function, and extracted some logic here. The purpose is not to introduce complex branching in original function.
- Loading branch information
Showing
3 changed files
with
50 additions
and
15 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