|
3 | 3 |
|
4 | 4 | import { AppConfigurationClient, ConfigurationSetting, ConfigurationSettingId, GetConfigurationSettingOptions, GetConfigurationSettingResponse, ListConfigurationSettingsOptions, featureFlagPrefix, isFeatureFlag } from "@azure/app-configuration"; |
5 | 5 | import { isRestError } from "@azure/core-rest-pipeline"; |
6 | | -import { AzureAppConfiguration, ConfigurationObjectConstructionOptions } from "./AzureAppConfiguration"; |
7 | | -import { AzureAppConfigurationOptions } from "./AzureAppConfigurationOptions"; |
8 | | -import { IKeyValueAdapter } from "./IKeyValueAdapter"; |
9 | | -import { JsonKeyValueAdapter } from "./JsonKeyValueAdapter"; |
10 | | -import { DEFAULT_REFRESH_INTERVAL_IN_MS, MIN_REFRESH_INTERVAL_IN_MS } from "./RefreshOptions"; |
11 | | -import { Disposable } from "./common/disposable"; |
12 | | -import { FEATURE_FLAGS_KEY_NAME, FEATURE_MANAGEMENT_KEY_NAME, TELEMETRY_KEY_NAME, ENABLED_KEY_NAME, METADATA_KEY_NAME, ETAG_KEY_NAME, FEATURE_FLAG_ID_KEY_NAME, FEATURE_FLAG_REFERENCE_KEY_NAME } from "./featureManagement/constants"; |
13 | | -import { AzureKeyVaultKeyValueAdapter } from "./keyvault/AzureKeyVaultKeyValueAdapter"; |
14 | | -import { RefreshTimer } from "./refresh/RefreshTimer"; |
15 | | -import { getConfigurationSettingWithTrace, listConfigurationSettingsWithTrace, requestTracingEnabled } from "./requestTracing/utils"; |
16 | | -import { KeyFilter, LabelFilter, SettingSelector } from "./types"; |
| 6 | +import { AzureAppConfiguration, ConfigurationObjectConstructionOptions } from "./AzureAppConfiguration.js"; |
| 7 | +import { AzureAppConfigurationOptions } from "./AzureAppConfigurationOptions.js"; |
| 8 | +import { IKeyValueAdapter } from "./IKeyValueAdapter.js"; |
| 9 | +import { JsonKeyValueAdapter } from "./JsonKeyValueAdapter.js"; |
| 10 | +import { DEFAULT_REFRESH_INTERVAL_IN_MS, MIN_REFRESH_INTERVAL_IN_MS } from "./RefreshOptions.js"; |
| 11 | +import { Disposable } from "./common/disposable.js"; |
| 12 | +import { FEATURE_FLAGS_KEY_NAME, FEATURE_MANAGEMENT_KEY_NAME, TELEMETRY_KEY_NAME, ENABLED_KEY_NAME, METADATA_KEY_NAME, ETAG_KEY_NAME, FEATURE_FLAG_ID_KEY_NAME, FEATURE_FLAG_REFERENCE_KEY_NAME } from "./featureManagement/constants.js"; |
| 13 | +import { AzureKeyVaultKeyValueAdapter } from "./keyvault/AzureKeyVaultKeyValueAdapter.js"; |
| 14 | +import { RefreshTimer } from "./refresh/RefreshTimer.js"; |
| 15 | +import { getConfigurationSettingWithTrace, listConfigurationSettingsWithTrace, requestTracingEnabled } from "./requestTracing/utils.js"; |
| 16 | +import { KeyFilter, LabelFilter, SettingSelector } from "./types.js"; |
17 | 17 |
|
18 | 18 | type PagedSettingSelector = SettingSelector & { |
19 | 19 | /** |
@@ -66,7 +66,7 @@ export class AzureAppConfigurationImpl implements AzureAppConfiguration { |
66 | 66 | this.#options = options; |
67 | 67 |
|
68 | 68 | // Enable request tracing if not opt-out |
69 | | - this.#requestTracingEnabled = requestTracingEnabled(); |
| 69 | + this.#requestTracingEnabled = options?.requestTracingOptions?.enabled ?? requestTracingEnabled(); |
70 | 70 |
|
71 | 71 | if (options?.trimKeyPrefixes) { |
72 | 72 | this.#sortedTrimKeyPrefixes = [...options.trimKeyPrefixes].sort((a, b) => b.localeCompare(a)); |
@@ -143,19 +143,19 @@ export class AzureAppConfigurationImpl implements AzureAppConfiguration { |
143 | 143 | return this.#configMap.size; |
144 | 144 | } |
145 | 145 |
|
146 | | - entries(): IterableIterator<[string, any]> { |
| 146 | + entries(): MapIterator<[string, any]> { |
147 | 147 | return this.#configMap.entries(); |
148 | 148 | } |
149 | 149 |
|
150 | | - keys(): IterableIterator<string> { |
| 150 | + keys(): MapIterator<string> { |
151 | 151 | return this.#configMap.keys(); |
152 | 152 | } |
153 | 153 |
|
154 | | - values(): IterableIterator<any> { |
| 154 | + values(): MapIterator<any> { |
155 | 155 | return this.#configMap.values(); |
156 | 156 | } |
157 | 157 |
|
158 | | - [Symbol.iterator](): IterableIterator<[string, any]> { |
| 158 | + [Symbol.iterator](): MapIterator<[string, any]> { |
159 | 159 | return this.#configMap[Symbol.iterator](); |
160 | 160 | } |
161 | 161 | // #endregion |
|
0 commit comments