@cdklabs/cdk-ecs-codedeploy 0.0.337 → 0.0.339

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.
Files changed (159) hide show
  1. package/.jsii +3 -3
  2. package/lib/api-canary/index.js +1 -1
  3. package/lib/ecs-appspec/index.js +1 -1
  4. package/lib/ecs-deployment/index.js +1 -1
  5. package/lib/ecs-patterns/application-load-balanced-codedeployed-fargate-service.js +1 -1
  6. package/node_modules/@aws-sdk/client-codedeploy/dist-types/runtimeConfig.browser.d.ts +1 -1
  7. package/node_modules/@aws-sdk/client-codedeploy/dist-types/runtimeConfig.native.d.ts +1 -1
  8. package/node_modules/@aws-sdk/client-codedeploy/dist-types/ts3.4/runtimeConfig.browser.d.ts +3 -1
  9. package/node_modules/@aws-sdk/client-codedeploy/dist-types/ts3.4/runtimeConfig.native.d.ts +3 -1
  10. package/node_modules/@aws-sdk/client-codedeploy/package.json +5 -5
  11. package/node_modules/@aws-sdk/client-sso/dist-types/runtimeConfig.browser.d.ts +1 -1
  12. package/node_modules/@aws-sdk/client-sso/dist-types/runtimeConfig.native.d.ts +1 -1
  13. package/node_modules/@aws-sdk/client-sso/dist-types/ts3.4/runtimeConfig.browser.d.ts +3 -1
  14. package/node_modules/@aws-sdk/client-sso/dist-types/ts3.4/runtimeConfig.native.d.ts +3 -1
  15. package/node_modules/@aws-sdk/client-sso/package.json +2 -2
  16. package/node_modules/@aws-sdk/client-sso-oidc/dist-types/runtimeConfig.browser.d.ts +1 -1
  17. package/node_modules/@aws-sdk/client-sso-oidc/dist-types/runtimeConfig.native.d.ts +1 -1
  18. package/node_modules/@aws-sdk/client-sso-oidc/dist-types/ts3.4/runtimeConfig.browser.d.ts +3 -1
  19. package/node_modules/@aws-sdk/client-sso-oidc/dist-types/ts3.4/runtimeConfig.native.d.ts +3 -1
  20. package/node_modules/@aws-sdk/client-sso-oidc/package.json +4 -4
  21. package/node_modules/@aws-sdk/client-sts/dist-types/runtimeConfig.browser.d.ts +1 -1
  22. package/node_modules/@aws-sdk/client-sts/dist-types/runtimeConfig.native.d.ts +1 -1
  23. package/node_modules/@aws-sdk/client-sts/dist-types/ts3.4/runtimeConfig.browser.d.ts +3 -1
  24. package/node_modules/@aws-sdk/client-sts/dist-types/ts3.4/runtimeConfig.native.d.ts +3 -1
  25. package/node_modules/@aws-sdk/client-sts/package.json +4 -4
  26. package/node_modules/@aws-sdk/credential-provider-ini/package.json +3 -3
  27. package/node_modules/@aws-sdk/credential-provider-node/package.json +3 -3
  28. package/node_modules/@aws-sdk/credential-provider-sso/package.json +2 -2
  29. package/node_modules/@aws-sdk/util-user-agent-browser/dist-cjs/index.native.js +8 -3
  30. package/node_modules/@aws-sdk/util-user-agent-browser/dist-es/index.native.js +6 -1
  31. package/node_modules/@aws-sdk/util-user-agent-browser/dist-types/index.d.ts +2 -5
  32. package/node_modules/@aws-sdk/util-user-agent-browser/dist-types/index.native.d.ts +9 -1
  33. package/node_modules/@aws-sdk/util-user-agent-browser/dist-types/ts3.4/index.d.ts +2 -2
  34. package/node_modules/@aws-sdk/util-user-agent-browser/dist-types/ts3.4/index.native.d.ts +12 -1
  35. package/node_modules/@aws-sdk/util-user-agent-browser/package.json +1 -1
  36. package/node_modules/@smithy/abort-controller/package.json +2 -2
  37. package/node_modules/@smithy/config-resolver/package.json +4 -4
  38. package/node_modules/@smithy/core/dist-cjs/index.js +79 -158
  39. package/node_modules/@smithy/core/dist-cjs/setFeature.js +1 -0
  40. package/node_modules/@smithy/core/dist-cjs/submodules/cbor/index.js +2 -2
  41. package/node_modules/@smithy/core/dist-cjs/submodules/protocols/index.js +163 -0
  42. package/node_modules/@smithy/core/dist-es/index.js +4 -3
  43. package/node_modules/@smithy/core/dist-es/middleware-http-auth-scheme/getHttpAuthSchemeEndpointRuleSetPlugin.js +1 -2
  44. package/node_modules/@smithy/core/dist-es/middleware-http-signing/getHttpSigningMiddleware.js +1 -2
  45. package/node_modules/@smithy/core/dist-es/protocols/requestBuilder.js +1 -67
  46. package/node_modules/@smithy/core/dist-es/setFeature.js +11 -0
  47. package/node_modules/@smithy/core/dist-es/submodules/cbor/parseCborBody.js +1 -1
  48. package/node_modules/@smithy/core/dist-es/submodules/protocols/collect-stream-body.js +11 -0
  49. package/node_modules/@smithy/core/dist-es/submodules/protocols/extended-encode-uri-component.js +5 -0
  50. package/node_modules/@smithy/core/dist-es/submodules/protocols/index.js +4 -0
  51. package/node_modules/@smithy/core/dist-es/submodules/protocols/requestBuilder.js +67 -0
  52. package/node_modules/@smithy/core/dist-es/submodules/protocols/resolve-path.js +19 -0
  53. package/node_modules/@smithy/core/dist-types/index.d.ts +4 -3
  54. package/node_modules/@smithy/core/dist-types/protocols/requestBuilder.d.ts +2 -48
  55. package/node_modules/@smithy/core/dist-types/setFeature.d.ts +12 -0
  56. package/node_modules/@smithy/core/dist-types/submodules/protocols/collect-stream-body.d.ts +10 -0
  57. package/node_modules/@smithy/core/dist-types/submodules/protocols/extended-encode-uri-component.d.ts +7 -0
  58. package/node_modules/@smithy/core/dist-types/submodules/protocols/index.d.ts +4 -0
  59. package/node_modules/@smithy/core/dist-types/submodules/protocols/requestBuilder.d.ts +51 -0
  60. package/node_modules/@smithy/core/dist-types/submodules/protocols/resolve-path.d.ts +4 -0
  61. package/node_modules/@smithy/core/dist-types/ts3.4/index.d.ts +4 -3
  62. package/node_modules/@smithy/core/dist-types/ts3.4/protocols/requestBuilder.d.ts +2 -48
  63. package/node_modules/@smithy/core/dist-types/ts3.4/setFeature.d.ts +12 -0
  64. package/node_modules/@smithy/core/dist-types/ts3.4/submodules/protocols/collect-stream-body.d.ts +10 -0
  65. package/node_modules/@smithy/core/dist-types/ts3.4/submodules/protocols/extended-encode-uri-component.d.ts +7 -0
  66. package/node_modules/@smithy/core/dist-types/ts3.4/submodules/protocols/index.d.ts +4 -0
  67. package/node_modules/@smithy/core/dist-types/ts3.4/submodules/protocols/requestBuilder.d.ts +51 -0
  68. package/node_modules/@smithy/core/dist-types/ts3.4/submodules/protocols/resolve-path.d.ts +4 -0
  69. package/node_modules/@smithy/core/package.json +15 -8
  70. package/node_modules/@smithy/core/protocols.d.ts +7 -0
  71. package/node_modules/@smithy/core/protocols.js +6 -0
  72. package/node_modules/@smithy/credential-provider-imds/package.json +5 -5
  73. package/node_modules/@smithy/hash-node/package.json +2 -2
  74. package/node_modules/@smithy/invalid-dependency/package.json +2 -2
  75. package/node_modules/@smithy/middleware-content-length/package.json +3 -3
  76. package/node_modules/@smithy/middleware-endpoint/dist-cjs/index.js +4 -0
  77. package/node_modules/@smithy/middleware-endpoint/dist-es/endpointMiddleware.js +4 -0
  78. package/node_modules/@smithy/middleware-endpoint/package.json +8 -7
  79. package/node_modules/@smithy/middleware-retry/package.json +8 -8
  80. package/node_modules/@smithy/middleware-serde/package.json +2 -2
  81. package/node_modules/@smithy/middleware-stack/package.json +2 -2
  82. package/node_modules/@smithy/node-config-provider/package.json +4 -4
  83. package/node_modules/@smithy/node-http-handler/package.json +5 -5
  84. package/node_modules/@smithy/property-provider/package.json +2 -2
  85. package/node_modules/@smithy/protocol-http/package.json +2 -2
  86. package/node_modules/@smithy/querystring-builder/package.json +2 -2
  87. package/node_modules/@smithy/querystring-parser/package.json +2 -2
  88. package/node_modules/@smithy/service-error-classification/package.json +2 -2
  89. package/node_modules/@smithy/shared-ini-file-loader/package.json +2 -2
  90. package/node_modules/@smithy/signature-v4/package.json +4 -4
  91. package/node_modules/@smithy/smithy-client/dist-cjs/index.js +6 -35
  92. package/node_modules/@smithy/smithy-client/dist-es/collect-stream-body.js +1 -11
  93. package/node_modules/@smithy/smithy-client/dist-es/extended-encode-uri-component.js +1 -5
  94. package/node_modules/@smithy/smithy-client/dist-es/resolve-path.js +1 -19
  95. package/node_modules/@smithy/smithy-client/dist-types/collect-stream-body.d.ts +2 -7
  96. package/node_modules/@smithy/smithy-client/dist-types/extended-encode-uri-component.d.ts +2 -4
  97. package/node_modules/@smithy/smithy-client/dist-types/resolve-path.d.ts +2 -1
  98. package/node_modules/@smithy/smithy-client/dist-types/ts3.4/collect-stream-body.d.ts +2 -7
  99. package/node_modules/@smithy/smithy-client/dist-types/ts3.4/extended-encode-uri-component.d.ts +2 -4
  100. package/node_modules/@smithy/smithy-client/dist-types/ts3.4/resolve-path.d.ts +2 -1
  101. package/node_modules/@smithy/smithy-client/package.json +7 -6
  102. package/node_modules/@smithy/types/dist-cjs/feature-ids.js +1 -0
  103. package/node_modules/@smithy/types/dist-es/feature-ids.js +1 -0
  104. package/node_modules/@smithy/types/dist-es/index.js +1 -0
  105. package/node_modules/@smithy/types/dist-types/feature-ids.d.ts +16 -0
  106. package/node_modules/@smithy/types/dist-types/index.d.ts +1 -0
  107. package/node_modules/@smithy/types/dist-types/middleware.d.ts +30 -6
  108. package/node_modules/@smithy/types/dist-types/ts3.4/feature-ids.d.ts +16 -0
  109. package/node_modules/@smithy/types/dist-types/ts3.4/index.d.ts +1 -0
  110. package/node_modules/@smithy/types/dist-types/ts3.4/middleware.d.ts +26 -2
  111. package/node_modules/@smithy/types/package.json +1 -1
  112. package/node_modules/@smithy/url-parser/package.json +3 -3
  113. package/node_modules/@smithy/util-defaults-mode-browser/package.json +4 -4
  114. package/node_modules/@smithy/util-defaults-mode-node/package.json +7 -7
  115. package/node_modules/@smithy/util-endpoints/package.json +3 -3
  116. package/node_modules/@smithy/util-middleware/package.json +2 -2
  117. package/node_modules/@smithy/util-retry/package.json +3 -3
  118. package/node_modules/@smithy/util-stream/dist-cjs/checksum/ChecksumStream.browser.js +7 -0
  119. package/node_modules/@smithy/util-stream/dist-cjs/checksum/ChecksumStream.js +49 -0
  120. package/node_modules/@smithy/util-stream/dist-cjs/checksum/createChecksumStream.browser.js +40 -0
  121. package/node_modules/@smithy/util-stream/dist-cjs/checksum/createChecksumStream.js +13 -0
  122. package/node_modules/@smithy/util-stream/dist-cjs/index.js +5 -1
  123. package/node_modules/@smithy/util-stream/dist-es/checksum/ChecksumStream.browser.js +3 -0
  124. package/node_modules/@smithy/util-stream/dist-es/checksum/ChecksumStream.js +44 -0
  125. package/node_modules/@smithy/util-stream/dist-es/checksum/createChecksumStream.browser.js +35 -0
  126. package/node_modules/@smithy/util-stream/dist-es/checksum/createChecksumStream.js +9 -0
  127. package/node_modules/@smithy/util-stream/dist-es/index.js +2 -0
  128. package/node_modules/@smithy/util-stream/dist-types/checksum/ChecksumStream.browser.d.ts +37 -0
  129. package/node_modules/@smithy/util-stream/dist-types/checksum/ChecksumStream.d.ts +61 -0
  130. package/node_modules/@smithy/util-stream/dist-types/checksum/createChecksumStream.browser.d.ts +15 -0
  131. package/node_modules/@smithy/util-stream/dist-types/checksum/createChecksumStream.d.ts +12 -0
  132. package/node_modules/@smithy/util-stream/dist-types/index.d.ts +2 -0
  133. package/node_modules/@smithy/util-stream/dist-types/ts3.4/checksum/ChecksumStream.browser.d.ts +37 -0
  134. package/node_modules/@smithy/util-stream/dist-types/ts3.4/checksum/ChecksumStream.d.ts +60 -0
  135. package/node_modules/@smithy/util-stream/dist-types/ts3.4/checksum/createChecksumStream.browser.d.ts +15 -0
  136. package/node_modules/@smithy/util-stream/dist-types/ts3.4/checksum/createChecksumStream.d.ts +12 -0
  137. package/node_modules/@smithy/util-stream/dist-types/ts3.4/index.d.ts +2 -0
  138. package/node_modules/@smithy/util-stream/node_modules/@smithy/fetch-http-handler/LICENSE +201 -0
  139. package/node_modules/@smithy/util-stream/node_modules/@smithy/fetch-http-handler/README.md +11 -0
  140. package/node_modules/@smithy/util-stream/node_modules/@smithy/fetch-http-handler/dist-cjs/fetch-http-handler.js +1 -0
  141. package/node_modules/@smithy/util-stream/node_modules/@smithy/fetch-http-handler/dist-cjs/index.js +230 -0
  142. package/node_modules/@smithy/util-stream/node_modules/@smithy/fetch-http-handler/dist-cjs/request-timeout.js +1 -0
  143. package/node_modules/@smithy/util-stream/node_modules/@smithy/fetch-http-handler/dist-cjs/stream-collector.js +1 -0
  144. package/node_modules/@smithy/util-stream/node_modules/@smithy/fetch-http-handler/dist-es/fetch-http-handler.js +138 -0
  145. package/node_modules/@smithy/util-stream/node_modules/@smithy/fetch-http-handler/dist-es/index.js +2 -0
  146. package/node_modules/@smithy/util-stream/node_modules/@smithy/fetch-http-handler/dist-es/request-timeout.js +11 -0
  147. package/node_modules/@smithy/util-stream/node_modules/@smithy/fetch-http-handler/dist-es/stream-collector.js +27 -0
  148. package/node_modules/@smithy/util-stream/node_modules/@smithy/fetch-http-handler/dist-types/fetch-http-handler.d.ts +33 -0
  149. package/node_modules/@smithy/util-stream/node_modules/@smithy/fetch-http-handler/dist-types/index.d.ts +2 -0
  150. package/node_modules/@smithy/util-stream/node_modules/@smithy/fetch-http-handler/dist-types/request-timeout.d.ts +1 -0
  151. package/node_modules/@smithy/util-stream/node_modules/@smithy/fetch-http-handler/dist-types/stream-collector.d.ts +2 -0
  152. package/node_modules/@smithy/util-stream/node_modules/@smithy/fetch-http-handler/dist-types/ts3.4/fetch-http-handler.d.ts +33 -0
  153. package/node_modules/@smithy/util-stream/node_modules/@smithy/fetch-http-handler/dist-types/ts3.4/index.d.ts +2 -0
  154. package/node_modules/@smithy/util-stream/node_modules/@smithy/fetch-http-handler/dist-types/ts3.4/request-timeout.d.ts +1 -0
  155. package/node_modules/@smithy/util-stream/node_modules/@smithy/fetch-http-handler/dist-types/ts3.4/stream-collector.d.ts +2 -0
  156. package/node_modules/@smithy/util-stream/node_modules/@smithy/fetch-http-handler/package.json +62 -0
  157. package/node_modules/@smithy/util-stream/package.json +10 -4
  158. package/node_modules/@smithy/util-waiter/package.json +3 -3
  159. package/package.json +5 -5
