@aws-sdk/middleware-endpoint-discovery 3.35.0 → 3.36.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +11 -0
- package/dist-cjs/configurations.js +0 -1
- package/dist-cjs/endpointDiscoveryMiddleware.js +0 -1
- package/dist-cjs/getCacheKey.js +0 -1
- package/dist-cjs/getEndpointDiscoveryPlugin.js +0 -1
- package/dist-cjs/index.js +0 -1
- package/dist-cjs/resolveEndpointDiscoveryConfig.js +0 -1
- package/dist-cjs/updateDiscoveredEndpointInCache.js +0 -1
- package/dist-es/configurations.js +0 -1
- package/dist-es/endpointDiscoveryMiddleware.js +0 -1
- package/dist-es/getCacheKey.js +0 -1
- package/dist-es/getEndpointDiscoveryPlugin.js +0 -1
- package/dist-es/index.js +0 -1
- package/dist-es/resolveEndpointDiscoveryConfig.js +0 -1
- package/dist-es/updateDiscoveredEndpointInCache.js +0 -1
- package/package.json +9 -6
- package/jest.config.js +0 -5
- package/src/configurations.spec.ts +0 -85
- package/src/configurations.ts +0 -32
- package/src/endpointDiscoveryMiddleware.spec.ts +0 -145
- package/src/endpointDiscoveryMiddleware.ts +0 -72
- package/src/getCacheKey.spec.ts +0 -32
- package/src/getCacheKey.ts +0 -24
- package/src/getEndpointDiscoveryPlugin.spec.ts +0 -32
- package/src/getEndpointDiscoveryPlugin.ts +0 -57
- package/src/index.ts +0 -3
- package/src/resolveEndpointDiscoveryConfig.spec.ts +0 -63
- package/src/resolveEndpointDiscoveryConfig.ts +0 -73
- package/src/updateDiscoveredEndpointInCache.spec.ts +0 -172
- package/src/updateDiscoveredEndpointInCache.ts +0 -88
- package/tsconfig.cjs.json +0 -9
- package/tsconfig.cjs.tsbuildinfo +0 -1
- package/tsconfig.es.json +0 -10
- package/tsconfig.es.tsbuildinfo +0 -1
- package/tsconfig.types.json +0 -9
- package/tsconfig.types.tsbuildinfo +0 -1
package/src/getCacheKey.ts
DELETED
|
@@ -1,24 +0,0 @@
|
|
|
1
|
-
import { Credentials, Provider } from "@aws-sdk/types";
|
|
2
|
-
|
|
3
|
-
/**
|
|
4
|
-
* Generate key to index the endpoints in the cache
|
|
5
|
-
*/
|
|
6
|
-
export const getCacheKey = async (
|
|
7
|
-
commandName: string,
|
|
8
|
-
config: { credentials: Provider<Credentials> },
|
|
9
|
-
options: {
|
|
10
|
-
identifiers?: { [key: string]: string };
|
|
11
|
-
}
|
|
12
|
-
) => {
|
|
13
|
-
const { accessKeyId } = await config.credentials();
|
|
14
|
-
const { identifiers } = options;
|
|
15
|
-
return JSON.stringify({
|
|
16
|
-
...(accessKeyId && { accessKeyId }),
|
|
17
|
-
...(identifiers && {
|
|
18
|
-
commandName,
|
|
19
|
-
identifiers: Object.entries(identifiers)
|
|
20
|
-
.sort()
|
|
21
|
-
.reduce((acc, [key, value]) => ({ ...acc, [key]: value }), {}),
|
|
22
|
-
}),
|
|
23
|
-
});
|
|
24
|
-
};
|
|
@@ -1,32 +0,0 @@
|
|
|
1
|
-
import { endpointDiscoveryMiddleware } from "./endpointDiscoveryMiddleware";
|
|
2
|
-
import { endpointDiscoveryMiddlewareOptions, getEndpointDiscoveryPlugin } from "./getEndpointDiscoveryPlugin";
|
|
3
|
-
|
|
4
|
-
jest.mock("./endpointDiscoveryMiddleware");
|
|
5
|
-
|
|
6
|
-
describe(getEndpointDiscoveryPlugin.name, () => {
|
|
7
|
-
const pluginConfig = {
|
|
8
|
-
isCustomEndpoint: false,
|
|
9
|
-
endpointCache: jest.fn(),
|
|
10
|
-
endpointDiscoveryEnabled: jest.fn(),
|
|
11
|
-
isClientEndpointDiscoveryEnabled: false,
|
|
12
|
-
};
|
|
13
|
-
const middlewareConfig = {
|
|
14
|
-
isDiscoveredEndpointRequired: false,
|
|
15
|
-
};
|
|
16
|
-
|
|
17
|
-
it(`applyToStack function adds endpoint discovery middleware`, () => {
|
|
18
|
-
const middlewareReturn = {};
|
|
19
|
-
(endpointDiscoveryMiddleware as jest.Mock).mockReturnValueOnce(middlewareReturn);
|
|
20
|
-
|
|
21
|
-
// @ts-ignore
|
|
22
|
-
const plugin = getEndpointDiscoveryPlugin(pluginConfig, middlewareConfig);
|
|
23
|
-
const commandStack = { add: jest.fn() };
|
|
24
|
-
|
|
25
|
-
// @ts-ignore
|
|
26
|
-
plugin.applyToStack(commandStack);
|
|
27
|
-
expect(commandStack.add).toHaveBeenCalled();
|
|
28
|
-
expect(commandStack.add).toHaveBeenCalledWith(middlewareReturn, endpointDiscoveryMiddlewareOptions);
|
|
29
|
-
expect(endpointDiscoveryMiddleware).toHaveBeenCalled();
|
|
30
|
-
expect(endpointDiscoveryMiddleware).toHaveBeenCalledWith(pluginConfig, middlewareConfig);
|
|
31
|
-
});
|
|
32
|
-
});
|
|
@@ -1,57 +0,0 @@
|
|
|
1
|
-
import { BuildHandlerOptions, HttpHandlerOptions, MiddlewareStack, Pluggable } from "@aws-sdk/types";
|
|
2
|
-
|
|
3
|
-
import { endpointDiscoveryMiddleware } from "./endpointDiscoveryMiddleware";
|
|
4
|
-
import { EndpointDiscoveryResolvedConfig, PreviouslyResolved } from "./resolveEndpointDiscoveryConfig";
|
|
5
|
-
|
|
6
|
-
export const endpointDiscoveryMiddlewareOptions: BuildHandlerOptions = {
|
|
7
|
-
name: "endpointDiscoveryMiddleware",
|
|
8
|
-
step: "build",
|
|
9
|
-
tags: ["ENDPOINT_DISCOVERY"],
|
|
10
|
-
override: true,
|
|
11
|
-
};
|
|
12
|
-
|
|
13
|
-
export interface EndpointDiscoveryMiddlewareConfig {
|
|
14
|
-
isDiscoveredEndpointRequired: boolean;
|
|
15
|
-
clientStack: MiddlewareStack<any, any>;
|
|
16
|
-
options?: HttpHandlerOptions;
|
|
17
|
-
identifiers?: { [key: string]: string };
|
|
18
|
-
}
|
|
19
|
-
|
|
20
|
-
export const getEndpointDiscoveryPlugin = (
|
|
21
|
-
pluginConfig: EndpointDiscoveryResolvedConfig & PreviouslyResolved,
|
|
22
|
-
middlewareConfig: EndpointDiscoveryMiddlewareConfig
|
|
23
|
-
): Pluggable<any, any> => ({
|
|
24
|
-
applyToStack: (commandStack) => {
|
|
25
|
-
commandStack.add(endpointDiscoveryMiddleware(pluginConfig, middlewareConfig), endpointDiscoveryMiddlewareOptions);
|
|
26
|
-
},
|
|
27
|
-
});
|
|
28
|
-
|
|
29
|
-
/**
|
|
30
|
-
* @deprecated Use getEndpointDiscoveryPlugin
|
|
31
|
-
*/
|
|
32
|
-
export const getEndpointDiscoveryRequiredPlugin = (
|
|
33
|
-
pluginConfig: EndpointDiscoveryResolvedConfig & PreviouslyResolved,
|
|
34
|
-
middlewareConfig: Omit<EndpointDiscoveryMiddlewareConfig, "isDiscoveredEndpointRequired">
|
|
35
|
-
): Pluggable<any, any> => ({
|
|
36
|
-
applyToStack: (commandStack) => {
|
|
37
|
-
commandStack.add(
|
|
38
|
-
endpointDiscoveryMiddleware(pluginConfig, { ...middlewareConfig, isDiscoveredEndpointRequired: true }),
|
|
39
|
-
endpointDiscoveryMiddlewareOptions
|
|
40
|
-
);
|
|
41
|
-
},
|
|
42
|
-
});
|
|
43
|
-
|
|
44
|
-
/**
|
|
45
|
-
* @deprecated Use getEndpointDiscoveryPlugin
|
|
46
|
-
*/
|
|
47
|
-
export const getEndpointDiscoveryOptionalPlugin = (
|
|
48
|
-
pluginConfig: EndpointDiscoveryResolvedConfig & PreviouslyResolved,
|
|
49
|
-
middlewareConfig: Omit<EndpointDiscoveryMiddlewareConfig, "isDiscoveredEndpointRequired">
|
|
50
|
-
): Pluggable<any, any> => ({
|
|
51
|
-
applyToStack: (commandStack) => {
|
|
52
|
-
commandStack.add(
|
|
53
|
-
endpointDiscoveryMiddleware(pluginConfig, { ...middlewareConfig, isDiscoveredEndpointRequired: false }),
|
|
54
|
-
endpointDiscoveryMiddlewareOptions
|
|
55
|
-
);
|
|
56
|
-
},
|
|
57
|
-
});
|
package/src/index.ts
DELETED
|
@@ -1,63 +0,0 @@
|
|
|
1
|
-
import { EndpointCache } from "@aws-sdk/endpoint-cache";
|
|
2
|
-
|
|
3
|
-
import { resolveEndpointDiscoveryConfig } from "./resolveEndpointDiscoveryConfig";
|
|
4
|
-
|
|
5
|
-
jest.mock("@aws-sdk/endpoint-cache");
|
|
6
|
-
|
|
7
|
-
describe(resolveEndpointDiscoveryConfig.name, () => {
|
|
8
|
-
const endpointDiscoveryCommandCtor = jest.fn();
|
|
9
|
-
const mockInput = {
|
|
10
|
-
isCustomEndpoint: false,
|
|
11
|
-
credentials: jest.fn(),
|
|
12
|
-
endpointDiscoveryEnabledProvider: jest.fn(),
|
|
13
|
-
};
|
|
14
|
-
|
|
15
|
-
afterEach(() => {
|
|
16
|
-
jest.clearAllMocks();
|
|
17
|
-
});
|
|
18
|
-
|
|
19
|
-
it("assigns endpointDiscoveryCommandCtor in resolvedConfig", () => {
|
|
20
|
-
const resolvedConfig = resolveEndpointDiscoveryConfig(mockInput, { endpointDiscoveryCommandCtor });
|
|
21
|
-
expect(resolvedConfig.endpointDiscoveryCommandCtor).toStrictEqual(endpointDiscoveryCommandCtor);
|
|
22
|
-
});
|
|
23
|
-
|
|
24
|
-
describe("endpointCache", () => {
|
|
25
|
-
it("creates cache of size endpointCacheSize if passed", () => {
|
|
26
|
-
const endpointCacheSize = 100;
|
|
27
|
-
resolveEndpointDiscoveryConfig(
|
|
28
|
-
{
|
|
29
|
-
...mockInput,
|
|
30
|
-
endpointCacheSize,
|
|
31
|
-
},
|
|
32
|
-
{ endpointDiscoveryCommandCtor }
|
|
33
|
-
);
|
|
34
|
-
expect(EndpointCache).toBeCalledWith(endpointCacheSize);
|
|
35
|
-
});
|
|
36
|
-
|
|
37
|
-
it("creates cache of size 1000 if endpointCacheSize not passed", () => {
|
|
38
|
-
resolveEndpointDiscoveryConfig(mockInput, { endpointDiscoveryCommandCtor });
|
|
39
|
-
expect(EndpointCache).toBeCalledWith(1000);
|
|
40
|
-
});
|
|
41
|
-
});
|
|
42
|
-
|
|
43
|
-
describe("endpointDiscoveryEnabled", () => {
|
|
44
|
-
it.each<boolean>([false, true])(`sets to value passed in the config: %s`, (endpointDiscoveryEnabled) => {
|
|
45
|
-
const resolvedConfig = resolveEndpointDiscoveryConfig(
|
|
46
|
-
{
|
|
47
|
-
...mockInput,
|
|
48
|
-
endpointDiscoveryEnabled,
|
|
49
|
-
},
|
|
50
|
-
{ endpointDiscoveryCommandCtor }
|
|
51
|
-
);
|
|
52
|
-
expect(resolvedConfig.endpointDiscoveryEnabled()).resolves.toBe(endpointDiscoveryEnabled);
|
|
53
|
-
expect(mockInput.endpointDiscoveryEnabledProvider).not.toHaveBeenCalled();
|
|
54
|
-
expect(resolvedConfig.isClientEndpointDiscoveryEnabled).toStrictEqual(true);
|
|
55
|
-
});
|
|
56
|
-
|
|
57
|
-
it(`sets to endpointDiscoveryEnabledProvider if value is not passed`, () => {
|
|
58
|
-
const resolvedConfig = resolveEndpointDiscoveryConfig(mockInput, { endpointDiscoveryCommandCtor });
|
|
59
|
-
expect(resolvedConfig.endpointDiscoveryEnabled).toBe(mockInput.endpointDiscoveryEnabledProvider);
|
|
60
|
-
expect(resolvedConfig.isClientEndpointDiscoveryEnabled).toStrictEqual(false);
|
|
61
|
-
});
|
|
62
|
-
});
|
|
63
|
-
});
|
|
@@ -1,73 +0,0 @@
|
|
|
1
|
-
import { EndpointCache } from "@aws-sdk/endpoint-cache";
|
|
2
|
-
import { Credentials, Provider } from "@aws-sdk/types";
|
|
3
|
-
|
|
4
|
-
export interface EndpointDiscoveryInputConfig {}
|
|
5
|
-
|
|
6
|
-
export interface PreviouslyResolved {
|
|
7
|
-
isCustomEndpoint: boolean;
|
|
8
|
-
credentials: Provider<Credentials>;
|
|
9
|
-
endpointDiscoveryEnabledProvider: Provider<boolean | undefined>;
|
|
10
|
-
}
|
|
11
|
-
|
|
12
|
-
export interface EndpointDiscoveryInputConfig {
|
|
13
|
-
/**
|
|
14
|
-
* The size of the client cache storing endpoints from endpoint discovery operations.
|
|
15
|
-
* Defaults to 1000.
|
|
16
|
-
*/
|
|
17
|
-
endpointCacheSize?: number;
|
|
18
|
-
|
|
19
|
-
/**
|
|
20
|
-
* Whether to call operations with endpoints given by service dynamically.
|
|
21
|
-
* Setting this config to `true` will enable endpoint discovery for all applicable operations.
|
|
22
|
-
* Setting it to `false` will explicitly disable endpoint discovery even though operations that
|
|
23
|
-
* require endpoint discovery will presumably fail. Leaving it to undefined means SDK only do
|
|
24
|
-
* endpoint discovery when it's required. Defaults to `undefined`.
|
|
25
|
-
*/
|
|
26
|
-
endpointDiscoveryEnabled?: boolean | undefined;
|
|
27
|
-
}
|
|
28
|
-
export interface EndpointDiscoveryResolvedConfig {
|
|
29
|
-
/**
|
|
30
|
-
* LRU Cache which stores endpoints from endpoint discovery operations.
|
|
31
|
-
* The size is either provided by {@link EndpointDiscoveryInputConfig.endpointCacheSize}.
|
|
32
|
-
*/
|
|
33
|
-
endpointCache: EndpointCache;
|
|
34
|
-
|
|
35
|
-
/**
|
|
36
|
-
* The constructor of the Command used for discovering endpoints.
|
|
37
|
-
* @internal
|
|
38
|
-
*/
|
|
39
|
-
endpointDiscoveryCommandCtor: new (comandConfig: any) => any;
|
|
40
|
-
|
|
41
|
-
/**
|
|
42
|
-
* Resolved value for input config {@link EndpointDiscoveryInputConfig.endpointDiscoveryEnabled}.
|
|
43
|
-
*/
|
|
44
|
-
endpointDiscoveryEnabled: Provider<boolean | undefined>;
|
|
45
|
-
|
|
46
|
-
/**
|
|
47
|
-
* Stores whether endpoint discovery configuration is set locally by passing
|
|
48
|
-
* {@link EndpointDiscoveryInputConfig.endpointDiscoveryEnabled} during client creation.
|
|
49
|
-
* @internal
|
|
50
|
-
*/
|
|
51
|
-
isClientEndpointDiscoveryEnabled: boolean;
|
|
52
|
-
}
|
|
53
|
-
|
|
54
|
-
export interface EndpointDiscoveryConfigOptions {
|
|
55
|
-
/**
|
|
56
|
-
* The constructor of the Command used for discovering endpoints.
|
|
57
|
-
*/
|
|
58
|
-
endpointDiscoveryCommandCtor: new (comandConfig: any) => any;
|
|
59
|
-
}
|
|
60
|
-
|
|
61
|
-
export const resolveEndpointDiscoveryConfig = <T>(
|
|
62
|
-
input: T & PreviouslyResolved & EndpointDiscoveryInputConfig,
|
|
63
|
-
{ endpointDiscoveryCommandCtor }: EndpointDiscoveryConfigOptions
|
|
64
|
-
): T & EndpointDiscoveryResolvedConfig => ({
|
|
65
|
-
...input,
|
|
66
|
-
endpointDiscoveryCommandCtor,
|
|
67
|
-
endpointCache: new EndpointCache(input.endpointCacheSize ?? 1000),
|
|
68
|
-
endpointDiscoveryEnabled:
|
|
69
|
-
input.endpointDiscoveryEnabled !== undefined
|
|
70
|
-
? () => Promise.resolve(input.endpointDiscoveryEnabled)
|
|
71
|
-
: input.endpointDiscoveryEnabledProvider,
|
|
72
|
-
isClientEndpointDiscoveryEnabled: input.endpointDiscoveryEnabled !== undefined,
|
|
73
|
-
});
|
|
@@ -1,172 +0,0 @@
|
|
|
1
|
-
import { updateDiscoveredEndpointInCache } from "./updateDiscoveredEndpointInCache";
|
|
2
|
-
|
|
3
|
-
describe(updateDiscoveredEndpointInCache.name, () => {
|
|
4
|
-
const cacheKey = "cacheKey";
|
|
5
|
-
const mockGet = jest.fn();
|
|
6
|
-
const mockSet = jest.fn();
|
|
7
|
-
const mockDelete = jest.fn();
|
|
8
|
-
|
|
9
|
-
const mockHandler = jest.fn();
|
|
10
|
-
const mockResolveMiddleware = jest.fn().mockReturnValue(mockHandler);
|
|
11
|
-
|
|
12
|
-
const mockEndpoints = [{ Address: "mockAddress", CachePeriodInMinutes: 2 }];
|
|
13
|
-
const placeholderEndpoints = [{ Address: "", CachePeriodInMinutes: 1 }];
|
|
14
|
-
|
|
15
|
-
const config = {
|
|
16
|
-
endpointCache: { get: mockGet, set: mockSet, delete: mockDelete },
|
|
17
|
-
};
|
|
18
|
-
|
|
19
|
-
const options = {
|
|
20
|
-
cacheKey,
|
|
21
|
-
commandName: "ExampleCommand",
|
|
22
|
-
endpointDiscoveryCommandCtor: jest.fn().mockReturnValue({ resolveMiddleware: mockResolveMiddleware }),
|
|
23
|
-
isDiscoveredEndpointRequired: false,
|
|
24
|
-
identifiers: { key: "value" },
|
|
25
|
-
};
|
|
26
|
-
|
|
27
|
-
beforeEach(() => {
|
|
28
|
-
mockGet.mockReturnValue(mockEndpoints);
|
|
29
|
-
});
|
|
30
|
-
|
|
31
|
-
afterEach(() => {
|
|
32
|
-
jest.clearAllMocks();
|
|
33
|
-
});
|
|
34
|
-
|
|
35
|
-
it(`returns if endpoints are present in cacheKey`, async () => {
|
|
36
|
-
// @ts-ignore
|
|
37
|
-
await updateDiscoveredEndpointInCache(config, options);
|
|
38
|
-
expect(mockGet).toHaveBeenCalledWith(cacheKey);
|
|
39
|
-
expect(mockSet).not.toHaveBeenCalled();
|
|
40
|
-
expect(mockDelete).not.toHaveBeenCalled();
|
|
41
|
-
});
|
|
42
|
-
|
|
43
|
-
describe("calls endpointDiscoveryCommandCtor", () => {
|
|
44
|
-
beforeEach(() => {
|
|
45
|
-
mockGet.mockReturnValue(undefined);
|
|
46
|
-
});
|
|
47
|
-
|
|
48
|
-
const verifyCallsOnCacheUndefined = () => {
|
|
49
|
-
expect(mockGet).toHaveBeenCalledTimes(1);
|
|
50
|
-
|
|
51
|
-
expect(options.endpointDiscoveryCommandCtor).toHaveBeenCalledWith({
|
|
52
|
-
Operation: options.commandName.substr(0, options.commandName.length - 7),
|
|
53
|
-
Identifiers: options.identifiers,
|
|
54
|
-
});
|
|
55
|
-
expect(mockHandler).toHaveBeenCalledTimes(1);
|
|
56
|
-
};
|
|
57
|
-
|
|
58
|
-
it("on successful call: updates cache", async () => {
|
|
59
|
-
mockHandler.mockResolvedValueOnce({ output: { Endpoints: mockEndpoints } });
|
|
60
|
-
|
|
61
|
-
// @ts-ignore
|
|
62
|
-
await updateDiscoveredEndpointInCache(config, options);
|
|
63
|
-
|
|
64
|
-
verifyCallsOnCacheUndefined();
|
|
65
|
-
expect(mockDelete).not.toHaveBeenCalled();
|
|
66
|
-
expect(mockSet).toHaveBeenCalledTimes(2);
|
|
67
|
-
expect(mockSet).toHaveBeenNthCalledWith(1, cacheKey, placeholderEndpoints);
|
|
68
|
-
expect(mockSet).toHaveBeenNthCalledWith(2, cacheKey, mockEndpoints);
|
|
69
|
-
});
|
|
70
|
-
|
|
71
|
-
it("calls endpointDiscoveryCommandCtor command just once in case of parallel calls", async () => {
|
|
72
|
-
mockHandler.mockResolvedValueOnce({ output: { Endpoints: mockEndpoints } });
|
|
73
|
-
// First call returns undefined, while other ones return placeholder endpoints a call is in progress
|
|
74
|
-
mockGet
|
|
75
|
-
.mockReturnValueOnce(undefined)
|
|
76
|
-
.mockReturnValueOnce(placeholderEndpoints)
|
|
77
|
-
.mockReturnValueOnce(placeholderEndpoints);
|
|
78
|
-
|
|
79
|
-
await Promise.all([
|
|
80
|
-
// @ts-ignore
|
|
81
|
-
updateDiscoveredEndpointInCache(config, options),
|
|
82
|
-
// @ts-ignore
|
|
83
|
-
updateDiscoveredEndpointInCache(config, options),
|
|
84
|
-
// @ts-ignore
|
|
85
|
-
updateDiscoveredEndpointInCache(config, options),
|
|
86
|
-
]);
|
|
87
|
-
|
|
88
|
-
expect(mockGet).toHaveBeenCalledTimes(3);
|
|
89
|
-
|
|
90
|
-
expect(options.endpointDiscoveryCommandCtor).toHaveBeenCalledWith({
|
|
91
|
-
Operation: options.commandName.substr(0, options.commandName.length - 7),
|
|
92
|
-
Identifiers: options.identifiers,
|
|
93
|
-
});
|
|
94
|
-
expect(mockHandler).toHaveBeenCalledTimes(1);
|
|
95
|
-
|
|
96
|
-
expect(mockDelete).not.toHaveBeenCalled();
|
|
97
|
-
expect(mockSet).toHaveBeenCalledTimes(2);
|
|
98
|
-
expect(mockSet).toHaveBeenNthCalledWith(1, cacheKey, placeholderEndpoints);
|
|
99
|
-
expect(mockSet).toHaveBeenNthCalledWith(2, cacheKey, mockEndpoints);
|
|
100
|
-
});
|
|
101
|
-
|
|
102
|
-
describe("on error", () => {
|
|
103
|
-
it(`throws if isDiscoveredEndpointRequired=true`, async () => {
|
|
104
|
-
const error = new Error("rejected");
|
|
105
|
-
mockHandler.mockRejectedValueOnce(error);
|
|
106
|
-
|
|
107
|
-
try {
|
|
108
|
-
// @ts-ignore
|
|
109
|
-
await updateDiscoveredEndpointInCache(config, { ...options, isDiscoveredEndpointRequired: true });
|
|
110
|
-
fail("updateDiscoveredEndpointInCache should throw");
|
|
111
|
-
} catch (error) {
|
|
112
|
-
expect(error).toEqual(
|
|
113
|
-
Object.assign(
|
|
114
|
-
new Error(
|
|
115
|
-
`The operation to discover endpoint failed.` +
|
|
116
|
-
` Please retry, or provide a custom endpoint and disable endpoint discovery to proceed.`
|
|
117
|
-
),
|
|
118
|
-
{ reason: error }
|
|
119
|
-
)
|
|
120
|
-
);
|
|
121
|
-
}
|
|
122
|
-
verifyCallsOnCacheUndefined();
|
|
123
|
-
expect(mockDelete).not.toHaveBeenCalled();
|
|
124
|
-
expect(mockSet).toHaveBeenCalledTimes(1);
|
|
125
|
-
expect(mockSet).toHaveBeenCalledWith(cacheKey, placeholderEndpoints);
|
|
126
|
-
});
|
|
127
|
-
|
|
128
|
-
it(`sets placeholder enpoint if isDiscoveredEndpointRequired=false`, async () => {
|
|
129
|
-
const error = new Error("rejected");
|
|
130
|
-
mockHandler.mockRejectedValueOnce(error);
|
|
131
|
-
|
|
132
|
-
// @ts-ignore
|
|
133
|
-
await updateDiscoveredEndpointInCache(config, options);
|
|
134
|
-
|
|
135
|
-
verifyCallsOnCacheUndefined();
|
|
136
|
-
expect(mockDelete).not.toHaveBeenCalled();
|
|
137
|
-
expect(mockSet).toHaveBeenCalledTimes(2);
|
|
138
|
-
expect(mockSet).toHaveBeenNthCalledWith(1, cacheKey, placeholderEndpoints);
|
|
139
|
-
expect(mockSet).toHaveBeenNthCalledWith(2, cacheKey, placeholderEndpoints);
|
|
140
|
-
});
|
|
141
|
-
|
|
142
|
-
describe(`deletes cacheKey in case of`, () => {
|
|
143
|
-
const verifyCallsOnCacheKeyDelete = () => {
|
|
144
|
-
expect(mockDelete).toHaveBeenCalledWith(cacheKey);
|
|
145
|
-
expect(mockSet).toHaveBeenCalledTimes(2);
|
|
146
|
-
expect(mockSet).toHaveBeenNthCalledWith(1, cacheKey, placeholderEndpoints);
|
|
147
|
-
expect(mockSet).toHaveBeenNthCalledWith(2, cacheKey, placeholderEndpoints);
|
|
148
|
-
};
|
|
149
|
-
|
|
150
|
-
it(`InvalidEndpointException`, async () => {
|
|
151
|
-
const error = Object.assign(new Error("Invalid endpoint!"), { name: "InvalidEndpointException" });
|
|
152
|
-
mockHandler.mockRejectedValueOnce(error);
|
|
153
|
-
|
|
154
|
-
// @ts-ignore
|
|
155
|
-
await updateDiscoveredEndpointInCache(config, options);
|
|
156
|
-
verifyCallsOnCacheUndefined();
|
|
157
|
-
verifyCallsOnCacheKeyDelete();
|
|
158
|
-
});
|
|
159
|
-
|
|
160
|
-
it(`Status code: 421`, async () => {
|
|
161
|
-
const error = Object.assign(new Error("Invalid endpoint!"), { $metadata: { httpStatusCode: 421 } });
|
|
162
|
-
mockHandler.mockRejectedValueOnce(error);
|
|
163
|
-
|
|
164
|
-
// @ts-ignore
|
|
165
|
-
await updateDiscoveredEndpointInCache(config, options);
|
|
166
|
-
verifyCallsOnCacheUndefined();
|
|
167
|
-
verifyCallsOnCacheKeyDelete();
|
|
168
|
-
});
|
|
169
|
-
});
|
|
170
|
-
});
|
|
171
|
-
});
|
|
172
|
-
});
|
|
@@ -1,88 +0,0 @@
|
|
|
1
|
-
import { EndpointDiscoveryMiddlewareConfig } from "./getEndpointDiscoveryPlugin";
|
|
2
|
-
import { EndpointDiscoveryResolvedConfig, PreviouslyResolved } from "./resolveEndpointDiscoveryConfig";
|
|
3
|
-
|
|
4
|
-
export interface UpdateDiscoveredEndpointInCacheOptions extends EndpointDiscoveryMiddlewareConfig {
|
|
5
|
-
cacheKey: string;
|
|
6
|
-
commandName: string;
|
|
7
|
-
endpointDiscoveryCommandCtor: new (comandConfig: any) => any;
|
|
8
|
-
}
|
|
9
|
-
|
|
10
|
-
const requestQueue: { [key: string]: { resolve: Function; reject: Function }[] } = {};
|
|
11
|
-
|
|
12
|
-
export const updateDiscoveredEndpointInCache = async (
|
|
13
|
-
config: EndpointDiscoveryResolvedConfig & PreviouslyResolved,
|
|
14
|
-
options: UpdateDiscoveredEndpointInCacheOptions
|
|
15
|
-
) =>
|
|
16
|
-
new Promise<void>((resolve, reject) => {
|
|
17
|
-
const { endpointCache } = config;
|
|
18
|
-
const { cacheKey, commandName, identifiers } = options;
|
|
19
|
-
|
|
20
|
-
const endpoints = endpointCache.get(cacheKey);
|
|
21
|
-
|
|
22
|
-
if (endpoints && endpoints.length === 1 && endpoints[0].Address === "") {
|
|
23
|
-
// Endpoint operation already in-flight.
|
|
24
|
-
// Add request to request queue only if discovered endpoint is required.
|
|
25
|
-
if (options.isDiscoveredEndpointRequired) {
|
|
26
|
-
if (!requestQueue[cacheKey]) requestQueue[cacheKey] = [];
|
|
27
|
-
requestQueue[cacheKey].push({ resolve, reject });
|
|
28
|
-
} else {
|
|
29
|
-
resolve();
|
|
30
|
-
}
|
|
31
|
-
} else if (endpoints && endpoints.length > 0) {
|
|
32
|
-
// Endpoint record is present in cache.
|
|
33
|
-
resolve();
|
|
34
|
-
} else {
|
|
35
|
-
// put in a placeholder for endpoints already requested, prevent
|
|
36
|
-
// too much in-flight calls.
|
|
37
|
-
const placeholderEndpoints = [{ Address: "", CachePeriodInMinutes: 1 }];
|
|
38
|
-
endpointCache.set(cacheKey, placeholderEndpoints);
|
|
39
|
-
|
|
40
|
-
const command = new options.endpointDiscoveryCommandCtor({
|
|
41
|
-
Operation: commandName.substr(0, commandName.length - 7), // strip "Command"
|
|
42
|
-
Identifiers: identifiers,
|
|
43
|
-
});
|
|
44
|
-
const handler = command.resolveMiddleware(options.clientStack, config, options.options);
|
|
45
|
-
handler(command)
|
|
46
|
-
.then((result: any) => {
|
|
47
|
-
endpointCache.set(cacheKey, result.output.Endpoints);
|
|
48
|
-
if (requestQueue[cacheKey]) {
|
|
49
|
-
requestQueue[cacheKey].forEach(({ resolve }) => {
|
|
50
|
-
resolve();
|
|
51
|
-
});
|
|
52
|
-
delete requestQueue[cacheKey];
|
|
53
|
-
}
|
|
54
|
-
resolve();
|
|
55
|
-
})
|
|
56
|
-
.catch((error: any) => {
|
|
57
|
-
if (error.name === "InvalidEndpointException" || error.$metadata?.httpStatusCode === 421) {
|
|
58
|
-
// Endpoint is invalid, delete the cache entry.
|
|
59
|
-
endpointCache.delete(cacheKey);
|
|
60
|
-
}
|
|
61
|
-
|
|
62
|
-
const errorToThrow = Object.assign(
|
|
63
|
-
new Error(
|
|
64
|
-
`The operation to discover endpoint failed.` +
|
|
65
|
-
` Please retry, or provide a custom endpoint and disable endpoint discovery to proceed.`
|
|
66
|
-
),
|
|
67
|
-
{ reason: error }
|
|
68
|
-
);
|
|
69
|
-
|
|
70
|
-
//fail all the pending requests in batch
|
|
71
|
-
if (requestQueue[cacheKey]) {
|
|
72
|
-
requestQueue[cacheKey].forEach(({ reject }) => {
|
|
73
|
-
reject(errorToThrow);
|
|
74
|
-
});
|
|
75
|
-
delete requestQueue[cacheKey];
|
|
76
|
-
}
|
|
77
|
-
|
|
78
|
-
if (options.isDiscoveredEndpointRequired) {
|
|
79
|
-
reject(errorToThrow);
|
|
80
|
-
} else {
|
|
81
|
-
// Endpoint Discovery is optional. No error needs to be thrown.
|
|
82
|
-
// Set placeHolder endpoint to disable refresh for one minute.
|
|
83
|
-
endpointCache.set(cacheKey, placeholderEndpoints);
|
|
84
|
-
resolve();
|
|
85
|
-
}
|
|
86
|
-
});
|
|
87
|
-
}
|
|
88
|
-
});
|
package/tsconfig.cjs.json
DELETED
package/tsconfig.cjs.tsbuildinfo
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"program":{"fileNames":["../../node_modules/typescript/lib/lib.es5.d.ts","../../node_modules/typescript/lib/lib.es2015.d.ts","../../node_modules/typescript/lib/lib.es2016.d.ts","../../node_modules/typescript/lib/lib.es2017.d.ts","../../node_modules/typescript/lib/lib.es2018.d.ts","../../node_modules/typescript/lib/lib.dom.d.ts","../../node_modules/typescript/lib/lib.es2015.core.d.ts","../../node_modules/typescript/lib/lib.es2015.collection.d.ts","../../node_modules/typescript/lib/lib.es2015.generator.d.ts","../../node_modules/typescript/lib/lib.es2015.iterable.d.ts","../../node_modules/typescript/lib/lib.es2015.promise.d.ts","../../node_modules/typescript/lib/lib.es2015.proxy.d.ts","../../node_modules/typescript/lib/lib.es2015.reflect.d.ts","../../node_modules/typescript/lib/lib.es2015.symbol.d.ts","../../node_modules/typescript/lib/lib.es2015.symbol.wellknown.d.ts","../../node_modules/typescript/lib/lib.es2016.array.include.d.ts","../../node_modules/typescript/lib/lib.es2017.object.d.ts","../../node_modules/typescript/lib/lib.es2017.sharedmemory.d.ts","../../node_modules/typescript/lib/lib.es2017.string.d.ts","../../node_modules/typescript/lib/lib.es2017.intl.d.ts","../../node_modules/typescript/lib/lib.es2017.typedarrays.d.ts","../../node_modules/typescript/lib/lib.es2018.asyncgenerator.d.ts","../../node_modules/typescript/lib/lib.es2018.asynciterable.d.ts","../../node_modules/typescript/lib/lib.es2018.intl.d.ts","../../node_modules/typescript/lib/lib.es2018.promise.d.ts","../../node_modules/typescript/lib/lib.es2018.regexp.d.ts","../../node_modules/typescript/lib/lib.es2020.bigint.d.ts","../../node_modules/typescript/lib/lib.esnext.intl.d.ts","../../node_modules/tslib/tslib.d.ts","../types/dist-types/abort.d.ts","../types/dist-types/logger.d.ts","../types/dist-types/http.d.ts","../types/dist-types/response.d.ts","../types/dist-types/util.d.ts","../types/dist-types/middleware.d.ts","../types/dist-types/command.d.ts","../types/dist-types/client.d.ts","../types/dist-types/credentials.d.ts","../types/dist-types/crypto.d.ts","../types/dist-types/eventStream.d.ts","../types/dist-types/pagination.d.ts","../types/dist-types/transfer.d.ts","../types/dist-types/serde.d.ts","../types/dist-types/shapes.d.ts","../types/dist-types/signature.d.ts","../types/dist-types/waiter.d.ts","../types/dist-types/index.d.ts","../../node_modules/@types/node/globals.d.ts","../../node_modules/@types/node/async_hooks.d.ts","../../node_modules/@types/node/buffer.d.ts","../../node_modules/@types/node/child_process.d.ts","../../node_modules/@types/node/cluster.d.ts","../../node_modules/@types/node/console.d.ts","../../node_modules/@types/node/constants.d.ts","../../node_modules/@types/node/crypto.d.ts","../../node_modules/@types/node/dgram.d.ts","../../node_modules/@types/node/dns.d.ts","../../node_modules/@types/node/domain.d.ts","../../node_modules/@types/node/events.d.ts","../../node_modules/@types/node/fs.d.ts","../../node_modules/@types/node/http.d.ts","../../node_modules/@types/node/http2.d.ts","../../node_modules/@types/node/https.d.ts","../../node_modules/@types/node/inspector.d.ts","../../node_modules/@types/node/module.d.ts","../../node_modules/@types/node/net.d.ts","../../node_modules/@types/node/os.d.ts","../../node_modules/@types/node/path.d.ts","../../node_modules/@types/node/perf_hooks.d.ts","../../node_modules/@types/node/process.d.ts","../../node_modules/@types/node/punycode.d.ts","../../node_modules/@types/node/querystring.d.ts","../../node_modules/@types/node/readline.d.ts","../../node_modules/@types/node/repl.d.ts","../../node_modules/@types/node/stream.d.ts","../../node_modules/@types/node/string_decoder.d.ts","../../node_modules/@types/node/timers.d.ts","../../node_modules/@types/node/tls.d.ts","../../node_modules/@types/node/trace_events.d.ts","../../node_modules/@types/node/tty.d.ts","../../node_modules/@types/node/url.d.ts","../../node_modules/@types/node/util.d.ts","../../node_modules/@types/node/v8.d.ts","../../node_modules/@types/node/vm.d.ts","../../node_modules/@types/node/worker_threads.d.ts","../../node_modules/@types/node/zlib.d.ts","../../node_modules/@types/node/globals.global.d.ts","../../node_modules/@types/node/wasi.d.ts","../../node_modules/@types/node/ts3.6/base.d.ts","../../node_modules/@types/node/assert.d.ts","../../node_modules/@types/node/base.d.ts","../../node_modules/@types/node/index.d.ts","../node-config-provider/dist-types/fromEnv.d.ts","../shared-ini-file-loader/dist-types/index.d.ts","../node-config-provider/dist-types/fromSharedConfigFiles.d.ts","../node-config-provider/dist-types/fromStatic.d.ts","../node-config-provider/dist-types/configLoader.d.ts","../node-config-provider/dist-types/index.d.ts","./src/configurations.ts","../protocol-http/dist-types/httpResponse.d.ts","../protocol-http/dist-types/httpRequest.d.ts","../protocol-http/dist-types/httpHandler.d.ts","../protocol-http/dist-types/isValidHostname.d.ts","../protocol-http/dist-types/index.d.ts","./src/getCacheKey.ts","../endpoint-cache/dist-types/Endpoint.d.ts","../endpoint-cache/dist-types/EndpointCache.d.ts","../endpoint-cache/dist-types/index.d.ts","./src/resolveEndpointDiscoveryConfig.ts","./src/getEndpointDiscoveryPlugin.ts","./src/updateDiscoveredEndpointInCache.ts","./src/endpointDiscoveryMiddleware.ts","./src/index.ts","../../node_modules/@babel/types/lib/index.d.ts","../../node_modules/@types/babel__generator/index.d.ts","../../node_modules/@babel/parser/typings/babel-parser.d.ts","../../node_modules/@types/babel__template/index.d.ts","../../node_modules/@types/babel__traverse/index.d.ts","../../node_modules/@types/babel__core/index.d.ts","../../node_modules/@types/chai/index.d.ts","../../node_modules/@types/chai-as-promised/index.d.ts","../../node_modules/@types/connect/index.d.ts","../../node_modules/@types/range-parser/index.d.ts","../../node_modules/@types/qs/index.d.ts","../../node_modules/@types/express-serve-static-core/index.d.ts","../../node_modules/@types/fs-extra/index.d.ts","../../node_modules/@types/minimatch/index.d.ts","../../node_modules/@types/glob/index.d.ts","../../node_modules/@types/graceful-fs/index.d.ts","../../node_modules/@types/istanbul-lib-coverage/index.d.ts","../../node_modules/@types/istanbul-lib-report/index.d.ts","../../node_modules/@types/istanbul-reports/index.d.ts","../../node_modules/jest-diff/build/cleanupSemantic.d.ts","../../node_modules/jest-diff/build/types.d.ts","../../node_modules/jest-diff/build/diffLines.d.ts","../../node_modules/jest-diff/build/printDiffs.d.ts","../../node_modules/jest-diff/build/index.d.ts","../../node_modules/pretty-format/build/types.d.ts","../../node_modules/pretty-format/build/index.d.ts","../../node_modules/@types/jest/index.d.ts","../../node_modules/@types/json-schema/index.d.ts","../../node_modules/@types/json5/index.d.ts","../../node_modules/@types/lodash/common/common.d.ts","../../node_modules/@types/lodash/common/array.d.ts","../../node_modules/@types/lodash/common/collection.d.ts","../../node_modules/@types/lodash/common/date.d.ts","../../node_modules/@types/lodash/common/function.d.ts","../../node_modules/@types/lodash/common/lang.d.ts","../../node_modules/@types/lodash/common/math.d.ts","../../node_modules/@types/lodash/common/number.d.ts","../../node_modules/@types/lodash/common/object.d.ts","../../node_modules/@types/lodash/common/seq.d.ts","../../node_modules/@types/lodash/common/string.d.ts","../../node_modules/@types/lodash/common/util.d.ts","../../node_modules/@types/lodash/index.d.ts","../../node_modules/@types/minimist/index.d.ts","../../node_modules/@types/normalize-package-data/index.d.ts","../../node_modules/@types/parse-json/index.d.ts","../../node_modules/@types/prettier/index.d.ts","../../node_modules/@types/stack-utils/index.d.ts","../../node_modules/@types/uuid/index.d.ts","../../node_modules/@types/ws/index.d.ts","../../node_modules/@types/yargs-parser/index.d.ts","../../node_modules/@types/yargs/index.d.ts","../../node_modules/@types/yauzl/index.d.ts"],"fileInfos":[{"version":"ac3a8c4040e183ce38da69d23b96939112457d1936198e6542672b7963cf0fce","affectsGlobalScope":true},"dc47c4fa66b9b9890cf076304de2a9c5201e94b740cffdf09f87296d877d71f6","7a387c58583dfca701b6c85e0adaf43fb17d590fb16d5b2dc0a2fbd89f35c467","8a12173c586e95f4433e0c6dc446bc88346be73ffe9ca6eec7aa63c8f3dca7f9","5f4e733ced4e129482ae2186aae29fde948ab7182844c3a5a51dd346182c7b06",{"version":"1dad4fe1561d99dfd6709127608b99a76e5c2643626c800434f99c48038567ee","affectsGlobalScope":true},{"version":"cce43d02223f8049864f8568bed322c39424013275cd3bcc3f51492d8b546cb3","affectsGlobalScope":true},{"version":"43fb1d932e4966a39a41b464a12a81899d9ae5f2c829063f5571b6b87e6d2f9c","affectsGlobalScope":true},{"version":"cdccba9a388c2ee3fd6ad4018c640a471a6c060e96f1232062223063b0a5ac6a","affectsGlobalScope":true},{"version":"8dff1b4c2df638fcd976cbb0e636f23ab5968e836cd45084cc31d47d1ab19c49","affectsGlobalScope":true},{"version":"2bb4b3927299434052b37851a47bf5c39764f2ba88a888a107b32262e9292b7c","affectsGlobalScope":true},{"version":"810627a82ac06fb5166da5ada4159c4ec11978dfbb0805fe804c86406dab8357","affectsGlobalScope":true},{"version":"62d80405c46c3f4c527ee657ae9d43fda65a0bf582292429aea1e69144a522a6","affectsGlobalScope":true},{"version":"3013574108c36fd3aaca79764002b3717da09725a36a6fc02eac386593110f93","affectsGlobalScope":true},{"version":"8f4c9f651c8294a2eb1cbd12581fe25bfb901ab1d474bb93cd38c7e2f4be7a30","affectsGlobalScope":true},{"version":"3be5a1453daa63e031d266bf342f3943603873d890ab8b9ada95e22389389006","affectsGlobalScope":true},{"version":"17bb1fc99591b00515502d264fa55dc8370c45c5298f4a5c2083557dccba5a2a","affectsGlobalScope":true},{"version":"7ce9f0bde3307ca1f944119f6365f2d776d281a393b576a18a2f2893a2d75c98","affectsGlobalScope":true},{"version":"6a6b173e739a6a99629a8594bfb294cc7329bfb7b227f12e1f7c11bc163b8577","affectsGlobalScope":true},{"version":"12a310447c5d23c7d0d5ca2af606e3bd08afda69100166730ab92c62999ebb9d","affectsGlobalScope":true},{"version":"b0124885ef82641903d232172577f2ceb5d3e60aed4da1153bab4221e1f6dd4e","affectsGlobalScope":true},{"version":"0eb85d6c590b0d577919a79e0084fa1744c1beba6fd0d4e951432fa1ede5510a","affectsGlobalScope":true},{"version":"da233fc1c8a377ba9e0bed690a73c290d843c2c3d23a7bd7ec5cd3d7d73ba1e0","affectsGlobalScope":true},{"version":"df9c8a72ca8b0ed62f5470b41208a0587f0f73f0a7db28e5a1272cf92537518e","affectsGlobalScope":true},{"version":"bb2d3fb05a1d2ffbca947cc7cbc95d23e1d053d6595391bd325deb265a18d36c","affectsGlobalScope":true},{"version":"c80df75850fea5caa2afe43b9949338ce4e2de086f91713e9af1a06f973872b8","affectsGlobalScope":true},{"version":"60761e6ea886034af0f294f025a7199360ce4e2c8ba4ec6408bc049cf9b89799","affectsGlobalScope":true},{"version":"506b80b9951c9381dc5f11897b31fca5e2a65731d96ddefa19687fbc26b23c6e","affectsGlobalScope":true},"12f4cfe2fe60b810c3174537bc2ddb20c1067b7768643d12cb1266fd183afb75","4f1034eac6404cb69bedb8bb04cf246871d1aaebbb99d5617be54f54323464c7","724eb35fdcfa2ad686611b3a8a9d704ad0d478539a8cf0089176e0b8047f7190","d71be3ec7ca8cf9aaf6a8b68653dd3b7d988678edc120a640fc0307967486cc5","2e04271499caec54dea75e7061de06b2549efbe1d652b9bdab2f74fd2572f61f","40b990c27c58cf6d4473c9cdc65daf0428cbfca5cf4b072c73a4ad5a4055ea7f","0b2fe702dda65d25d5e00ec95fc8952036e7e75870c376abeb2cd2150b0a3bed","a9367ec48d3b67800c69c890e616337935df67caad5bff99383949af561042a8","5c1a8d6754a7cceee2135728e8ce6a4f984966a2d16ff1cbed879f7527d55864","a99add785a8a06f19582501ca19e92949f6b840b3f91d880e73582c5efacccde","5a7bb8afd0a22b7754275793f5ca5aeea379a2aad6153a6d68af49a60a899f69","a604c1ae24a48ccdb36396f49a20677d32722f8fd461dfb47186a5b12fd88d60","259c58ced9d80f66a61362a8768529a2746a2bc80183cdb04726f610913bb5d5","b14456a54e15ce24ff9e5ad3b70675b104a36eb35886e3ffaae614292c0908c4","ed01aa50ff4fdbf0f6857596fc385587d87da4896c7980ea75527e098031c488","9e5aef3efc63316ce7aa61b137d354449f792ab92885d03c8894b239db75d90a","8a6c15bfa2a0a9e68005a53fb71b60f3769af0da81001b95e4861310e260b788","aaffeca0d82a3d862c5186af3ca707801e45cc8b2e7d31e430eb715648ffa839","aedcac717f286d9925f0c52aa6165f4e91a2ed05ad9c1e2a8cc91eca18b8eb2b",{"version":"f7be6b47e03c43fa3ad1224b4fd995f3fd35bb29f0c2da5843c9dc04f4162fb3","affectsGlobalScope":true},"0829c48316ebcd238419d1ba2f142c866fe064a2452b449197dc85a9f43a3612","e63d5487b6d47f8abcbfdc3af9450d56118041805dd043febd249af0502dc9b1","5f505b075956d1c7db95d14e2e7a27d4e4a9d1ffc34b83b8273c51b074d575bd","458d55b08da524f900192dafb5837fcc2471cb59c0c149eea4754c180f943473","65409a1cc0ce6d0e4bc9a4dfd35e7df27b8b2646c9055230fdbb03f694b0cc88","e9339a66a8c672260b9c6b727f6d818c42a8d13bade07dfaf907103928e3c456","51d9197446e865a6919a2f217f4d0ad19f77483e5c7f2ebc520de4dc416dc5a3","b39ae9f0d9d0bdcde86891b047ac912602a59fa188c1d2c4bc201fc7c86cfaa9","f8a7a6d7af6267022984c5604ec31c4539fea5cb749e63ff3a0cf8a42fd19603","6570493ff2552919da1e6480f20d0b623b8007343a777922fca7788b6ce85ea1","d42d0bfd355a4f9f247789676137aec627d0b23122452c388a6c1a83105ae811","5efce49fe6c5e6c7211f4cfb93724adc1cf5783c63d608dca8cb61bfcbee29e6","bb05e8566a80f6e42df974e7523744b0af66aa9fafc721022156b202276c480e","9771ae64c7390ee98639ac79e9fb37b87a17de52b4bb705d48c9fc67af429e64","1939c52bd6e3fe0c5beacd7f5762f9847e86861059685fbdf471bd8afaf87944","d4fa2c2de99b1f4ff83aba4732c33fff918bf5869c04674aa2bfe927adfbd386","9cd5d57333119af9861227e2415a944d23ae7fa67706ac60a4c9a5cfde0a5a05","cf36f4557f363a203e39329aba07cc2f916ae181b4f71c61814db2e9ca6ca30c","b0d1073a8fbdd7b36fd048d82b1f148ce161ed54569a4b4b43007733ee643fff","311f6a6b6c05d334c29eb795d765bfbb596bb43a78fcb72bc23a6121eefb3924","b76f9cfe8fdfe10bb5ab1b540ea866771b89bb0e0acafbe119c9c8cbe398c092",{"version":"7e56a8722b9aeae9496e1278539f1b7da4651614b487346e225beba1c7b29fb5","affectsGlobalScope":true},"a7b43c69f9602d198825e403ee34e5d64f83c48b391b2897e8c0e6f72bca35f8","c567c7d3038a689bd3274285c3a421eaabc3289d38e8441e686a91db97a3d663","ae0784437911149dabe5cd245e5858305ebf2c30d44a80a037aa990b8500c5f3","133c3fe00db1cce01ae605753f88e29aa707c9a22c5f25c48d9d6e2ee6dab0c7","fe7b61b633d3c7ec4ebd8039f40e650adbe7ce872239de15da90d2452849c060","05af2a124f5a9113e7503539a3f1e1c72e92d9c756a2e5ad2e5afab11e0325d7","2f9c94d2805d249de1ed836937ce1c62dd051bae445661e62ecf238b69893b29","c1e031196368cb57b219684032865182384fcd3d60027783a42449f6e0a580d1","0b7733d83619ac4e3963e2a9f7c75dc1e9af6850cb2354c9554977813092c10a","3ce933f0c3955f67f67eb7d6b5c83c2c54a18472c1d6f2bb651e51dd40c84837","911690e5b1cdb5516785d9f811b5f9679fae1a2a1df5fad1f001e8d167c7fd98","bd180a2d4ada8a0e92ad33333933e2c96646ea94837bf80f68ec7f95e79b5e12","121cfafda904699b1abc90b7894128a78692a877380d70a9eca2e2b79207076a","8ef3d66d40dd2b5332b4e84bf591219a04d41a7fdb5237d470f7b2002557e427","e959c2855e83468c9b9f2bb73860f718dd80cc82a6d9b8793b81dedf7b1aa249","ce67e3dcf0f09888d0059fc61017ea22a7e5ac9112c727159fbff7937498e8dd",{"version":"2708349d5a11a5c2e5f3a0765259ebe7ee00cdcc8161cb9990cb4910328442a1","affectsGlobalScope":true},"2580346168c485710cca0ae724e081c715dafaba9ee1f735aceecc2432427027","483b37cab381fe1a5c118f86ac931aebc4e1ad76f8867dc60c0f10c5c6a9305c","8ea1394bb5549f22e31c1896fb14d943185b72b14db2f39c8fc00e64e8b67361","e61a21e9418f279bc480394a94d1581b2dee73747adcbdef999b6737e34d721b","23dca7e2d421cdf16f12144497b3da31302dfbe88d648eff16bf37944483f3bd","559c8c6979e9c6d649b26a0f56f0b6f1080606a0e8ea537a0099537c6b10584c","3b1c4e120e1050d6a4203fcdd82b561d9ce6cbf45d48d3837450a7b78919fd59","667c77aa756d8e4547eb170ccc0f2cb39852130c94eb299491b45008210ae681","126c87faf0c84b1326c3863ce2235b6a47dc2e548c3aba754c2d3eed16d7eee8","a63605647d8d06e31298d7e04ede8e4775f9b10c51955de611e7207681a39012","a11288edc8161f664148ea7d56101517e380335f5fa1a94408db86efce025bba","3d3c8cf9262ffe218c09c05dcb96832f81c189335a9d600642c49a1f05db40bc","dd5bab97b9f2d5dec2796fa4ff1b6db7221dfc9158f4e81cf9bcef8750dc32ba","f10a176bcf3a0320f5137c6fc1da2d9b7347f8e2852a0ca5802a0ea9aac2df4c","1c33a2766d210aa58703a1fb9d51c0c49fb0f98495974847870f2f090df9e52a","d1f8a829c5e90734bb47a1d1941b8819aeee6e81a2a772c3c0f70b30e3693fa9","413cb528dd3ba14550e9c10c3f87190aeb9a2359d4a2538972648ee285356af6","c3af56254d446bd82dfce2c64332ad737a32ba3d36c6aaab10e4556936aaf086","17c846b03d5877499082fba19e05d7e7f743402e4227640dbc8381ae24f6a83b","248635dc39ffd890d8a4bf8548dc7ba42a980e448f23847b6f125d6683541d3b","360133226431f8678b893d4d8f599b7d7edae4f07c8f5548964f5f2f4140fb68","502908f97b699fd309472908eb0a1378a66ee66e040a8ec7c428a4a0a4f5f278","aff2ce6bb4d9dd023c27f2fbacb51fd22ed7e07d3527da656739359508e3156f","a1274a49fdcdedfc138e81b307ceaa15ec0bf270f55b1dee51df8f29f1fff03b","a40c24317de6bfca7e3746d02c14b4da39f52d3b65223b8defa567711b76060d","0ca62963192a317daa21cd8f940ae301040d77ffa91cae99a7dca7fbc91267e9","b668b7fb7c52a05fb9233a27ba5099a73cd8e157b037d67399336635495ab483","b25c5f2970d06c729f464c0aeaa64b1a5b5f1355aa93554bb5f9c199b8624b1e","069733dc220affbe58d9c1d1a93af3707bc515aaed761701d8741b57da4cb964","3051751533eee92572241b3cef28333212401408c4e7aa21718714b793c0f4ed","691aea9772797ca98334eb743e7686e29325b02c6931391bcee4cc7bf27a9f3b","6f1d39d26959517da3bd105c552eded4c34702705c64d75b03f54d864b6e41c2",{"version":"e9cf450600c496a87ab96d288157b79be6c193e8623bd93553d5d64755940dea","affectsGlobalScope":true},{"version":"c8a2f72f046b5efb790cc37cfe79dcf11ce8e35e7e7d9430e10e53e0aa05c7a2","affectsGlobalScope":true},"6d829824ead8999f87b6df21200df3c6150391b894b4e80662caa462bd48d073","16d51f964ec125ad2024cf03f0af444b3bc3ec3614d9345cc54d09bab45c9a4c","ba601641fac98c229ccd4a303f747de376d761babb33229bb7153bed9356c9cc",{"version":"61b60d145059c3c8e3c7b484713191b6d0b70999bcb11f2b26286b15926a2b5f","affectsGlobalScope":true},"5171627120eeb3a7e8afb8ed04ea9be7f0b53ba09bb1fc95172483e0fbb0740c","95c22bc19835e28e2e524a4bb8898eb5f2107b640d7279a6d3aade261916bbf2","393137c76bd922ba70a2f8bf1ade4f59a16171a02fb25918c168d48875b0cfb0","3ebae8c00411116a66fca65b08228ea0cf0b72724701f9b854442100aab55aba","de18acda71730bac52f4b256ce7511bb56cc21f6f114c59c46782eff2f632857","7eb06594824ada538b1d8b48c3925a83e7db792f47a081a62cf3e5c4e23cf0ee","905c3e8f7ddaa6c391b60c05b2f4c3931d7127ad717a080359db3df510b7bdab","d8aab31ba8e618cc3eea10b0945de81cb93b7e8150a013a482332263b9305322","69da61a7b5093dac77fa3bec8be95dcf9a74c95a0e9161edb98bb24e30e439d2","561eca7a381b96d6ccac6e4061e6d2ae53f5bc44203f3fd9f5b26864c32ae6e9","62ea38627e3ebab429f7616812a9394d327c2bc271003dfba985de9b4137369f","b4439890c168d646357928431100daac5cbdee1d345a34e6bf6eca9f3abe22bc","5d72971a459517c44c1379dab9ed248e87a61ba0a1e0f25c9d67e1e640cd9a09","02d734976af36f4273d930bea88b3e62adf6b078cf120c1c63d49aa8d8427c5c",{"version":"ce2169125f42515a26fa60977b6d56ae407f3462e28832fbf6a9013f6a828bab","affectsGlobalScope":true},"0359682c54e487c4cab2b53b2b4d35cc8dea4d9914bc6abcdb5701f8b8e745a4","96d14f21b7652903852eef49379d04dbda28c16ed36468f8c9fa08f7c14c9538","675e702f2032766a91eeadee64f51014c64688525da99dccd8178f0c599f13a8","378df8bbbb9e3f6fca05d58f644aab538e1062eab5e778fb0b83d41125df246d","d88a479cccf787b4aa82362150fbeba5211a32dbfafa7b92ba6995ecaf9a1a89","187119ff4f9553676a884e296089e131e8cc01691c546273b1d0089c3533ce42","c24ad9be9adf28f0927e3d9d9e9cec1c677022356f241ccbbfb97bfe8fb3d1a1","0ec0998e2d085e8ea54266f547976ae152c9dd6cdb9ac4d8a520a230f5ebae84","9364c7566b0be2f7b70ff5285eb34686f83ccb01bda529b82d23b2a844653bfb","00baffbe8a2f2e4875367479489b5d43b5fc1429ecb4a4cc98cfc3009095f52a","82251920b05f30981c9a4109cb5f3169dce4b477effc845c6d781044a30e7672","3c92b6dfd43cc1c2485d9eba5ff0b74a19bb8725b692773ef1d66dac48cda4bd","3e59f00ab03c33717b3130066d4debb272da90eeded4935ff0604c2bc25a5cae","9fa6b83a35e897f340858995ca5d77e901d89fd18644cd4c9e8a4afe0b2e6363",{"version":"0714e2046df66c0e93c3330d30dbc0565b3e8cd3ee302cf99e4ede6220e5fec8","affectsGlobalScope":true},"e437d83044ba17246a861aa9691aa14223ff4a9d6f338ab1269c41c758586a88","c9ad058b2cc9ce6dc2ed92960d6d009e8c04bef46d3f5312283debca6869f613","2b8264b2fefd7367e0f20e2c04eed5d3038831fe00f5efbc110ff0131aab899b","08b428a44bc98005536a12456518797e9afe2a08e8b5d9785641713a54475881","c6c4fea9acc55d5e38ff2b70d57ab0b5cdbd08f8bc5d7a226e322cea128c5b57","96b49a9de749afcf92b5bce1d8cc42cfae6816cdf5ea36584fd9256b8b2e5292","bc81aff061c53a7140270555f4b22da4ecfe8601e8027cf5aa175fbdc7927c31","3bdd93ec24853e61bfa4c63ebaa425ff3e474156e87a47d90122e1d8cc717c1f","5a2a25feca554a8f289ed62114771b8c63d89f2b58325e2f8b7043e4e0160d11","3845d3b64286c12c60d39fc90ac1cc5e47cbc951530658d2567d578b2faa1f26"],"options":{"downlevelIteration":true,"esModuleInterop":true,"importHelpers":true,"inlineSourceMap":true,"inlineSources":true,"module":1,"noEmitHelpers":true,"noFallthroughCasesInSwitch":true,"outDir":"./dist-cjs","preserveConstEnums":true,"removeComments":true,"rootDir":"./src","strict":true,"target":5},"fileIdsList":[[114],[114,115,116,117,118],[114,116],[120],[61,92],[59,61,92,123,124],[60,92],[59,92,127],[130],[131],[137,139],[143,145,146,147,148,149,150,151,152,153,154,155],[143,144,146,147,148,149,150,151,152,153,154,155],[144,145,146,147,148,149,150,151,152,153,154,155],[143,144,145,147,148,149,150,151,152,153,154,155],[143,144,145,146,148,149,150,151,152,153,154,155],[143,144,145,146,147,149,150,151,152,153,154,155],[143,144,145,146,147,148,150,151,152,153,154,155],[143,144,145,146,147,148,149,151,152,153,154,155],[143,144,145,146,147,148,149,150,152,153,154,155],[143,144,145,146,147,148,149,150,151,153,154,155],[143,144,145,146,147,148,149,150,151,152,154,155],[143,144,145,146,147,148,149,150,151,152,153,155],[143,144,145,146,147,148,149,150,151,152,153,154],[90],[49],[89,90],[50],[51,59,66,75],[51,52,59,66],[54],[55,75],[56,57,59,66],[57],[58,59],[59],[59,60,75,81],[61,66,75,81],[59,60,61,62,66,75,78,81],[61,63,78,81],[91],[59,64],[57,59,66,75],[67],[68],[49,69],[80],[71],[72],[59,73],[73,74,82,84],[59,75],[76],[77],[66,78],[79],[48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88],[66,80],[72,81],[82],[75,83],[84],[88],[59,60,75,84,85],[75,86],[59,61,63,66,75,78,81,86,92],[163],[59,75,92],[133,134],[133,134,135,136],[138],[106],[106,107],[29,98],[29,47,104,105,109,110,111],[29,47],[29,47,109,112],[29,99,109,110],[29,47,108],[29,109,110],[47,93,95,96],[47,92],[47,94],[47],[97],[47,100,101],[100,101,102,103],[33,35,36],[33,35],[34],[32,33,35],[30],[30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46],[31,34],[37],[32,34,42],[33],[32]],"referencedMap":[[116,1],[119,2],[115,1],[117,3],[118,1],[121,4],[122,5],[125,6],[126,7],[128,8],[129,7],[131,9],[132,10],[140,11],[144,12],[145,13],[143,14],[146,15],[147,16],[148,17],[149,18],[150,19],[151,20],[152,21],[153,22],[154,23],[155,24],[90,25],[49,26],[91,27],[50,28],[51,29],[52,30],[54,31],[55,32],[56,33],[57,34],[58,35],[59,36],[60,37],[61,38],[62,39],[63,40],[92,41],[64,42],[66,43],[67,44],[68,45],[69,46],[70,47],[71,48],[72,49],[73,50],[74,51],[75,52],[76,53],[77,54],[78,55],[79,56],[89,57],[80,58],[81,59],[82,60],[83,61],[84,62],[88,63],[85,64],[86,65],[162,66],[164,67],[165,68],[135,69],[137,70],[136,69],[139,71],[107,72],[108,73],[99,74],[112,75],[105,76],[110,77],[113,78],[109,79],[111,80],[97,81],[93,82],[95,83],[96,84],[98,85],[102,86],[101,84],[100,84],[104,87],[37,88],[36,89],[38,90],[40,91],[32,92],[47,93],[35,94],[41,95],[43,96],[44,97],[45,98],[34,91],[46,92]],"exportedModulesMap":[[116,1],[119,2],[115,1],[117,3],[118,1],[121,4],[122,5],[125,6],[126,7],[128,8],[129,7],[131,9],[132,10],[140,11],[144,12],[145,13],[143,14],[146,15],[147,16],[148,17],[149,18],[150,19],[151,20],[152,21],[153,22],[154,23],[155,24],[90,25],[49,26],[91,27],[50,28],[51,29],[52,30],[54,31],[55,32],[56,33],[57,34],[58,35],[59,36],[60,37],[61,38],[62,39],[63,40],[92,41],[64,42],[66,43],[67,44],[68,45],[69,46],[70,47],[71,48],[72,49],[73,50],[74,51],[75,52],[76,53],[77,54],[78,55],[79,56],[89,57],[80,58],[81,59],[82,60],[83,61],[84,62],[88,63],[85,64],[86,65],[162,66],[164,67],[165,68],[135,69],[137,70],[136,69],[139,71],[107,72],[108,73],[99,74],[112,75],[105,76],[110,77],[113,78],[109,79],[111,80],[97,81],[93,82],[95,83],[96,84],[98,85],[102,86],[101,84],[100,84],[104,87],[37,88],[36,89],[38,90],[40,91],[32,92],[47,93],[35,94],[41,95],[43,96],[44,97],[45,98],[34,91],[46,92]],"semanticDiagnosticsPerFile":[116,114,119,115,117,118,121,120,122,125,126,128,129,130,131,132,140,141,142,144,145,143,146,147,148,149,150,151,152,153,154,155,127,156,90,49,91,50,51,52,53,54,55,56,57,58,59,60,48,87,61,62,63,92,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,89,80,81,82,83,84,88,85,86,157,158,159,124,123,160,161,162,163,164,165,133,135,137,136,134,139,138,29,6,8,7,2,9,10,11,12,13,14,15,16,3,4,20,17,18,19,21,22,23,5,24,25,26,27,1,28,106,107,108,99,112,105,110,113,109,111,97,93,95,96,98,102,101,100,104,103,94,30,37,36,38,39,40,32,47,31,35,41,33,43,44,45,42,34,46]},"version":"4.3.5"}
|
package/tsconfig.es.json
DELETED