Fix DNS resolution race condition.

Pulling in from
https://github.com/NREL/api-umbrella-gatekeeper/commit/dc73bae549b9db40dcc144de53a87f054f5919c9