@@ -0,0 +1,138 @@
1
+ import { HttpResponse } from "@smithy/protocol-http";
2
+ import { buildQueryString } from "@smithy/querystring-builder";
3
+ import { requestTimeout } from "./request-timeout";
4
+ export const keepAliveSupport = {
5
+ supported: undefined,
6
+ };
7
+ export class FetchHttpHandler {
8
+ static create(instanceOrOptions) {
9
+ if (typeof instanceOrOptions?.handle === "function") {
10
+ return instanceOrOptions;
11
+ }
12
+ return new FetchHttpHandler(instanceOrOptions);
13
+ }
14
+ constructor(options) {
15
+ if (typeof options === "function") {
16
+ this.configProvider = options().then((opts) => opts || {});
17
+ }
18
+ else {
19
+ this.config = options ?? {};
20
+ this.configProvider = Promise.resolve(this.config);
21
+ }
22
+ if (keepAliveSupport.supported === undefined) {
23
+ keepAliveSupport.supported = Boolean(typeof Request !== "undefined" && "keepalive" in new Request("https://[::1]"));
24
+ }
25
+ }
26
+ destroy() {
27
+ }
28
+ async handle(request, { abortSignal } = {}) {
29
+ if (!this.config) {
30
+ this.config = await this.configProvider;
31
+ }
32
+ const requestTimeoutInMs = this.config.requestTimeout;
33
+ const keepAlive = this.config.keepAlive === true;
34
+ const credentials = this.config.credentials;
35
+ if (abortSignal?.aborted) {
36
+ const abortError = new Error("Request aborted");
37
+ abortError.name = "AbortError";
38
+ return Promise.reject(abortError);
39
+ }
40
+ let path = request.path;
41
+ const queryString = buildQueryString(request.query || {});
42
+ if (queryString) {
43
+ path += `?${queryString}`;
44
+ }
45
+ if (request.fragment) {
46
+ path += `#${request.fragment}`;
47
+ }
48
+ let auth = "";
49
+ if (request.username != null || request.password != null) {
50
+ const username = request.username ?? "";
51
+ const password = request.password ?? "";
52
+ auth = `${username}:${password}@`;
53
+ }
54
+ const { port, method } = request;
55
+ const url = `${request.protocol}//${auth}${request.hostname}${port ? `:${port}` : ""}${path}`;
56
+ const body = method === "GET" || method === "HEAD" ? undefined : request.body;
57
+ const requestOptions = {
58
+ body,
59
+ headers: new Headers(request.headers),
60
+ method: method,
61
+ credentials,
62
+ };
63
+ if (this.config?.cache) {
64
+ requestOptions.cache = this.config.cache;
65
+ }
66
+ if (body) {
67
+ requestOptions.duplex = "half";
68
+ }
69
+ if (typeof AbortController !== "undefined") {
70
+ requestOptions.signal = abortSignal;
71
+ }
72
+ if (keepAliveSupport.supported) {
73
+ requestOptions.keepalive = keepAlive;
74
+ }
75
+ if (typeof this.config.requestInit === "function") {
76
+ Object.assign(requestOptions, this.config.requestInit(request));
77
+ }
78
+ let removeSignalEventListener = () => { };
79
+ const fetchRequest = new Request(url, requestOptions);
80
+ const raceOfPromises = [
81
+ fetch(fetchRequest).then((response) => {
82
+ const fetchHeaders = response.headers;
83
+ const transformedHeaders = {};
84
+ for (const pair of fetchHeaders.entries()) {
85
+ transformedHeaders[pair[0]] = pair[1];
86
+ }
87
+ const hasReadableStream = response.body != undefined;
88
+ if (!hasReadableStream) {
89
+ return response.blob().then((body) => ({
90
+ response: new HttpResponse({
91
+ headers: transformedHeaders,
92
+ reason: response.statusText,
93
+ statusCode: response.status,
94
+ body,
95
+ }),
96
+ }));
97
+ }
98
+ return {
99
+ response: new HttpResponse({
100
+ headers: transformedHeaders,
101
+ reason: response.statusText,
102
+ statusCode: response.status,
103
+ body: response.body,
104
+ }),
105
+ };
106
+ }),
107
+ requestTimeout(requestTimeoutInMs),
108
+ ];
109
+ if (abortSignal) {
110
+ raceOfPromises.push(new Promise((resolve, reject) => {
111
+ const onAbort = () => {
112
+ const abortError = new Error("Request aborted");
113
+ abortError.name = "AbortError";
114
+ reject(abortError);
115
+ };
116
+ if (typeof abortSignal.addEventListener === "function") {
117
+ const signal = abortSignal;
118
+ signal.addEventListener("abort", onAbort, { once: true });
119
+ removeSignalEventListener = () => signal.removeEventListener("abort", onAbort);
120
+ }
121
+ else {
122
+ abortSignal.onabort = onAbort;
123
+ }
124
+ }));
125
+ }
126
+ return Promise.race(raceOfPromises).finally(removeSignalEventListener);
127
+ }
128
+ updateHttpClientConfig(key, value) {
129
+ this.config = undefined;
130
+ this.configProvider = this.configProvider.then((config) => {
131
+ config[key] = value;
132
+ return config;
133
+ });
134
+ }
135
+ httpHandlerConfigs() {
136
+ return this.config ?? {};
137
+ }
138
+ }
@@ -0,0 +1,2 @@
1
+ export * from "./fetch-http-handler";
2
+ export * from "./stream-collector";
@@ -0,0 +1,11 @@
1
+ export function requestTimeout(timeoutInMs = 0) {
2
+ return new Promise((resolve, reject) => {
3
+ if (timeoutInMs) {
4
+ setTimeout(() => {
5
+ const timeoutError = new Error(`Request did not complete within ${timeoutInMs} ms`);
6
+ timeoutError.name = "TimeoutError";
7
+ reject(timeoutError);
8
+ }, timeoutInMs);
9
+ }
10
+ });
11
+ }
@@ -0,0 +1,27 @@
1
+ export const streamCollector = async (stream) => {
2
+ if (typeof Blob === "function" && stream instanceof Blob) {
3
+ return new Uint8Array(await stream.arrayBuffer());
4
+ }
5
+ return collectStream(stream);
6
+ };
7
+ async function collectStream(stream) {
8
+ const chunks = [];
9
+ const reader = stream.getReader();
10
+ let isDone = false;
11
+ let length = 0;
12
+ while (!isDone) {
13
+ const { done, value } = await reader.read();
14
+ if (value) {
15
+ chunks.push(value);
16
+ length += value.length;
17
+ }
18
+ isDone = done;
19
+ }
20
+ const collected = new Uint8Array(length);
21
+ let offset = 0;
22
+ for (const chunk of chunks) {
23
+ collected.set(chunk, offset);
24
+ offset += chunk.length;
25
+ }
26
+ return collected;
27
+ }
@@ -0,0 +1,33 @@
1
+ import { HttpHandler, HttpRequest, HttpResponse } from "@smithy/protocol-http";
2
+ import type { FetchHttpHandlerOptions } from "@smithy/types";
3
+ import { HttpHandlerOptions, Provider } from "@smithy/types";
4
+ export { FetchHttpHandlerOptions };
5
+ type FetchHttpHandlerConfig = FetchHttpHandlerOptions;
6
+ /**
7
+ * @internal
8
+ * Detection of keepalive support. Can be overridden for testing.
9
+ */
10
+ export declare const keepAliveSupport: {
11
+ supported: boolean | undefined;
12
+ };
13
+ /**
14
+ * @public
15
+ *
16
+ * HttpHandler implementation using browsers' `fetch` global function.
17
+ */
18
+ export declare class FetchHttpHandler implements HttpHandler<FetchHttpHandlerConfig> {
19
+ private config?;
20
+ private configProvider;
21
+ /**
22
+ * @returns the input if it is an HttpHandler of any class,
23
+ * or instantiates a new instance of this handler.
24
+ */
25
+ static create(instanceOrOptions?: HttpHandler<any> | FetchHttpHandlerOptions | Provider<FetchHttpHandlerOptions | void>): FetchHttpHandler | HttpHandler<any>;
26
+ constructor(options?: FetchHttpHandlerOptions | Provider<FetchHttpHandlerOptions | void>);
27
+ destroy(): void;
28
+ handle(request: HttpRequest, { abortSignal }?: HttpHandlerOptions): Promise<{
29
+ response: HttpResponse;
30
+ }>;
31
+ updateHttpClientConfig(key: keyof FetchHttpHandlerConfig, value: FetchHttpHandlerConfig[typeof key]): void;
32
+ httpHandlerConfigs(): FetchHttpHandlerConfig;
33
+ }
@@ -0,0 +1,2 @@
1
+ export * from "./fetch-http-handler";
2
+ export * from "./stream-collector";
@@ -0,0 +1 @@
1
+ export declare function requestTimeout(timeoutInMs?: number): Promise<never>;
@@ -0,0 +1,2 @@
1
+ import { StreamCollector } from "@smithy/types";
2
+ export declare const streamCollector: StreamCollector;
@@ -0,0 +1,33 @@
1
+ import { HttpHandler, HttpRequest, HttpResponse } from "@smithy/protocol-http";
2
+ import { FetchHttpHandlerOptions } from "@smithy/types";
3
+ import { HttpHandlerOptions, Provider } from "@smithy/types";
4
+ export { FetchHttpHandlerOptions };
5
+ type FetchHttpHandlerConfig = FetchHttpHandlerOptions;
6
+ /**
7
+ * @internal
8
+ * Detection of keepalive support. Can be overridden for testing.
9
+ */
10
+ export declare const keepAliveSupport: {
11
+ supported: boolean | undefined;
12
+ };
13
+ /**
14
+ * @public
15
+ *
16
+ * HttpHandler implementation using browsers' `fetch` global function.
17
+ */
18
+ export declare class FetchHttpHandler implements HttpHandler<FetchHttpHandlerConfig> {
19
+ private config?;
20
+ private configProvider;
21
+ /**
22
+ * @returns the input if it is an HttpHandler of any class,
23
+ * or instantiates a new instance of this handler.
24
+ */
25
+ static create(instanceOrOptions?: HttpHandler<any> | FetchHttpHandlerOptions | Provider<FetchHttpHandlerOptions | void>): FetchHttpHandler | HttpHandler<any>;
26
+ constructor(options?: FetchHttpHandlerOptions | Provider<FetchHttpHandlerOptions | void>);
27
+ destroy(): void;
28
+ handle(request: HttpRequest, { abortSignal }?: HttpHandlerOptions): Promise<{
29
+ response: HttpResponse;
30
+ }>;
31
+ updateHttpClientConfig(key: keyof FetchHttpHandlerConfig, value: FetchHttpHandlerConfig[typeof key]): void;
32
+ httpHandlerConfigs(): FetchHttpHandlerConfig;
33
+ }
@@ -0,0 +1,2 @@
1
+ export * from "./fetch-http-handler";
2
+ export * from "./stream-collector";
@@ -0,0 +1 @@
1
+ export declare function requestTimeout(timeoutInMs?: number): Promise<never>;
@@ -0,0 +1,2 @@
1
+ import { StreamCollector } from "@smithy/types";
2
+ export declare const streamCollector: StreamCollector;
@@ -0,0 +1,62 @@
1
+ {
2
+ "name": "@smithy/fetch-http-handler",
3
+ "version": "4.0.0",
4
+ "description": "Provides a way to make requests",
5
+ "scripts": {
6
+ "build": "concurrently 'yarn:build:cjs' 'yarn:build:es' 'yarn:build:types && yarn build:types:downlevel'",
7
+ "build:cjs": "node ../../scripts/inline fetch-http-handler",
8
+ "build:es": "yarn g:tsc -p tsconfig.es.json",
9
+ "build:types": "yarn g:tsc -p tsconfig.types.json",
10
+ "build:types:downlevel": "rimraf dist-types/ts3.4 && downlevel-dts dist-types dist-types/ts3.4",
11
+ "stage-release": "rimraf ./.release && yarn pack && mkdir ./.release && tar zxvf ./package.tgz --directory ./.release && rm ./package.tgz",
12
+ "clean": "rimraf ./dist-* && rimraf *.tsbuildinfo || exit 0",
13
+ "lint": "eslint -c ../../.eslintrc.js \"src/**/*.ts\"",
14
+ "format": "prettier --config ../../prettier.config.js --ignore-path ../.prettierignore --write \"**/*.{ts,md,json}\"",
15
+ "extract:docs": "api-extractor run --local",
16
+ "test": "yarn g:jest --coverage --forceExit && yarn g:karma start karma.conf.js"
17
+ },
18
+ "author": {
19
+ "name": "AWS SDK for JavaScript Team",
20
+ "url": "https://aws.amazon.com/javascript/"
21
+ },
22
+ "license": "Apache-2.0",
23
+ "main": "./dist-cjs/index.js",
24
+ "module": "./dist-es/index.js",
25
+ "types": "./dist-types/index.d.ts",
26
+ "dependencies": {
27
+ "@smithy/protocol-http": "^4.1.5",
28
+ "@smithy/querystring-builder": "^3.0.8",
29
+ "@smithy/types": "^3.6.0",
30
+ "@smithy/util-base64": "^3.0.0",
31
+ "tslib": "^2.6.2"
32
+ },
33
+ "devDependencies": {
34
+ "@smithy/abort-controller": "^3.1.6",
35
+ "concurrently": "7.0.0",
36
+ "downlevel-dts": "0.10.1",
37
+ "rimraf": "3.0.2",
38
+ "typedoc": "0.23.23"
39
+ },
40
+ "typesVersions": {
41
+ "<4.0": {
42
+ "dist-types/*": [
43
+ "dist-types/ts3.4/*"
44
+ ]
45
+ }
46
+ },
47
+ "files": [
48
+ "dist-*/**"
49
+ ],
50
+ "homepage": "https://github.com/awslabs/smithy-typescript/tree/main/packages/fetch-http-handler",
51
+ "repository": {
52
+ "type": "git",
53
+ "url": "https://github.com/awslabs/smithy-typescript.git",
54
+ "directory": "packages/fetch-http-handler"
55
+ },
56
+ "typedoc": {
57
+ "entryPoint": "src/index.ts"
58
+ },
59
+ "publishConfig": {
60
+ "directory": ".release/package"
61
+ }
62
+ }
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@smithy/util-stream",
3
- "version": "3.1.9",
3
+ "version": "3.2.1",
4
4
  "scripts": {
5
5
  "build": "concurrently 'yarn:build:cjs' 'yarn:build:es' 'yarn:build:types && yarn build:types:downlevel'",
6
6
  "build:cjs": "node ../../scripts/inline util-stream",
@@ -24,9 +24,9 @@
24
24
  },
