Skip to content

Commit 1a023af

Browse files
update
1 parent 83d4499 commit 1a023af

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

src/ConfigurationClientManager.ts

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,6 @@ import { AzureAppConfigurationOptions, MaxRetries, MaxRetryDelayInMs } from "./A
88
import { isBrowser, isWebWorker } from "./requestTracing/utils.js";
99
import * as RequestTracing from "./requestTracing/constants.js";
1010
import { shuffleList } from "./common/utils.js";
11-
import { Resolver } from "dns/promises";
1211

1312
const TCP_ORIGIN_KEY_NAME = "_origin._tcp";
1413
const ALT_KEY_NAME = "_alt";
@@ -181,7 +180,7 @@ export class ConfigurationClientManager {
181180

182181
try {
183182
// https://nodejs.org/api/dns.html#dnspromisesresolvesrvhostname
184-
const resolver = new Resolver({timeout: DNS_RESOLVER_TIMEOUT, tries: DNS_RESOLVER_TRIES});
183+
const resolver = new this.#dns.Resolver({timeout: DNS_RESOLVER_TIMEOUT, tries: DNS_RESOLVER_TRIES});
185184
// On success, resolveSrv() returns an array of SrvRecord
186185
// On failure, resolveSrv() throws an error with code 'ENOTFOUND'.
187186
const originRecords = await resolver.resolveSrv(`${TCP_ORIGIN_KEY_NAME}.${host}`); // look up SRV records for the origin host

0 commit comments

Comments
 (0)