@aws-sdk/endpoint-cache 3.36.0 → 3.49.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 CHANGED
@@ -3,6 +3,41 @@
3
3
  All notable changes to this project will be documented in this file.
4
4
  See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
5
5
 
6
+ # [3.49.0](https://github.com/aws/aws-sdk-js-v3/compare/v3.48.0...v3.49.0) (2022-01-29)
7
+
8
+ **Note:** Version bump only for package @aws-sdk/endpoint-cache
9
+
10
+
11
+
12
+
13
+
14
+ ## [3.47.1](https://github.com/aws/aws-sdk-js-v3/compare/v3.47.0-release-test-1...v3.47.1) (2022-01-20)
15
+
16
+ **Note:** Version bump only for package @aws-sdk/endpoint-cache
17
+
18
+
19
+
20
+
21
+
22
+ # [3.47.0](https://github.com/aws/aws-sdk-js-v3/compare/v3.46.0...v3.47.0) (2022-01-15)
23
+
24
+ **Note:** Version bump only for package @aws-sdk/endpoint-cache
25
+
26
+
27
+
28
+
29
+
30
+ # [3.46.0](https://github.com/aws/aws-sdk-js-v3/compare/v3.45.0...v3.46.0) (2022-01-07)
31
+
32
+
33
+ ### Features
34
+
35
+ * **packages:** end support for Node.js 10.x ([#3141](https://github.com/aws/aws-sdk-js-v3/issues/3141)) ([1a62865](https://github.com/aws/aws-sdk-js-v3/commit/1a6286513f7cdb556708845c512861c5f92eb883))
36
+
37
+
38
+
39
+
40
+
6
41
  # [3.36.0](https://github.com/aws/aws-sdk-js-v3/compare/v3.35.0...v3.36.0) (2021-10-08)
7
42
 
8
43
 
@@ -1,10 +1,6 @@
1
1
  export interface Endpoint {
2
- /**
3
- * <p>An endpoint address.</p>
4
- */
2
+
5
3
  Address: string;
6
- /**
7
- * <p>The TTL for the endpoint, in minutes.</p>
8
- */
4
+
9
5
  CachePeriodInMinutes: number;
10
6
  }
@@ -5,46 +5,16 @@ export interface EndpointWithExpiry extends Pick<Endpoint, "Address"> {
5
5
  export declare class EndpointCache {
6
6
  private readonly cache;
7
7
  constructor(capacity: number);
8
- /**
9
- * Returns an un-expired endpoint for the given key.
10
- *
11
- * @param endpointsWithExpiry
12
- * @returns
13
- */
8
+
14
9
  getEndpoint(key: string): string | undefined;
15
- /**
16
- * Returns un-expired endpoints for the given key.
17
- *
18
- * @param key
19
- * @returns
20
- */
10
+
21
11
  get(key: string): EndpointWithExpiry[] | undefined;
22
- /**
23
- * Stores the endpoints passed for the key in cache.
24
- * If not defined, uses empty string for the Address in endpoint.
25
- * If not defined, uses one minute for CachePeriodInMinutes in endpoint.
26
- * Stores milliseconds elapsed since the UNIX epoch in Expires param based
27
- * on value provided in CachePeriodInMinutes.
28
- *
29
- * @param key
30
- * @param endpoints
31
- */
12
+
32
13
  set(key: string, endpoints: Endpoint[]): void;
33
- /**
34
- * Deletes the value for the given key in the cache.
35
- *
36
- * @param {string} key
37
- */
14
+
38
15
  delete(key: string): void;
39
- /**
40
- * Checks whether the key exists in cache.
41
- *
42
- * @param {string} key
43
- * @returns {boolean}
44
- */
16
+
45
17
  has(key: string): boolean;
46
- /**
47
- * Clears the cache.
48
- */
18
+
49
19
  clear(): void;
50
20
  }
package/package.json CHANGED
@@ -1,12 +1,13 @@
1
1
  {
2
2
  "name": "@aws-sdk/endpoint-cache",
3
- "version": "3.36.0",
3
+ "version": "3.49.0",
4
4
  "scripts": {
5
- "build": "yarn build:cjs && yarn build:es && yarn build:types",
5
+ "build": "concurrently 'yarn:build:cjs' 'yarn:build:es' 'yarn:build:types'",
6
6
  "build:cjs": "tsc -p tsconfig.cjs.json",
7
7
  "build:es": "tsc -p tsconfig.es.json",
8
8
  "build:types": "tsc -p tsconfig.types.json",
9
- "downlevel-dts": "downlevel-dts dist-types dist-types/ts3.4",
9
+ "build:types:downlevel": "downlevel-dts dist-types dist-types/ts3.4",
10
+ "clean": "rimraf ./dist-*",
10
11
  "test": "jest --passWithNoTests"
11
12
  },
12
13
  "author": {
@@ -22,13 +23,16 @@
22
23
  "tslib": "^2.3.0"
23
24
  },
24
25
  "devDependencies": {
25
- "@types/jest": "^26.0.4",
26
+ "@tsconfig/recommended": "1.0.1",
26
27
  "@types/node": "^10.0.0",
27
- "jest": "^26.1.0",
28
+ "concurrently": "7.0.0",
29
+ "downlevel-dts": "0.7.0",
30
+ "rimraf": "3.0.2",
31
+ "typedoc": "0.19.2",
28
32
  "typescript": "~4.3.5"
29
33
  },
30
34
  "engines": {
31
- "node": ">= 10.0.0"
35
+ "node": ">= 12.0.0"
32
36
  },
33
37
  "typesVersions": {
34
38
  "<4.0": {