25
25
  "license": "Apache-2.0",
26
26
  "dependencies": {
27
- "@smithy/fetch-http-handler": "^3.2.9",
28
- "@smithy/node-http-handler": "^3.2.4",
29
- "@smithy/types": "^3.5.0",
27
+ "@smithy/fetch-http-handler": "^4.0.0",
28
+ "@smithy/node-http-handler": "^3.2.5",
29
+ "@smithy/types": "^3.6.0",
30
30
  "@smithy/util-base64": "^3.0.0",
31
31
  "@smithy/util-buffer-from": "^3.0.0",
32
32
  "@smithy/util-hex-encoding": "^3.0.0",
@@ -55,16 +55,22 @@
55
55
  "dist-*/**"
56
56
  ],
57
57
  "browser": {
58
+ "./dist-es/checksum/ChecksumStream": "./dist-es/checksum/ChecksumStream.browser",
59
+ "./dist-es/checksum/createChecksumStream": "./dist-es/checksum/createChecksumStream.browser",
58
60
  "./dist-es/getAwsChunkedEncodingStream": "./dist-es/getAwsChunkedEncodingStream.browser",
59
61
  "./dist-es/headStream": "./dist-es/headStream.browser",
60
62
  "./dist-es/sdk-stream-mixin": "./dist-es/sdk-stream-mixin.browser",
61
63
  "./dist-es/splitStream": "./dist-es/splitStream.browser"
62
64
  },
