@aws-sdk/client-arc-region-switch 3.859.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/LICENSE +201 -0
- package/README.md +365 -0
- package/dist-cjs/ARCRegionSwitch.js +51 -0
- package/dist-cjs/ARCRegionSwitchClient.js +52 -0
- package/dist-cjs/auth/httpAuthExtensionConfiguration.js +43 -0
- package/dist-cjs/auth/httpAuthSchemeProvider.js +47 -0
- package/dist-cjs/commands/ApprovePlanExecutionStepCommand.js +26 -0
- package/dist-cjs/commands/CancelPlanExecutionCommand.js +26 -0
- package/dist-cjs/commands/CreatePlanCommand.js +29 -0
- package/dist-cjs/commands/DeletePlanCommand.js +29 -0
- package/dist-cjs/commands/GetPlanCommand.js +29 -0
- package/dist-cjs/commands/GetPlanEvaluationStatusCommand.js +26 -0
- package/dist-cjs/commands/GetPlanExecutionCommand.js +26 -0
- package/dist-cjs/commands/GetPlanInRegionCommand.js +26 -0
- package/dist-cjs/commands/ListPlanExecutionEventsCommand.js +26 -0
- package/dist-cjs/commands/ListPlanExecutionsCommand.js +26 -0
- package/dist-cjs/commands/ListPlansCommand.js +29 -0
- package/dist-cjs/commands/ListPlansInRegionCommand.js +26 -0
- package/dist-cjs/commands/ListRoute53HealthChecksCommand.js +29 -0
- package/dist-cjs/commands/ListTagsForResourceCommand.js +29 -0
- package/dist-cjs/commands/StartPlanExecutionCommand.js +26 -0
- package/dist-cjs/commands/TagResourceCommand.js +29 -0
- package/dist-cjs/commands/UntagResourceCommand.js +29 -0
- package/dist-cjs/commands/UpdatePlanCommand.js +29 -0
- package/dist-cjs/commands/UpdatePlanExecutionCommand.js +26 -0
- package/dist-cjs/commands/UpdatePlanExecutionStepCommand.js +26 -0
- package/dist-cjs/commands/index.js +23 -0
- package/dist-cjs/endpoint/EndpointParameters.js +15 -0
- package/dist-cjs/endpoint/endpointResolver.js +18 -0
- package/dist-cjs/endpoint/ruleset.js +7 -0
- package/dist-cjs/extensionConfiguration.js +2 -0
- package/dist-cjs/index.js +12 -0
- package/dist-cjs/models/ARCRegionSwitchServiceException.js +12 -0
- package/dist-cjs/models/index.js +4 -0
- package/dist-cjs/models/models_0.js +233 -0
- package/dist-cjs/pagination/GetPlanEvaluationStatusPaginator.js +7 -0
- package/dist-cjs/pagination/GetPlanExecutionPaginator.js +7 -0
- package/dist-cjs/pagination/Interfaces.js +2 -0
- package/dist-cjs/pagination/ListPlanExecutionEventsPaginator.js +7 -0
- package/dist-cjs/pagination/ListPlanExecutionsPaginator.js +7 -0
- package/dist-cjs/pagination/ListPlansInRegionPaginator.js +7 -0
- package/dist-cjs/pagination/ListPlansPaginator.js +7 -0
- package/dist-cjs/pagination/ListRoute53HealthChecksPaginator.js +7 -0
- package/dist-cjs/pagination/index.js +11 -0
- package/dist-cjs/protocols/Aws_json1_0.js +919 -0
- package/dist-cjs/runtimeConfig.browser.js +39 -0
- package/dist-cjs/runtimeConfig.js +56 -0
- package/dist-cjs/runtimeConfig.native.js +15 -0
- package/dist-cjs/runtimeConfig.shared.js +34 -0
- package/dist-cjs/runtimeExtensions.js +13 -0
- package/dist-cjs/waiters/index.js +5 -0
- package/dist-cjs/waiters/waitForPlanEvaluationStatusPassed.js +54 -0
- package/dist-cjs/waiters/waitForPlanExecutionCompleted.js +72 -0
- package/dist-es/ARCRegionSwitch.js +47 -0
- package/dist-es/ARCRegionSwitchClient.js +48 -0
- package/dist-es/auth/httpAuthExtensionConfiguration.js +38 -0
- package/dist-es/auth/httpAuthSchemeProvider.js +41 -0
- package/dist-es/commands/ApprovePlanExecutionStepCommand.js +22 -0
- package/dist-es/commands/CancelPlanExecutionCommand.js +22 -0
- package/dist-es/commands/CreatePlanCommand.js +25 -0
- package/dist-es/commands/DeletePlanCommand.js +25 -0
- package/dist-es/commands/GetPlanCommand.js +25 -0
- package/dist-es/commands/GetPlanEvaluationStatusCommand.js +22 -0
- package/dist-es/commands/GetPlanExecutionCommand.js +22 -0
- package/dist-es/commands/GetPlanInRegionCommand.js +22 -0
- package/dist-es/commands/ListPlanExecutionEventsCommand.js +22 -0
- package/dist-es/commands/ListPlanExecutionsCommand.js +22 -0
- package/dist-es/commands/ListPlansCommand.js +25 -0
- package/dist-es/commands/ListPlansInRegionCommand.js +22 -0
- package/dist-es/commands/ListRoute53HealthChecksCommand.js +25 -0
- package/dist-es/commands/ListTagsForResourceCommand.js +25 -0
- package/dist-es/commands/StartPlanExecutionCommand.js +22 -0
- package/dist-es/commands/TagResourceCommand.js +25 -0
- package/dist-es/commands/UntagResourceCommand.js +25 -0
- package/dist-es/commands/UpdatePlanCommand.js +25 -0
- package/dist-es/commands/UpdatePlanExecutionCommand.js +22 -0
- package/dist-es/commands/UpdatePlanExecutionStepCommand.js +22 -0
- package/dist-es/commands/index.js +20 -0
- package/dist-es/endpoint/EndpointParameters.js +11 -0
- package/dist-es/endpoint/endpointResolver.js +14 -0
- package/dist-es/endpoint/ruleset.js +4 -0
- package/dist-es/extensionConfiguration.js +1 -0
- package/dist-es/index.js +7 -0
- package/dist-es/models/ARCRegionSwitchServiceException.js +8 -0
- package/dist-es/models/index.js +1 -0
- package/dist-es/models/models_0.js +225 -0
- package/dist-es/pagination/GetPlanEvaluationStatusPaginator.js +4 -0
- package/dist-es/pagination/GetPlanExecutionPaginator.js +4 -0
- package/dist-es/pagination/Interfaces.js +1 -0
- package/dist-es/pagination/ListPlanExecutionEventsPaginator.js +4 -0
- package/dist-es/pagination/ListPlanExecutionsPaginator.js +4 -0
- package/dist-es/pagination/ListPlansInRegionPaginator.js +4 -0
- package/dist-es/pagination/ListPlansPaginator.js +4 -0
- package/dist-es/pagination/ListRoute53HealthChecksPaginator.js +4 -0
- package/dist-es/pagination/index.js +8 -0
- package/dist-es/protocols/Aws_json1_0.js +876 -0
- package/dist-es/runtimeConfig.browser.js +34 -0
- package/dist-es/runtimeConfig.js +51 -0
- package/dist-es/runtimeConfig.native.js +11 -0
- package/dist-es/runtimeConfig.shared.js +30 -0
- package/dist-es/runtimeExtensions.js +9 -0
- package/dist-es/waiters/index.js +2 -0
- package/dist-es/waiters/waitForPlanEvaluationStatusPassed.js +49 -0
- package/dist-es/waiters/waitForPlanExecutionCompleted.js +67 -0
- package/dist-types/ARCRegionSwitch.d.ts +152 -0
- package/dist-types/ARCRegionSwitchClient.d.ts +207 -0
- package/dist-types/auth/httpAuthExtensionConfiguration.d.ts +29 -0
- package/dist-types/auth/httpAuthSchemeProvider.d.ts +75 -0
- package/dist-types/commands/ApprovePlanExecutionStepCommand.d.ts +80 -0
- package/dist-types/commands/CancelPlanExecutionCommand.d.ts +78 -0
- package/dist-types/commands/CreatePlanCommand.d.ts +697 -0
- package/dist-types/commands/DeletePlanCommand.d.ts +76 -0
- package/dist-types/commands/GetPlanCommand.d.ts +389 -0
- package/dist-types/commands/GetPlanEvaluationStatusCommand.d.ts +99 -0
- package/dist-types/commands/GetPlanExecutionCommand.d.ts +417 -0
- package/dist-types/commands/GetPlanInRegionCommand.d.ts +392 -0
- package/dist-types/commands/ListPlanExecutionEventsCommand.d.ts +97 -0
- package/dist-types/commands/ListPlanExecutionsCommand.d.ts +97 -0
- package/dist-types/commands/ListPlansCommand.d.ts +91 -0
- package/dist-types/commands/ListPlansInRegionCommand.d.ts +94 -0
- package/dist-types/commands/ListRoute53HealthChecksCommand.d.ts +93 -0
- package/dist-types/commands/ListTagsForResourceCommand.d.ts +80 -0
- package/dist-types/commands/StartPlanExecutionCommand.d.ts +93 -0
- package/dist-types/commands/TagResourceCommand.d.ts +79 -0
- package/dist-types/commands/UntagResourceCommand.d.ts +79 -0
- package/dist-types/commands/UpdatePlanCommand.d.ts +692 -0
- package/dist-types/commands/UpdatePlanExecutionCommand.d.ts +82 -0
- package/dist-types/commands/UpdatePlanExecutionStepCommand.d.ts +80 -0
- package/dist-types/commands/index.d.ts +20 -0
- package/dist-types/endpoint/EndpointParameters.d.ts +33 -0
- package/dist-types/endpoint/endpointResolver.d.ts +5 -0
- package/dist-types/endpoint/ruleset.d.ts +2 -0
- package/dist-types/extensionConfiguration.d.ts +9 -0
- package/dist-types/index.d.ts +15 -0
- package/dist-types/models/ARCRegionSwitchServiceException.d.ts +14 -0
- package/dist-types/models/index.d.ts +1 -0
- package/dist-types/models/models_0.d.ts +2370 -0
- package/dist-types/pagination/GetPlanEvaluationStatusPaginator.d.ts +7 -0
- package/dist-types/pagination/GetPlanExecutionPaginator.d.ts +7 -0
- package/dist-types/pagination/Interfaces.d.ts +8 -0
- package/dist-types/pagination/ListPlanExecutionEventsPaginator.d.ts +7 -0
- package/dist-types/pagination/ListPlanExecutionsPaginator.d.ts +7 -0
- package/dist-types/pagination/ListPlansInRegionPaginator.d.ts +7 -0
- package/dist-types/pagination/ListPlansPaginator.d.ts +7 -0
- package/dist-types/pagination/ListRoute53HealthChecksPaginator.d.ts +7 -0
- package/dist-types/pagination/index.d.ts +8 -0
- package/dist-types/protocols/Aws_json1_0.d.ts +182 -0
- package/dist-types/runtimeConfig.browser.d.ts +50 -0
- package/dist-types/runtimeConfig.d.ts +50 -0
- package/dist-types/runtimeConfig.native.d.ts +49 -0
- package/dist-types/runtimeConfig.shared.d.ts +21 -0
- package/dist-types/runtimeExtensions.d.ts +17 -0
- package/dist-types/ts3.4/ARCRegionSwitch.d.ts +349 -0
- package/dist-types/ts3.4/ARCRegionSwitchClient.d.ts +240 -0
- package/dist-types/ts3.4/auth/httpAuthExtensionConfiguration.d.ts +32 -0
- package/dist-types/ts3.4/auth/httpAuthSchemeProvider.d.ts +47 -0
- package/dist-types/ts3.4/commands/ApprovePlanExecutionStepCommand.d.ts +51 -0
- package/dist-types/ts3.4/commands/CancelPlanExecutionCommand.d.ts +51 -0
- package/dist-types/ts3.4/commands/CreatePlanCommand.d.ts +47 -0
- package/dist-types/ts3.4/commands/DeletePlanCommand.d.ts +47 -0
- package/dist-types/ts3.4/commands/GetPlanCommand.d.ts +43 -0
- package/dist-types/ts3.4/commands/GetPlanEvaluationStatusCommand.d.ts +51 -0
- package/dist-types/ts3.4/commands/GetPlanExecutionCommand.d.ts +50 -0
- package/dist-types/ts3.4/commands/GetPlanInRegionCommand.d.ts +50 -0
- package/dist-types/ts3.4/commands/ListPlanExecutionEventsCommand.d.ts +51 -0
- package/dist-types/ts3.4/commands/ListPlanExecutionsCommand.d.ts +51 -0
- package/dist-types/ts3.4/commands/ListPlansCommand.d.ts +47 -0
- package/dist-types/ts3.4/commands/ListPlansInRegionCommand.d.ts +51 -0
- package/dist-types/ts3.4/commands/ListRoute53HealthChecksCommand.d.ts +51 -0
- package/dist-types/ts3.4/commands/ListTagsForResourceCommand.d.ts +51 -0
- package/dist-types/ts3.4/commands/StartPlanExecutionCommand.d.ts +51 -0
- package/dist-types/ts3.4/commands/TagResourceCommand.d.ts +47 -0
- package/dist-types/ts3.4/commands/UntagResourceCommand.d.ts +50 -0
- package/dist-types/ts3.4/commands/UpdatePlanCommand.d.ts +47 -0
- package/dist-types/ts3.4/commands/UpdatePlanExecutionCommand.d.ts +51 -0
- package/dist-types/ts3.4/commands/UpdatePlanExecutionStepCommand.d.ts +51 -0
- package/dist-types/ts3.4/commands/index.d.ts +20 -0
- package/dist-types/ts3.4/endpoint/EndpointParameters.d.ts +46 -0
- package/dist-types/ts3.4/endpoint/endpointResolver.d.ts +8 -0
- package/dist-types/ts3.4/endpoint/ruleset.d.ts +2 -0
- package/dist-types/ts3.4/extensionConfiguration.d.ts +9 -0
- package/dist-types/ts3.4/index.d.ts +10 -0
- package/dist-types/ts3.4/models/ARCRegionSwitchServiceException.d.ts +9 -0
- package/dist-types/ts3.4/models/index.d.ts +1 -0
- package/dist-types/ts3.4/models/models_0.d.ts +813 -0
- package/dist-types/ts3.4/pagination/GetPlanEvaluationStatusPaginator.d.ts +11 -0
- package/dist-types/ts3.4/pagination/GetPlanExecutionPaginator.d.ts +11 -0
- package/dist-types/ts3.4/pagination/Interfaces.d.ts +6 -0
- package/dist-types/ts3.4/pagination/ListPlanExecutionEventsPaginator.d.ts +11 -0
- package/dist-types/ts3.4/pagination/ListPlanExecutionsPaginator.d.ts +11 -0
- package/dist-types/ts3.4/pagination/ListPlansInRegionPaginator.d.ts +11 -0
- package/dist-types/ts3.4/pagination/ListPlansPaginator.d.ts +11 -0
- package/dist-types/ts3.4/pagination/ListRoute53HealthChecksPaginator.d.ts +11 -0
- package/dist-types/ts3.4/pagination/index.d.ts +8 -0
- package/dist-types/ts3.4/protocols/Aws_json1_0.d.ts +245 -0
- package/dist-types/ts3.4/runtimeConfig.browser.d.ts +93 -0
- package/dist-types/ts3.4/runtimeConfig.d.ts +91 -0
- package/dist-types/ts3.4/runtimeConfig.native.d.ts +97 -0
- package/dist-types/ts3.4/runtimeConfig.shared.d.ts +23 -0
- package/dist-types/ts3.4/runtimeExtensions.d.ts +13 -0
- package/dist-types/ts3.4/waiters/index.d.ts +2 -0
- package/dist-types/ts3.4/waiters/waitForPlanEvaluationStatusPassed.d.ts +11 -0
- package/dist-types/ts3.4/waiters/waitForPlanExecutionCompleted.d.ts +11 -0
- package/dist-types/waiters/index.d.ts +2 -0
- package/dist-types/waiters/waitForPlanEvaluationStatusPassed.d.ts +14 -0
- package/dist-types/waiters/waitForPlanExecutionCompleted.d.ts +14 -0
- package/package.json +100 -0
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
import packageInfo from "../package.json";
|
|
2
|
+
import { Sha256 } from "@aws-crypto/sha256-browser";
|
|
3
|
+
import { createDefaultUserAgentProvider } from "@aws-sdk/util-user-agent-browser";
|
|
4
|
+
import { DEFAULT_USE_DUALSTACK_ENDPOINT, DEFAULT_USE_FIPS_ENDPOINT } from "@smithy/config-resolver";
|
|
5
|
+
import { FetchHttpHandler as RequestHandler, streamCollector } from "@smithy/fetch-http-handler";
|
|
6
|
+
import { invalidProvider } from "@smithy/invalid-dependency";
|
|
7
|
+
import { calculateBodyLength } from "@smithy/util-body-length-browser";
|
|
8
|
+
import { DEFAULT_MAX_ATTEMPTS, DEFAULT_RETRY_MODE } from "@smithy/util-retry";
|
|
9
|
+
import { getRuntimeConfig as getSharedRuntimeConfig } from "./runtimeConfig.shared";
|
|
10
|
+
import { loadConfigsForDefaultMode } from "@smithy/smithy-client";
|
|
11
|
+
import { resolveDefaultsModeConfig } from "@smithy/util-defaults-mode-browser";
|
|
12
|
+
export const getRuntimeConfig = (config) => {
|
|
13
|
+
const defaultsMode = resolveDefaultsModeConfig(config);
|
|
14
|
+
const defaultConfigProvider = () => defaultsMode().then(loadConfigsForDefaultMode);
|
|
15
|
+
const clientSharedValues = getSharedRuntimeConfig(config);
|
|
16
|
+
return {
|
|
17
|
+
...clientSharedValues,
|
|
18
|
+
...config,
|
|
19
|
+
runtime: "browser",
|
|
20
|
+
defaultsMode,
|
|
21
|
+
bodyLengthChecker: config?.bodyLengthChecker ?? calculateBodyLength,
|
|
22
|
+
credentialDefaultProvider: config?.credentialDefaultProvider ?? ((_) => () => Promise.reject(new Error("Credential is missing"))),
|
|
23
|
+
defaultUserAgentProvider: config?.defaultUserAgentProvider ??
|
|
24
|
+
createDefaultUserAgentProvider({ serviceId: clientSharedValues.serviceId, clientVersion: packageInfo.version }),
|
|
25
|
+
maxAttempts: config?.maxAttempts ?? DEFAULT_MAX_ATTEMPTS,
|
|
26
|
+
region: config?.region ?? invalidProvider("Region is missing"),
|
|
27
|
+
requestHandler: RequestHandler.create(config?.requestHandler ?? defaultConfigProvider),
|
|
28
|
+
retryMode: config?.retryMode ?? (async () => (await defaultConfigProvider()).retryMode || DEFAULT_RETRY_MODE),
|
|
29
|
+
sha256: config?.sha256 ?? Sha256,
|
|
30
|
+
streamCollector: config?.streamCollector ?? streamCollector,
|
|
31
|
+
useDualstackEndpoint: config?.useDualstackEndpoint ?? (() => Promise.resolve(DEFAULT_USE_DUALSTACK_ENDPOINT)),
|
|
32
|
+
useFipsEndpoint: config?.useFipsEndpoint ?? (() => Promise.resolve(DEFAULT_USE_FIPS_ENDPOINT)),
|
|
33
|
+
};
|
|
34
|
+
};
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
import packageInfo from "../package.json";
|
|
2
|
+
import { NODE_AUTH_SCHEME_PREFERENCE_OPTIONS, emitWarningIfUnsupportedVersion as awsCheckVersion } from "@aws-sdk/core";
|
|
3
|
+
import { defaultProvider as credentialDefaultProvider } from "@aws-sdk/credential-provider-node";
|
|
4
|
+
import { NODE_APP_ID_CONFIG_OPTIONS, createDefaultUserAgentProvider } from "@aws-sdk/util-user-agent-node";
|
|
5
|
+
import { NODE_REGION_CONFIG_FILE_OPTIONS, NODE_REGION_CONFIG_OPTIONS, NODE_USE_DUALSTACK_ENDPOINT_CONFIG_OPTIONS, NODE_USE_FIPS_ENDPOINT_CONFIG_OPTIONS, } from "@smithy/config-resolver";
|
|
6
|
+
import { Hash } from "@smithy/hash-node";
|
|
7
|
+
import { NODE_MAX_ATTEMPT_CONFIG_OPTIONS, NODE_RETRY_MODE_CONFIG_OPTIONS } from "@smithy/middleware-retry";
|
|
8
|
+
import { loadConfig as loadNodeConfig } from "@smithy/node-config-provider";
|
|
9
|
+
import { NodeHttpHandler as RequestHandler, streamCollector } from "@smithy/node-http-handler";
|
|
10
|
+
import { calculateBodyLength } from "@smithy/util-body-length-node";
|
|
11
|
+
import { DEFAULT_RETRY_MODE } from "@smithy/util-retry";
|
|
12
|
+
import { getRuntimeConfig as getSharedRuntimeConfig } from "./runtimeConfig.shared";
|
|
13
|
+
import { loadConfigsForDefaultMode } from "@smithy/smithy-client";
|
|
14
|
+
import { resolveDefaultsModeConfig } from "@smithy/util-defaults-mode-node";
|
|
15
|
+
import { emitWarningIfUnsupportedVersion } from "@smithy/smithy-client";
|
|
16
|
+
export const getRuntimeConfig = (config) => {
|
|
17
|
+
emitWarningIfUnsupportedVersion(process.version);
|
|
18
|
+
const defaultsMode = resolveDefaultsModeConfig(config);
|
|
19
|
+
const defaultConfigProvider = () => defaultsMode().then(loadConfigsForDefaultMode);
|
|
20
|
+
const clientSharedValues = getSharedRuntimeConfig(config);
|
|
21
|
+
awsCheckVersion(process.version);
|
|
22
|
+
const loaderConfig = {
|
|
23
|
+
profile: config?.profile,
|
|
24
|
+
logger: clientSharedValues.logger,
|
|
25
|
+
};
|
|
26
|
+
return {
|
|
27
|
+
...clientSharedValues,
|
|
28
|
+
...config,
|
|
29
|
+
runtime: "node",
|
|
30
|
+
defaultsMode,
|
|
31
|
+
authSchemePreference: config?.authSchemePreference ?? loadNodeConfig(NODE_AUTH_SCHEME_PREFERENCE_OPTIONS, loaderConfig),
|
|
32
|
+
bodyLengthChecker: config?.bodyLengthChecker ?? calculateBodyLength,
|
|
33
|
+
credentialDefaultProvider: config?.credentialDefaultProvider ?? credentialDefaultProvider,
|
|
34
|
+
defaultUserAgentProvider: config?.defaultUserAgentProvider ??
|
|
35
|
+
createDefaultUserAgentProvider({ serviceId: clientSharedValues.serviceId, clientVersion: packageInfo.version }),
|
|
36
|
+
maxAttempts: config?.maxAttempts ?? loadNodeConfig(NODE_MAX_ATTEMPT_CONFIG_OPTIONS, config),
|
|
37
|
+
region: config?.region ??
|
|
38
|
+
loadNodeConfig(NODE_REGION_CONFIG_OPTIONS, { ...NODE_REGION_CONFIG_FILE_OPTIONS, ...loaderConfig }),
|
|
39
|
+
requestHandler: RequestHandler.create(config?.requestHandler ?? defaultConfigProvider),
|
|
40
|
+
retryMode: config?.retryMode ??
|
|
41
|
+
loadNodeConfig({
|
|
42
|
+
...NODE_RETRY_MODE_CONFIG_OPTIONS,
|
|
43
|
+
default: async () => (await defaultConfigProvider()).retryMode || DEFAULT_RETRY_MODE,
|
|
44
|
+
}, config),
|
|
45
|
+
sha256: config?.sha256 ?? Hash.bind(null, "sha256"),
|
|
46
|
+
streamCollector: config?.streamCollector ?? streamCollector,
|
|
47
|
+
useDualstackEndpoint: config?.useDualstackEndpoint ?? loadNodeConfig(NODE_USE_DUALSTACK_ENDPOINT_CONFIG_OPTIONS, loaderConfig),
|
|
48
|
+
useFipsEndpoint: config?.useFipsEndpoint ?? loadNodeConfig(NODE_USE_FIPS_ENDPOINT_CONFIG_OPTIONS, loaderConfig),
|
|
49
|
+
userAgentAppId: config?.userAgentAppId ?? loadNodeConfig(NODE_APP_ID_CONFIG_OPTIONS, loaderConfig),
|
|
50
|
+
};
|
|
51
|
+
};
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { Sha256 } from "@aws-crypto/sha256-js";
|
|
2
|
+
import { getRuntimeConfig as getBrowserRuntimeConfig } from "./runtimeConfig.browser";
|
|
3
|
+
export const getRuntimeConfig = (config) => {
|
|
4
|
+
const browserDefaults = getBrowserRuntimeConfig(config);
|
|
5
|
+
return {
|
|
6
|
+
...browserDefaults,
|
|
7
|
+
...config,
|
|
8
|
+
runtime: "react-native",
|
|
9
|
+
sha256: config?.sha256 ?? Sha256,
|
|
10
|
+
};
|
|
11
|
+
};
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import { AwsSdkSigV4Signer } from "@aws-sdk/core";
|
|
2
|
+
import { NoOpLogger } from "@smithy/smithy-client";
|
|
3
|
+
import { parseUrl } from "@smithy/url-parser";
|
|
4
|
+
import { fromBase64, toBase64 } from "@smithy/util-base64";
|
|
5
|
+
import { fromUtf8, toUtf8 } from "@smithy/util-utf8";
|
|
6
|
+
import { defaultARCRegionSwitchHttpAuthSchemeProvider } from "./auth/httpAuthSchemeProvider";
|
|
7
|
+
import { defaultEndpointResolver } from "./endpoint/endpointResolver";
|
|
8
|
+
export const getRuntimeConfig = (config) => {
|
|
9
|
+
return {
|
|
10
|
+
apiVersion: "2022-07-26",
|
|
11
|
+
base64Decoder: config?.base64Decoder ?? fromBase64,
|
|
12
|
+
base64Encoder: config?.base64Encoder ?? toBase64,
|
|
13
|
+
disableHostPrefix: config?.disableHostPrefix ?? false,
|
|
14
|
+
endpointProvider: config?.endpointProvider ?? defaultEndpointResolver,
|
|
15
|
+
extensions: config?.extensions ?? [],
|
|
16
|
+
httpAuthSchemeProvider: config?.httpAuthSchemeProvider ?? defaultARCRegionSwitchHttpAuthSchemeProvider,
|
|
17
|
+
httpAuthSchemes: config?.httpAuthSchemes ?? [
|
|
18
|
+
{
|
|
19
|
+
schemeId: "aws.auth#sigv4",
|
|
20
|
+
identityProvider: (ipc) => ipc.getIdentityProvider("aws.auth#sigv4"),
|
|
21
|
+
signer: new AwsSdkSigV4Signer(),
|
|
22
|
+
},
|
|
23
|
+
],
|
|
24
|
+
logger: config?.logger ?? new NoOpLogger(),
|
|
25
|
+
serviceId: config?.serviceId ?? "ARC Region switch",
|
|
26
|
+
urlParser: config?.urlParser ?? parseUrl,
|
|
27
|
+
utf8Decoder: config?.utf8Decoder ?? fromUtf8,
|
|
28
|
+
utf8Encoder: config?.utf8Encoder ?? toUtf8,
|
|
29
|
+
};
|
|
30
|
+
};
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { getAwsRegionExtensionConfiguration, resolveAwsRegionExtensionConfiguration, } from "@aws-sdk/region-config-resolver";
|
|
2
|
+
import { getHttpHandlerExtensionConfiguration, resolveHttpHandlerRuntimeConfig } from "@smithy/protocol-http";
|
|
3
|
+
import { getDefaultExtensionConfiguration, resolveDefaultRuntimeConfig } from "@smithy/smithy-client";
|
|
4
|
+
import { getHttpAuthExtensionConfiguration, resolveHttpAuthRuntimeConfig } from "./auth/httpAuthExtensionConfiguration";
|
|
5
|
+
export const resolveRuntimeExtensions = (runtimeConfig, extensions) => {
|
|
6
|
+
const extensionConfiguration = Object.assign(getAwsRegionExtensionConfiguration(runtimeConfig), getDefaultExtensionConfiguration(runtimeConfig), getHttpHandlerExtensionConfiguration(runtimeConfig), getHttpAuthExtensionConfiguration(runtimeConfig));
|
|
7
|
+
extensions.forEach((extension) => extension.configure(extensionConfiguration));
|
|
8
|
+
return Object.assign(runtimeConfig, resolveAwsRegionExtensionConfiguration(extensionConfiguration), resolveDefaultRuntimeConfig(extensionConfiguration), resolveHttpHandlerRuntimeConfig(extensionConfiguration), resolveHttpAuthRuntimeConfig(extensionConfiguration));
|
|
9
|
+
};
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
import { checkExceptions, createWaiter, WaiterState } from "@smithy/util-waiter";
|
|
2
|
+
import { GetPlanEvaluationStatusCommand, } from "../commands/GetPlanEvaluationStatusCommand";
|
|
3
|
+
const checkState = async (client, input) => {
|
|
4
|
+
let reason;
|
|
5
|
+
try {
|
|
6
|
+
const result = await client.send(new GetPlanEvaluationStatusCommand(input));
|
|
7
|
+
reason = result;
|
|
8
|
+
try {
|
|
9
|
+
const returnComparator = () => {
|
|
10
|
+
return result.evaluationState;
|
|
11
|
+
};
|
|
12
|
+
if (returnComparator() === "passed") {
|
|
13
|
+
return { state: WaiterState.SUCCESS, reason };
|
|
14
|
+
}
|
|
15
|
+
}
|
|
16
|
+
catch (e) { }
|
|
17
|
+
try {
|
|
18
|
+
const returnComparator = () => {
|
|
19
|
+
return result.evaluationState;
|
|
20
|
+
};
|
|
21
|
+
if (returnComparator() === "actionRequired") {
|
|
22
|
+
return { state: WaiterState.FAILURE, reason };
|
|
23
|
+
}
|
|
24
|
+
}
|
|
25
|
+
catch (e) { }
|
|
26
|
+
try {
|
|
27
|
+
const returnComparator = () => {
|
|
28
|
+
return result.evaluationState;
|
|
29
|
+
};
|
|
30
|
+
if (returnComparator() === "pendingEvaluation") {
|
|
31
|
+
return { state: WaiterState.RETRY, reason };
|
|
32
|
+
}
|
|
33
|
+
}
|
|
34
|
+
catch (e) { }
|
|
35
|
+
}
|
|
36
|
+
catch (exception) {
|
|
37
|
+
reason = exception;
|
|
38
|
+
}
|
|
39
|
+
return { state: WaiterState.RETRY, reason };
|
|
40
|
+
};
|
|
41
|
+
export const waitForPlanEvaluationStatusPassed = async (params, input) => {
|
|
42
|
+
const serviceDefaults = { minDelay: 30, maxDelay: 120 };
|
|
43
|
+
return createWaiter({ ...serviceDefaults, ...params }, input, checkState);
|
|
44
|
+
};
|
|
45
|
+
export const waitUntilPlanEvaluationStatusPassed = async (params, input) => {
|
|
46
|
+
const serviceDefaults = { minDelay: 30, maxDelay: 120 };
|
|
47
|
+
const result = await createWaiter({ ...serviceDefaults, ...params }, input, checkState);
|
|
48
|
+
return checkExceptions(result);
|
|
49
|
+
};
|
|
@@ -0,0 +1,67 @@
|
|
|
1
|
+
import { checkExceptions, createWaiter, WaiterState } from "@smithy/util-waiter";
|
|
2
|
+
import { GetPlanExecutionCommand } from "../commands/GetPlanExecutionCommand";
|
|
3
|
+
const checkState = async (client, input) => {
|
|
4
|
+
let reason;
|
|
5
|
+
try {
|
|
6
|
+
const result = await client.send(new GetPlanExecutionCommand(input));
|
|
7
|
+
reason = result;
|
|
8
|
+
try {
|
|
9
|
+
const returnComparator = () => {
|
|
10
|
+
return result.executionState;
|
|
11
|
+
};
|
|
12
|
+
if (returnComparator() === "completed") {
|
|
13
|
+
return { state: WaiterState.SUCCESS, reason };
|
|
14
|
+
}
|
|
15
|
+
}
|
|
16
|
+
catch (e) { }
|
|
17
|
+
try {
|
|
18
|
+
const returnComparator = () => {
|
|
19
|
+
return result.executionState;
|
|
20
|
+
};
|
|
21
|
+
if (returnComparator() === "completedWithExceptions") {
|
|
22
|
+
return { state: WaiterState.SUCCESS, reason };
|
|
23
|
+
}
|
|
24
|
+
}
|
|
25
|
+
catch (e) { }
|
|
26
|
+
try {
|
|
27
|
+
const returnComparator = () => {
|
|
28
|
+
return result.executionState;
|
|
29
|
+
};
|
|
30
|
+
if (returnComparator() === "failed") {
|
|
31
|
+
return { state: WaiterState.FAILURE, reason };
|
|
32
|
+
}
|
|
33
|
+
}
|
|
34
|
+
catch (e) { }
|
|
35
|
+
try {
|
|
36
|
+
const returnComparator = () => {
|
|
37
|
+
return result.executionState;
|
|
38
|
+
};
|
|
39
|
+
if (returnComparator() === "canceled") {
|
|
40
|
+
return { state: WaiterState.FAILURE, reason };
|
|
41
|
+
}
|
|
42
|
+
}
|
|
43
|
+
catch (e) { }
|
|
44
|
+
try {
|
|
45
|
+
const returnComparator = () => {
|
|
46
|
+
return result.executionState;
|
|
47
|
+
};
|
|
48
|
+
if (returnComparator() === "planExecutionTimedOut") {
|
|
49
|
+
return { state: WaiterState.FAILURE, reason };
|
|
50
|
+
}
|
|
51
|
+
}
|
|
52
|
+
catch (e) { }
|
|
53
|
+
}
|
|
54
|
+
catch (exception) {
|
|
55
|
+
reason = exception;
|
|
56
|
+
}
|
|
57
|
+
return { state: WaiterState.RETRY, reason };
|
|
58
|
+
};
|
|
59
|
+
export const waitForPlanExecutionCompleted = async (params, input) => {
|
|
60
|
+
const serviceDefaults = { minDelay: 30, maxDelay: 120 };
|
|
61
|
+
return createWaiter({ ...serviceDefaults, ...params }, input, checkState);
|
|
62
|
+
};
|
|
63
|
+
export const waitUntilPlanExecutionCompleted = async (params, input) => {
|
|
64
|
+
const serviceDefaults = { minDelay: 30, maxDelay: 120 };
|
|
65
|
+
const result = await createWaiter({ ...serviceDefaults, ...params }, input, checkState);
|
|
66
|
+
return checkExceptions(result);
|
|
67
|
+
};
|
|
@@ -0,0 +1,152 @@
|
|
|
1
|
+
import { HttpHandlerOptions as __HttpHandlerOptions } from "@smithy/types";
|
|
2
|
+
import { ARCRegionSwitchClient } from "./ARCRegionSwitchClient";
|
|
3
|
+
import { ApprovePlanExecutionStepCommandInput, ApprovePlanExecutionStepCommandOutput } from "./commands/ApprovePlanExecutionStepCommand";
|
|
4
|
+
import { CancelPlanExecutionCommandInput, CancelPlanExecutionCommandOutput } from "./commands/CancelPlanExecutionCommand";
|
|
5
|
+
import { CreatePlanCommandInput, CreatePlanCommandOutput } from "./commands/CreatePlanCommand";
|
|
6
|
+
import { DeletePlanCommandInput, DeletePlanCommandOutput } from "./commands/DeletePlanCommand";
|
|
7
|
+
import { GetPlanCommandInput, GetPlanCommandOutput } from "./commands/GetPlanCommand";
|
|
8
|
+
import { GetPlanEvaluationStatusCommandInput, GetPlanEvaluationStatusCommandOutput } from "./commands/GetPlanEvaluationStatusCommand";
|
|
9
|
+
import { GetPlanExecutionCommandInput, GetPlanExecutionCommandOutput } from "./commands/GetPlanExecutionCommand";
|
|
10
|
+
import { GetPlanInRegionCommandInput, GetPlanInRegionCommandOutput } from "./commands/GetPlanInRegionCommand";
|
|
11
|
+
import { ListPlanExecutionEventsCommandInput, ListPlanExecutionEventsCommandOutput } from "./commands/ListPlanExecutionEventsCommand";
|
|
12
|
+
import { ListPlanExecutionsCommandInput, ListPlanExecutionsCommandOutput } from "./commands/ListPlanExecutionsCommand";
|
|
13
|
+
import { ListPlansCommandInput, ListPlansCommandOutput } from "./commands/ListPlansCommand";
|
|
14
|
+
import { ListPlansInRegionCommandInput, ListPlansInRegionCommandOutput } from "./commands/ListPlansInRegionCommand";
|
|
15
|
+
import { ListRoute53HealthChecksCommandInput, ListRoute53HealthChecksCommandOutput } from "./commands/ListRoute53HealthChecksCommand";
|
|
16
|
+
import { ListTagsForResourceCommandInput, ListTagsForResourceCommandOutput } from "./commands/ListTagsForResourceCommand";
|
|
17
|
+
import { StartPlanExecutionCommandInput, StartPlanExecutionCommandOutput } from "./commands/StartPlanExecutionCommand";
|
|
18
|
+
import { TagResourceCommandInput, TagResourceCommandOutput } from "./commands/TagResourceCommand";
|
|
19
|
+
import { UntagResourceCommandInput, UntagResourceCommandOutput } from "./commands/UntagResourceCommand";
|
|
20
|
+
import { UpdatePlanCommandInput, UpdatePlanCommandOutput } from "./commands/UpdatePlanCommand";
|
|
21
|
+
import { UpdatePlanExecutionCommandInput, UpdatePlanExecutionCommandOutput } from "./commands/UpdatePlanExecutionCommand";
|
|
22
|
+
import { UpdatePlanExecutionStepCommandInput, UpdatePlanExecutionStepCommandOutput } from "./commands/UpdatePlanExecutionStepCommand";
|
|
23
|
+
export interface ARCRegionSwitch {
|
|
24
|
+
/**
|
|
25
|
+
* @see {@link ApprovePlanExecutionStepCommand}
|
|
26
|
+
*/
|
|
27
|
+
approvePlanExecutionStep(args: ApprovePlanExecutionStepCommandInput, options?: __HttpHandlerOptions): Promise<ApprovePlanExecutionStepCommandOutput>;
|
|
28
|
+
approvePlanExecutionStep(args: ApprovePlanExecutionStepCommandInput, cb: (err: any, data?: ApprovePlanExecutionStepCommandOutput) => void): void;
|
|
29
|
+
approvePlanExecutionStep(args: ApprovePlanExecutionStepCommandInput, options: __HttpHandlerOptions, cb: (err: any, data?: ApprovePlanExecutionStepCommandOutput) => void): void;
|
|
30
|
+
/**
|
|
31
|
+
* @see {@link CancelPlanExecutionCommand}
|
|
32
|
+
*/
|
|
33
|
+
cancelPlanExecution(args: CancelPlanExecutionCommandInput, options?: __HttpHandlerOptions): Promise<CancelPlanExecutionCommandOutput>;
|
|
34
|
+
cancelPlanExecution(args: CancelPlanExecutionCommandInput, cb: (err: any, data?: CancelPlanExecutionCommandOutput) => void): void;
|
|
35
|
+
cancelPlanExecution(args: CancelPlanExecutionCommandInput, options: __HttpHandlerOptions, cb: (err: any, data?: CancelPlanExecutionCommandOutput) => void): void;
|
|
36
|
+
/**
|
|
37
|
+
* @see {@link CreatePlanCommand}
|
|
38
|
+
*/
|
|
39
|
+
createPlan(args: CreatePlanCommandInput, options?: __HttpHandlerOptions): Promise<CreatePlanCommandOutput>;
|
|
40
|
+
createPlan(args: CreatePlanCommandInput, cb: (err: any, data?: CreatePlanCommandOutput) => void): void;
|
|
41
|
+
createPlan(args: CreatePlanCommandInput, options: __HttpHandlerOptions, cb: (err: any, data?: CreatePlanCommandOutput) => void): void;
|
|
42
|
+
/**
|
|
43
|
+
* @see {@link DeletePlanCommand}
|
|
44
|
+
*/
|
|
45
|
+
deletePlan(args: DeletePlanCommandInput, options?: __HttpHandlerOptions): Promise<DeletePlanCommandOutput>;
|
|
46
|
+
deletePlan(args: DeletePlanCommandInput, cb: (err: any, data?: DeletePlanCommandOutput) => void): void;
|
|
47
|
+
deletePlan(args: DeletePlanCommandInput, options: __HttpHandlerOptions, cb: (err: any, data?: DeletePlanCommandOutput) => void): void;
|
|
48
|
+
/**
|
|
49
|
+
* @see {@link GetPlanCommand}
|
|
50
|
+
*/
|
|
51
|
+
getPlan(args: GetPlanCommandInput, options?: __HttpHandlerOptions): Promise<GetPlanCommandOutput>;
|
|
52
|
+
getPlan(args: GetPlanCommandInput, cb: (err: any, data?: GetPlanCommandOutput) => void): void;
|
|
53
|
+
getPlan(args: GetPlanCommandInput, options: __HttpHandlerOptions, cb: (err: any, data?: GetPlanCommandOutput) => void): void;
|
|
54
|
+
/**
|
|
55
|
+
* @see {@link GetPlanEvaluationStatusCommand}
|
|
56
|
+
*/
|
|
57
|
+
getPlanEvaluationStatus(args: GetPlanEvaluationStatusCommandInput, options?: __HttpHandlerOptions): Promise<GetPlanEvaluationStatusCommandOutput>;
|
|
58
|
+
getPlanEvaluationStatus(args: GetPlanEvaluationStatusCommandInput, cb: (err: any, data?: GetPlanEvaluationStatusCommandOutput) => void): void;
|
|
59
|
+
getPlanEvaluationStatus(args: GetPlanEvaluationStatusCommandInput, options: __HttpHandlerOptions, cb: (err: any, data?: GetPlanEvaluationStatusCommandOutput) => void): void;
|
|
60
|
+
/**
|
|
61
|
+
* @see {@link GetPlanExecutionCommand}
|
|
62
|
+
*/
|
|
63
|
+
getPlanExecution(args: GetPlanExecutionCommandInput, options?: __HttpHandlerOptions): Promise<GetPlanExecutionCommandOutput>;
|
|
64
|
+
getPlanExecution(args: GetPlanExecutionCommandInput, cb: (err: any, data?: GetPlanExecutionCommandOutput) => void): void;
|
|
65
|
+
getPlanExecution(args: GetPlanExecutionCommandInput, options: __HttpHandlerOptions, cb: (err: any, data?: GetPlanExecutionCommandOutput) => void): void;
|
|
66
|
+
/**
|
|
67
|
+
* @see {@link GetPlanInRegionCommand}
|
|
68
|
+
*/
|
|
69
|
+
getPlanInRegion(args: GetPlanInRegionCommandInput, options?: __HttpHandlerOptions): Promise<GetPlanInRegionCommandOutput>;
|
|
70
|
+
getPlanInRegion(args: GetPlanInRegionCommandInput, cb: (err: any, data?: GetPlanInRegionCommandOutput) => void): void;
|
|
71
|
+
getPlanInRegion(args: GetPlanInRegionCommandInput, options: __HttpHandlerOptions, cb: (err: any, data?: GetPlanInRegionCommandOutput) => void): void;
|
|
72
|
+
/**
|
|
73
|
+
* @see {@link ListPlanExecutionEventsCommand}
|
|
74
|
+
*/
|
|
75
|
+
listPlanExecutionEvents(args: ListPlanExecutionEventsCommandInput, options?: __HttpHandlerOptions): Promise<ListPlanExecutionEventsCommandOutput>;
|
|
76
|
+
listPlanExecutionEvents(args: ListPlanExecutionEventsCommandInput, cb: (err: any, data?: ListPlanExecutionEventsCommandOutput) => void): void;
|
|
77
|
+
listPlanExecutionEvents(args: ListPlanExecutionEventsCommandInput, options: __HttpHandlerOptions, cb: (err: any, data?: ListPlanExecutionEventsCommandOutput) => void): void;
|
|
78
|
+
/**
|
|
79
|
+
* @see {@link ListPlanExecutionsCommand}
|
|
80
|
+
*/
|
|
81
|
+
listPlanExecutions(args: ListPlanExecutionsCommandInput, options?: __HttpHandlerOptions): Promise<ListPlanExecutionsCommandOutput>;
|
|
82
|
+
listPlanExecutions(args: ListPlanExecutionsCommandInput, cb: (err: any, data?: ListPlanExecutionsCommandOutput) => void): void;
|
|
83
|
+
listPlanExecutions(args: ListPlanExecutionsCommandInput, options: __HttpHandlerOptions, cb: (err: any, data?: ListPlanExecutionsCommandOutput) => void): void;
|
|
84
|
+
/**
|
|
85
|
+
* @see {@link ListPlansCommand}
|
|
86
|
+
*/
|
|
87
|
+
listPlans(): Promise<ListPlansCommandOutput>;
|
|
88
|
+
listPlans(args: ListPlansCommandInput, options?: __HttpHandlerOptions): Promise<ListPlansCommandOutput>;
|
|
89
|
+
listPlans(args: ListPlansCommandInput, cb: (err: any, data?: ListPlansCommandOutput) => void): void;
|
|
90
|
+
listPlans(args: ListPlansCommandInput, options: __HttpHandlerOptions, cb: (err: any, data?: ListPlansCommandOutput) => void): void;
|
|
91
|
+
/**
|
|
92
|
+
* @see {@link ListPlansInRegionCommand}
|
|
93
|
+
*/
|
|
94
|
+
listPlansInRegion(): Promise<ListPlansInRegionCommandOutput>;
|
|
95
|
+
listPlansInRegion(args: ListPlansInRegionCommandInput, options?: __HttpHandlerOptions): Promise<ListPlansInRegionCommandOutput>;
|
|
96
|
+
listPlansInRegion(args: ListPlansInRegionCommandInput, cb: (err: any, data?: ListPlansInRegionCommandOutput) => void): void;
|
|
97
|
+
listPlansInRegion(args: ListPlansInRegionCommandInput, options: __HttpHandlerOptions, cb: (err: any, data?: ListPlansInRegionCommandOutput) => void): void;
|
|
98
|
+
/**
|
|
99
|
+
* @see {@link ListRoute53HealthChecksCommand}
|
|
100
|
+
*/
|
|
101
|
+
listRoute53HealthChecks(args: ListRoute53HealthChecksCommandInput, options?: __HttpHandlerOptions): Promise<ListRoute53HealthChecksCommandOutput>;
|
|
102
|
+
listRoute53HealthChecks(args: ListRoute53HealthChecksCommandInput, cb: (err: any, data?: ListRoute53HealthChecksCommandOutput) => void): void;
|
|
103
|
+
listRoute53HealthChecks(args: ListRoute53HealthChecksCommandInput, options: __HttpHandlerOptions, cb: (err: any, data?: ListRoute53HealthChecksCommandOutput) => void): void;
|
|
104
|
+
/**
|
|
105
|
+
* @see {@link ListTagsForResourceCommand}
|
|
106
|
+
*/
|
|
107
|
+
listTagsForResource(args: ListTagsForResourceCommandInput, options?: __HttpHandlerOptions): Promise<ListTagsForResourceCommandOutput>;
|
|
108
|
+
listTagsForResource(args: ListTagsForResourceCommandInput, cb: (err: any, data?: ListTagsForResourceCommandOutput) => void): void;
|
|
109
|
+
listTagsForResource(args: ListTagsForResourceCommandInput, options: __HttpHandlerOptions, cb: (err: any, data?: ListTagsForResourceCommandOutput) => void): void;
|
|
110
|
+
/**
|
|
111
|
+
* @see {@link StartPlanExecutionCommand}
|
|
112
|
+
*/
|
|
113
|
+
startPlanExecution(args: StartPlanExecutionCommandInput, options?: __HttpHandlerOptions): Promise<StartPlanExecutionCommandOutput>;
|
|
114
|
+
startPlanExecution(args: StartPlanExecutionCommandInput, cb: (err: any, data?: StartPlanExecutionCommandOutput) => void): void;
|
|
115
|
+
startPlanExecution(args: StartPlanExecutionCommandInput, options: __HttpHandlerOptions, cb: (err: any, data?: StartPlanExecutionCommandOutput) => void): void;
|
|
116
|
+
/**
|
|
117
|
+
* @see {@link TagResourceCommand}
|
|
118
|
+
*/
|
|
119
|
+
tagResource(args: TagResourceCommandInput, options?: __HttpHandlerOptions): Promise<TagResourceCommandOutput>;
|
|
120
|
+
tagResource(args: TagResourceCommandInput, cb: (err: any, data?: TagResourceCommandOutput) => void): void;
|
|
121
|
+
tagResource(args: TagResourceCommandInput, options: __HttpHandlerOptions, cb: (err: any, data?: TagResourceCommandOutput) => void): void;
|
|
122
|
+
/**
|
|
123
|
+
* @see {@link UntagResourceCommand}
|
|
124
|
+
*/
|
|
125
|
+
untagResource(args: UntagResourceCommandInput, options?: __HttpHandlerOptions): Promise<UntagResourceCommandOutput>;
|
|
126
|
+
untagResource(args: UntagResourceCommandInput, cb: (err: any, data?: UntagResourceCommandOutput) => void): void;
|
|
127
|
+
untagResource(args: UntagResourceCommandInput, options: __HttpHandlerOptions, cb: (err: any, data?: UntagResourceCommandOutput) => void): void;
|
|
128
|
+
/**
|
|
129
|
+
* @see {@link UpdatePlanCommand}
|
|
130
|
+
*/
|
|
131
|
+
updatePlan(args: UpdatePlanCommandInput, options?: __HttpHandlerOptions): Promise<UpdatePlanCommandOutput>;
|
|
132
|
+
updatePlan(args: UpdatePlanCommandInput, cb: (err: any, data?: UpdatePlanCommandOutput) => void): void;
|
|
133
|
+
updatePlan(args: UpdatePlanCommandInput, options: __HttpHandlerOptions, cb: (err: any, data?: UpdatePlanCommandOutput) => void): void;
|
|
134
|
+
/**
|
|
135
|
+
* @see {@link UpdatePlanExecutionCommand}
|
|
136
|
+
*/
|
|
137
|
+
updatePlanExecution(args: UpdatePlanExecutionCommandInput, options?: __HttpHandlerOptions): Promise<UpdatePlanExecutionCommandOutput>;
|
|
138
|
+
updatePlanExecution(args: UpdatePlanExecutionCommandInput, cb: (err: any, data?: UpdatePlanExecutionCommandOutput) => void): void;
|
|
139
|
+
updatePlanExecution(args: UpdatePlanExecutionCommandInput, options: __HttpHandlerOptions, cb: (err: any, data?: UpdatePlanExecutionCommandOutput) => void): void;
|
|
140
|
+
/**
|
|
141
|
+
* @see {@link UpdatePlanExecutionStepCommand}
|
|
142
|
+
*/
|
|
143
|
+
updatePlanExecutionStep(args: UpdatePlanExecutionStepCommandInput, options?: __HttpHandlerOptions): Promise<UpdatePlanExecutionStepCommandOutput>;
|
|
144
|
+
updatePlanExecutionStep(args: UpdatePlanExecutionStepCommandInput, cb: (err: any, data?: UpdatePlanExecutionStepCommandOutput) => void): void;
|
|
145
|
+
updatePlanExecutionStep(args: UpdatePlanExecutionStepCommandInput, options: __HttpHandlerOptions, cb: (err: any, data?: UpdatePlanExecutionStepCommandOutput) => void): void;
|
|
146
|
+
}
|
|
147
|
+
/**
|
|
148
|
+
* <p>Amazon Application Recovery Controller (ARC) Region switch helps you to quickly and reliably shift traffic away from an impaired Amazon Web Services Region to a healthy Region. With Region switch, you can create plans that define the steps to shift traffic for your application from one Amazon Web Services Region to another. You can test your plans in practice mode before using them in a real recovery scenario.</p> <p>Region switch provides a structured approach to multi-Region failover, helping you to meet your recovery time objectives (RTOs) and maintain business continuity during regional disruptions.</p>
|
|
149
|
+
* @public
|
|
150
|
+
*/
|
|
151
|
+
export declare class ARCRegionSwitch extends ARCRegionSwitchClient implements ARCRegionSwitch {
|
|
152
|
+
}
|
|
@@ -0,0 +1,207 @@
|
|
|
1
|
+
import { HostHeaderInputConfig, HostHeaderResolvedConfig } from "@aws-sdk/middleware-host-header";
|
|
2
|
+
import { UserAgentInputConfig, UserAgentResolvedConfig } from "@aws-sdk/middleware-user-agent";
|
|
3
|
+
import { RegionInputConfig, RegionResolvedConfig } from "@smithy/config-resolver";
|
|
4
|
+
import { EndpointInputConfig, EndpointResolvedConfig } from "@smithy/middleware-endpoint";
|
|
5
|
+
import { RetryInputConfig, RetryResolvedConfig } from "@smithy/middleware-retry";
|
|
6
|
+
import { HttpHandlerUserInput as __HttpHandlerUserInput } from "@smithy/protocol-http";
|
|
7
|
+
import { Client as __Client, DefaultsMode as __DefaultsMode, SmithyConfiguration as __SmithyConfiguration, SmithyResolvedConfiguration as __SmithyResolvedConfiguration } from "@smithy/smithy-client";
|
|
8
|
+
import { AwsCredentialIdentityProvider, BodyLengthCalculator as __BodyLengthCalculator, CheckOptionalClientConfig as __CheckOptionalClientConfig, ChecksumConstructor as __ChecksumConstructor, Decoder as __Decoder, Encoder as __Encoder, HashConstructor as __HashConstructor, HttpHandlerOptions as __HttpHandlerOptions, Logger as __Logger, Provider as __Provider, Provider, StreamCollector as __StreamCollector, UrlParser as __UrlParser, UserAgent as __UserAgent } from "@smithy/types";
|
|
9
|
+
import { HttpAuthSchemeInputConfig, HttpAuthSchemeResolvedConfig } from "./auth/httpAuthSchemeProvider";
|
|
10
|
+
import { ApprovePlanExecutionStepCommandInput, ApprovePlanExecutionStepCommandOutput } from "./commands/ApprovePlanExecutionStepCommand";
|
|
11
|
+
import { CancelPlanExecutionCommandInput, CancelPlanExecutionCommandOutput } from "./commands/CancelPlanExecutionCommand";
|
|
12
|
+
import { CreatePlanCommandInput, CreatePlanCommandOutput } from "./commands/CreatePlanCommand";
|
|
13
|
+
import { DeletePlanCommandInput, DeletePlanCommandOutput } from "./commands/DeletePlanCommand";
|
|
14
|
+
import { GetPlanCommandInput, GetPlanCommandOutput } from "./commands/GetPlanCommand";
|
|
15
|
+
import { GetPlanEvaluationStatusCommandInput, GetPlanEvaluationStatusCommandOutput } from "./commands/GetPlanEvaluationStatusCommand";
|
|
16
|
+
import { GetPlanExecutionCommandInput, GetPlanExecutionCommandOutput } from "./commands/GetPlanExecutionCommand";
|
|
17
|
+
import { GetPlanInRegionCommandInput, GetPlanInRegionCommandOutput } from "./commands/GetPlanInRegionCommand";
|
|
18
|
+
import { ListPlanExecutionEventsCommandInput, ListPlanExecutionEventsCommandOutput } from "./commands/ListPlanExecutionEventsCommand";
|
|
19
|
+
import { ListPlanExecutionsCommandInput, ListPlanExecutionsCommandOutput } from "./commands/ListPlanExecutionsCommand";
|
|
20
|
+
import { ListPlansCommandInput, ListPlansCommandOutput } from "./commands/ListPlansCommand";
|
|
21
|
+
import { ListPlansInRegionCommandInput, ListPlansInRegionCommandOutput } from "./commands/ListPlansInRegionCommand";
|
|
22
|
+
import { ListRoute53HealthChecksCommandInput, ListRoute53HealthChecksCommandOutput } from "./commands/ListRoute53HealthChecksCommand";
|
|
23
|
+
import { ListTagsForResourceCommandInput, ListTagsForResourceCommandOutput } from "./commands/ListTagsForResourceCommand";
|
|
24
|
+
import { StartPlanExecutionCommandInput, StartPlanExecutionCommandOutput } from "./commands/StartPlanExecutionCommand";
|
|
25
|
+
import { TagResourceCommandInput, TagResourceCommandOutput } from "./commands/TagResourceCommand";
|
|
26
|
+
import { UntagResourceCommandInput, UntagResourceCommandOutput } from "./commands/UntagResourceCommand";
|
|
27
|
+
import { UpdatePlanCommandInput, UpdatePlanCommandOutput } from "./commands/UpdatePlanCommand";
|
|
28
|
+
import { UpdatePlanExecutionCommandInput, UpdatePlanExecutionCommandOutput } from "./commands/UpdatePlanExecutionCommand";
|
|
29
|
+
import { UpdatePlanExecutionStepCommandInput, UpdatePlanExecutionStepCommandOutput } from "./commands/UpdatePlanExecutionStepCommand";
|
|
30
|
+
import { ClientInputEndpointParameters, ClientResolvedEndpointParameters, EndpointParameters } from "./endpoint/EndpointParameters";
|
|
31
|
+
import { RuntimeExtension, RuntimeExtensionsConfig } from "./runtimeExtensions";
|
|
32
|
+
export { __Client };
|
|
33
|
+
/**
|
|
34
|
+
* @public
|
|
35
|
+
*/
|
|
36
|
+
export type ServiceInputTypes = ApprovePlanExecutionStepCommandInput | CancelPlanExecutionCommandInput | CreatePlanCommandInput | DeletePlanCommandInput | GetPlanCommandInput | GetPlanEvaluationStatusCommandInput | GetPlanExecutionCommandInput | GetPlanInRegionCommandInput | ListPlanExecutionEventsCommandInput | ListPlanExecutionsCommandInput | ListPlansCommandInput | ListPlansInRegionCommandInput | ListRoute53HealthChecksCommandInput | ListTagsForResourceCommandInput | StartPlanExecutionCommandInput | TagResourceCommandInput | UntagResourceCommandInput | UpdatePlanCommandInput | UpdatePlanExecutionCommandInput | UpdatePlanExecutionStepCommandInput;
|
|
37
|
+
/**
|
|
38
|
+
* @public
|
|
39
|
+
*/
|
|
40
|
+
export type ServiceOutputTypes = ApprovePlanExecutionStepCommandOutput | CancelPlanExecutionCommandOutput | CreatePlanCommandOutput | DeletePlanCommandOutput | GetPlanCommandOutput | GetPlanEvaluationStatusCommandOutput | GetPlanExecutionCommandOutput | GetPlanInRegionCommandOutput | ListPlanExecutionEventsCommandOutput | ListPlanExecutionsCommandOutput | ListPlansCommandOutput | ListPlansInRegionCommandOutput | ListRoute53HealthChecksCommandOutput | ListTagsForResourceCommandOutput | StartPlanExecutionCommandOutput | TagResourceCommandOutput | UntagResourceCommandOutput | UpdatePlanCommandOutput | UpdatePlanExecutionCommandOutput | UpdatePlanExecutionStepCommandOutput;
|
|
41
|
+
/**
|
|
42
|
+
* @public
|
|
43
|
+
*/
|
|
44
|
+
export interface ClientDefaults extends Partial<__SmithyConfiguration<__HttpHandlerOptions>> {
|
|
45
|
+
/**
|
|
46
|
+
* The HTTP handler to use or its constructor options. Fetch in browser and Https in Nodejs.
|
|
47
|
+
*/
|
|
48
|
+
requestHandler?: __HttpHandlerUserInput;
|
|
49
|
+
/**
|
|
50
|
+
* A constructor for a class implementing the {@link @smithy/types#ChecksumConstructor} interface
|
|
51
|
+
* that computes the SHA-256 HMAC or checksum of a string or binary buffer.
|
|
52
|
+
* @internal
|
|
53
|
+
*/
|
|
54
|
+
sha256?: __ChecksumConstructor | __HashConstructor;
|
|
55
|
+
/**
|
|
56
|
+
* The function that will be used to convert strings into HTTP endpoints.
|
|
57
|
+
* @internal
|
|
58
|
+
*/
|
|
59
|
+
urlParser?: __UrlParser;
|
|
60
|
+
/**
|
|
61
|
+
* A function that can calculate the length of a request body.
|
|
62
|
+
* @internal
|
|
63
|
+
*/
|
|
64
|
+
bodyLengthChecker?: __BodyLengthCalculator;
|
|
65
|
+
/**
|
|
66
|
+
* A function that converts a stream into an array of bytes.
|
|
67
|
+
* @internal
|
|
68
|
+
*/
|
|
69
|
+
streamCollector?: __StreamCollector;
|
|
70
|
+
/**
|
|
71
|
+
* The function that will be used to convert a base64-encoded string to a byte array.
|
|
72
|
+
* @internal
|
|
73
|
+
*/
|
|
74
|
+
base64Decoder?: __Decoder;
|
|
75
|
+
/**
|
|
76
|
+
* The function that will be used to convert binary data to a base64-encoded string.
|
|
77
|
+
* @internal
|
|
78
|
+
*/
|
|
79
|
+
base64Encoder?: __Encoder;
|
|
80
|
+
/**
|
|
81
|
+
* The function that will be used to convert a UTF8-encoded string to a byte array.
|
|
82
|
+
* @internal
|
|
83
|
+
*/
|
|
84
|
+
utf8Decoder?: __Decoder;
|
|
85
|
+
/**
|
|
86
|
+
* The function that will be used to convert binary data to a UTF-8 encoded string.
|
|
87
|
+
* @internal
|
|
88
|
+
*/
|
|
89
|
+
utf8Encoder?: __Encoder;
|
|
90
|
+
/**
|
|
91
|
+
* The runtime environment.
|
|
92
|
+
* @internal
|
|
93
|
+
*/
|
|
94
|
+
runtime?: string;
|
|
95
|
+
/**
|
|
96
|
+
* Disable dynamically changing the endpoint of the client based on the hostPrefix
|
|
97
|
+
* trait of an operation.
|
|
98
|
+
*/
|
|
99
|
+
disableHostPrefix?: boolean;
|
|
100
|
+
/**
|
|
101
|
+
* Unique service identifier.
|
|
102
|
+
* @internal
|
|
103
|
+
*/
|
|
104
|
+
serviceId?: string;
|
|
105
|
+
/**
|
|
106
|
+
* Enables IPv6/IPv4 dualstack endpoint.
|
|
107
|
+
*/
|
|
108
|
+
useDualstackEndpoint?: boolean | __Provider<boolean>;
|
|
109
|
+
/**
|
|
110
|
+
* Enables FIPS compatible endpoints.
|
|
111
|
+
*/
|
|
112
|
+
useFipsEndpoint?: boolean | __Provider<boolean>;
|
|
113
|
+
/**
|
|
114
|
+
* The AWS region to which this client will send requests
|
|
115
|
+
*/
|
|
116
|
+
region?: string | __Provider<string>;
|
|
117
|
+
/**
|
|
118
|
+
* Setting a client profile is similar to setting a value for the
|
|
119
|
+
* AWS_PROFILE environment variable. Setting a profile on a client
|
|
120
|
+
* in code only affects the single client instance, unlike AWS_PROFILE.
|
|
121
|
+
*
|
|
122
|
+
* When set, and only for environments where an AWS configuration
|
|
123
|
+
* file exists, fields configurable by this file will be retrieved
|
|
124
|
+
* from the specified profile within that file.
|
|
125
|
+
* Conflicting code configuration and environment variables will
|
|
126
|
+
* still have higher priority.
|
|
127
|
+
*
|
|
128
|
+
* For client credential resolution that involves checking the AWS
|
|
129
|
+
* configuration file, the client's profile (this value) will be
|
|
130
|
+
* used unless a different profile is set in the credential
|
|
131
|
+
* provider options.
|
|
132
|
+
*
|
|
133
|
+
*/
|
|
134
|
+
profile?: string;
|
|
135
|
+
/**
|
|
136
|
+
* The provider populating default tracking information to be sent with `user-agent`, `x-amz-user-agent` header
|
|
137
|
+
* @internal
|
|
138
|
+
*/
|
|
139
|
+
defaultUserAgentProvider?: Provider<__UserAgent>;
|
|
140
|
+
/**
|
|
141
|
+
* Default credentials provider; Not available in browser runtime.
|
|
142
|
+
* @deprecated
|
|
143
|
+
* @internal
|
|
144
|
+
*/
|
|
145
|
+
credentialDefaultProvider?: (input: any) => AwsCredentialIdentityProvider;
|
|
146
|
+
/**
|
|
147
|
+
* Value for how many times a request will be made at most in case of retry.
|
|
148
|
+
*/
|
|
149
|
+
maxAttempts?: number | __Provider<number>;
|
|
150
|
+
/**
|
|
151
|
+
* Specifies which retry algorithm to use.
|
|
152
|
+
* @see https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-smithy-util-retry/Enum/RETRY_MODES/
|
|
153
|
+
*
|
|
154
|
+
*/
|
|
155
|
+
retryMode?: string | __Provider<string>;
|
|
156
|
+
/**
|
|
157
|
+
* Optional logger for logging debug/info/warn/error.
|
|
158
|
+
*/
|
|
159
|
+
logger?: __Logger;
|
|
160
|
+
/**
|
|
161
|
+
* Optional extensions
|
|
162
|
+
*/
|
|
163
|
+
extensions?: RuntimeExtension[];
|
|
164
|
+
/**
|
|
165
|
+
* The {@link @smithy/smithy-client#DefaultsMode} that will be used to determine how certain default configuration options are resolved in the SDK.
|
|
166
|
+
*/
|
|
167
|
+
defaultsMode?: __DefaultsMode | __Provider<__DefaultsMode>;
|
|
168
|
+
}
|
|
169
|
+
/**
|
|
170
|
+
* @public
|
|
171
|
+
*/
|
|
172
|
+
export type ARCRegionSwitchClientConfigType = Partial<__SmithyConfiguration<__HttpHandlerOptions>> & ClientDefaults & UserAgentInputConfig & RetryInputConfig & RegionInputConfig & HostHeaderInputConfig & EndpointInputConfig<EndpointParameters> & HttpAuthSchemeInputConfig & ClientInputEndpointParameters;
|
|
173
|
+
/**
|
|
174
|
+
* @public
|
|
175
|
+
*
|
|
176
|
+
* The configuration interface of ARCRegionSwitchClient class constructor that set the region, credentials and other options.
|
|
177
|
+
*/
|
|
178
|
+
export interface ARCRegionSwitchClientConfig extends ARCRegionSwitchClientConfigType {
|
|
179
|
+
}
|
|
180
|
+
/**
|
|
181
|
+
* @public
|
|
182
|
+
*/
|
|
183
|
+
export type ARCRegionSwitchClientResolvedConfigType = __SmithyResolvedConfiguration<__HttpHandlerOptions> & Required<ClientDefaults> & RuntimeExtensionsConfig & UserAgentResolvedConfig & RetryResolvedConfig & RegionResolvedConfig & HostHeaderResolvedConfig & EndpointResolvedConfig<EndpointParameters> & HttpAuthSchemeResolvedConfig & ClientResolvedEndpointParameters;
|
|
184
|
+
/**
|
|
185
|
+
* @public
|
|
186
|
+
*
|
|
187
|
+
* The resolved configuration interface of ARCRegionSwitchClient class. This is resolved and normalized from the {@link ARCRegionSwitchClientConfig | constructor configuration interface}.
|
|
188
|
+
*/
|
|
189
|
+
export interface ARCRegionSwitchClientResolvedConfig extends ARCRegionSwitchClientResolvedConfigType {
|
|
190
|
+
}
|
|
191
|
+
/**
|
|
192
|
+
* <p>Amazon Application Recovery Controller (ARC) Region switch helps you to quickly and reliably shift traffic away from an impaired Amazon Web Services Region to a healthy Region. With Region switch, you can create plans that define the steps to shift traffic for your application from one Amazon Web Services Region to another. You can test your plans in practice mode before using them in a real recovery scenario.</p> <p>Region switch provides a structured approach to multi-Region failover, helping you to meet your recovery time objectives (RTOs) and maintain business continuity during regional disruptions.</p>
|
|
193
|
+
* @public
|
|
194
|
+
*/
|
|
195
|
+
export declare class ARCRegionSwitchClient extends __Client<__HttpHandlerOptions, ServiceInputTypes, ServiceOutputTypes, ARCRegionSwitchClientResolvedConfig> {
|
|
196
|
+
/**
|
|
197
|
+
* The resolved configuration of ARCRegionSwitchClient class. This is resolved and normalized from the {@link ARCRegionSwitchClientConfig | constructor configuration interface}.
|
|
198
|
+
*/
|
|
199
|
+
readonly config: ARCRegionSwitchClientResolvedConfig;
|
|
200
|
+
constructor(...[configuration]: __CheckOptionalClientConfig<ARCRegionSwitchClientConfig>);
|
|
201
|
+
/**
|
|
202
|
+
* Destroy underlying resources, like sockets. It's usually not necessary to do this.
|
|
203
|
+
* However in Node.js, it's best to explicitly shut down the client's agent when it is no longer needed.
|
|
204
|
+
* Otherwise, sockets might stay open for quite a long time before the server terminates them.
|
|
205
|
+
*/
|
|
206
|
+
destroy(): void;
|
|
207
|
+
}
|