backend v4 half
This commit is contained in:
+2
-2
@@ -83,11 +83,11 @@ var FetchHttpHandler = class _FetchHttpHandler {
|
||||
}
|
||||
destroy() {
|
||||
}
|
||||
async handle(request, { abortSignal } = {}) {
|
||||
async handle(request, { abortSignal, requestTimeout: requestTimeout2 } = {}) {
|
||||
if (!this.config) {
|
||||
this.config = await this.configProvider;
|
||||
}
|
||||
const requestTimeoutInMs = this.config.requestTimeout;
|
||||
const requestTimeoutInMs = requestTimeout2 ?? this.config.requestTimeout;
|
||||
const keepAlive = this.config.keepAlive === true;
|
||||
const credentials = this.config.credentials;
|
||||
if (abortSignal?.aborted) {
|
||||
|
||||
Generated
Vendored
+4
-4
@@ -1,7 +1,7 @@
|
||||
import { HttpResponse } from "@smithy/protocol-http";
|
||||
import { buildQueryString } from "@smithy/querystring-builder";
|
||||
import { createRequest } from "./create-request";
|
||||
import { requestTimeout } from "./request-timeout";
|
||||
import { requestTimeout as requestTimeoutFn } from "./request-timeout";
|
||||
export const keepAliveSupport = {
|
||||
supported: undefined,
|
||||
};
|
||||
@@ -26,11 +26,11 @@ export class FetchHttpHandler {
|
||||
}
|
||||
destroy() {
|
||||
}
|
||||
async handle(request, { abortSignal } = {}) {
|
||||
async handle(request, { abortSignal, requestTimeout } = {}) {
|
||||
if (!this.config) {
|
||||
this.config = await this.configProvider;
|
||||
}
|
||||
const requestTimeoutInMs = this.config.requestTimeout;
|
||||
const requestTimeoutInMs = requestTimeout ?? this.config.requestTimeout;
|
||||
const keepAlive = this.config.keepAlive === true;
|
||||
const credentials = this.config.credentials;
|
||||
if (abortSignal?.aborted) {
|
||||
@@ -105,7 +105,7 @@ export class FetchHttpHandler {
|
||||
}),
|
||||
};
|
||||
}),
|
||||
requestTimeout(requestTimeoutInMs),
|
||||
requestTimeoutFn(requestTimeoutInMs),
|
||||
];
|
||||
if (abortSignal) {
|
||||
raceOfPromises.push(new Promise((resolve, reject) => {
|
||||
|
||||
Generated
Vendored
+1
-1
@@ -33,7 +33,7 @@ export declare class FetchHttpHandler implements HttpHandler<FetchHttpHandlerOpt
|
||||
static create(instanceOrOptions?: HttpHandler<any> | FetchHttpHandlerOptions | Provider<FetchHttpHandlerOptions | void>): FetchHttpHandler | HttpHandler<any>;
|
||||
constructor(options?: FetchHttpHandlerOptions | Provider<FetchHttpHandlerOptions | void>);
|
||||
destroy(): void;
|
||||
handle(request: HttpRequest, { abortSignal }?: HttpHandlerOptions): Promise<{
|
||||
handle(request: HttpRequest, { abortSignal, requestTimeout }?: HttpHandlerOptions): Promise<{
|
||||
response: HttpResponse;
|
||||
}>;
|
||||
updateHttpClientConfig(key: keyof FetchHttpHandlerOptions, value: FetchHttpHandlerOptions[typeof key]): void;
|
||||
|
||||
SerpentRace_Backend/node_modules/@smithy/fetch-http-handler/dist-types/ts3.4/fetch-http-handler.d.ts
Generated
Vendored
+1
-1
@@ -33,7 +33,7 @@ export declare class FetchHttpHandler implements HttpHandler<FetchHttpHandlerOpt
|
||||
static create(instanceOrOptions?: HttpHandler<any> | FetchHttpHandlerOptions | Provider<FetchHttpHandlerOptions | void>): FetchHttpHandler | HttpHandler<any>;
|
||||
constructor(options?: FetchHttpHandlerOptions | Provider<FetchHttpHandlerOptions | void>);
|
||||
destroy(): void;
|
||||
handle(request: HttpRequest, { abortSignal }?: HttpHandlerOptions): Promise<{
|
||||
handle(request: HttpRequest, { abortSignal, requestTimeout }?: HttpHandlerOptions): Promise<{
|
||||
response: HttpResponse;
|
||||
}>;
|
||||
updateHttpClientConfig(key: keyof FetchHttpHandlerOptions, value: FetchHttpHandlerOptions[typeof key]): void;
|
||||
|
||||
+1
-1
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@smithy/fetch-http-handler",
|
||||
"version": "5.0.4",
|
||||
"version": "5.1.0",
|
||||
"description": "Provides a way to make requests",
|
||||
"scripts": {
|
||||
"build": "concurrently 'yarn:build:cjs' 'yarn:build:es' 'yarn:build:types && yarn build:types:downlevel'",
|
||||
|
||||
Reference in New Issue
Block a user