63
65
  "react-native": {
66
+ "./dist-es/checksum/createChecksumStream": "./dist-es/checksum/createChecksumStream.browser",
67
+ "./dist-es/checksum/ChecksumStream": "./dist-es/checksum/ChecksumStream.browser",
64
68
  "./dist-es/getAwsChunkedEncodingStream": "./dist-es/getAwsChunkedEncodingStream.browser",
65
69
  "./dist-es/sdk-stream-mixin": "./dist-es/sdk-stream-mixin.browser",
66
70
  "./dist-es/headStream": "./dist-es/headStream.browser",
67
71
  "./dist-es/splitStream": "./dist-es/splitStream.browser",
72
+ "./dist-cjs/checksum/createChecksumStream": "./dist-cjs/checksum/createChecksumStream.browser",
73
+ "./dist-cjs/checksum/ChecksumStream": "./dist-cjs/checksum/ChecksumStream.browser",
68
74
  "./dist-cjs/getAwsChunkedEncodingStream": "./dist-cjs/getAwsChunkedEncodingStream.browser",
69
75
  "./dist-cjs/sdk-stream-mixin": "./dist-cjs/sdk-stream-mixin.browser",
70
76
  "./dist-cjs/headStream": "./dist-cjs/headStream.browser",
@@ -1,10 +1,10 @@
1
1
  {
2
2
  "name": "@smithy/util-waiter",
3
- "version": "3.1.6",
3
+ "version": "3.1.7",
4
4
  "description": "Shared utilities for client waiters for the AWS SDK",
5
5
  "dependencies": {
6
- "@smithy/abort-controller": "^3.1.5",
7
- "@smithy/types": "^3.5.0",
6
+ "@smithy/abort-controller": "^3.1.6",
7
+ "@smithy/types": "^3.6.0",
8
8
  "tslib": "^2.6.2"
9
9
  },
10
10
  "scripts": {
package/package.json CHANGED
@@ -81,9 +81,9 @@
81
81
  "@typescript-eslint/parser": "^7",
82
82
  "aws-cdk": "^2",
83
83
  "aws-cdk-lib": "2.139.0",
84
- "aws-sdk-client-mock": "^4.0.2",
85
- "aws-sdk-client-mock-jest": "^4.0.2",
86
- "cdk-nag": "^2.29.6",
84
+ "aws-sdk-client-mock": "^4.1.0",
85
+ "aws-sdk-client-mock-jest": "^4.1.0",
86
+ "cdk-nag": "^2.29.12",
87
87
  "cdklabs-projen-project-types": "^0.1.204",
88
88
  "commit-and-tag-version": "^12",
89
89
  "constructs": "10.0.5",
@@ -109,7 +109,7 @@
109
109
  "constructs": "^10.0.5"
110
110
  },
111
111
  "dependencies": {
112
- "@aws-sdk/client-codedeploy": "^3.670.0",
112
+ "@aws-sdk/client-codedeploy": "^3.675.0",
113
113
  "jmespath": "^0.16.0"
114
114
  },
115
115
  "bundledDependencies": [
@@ -127,7 +127,7 @@
127
127
  "publishConfig": {
128
128
  "access": "public"
129
129
  },
130
- "version": "0.0.337",
130
+ "version": "0.0.339",
131
131
  "jest": {
132
132
  "coverageProvider": "v8",
133
133
  "testMatch": [