@go-to-k/cdkd 0.296.14 → 0.296.15
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/dist/{asg-provider-eXsnCQh2.js → asg-provider-BbWC_1l5.js} +2 -2
- package/dist/{asg-provider-eXsnCQh2.js.map → asg-provider-BbWC_1l5.js.map} +1 -1
- package/dist/cli.js +2 -2
- package/dist/{deploy-engine-Z_zHC0jz.js → deploy-engine-CjLZZzyn.js} +70 -22
- package/dist/deploy-engine-CjLZZzyn.js.map +1 -0
- package/dist/{iam-role-provider-BTYPRrDe.js → iam-role-provider-DAqNwSNR.js} +2 -2
- package/dist/{iam-role-provider-BTYPRrDe.js.map → iam-role-provider-DAqNwSNR.js.map} +1 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +2 -2
- package/dist/{neptune-provider-ZYVwKq6K.js → neptune-provider-DlSon_pZ.js} +2 -2
- package/dist/{neptune-provider-ZYVwKq6K.js.map → neptune-provider-DlSon_pZ.js.map} +1 -1
- package/dist/{program-CKV6Kn8Q.js → program-CqKPsOUR.js} +30 -12
- package/dist/program-CqKPsOUR.js.map +1 -0
- package/dist/{provider-classes-Dz2gVtOZ.js → provider-classes-Drnm0GAz.js} +69 -11
- package/dist/{provider-classes-Dz2gVtOZ.js.map → provider-classes-Drnm0GAz.js.map} +1 -1
- package/dist/{rds-provider-6YeZRRfW.js → rds-provider-e6XtJAGl.js} +2 -2
- package/dist/{rds-provider-6YeZRRfW.js.map → rds-provider-e6XtJAGl.js.map} +1 -1
- package/dist/{version-1NhJbqzi.js → version-Bdg2mYAM.js} +2 -2
- package/dist/{version-1NhJbqzi.js.map → version-Bdg2mYAM.js.map} +1 -1
- package/package.json +1 -1
- package/dist/deploy-engine-Z_zHC0jz.js.map +0 -1
- package/dist/program-CKV6Kn8Q.js.map +0 -1
|
@@ -2,12 +2,12 @@ import { r as getAwsClients } from "./aws-clients-CnmtbrxD.js";
|
|
|
2
2
|
import { F as displayStackName, I as isPasteableIdent, N as displayIdent, O as SECRET_REF_MAX_CODE_POINTS, P as displaySafe, R as plainIdentOr, a as getLogger, b as generateResourceNameWithFallback, n as isAwsAuthoredFailure, r as safeStringify, t as describeAwsFailure, y as generateResourceName, z as safeMsg } from "./aws-failure-text-BaWeCWRz.js";
|
|
3
3
|
import { $ as protectedReplacementAdvice, $t as AccountIdUnavailableError, A as isQuotableImportValue, An as commandHole, B as isTerminalDeleteFailure, C as setBounded, D as VALUE_NOT_SHOWN, E as assertRegionMatch, F as resolveExplicitPhysicalId, Fn as plainOrDescribed, H as observeThenDisableProtection, Jn as markNameCollision, Jt as withPasteableAwsProfile, L as ProtectionFlipRegistry, M as quotedRemedyLogicalId, Mn as isInertUnquoted, Mt as markCreatedBeforeFailure, N as refusalTypeShown, Nn as pasteableCommand, O as isPlainImportJson, P as remedyLogicalId, Q as pasteableAwsCommand, Qn as isAmbiguousOutcomeError, Qt as credentialFingerprint, Rn as shellQuote, S as replayedSendWindow, St as withDerivedNameMasks, T as RESOURCE_NOT_FOUND, Tt as clearCreatedBeforeFailure, U as protectionFlipKey, Ut as injectiveKey, V as logGroupProtectionSite, W as rdsFamilyProtectionSite, Wt as injectiveKeyPrefix, X as WITHHELD_AWS_COMMAND, Xt as ambientCredentialConfig, Y as UNNAMEABLE_ID_CLAUSE, Yn as markReplayMayCollide, Yt as ambientClientDefaults, Z as isAwsCliLiteral, Zt as clientDefaultsFor, _ as RecentIdSet, _n as ResourceUpdateNotSupportedError, _t as createMaskedLogSinks, a as onlySecretDerived, ar as isThrottlingError, at as startInterruptWatch, b as isInsideWindow, bt as maskDeep, c as recordedPrincipalsRepair, cr as wrapMaskedAwsError, ct as canonicalizeRoute53QueryName, dt as compositeIdSkipResult, er as isRetryableTransientError, et as renderDisableCommand, ft as logicalIdShown, g as AmbiguousCreateLatch, gt as stateOrphanRecordRemedy, h as AMBIGUOUS_LATCH_TTL_MS, hn as ProvisioningError, ht as segmentAfterAnchor, i as holdsSecretDerivedEntry, ir as isMarkedNonRetryable, it as isInterruptedWaitError, j as normalizeAwsTagsToCfn, jn as hasClauseBreak, jt as markAuxiliaryFailure, k as isPlainImportValue, lt as compositeIdFormatMessage, o as readPrincipalLists, or as markNonRetryable, ot as ElapsedBudgetRegistry, p as withRemovalDefaults, pt as packCompositeId, q as userPoolProtectionSite, r as SECRET_DERIVED_READ_LIVE, rr as THROTTLING_ERROR_NAMES, sr as markRedactedCause, tn as CdkdError, tr as isTransientServerError, u as clearOnUpdateRemoval, ut as compositeIdSeparatorRefusal, v as ambiguousAttemptLead, vt as createMaskedRetryLogger, w as withoutServerErrorRetries, x as replayFollowedAmbiguousAttempt, xt as maskerOrIdentity, y as createAttemptKey, yt as isSecretDerivedValue, z as deleteWithProtectionCompensation, zn as withheldTargetClause } from "./iam-policy-targets-BoZuWtxK.js";
|
|
4
4
|
import { s as ambientRegion } from "./aws-client-defaults-D0q0z4dG.js";
|
|
5
|
-
import { $
|
|
6
|
-
import { n as collectInlinePolicyNamesManagedBySiblings, r as IamCreateClientCache, t as IAMRoleProvider } from "./iam-role-provider-
|
|
7
|
-
import { a as canonicalizeIpProtocolValue, i as resolveSecretDerivedPrincipals, n as runDestroyForStack, o as resolvedResourceTimeoutMs, r as isResolvableSecretPrincipalList, t as canonicalizeIpv4Cidr } from "./program-
|
|
8
|
-
import { RDSProvider } from "./rds-provider-
|
|
9
|
-
import { NeptuneProvider } from "./neptune-provider-
|
|
10
|
-
import { ASGProvider } from "./asg-provider-
|
|
5
|
+
import { $r as parseWebACLArn, Aa as isWarmThroughputDecrease, Ac as renderAssemblyPathEscape, Ba as requireConfigArray, Bn as DBPROXY_TAGS_WHAT, Ct as INDEX_SETTLE_POLL_INTERVAL_MS, Dt as S3_AUTO_DELETE_OBJECTS_TAG, Et as ECR_AUTO_DELETE_IMAGES_TAG, Fa as configBooleanRefusal, Fn as earliestDefined, Fr as s3BucketArn, Gn as tagMapAsList, Gt as redactedDeleteAddressFields, Ha as requireConfigString, Hn as planTagDiff, Ia as configIntegerRefusal, Ir as s3BucketDomainName, Ja as lambdaFunctionNameForMask, Jn as stringifyIfAssigned, Ka as withRetry, Kn as tagPlanWarning, Kt as redactedDeleteAddressSkip, La as configStringRefusal, Li as refuseMalformedNestedChildOutputs, Ln as reserveStackCreateToken, Lr as s3BucketDualStackDomainName, Ma as toFiniteNumber, Na as coerceCfnBoolean, Oa as WARM_THROUGHPUT_MEMBERS, Oc as describeFileReadFailure, Ot as hasCdkAutoDeleteTag, Pa as coerceCfnInteger, Pr as isSettledInstanceState, Ra as readConfigString, Rr as s3BucketRegionalDomainName, St as DELETE_INDEX_WAIT_PROCEED_NOTE, T as markRefusedBeforeApplying, Tt as waitForIndexesSettled, Un as readTagList, Ur as getAccountInfo, Ut as REDACTED_DELETE_ADDRESS_SKIP_REASON, Va as requireConfigObject, Vn as DBPROXY_TAG_OPTIONS, Vt as getCurrentProducerRegions, W as getNestedRevertRun, Wn as refuseMalformedDesiredTags, Wt as isRedactedRecordedValue, X as getCurrentNestedStackContext, Ya as sameLambdaFunctionAddress, Z as withNestedStackContext, _a as findSilentDropProperties, _c as canonicalizeRegion, _r as reEnableInstanceApiTermination, _t as beginDeleteWait, a as findNestedTemplateTreeDefect, ar as unchangedBehindSecretReference, bo as markSameGenerationBag, bt as resolveDynamoDbDeleteBudgetClock, c as renderNestedTemplateTreeDefect, ci as accountArgs, cr as deleteSkipReason, dr as markWaitAbandoned, gr as reDisableInstanceApiTermination, gt as DYNAMODB_DELETE_MIN_RESOURCE_TIMEOUT_MS, ha as withheldAccountClause, hr as observeThenDisableInstanceApiTermination, ht as DynamoDBGlobalTableProvider, io as passedNoEchoParametersOf, ir as slowCcOperationTimeoutMs, ja as toCfnInteger, jc as resolveAssemblyPath, jo as carriesSecretMask, ka as coerceWarmThroughput$1, kc as displayAssemblyPath, ko as recoverMaskedOutput, kt as isTruthyCfnBoolean, lo as hasMaskableValues, lr as withIndeterminateGuard, ls as stringifyValue, lt as getStackRecords, mc as decodeListingKey, mr as isTerminationProtectionPropagationError, ms as rewriteTemplateAssetReferences, ni as passedParameterClassesOf, o as isAbsoluteAssetPath, pr as ec2InstanceProtectionSite, q as revertNestedChildFromJournal, qa as canonicalLambdaFunctionName, qn as definedAttributes, ra as refuseMalformedResourcesForDestroy, s as listNestedTemplateRows, st as awaitInFlightSibling, t as DeployEngine, tr as getCurrentResourceSecrets, ur as isWaitAbandonedError, vc as derivePartitionAndUrlSuffix, vt as compensateRemovedDeletionProtection, w as getPriorAttempts, wo as dynamicReferenceTokens, wt as deleteTableWithIndexBusyRetry, xo as redactSecretsForState, xt as resolveDynamoDbDeleteBudgetMs, ya as withoutSilentDropProperties, yt as deleteBudgetKey, za as replayWarn, zn as acquireIdempotencyToken, zr as s3BucketWebsiteUrl } from "./deploy-engine-CjLZZzyn.js";
|
|
6
|
+
import { n as collectInlinePolicyNamesManagedBySiblings, r as IamCreateClientCache, t as IAMRoleProvider } from "./iam-role-provider-DAqNwSNR.js";
|
|
7
|
+
import { a as canonicalizeIpProtocolValue, i as resolveSecretDerivedPrincipals, n as runDestroyForStack, o as resolvedResourceTimeoutMs, r as isResolvableSecretPrincipalList, t as canonicalizeIpv4Cidr } from "./program-CqKPsOUR.js";
|
|
8
|
+
import { RDSProvider } from "./rds-provider-e6XtJAGl.js";
|
|
9
|
+
import { NeptuneProvider } from "./neptune-provider-DlSon_pZ.js";
|
|
10
|
+
import { ASGProvider } from "./asg-provider-BbWC_1l5.js";
|
|
11
11
|
import { createHash, randomUUID } from "node:crypto";
|
|
12
12
|
import { CreateBucketCommand, DeleteBucketAnalyticsConfigurationCommand, DeleteBucketCommand, DeleteBucketCorsCommand, DeleteBucketEncryptionCommand, DeleteBucketIntelligentTieringConfigurationCommand, DeleteBucketInventoryConfigurationCommand, DeleteBucketLifecycleCommand, DeleteBucketMetricsConfigurationCommand, DeleteBucketOwnershipControlsCommand, DeleteBucketPolicyCommand, DeleteBucketReplicationCommand, DeleteBucketTaggingCommand, DeleteBucketWebsiteCommand, DeleteObjectsCommand, GetBucketAccelerateConfigurationCommand, GetBucketCorsCommand, GetBucketEncryptionCommand, GetBucketLifecycleConfigurationCommand, GetBucketLocationCommand, GetBucketLoggingCommand, GetBucketNotificationConfigurationCommand, GetBucketOwnershipControlsCommand, GetBucketPolicyCommand, GetBucketReplicationCommand, GetBucketTaggingCommand, GetBucketVersioningCommand, GetBucketWebsiteCommand, GetObjectCommand, GetObjectLockConfigurationCommand, GetPublicAccessBlockCommand, HeadBucketCommand, ListBucketAnalyticsConfigurationsCommand, ListBucketIntelligentTieringConfigurationsCommand, ListBucketInventoryConfigurationsCommand, ListBucketMetricsConfigurationsCommand, ListObjectVersionsCommand, ListObjectsV2Command, NoSuchBucket, PutBucketAccelerateConfigurationCommand, PutBucketAnalyticsConfigurationCommand, PutBucketCorsCommand, PutBucketEncryptionCommand, PutBucketIntelligentTieringConfigurationCommand, PutBucketInventoryConfigurationCommand, PutBucketLifecycleConfigurationCommand, PutBucketLoggingCommand, PutBucketMetricsConfigurationCommand, PutBucketNotificationConfigurationCommand, PutBucketOwnershipControlsCommand, PutBucketPolicyCommand, PutBucketReplicationCommand, PutBucketTaggingCommand, PutBucketVersioningCommand, PutBucketWebsiteCommand, PutObjectLockConfigurationCommand, PutPublicAccessBlockCommand, S3Client } from "@aws-sdk/client-s3";
|
|
13
13
|
import { AddRoleToInstanceProfileCommand, AddUserToGroupCommand, AttachGroupPolicyCommand, AttachRolePolicyCommand, AttachUserPolicyCommand, CreateAccessKeyCommand, CreateGroupCommand, CreateInstanceProfileCommand, CreateLoginProfileCommand, CreatePolicyCommand, CreatePolicyVersionCommand, CreateUserCommand, DeleteAccessKeyCommand, DeleteGroupCommand, DeleteGroupPolicyCommand, DeleteInstanceProfileCommand, DeleteLoginProfileCommand, DeletePolicyCommand, DeletePolicyVersionCommand, DeleteRolePolicyCommand, DeleteUserCommand, DeleteUserPermissionsBoundaryCommand, DeleteUserPolicyCommand, DetachGroupPolicyCommand, DetachRolePolicyCommand, DetachUserPolicyCommand, GetAccessKeyLastUsedCommand, GetGroupCommand, GetGroupPolicyCommand, GetInstanceProfileCommand, GetPolicyCommand, GetPolicyVersionCommand, GetRolePolicyCommand, GetUserCommand, GetUserPolicyCommand, IAMClient, ListAccessKeysCommand, ListAttachedGroupPoliciesCommand, ListAttachedUserPoliciesCommand, ListEntitiesForPolicyCommand, ListGroupPoliciesCommand, ListGroupsForUserCommand, ListPoliciesCommand, ListPolicyTagsCommand, ListPolicyVersionsCommand, ListUserPoliciesCommand, NoSuchEntityException, PutGroupPolicyCommand, PutRolePolicyCommand, PutUserPermissionsBoundaryCommand, PutUserPolicyCommand, RemoveRoleFromInstanceProfileCommand, RemoveUserFromGroupCommand, TagPolicyCommand, TagUserCommand, UntagPolicyCommand, UntagUserCommand, UpdateAccessKeyCommand, UpdateLoginProfileCommand } from "@aws-sdk/client-iam";
|
|
@@ -25678,6 +25678,9 @@ function instanceAttributes(instance) {
|
|
|
25678
25678
|
Arn: instance?.DBInstanceArn
|
|
25679
25679
|
});
|
|
25680
25680
|
}
|
|
25681
|
+
function isDbIdentifier(id) {
|
|
25682
|
+
return id.length <= 63 && /^[A-Za-z](?:-?[A-Za-z0-9])*$/.test(id);
|
|
25683
|
+
}
|
|
25681
25684
|
var DocDBProvider = class {
|
|
25682
25685
|
docdbClient;
|
|
25683
25686
|
createClient;
|
|
@@ -25758,6 +25761,7 @@ var DocDBProvider = class {
|
|
|
25758
25761
|
lowercase: true
|
|
25759
25762
|
});
|
|
25760
25763
|
let clusterCreated = false;
|
|
25764
|
+
let createdResourceId;
|
|
25761
25765
|
try {
|
|
25762
25766
|
const response = await this.getCreateClient().send(new CreateDBClusterCommand$1({
|
|
25763
25767
|
DBClusterIdentifier: dbClusterIdentifier,
|
|
@@ -25778,6 +25782,7 @@ var DocDBProvider = class {
|
|
|
25778
25782
|
...tags.length > 0 && { Tags: tags }
|
|
25779
25783
|
}));
|
|
25780
25784
|
clusterCreated = true;
|
|
25785
|
+
createdResourceId = response.DBCluster?.DbClusterResourceId;
|
|
25781
25786
|
if (!response.DBCluster) throw new Error("CreateDBCluster did not return DBCluster");
|
|
25782
25787
|
this.logger.debug(`Successfully created DocDB DBCluster ${logicalId}: ${dbClusterIdentifier}`);
|
|
25783
25788
|
if (process.env["CDKD_NO_WAIT"] !== "true") await this.waitForClusterAvailable(dbClusterIdentifier);
|
|
@@ -25787,7 +25792,7 @@ var DocDBProvider = class {
|
|
|
25787
25792
|
};
|
|
25788
25793
|
} catch (error) {
|
|
25789
25794
|
const thrown = error instanceof ProvisioningError ? error : new ProvisioningError(`Failed to create DocDB DBCluster ${logicalId}: ${error instanceof Error ? error.message : String(error)}`, resourceType, logicalId, dbClusterIdentifier, error instanceof Error ? error : void 0);
|
|
25790
|
-
if (clusterCreated) markCreatedBeforeFailure(thrown, logicalId, resourceType, dbClusterIdentifier);
|
|
25795
|
+
if (clusterCreated) markCreatedBeforeFailure(thrown, logicalId, resourceType, dbClusterIdentifier, createdResourceId);
|
|
25791
25796
|
throw thrown;
|
|
25792
25797
|
}
|
|
25793
25798
|
}
|
|
@@ -25889,7 +25894,8 @@ var DocDBProvider = class {
|
|
|
25889
25894
|
if (isDocDBNotFoundError(error, "DBClusterNotFoundFault")) {
|
|
25890
25895
|
const clientRegion = await this.getClient().config.region();
|
|
25891
25896
|
assertRegionMatch(clientRegion, context?.expectedRegion, resourceType, logicalId, physicalId);
|
|
25892
|
-
this.logger.
|
|
25897
|
+
if (context?.failedCreateOrphan === true) this.logger.info(safeMsg` DocDB DB cluster ${physicalId} (${logicalId}), which a failed deploy created, is already gone; nothing to delete`);
|
|
25898
|
+
else this.logger.debug(`DocDB DBCluster ${logicalId} does not exist, skipping deletion`);
|
|
25893
25899
|
return;
|
|
25894
25900
|
}
|
|
25895
25901
|
const cause = error instanceof Error ? error : void 0;
|
|
@@ -25904,6 +25910,7 @@ var DocDBProvider = class {
|
|
|
25904
25910
|
lowercase: true
|
|
25905
25911
|
});
|
|
25906
25912
|
let instanceCreated = false;
|
|
25913
|
+
let createdResourceId;
|
|
25907
25914
|
try {
|
|
25908
25915
|
const response = await this.getCreateClient().send(new CreateDBInstanceCommand$1({
|
|
25909
25916
|
DBInstanceIdentifier: dbInstanceIdentifier,
|
|
@@ -25916,6 +25923,7 @@ var DocDBProvider = class {
|
|
|
25916
25923
|
...tags.length > 0 && { Tags: tags }
|
|
25917
25924
|
}));
|
|
25918
25925
|
instanceCreated = true;
|
|
25926
|
+
createdResourceId = response.DBInstance?.DbiResourceId;
|
|
25919
25927
|
if (!response.DBInstance) throw new Error("CreateDBInstance did not return DBInstance");
|
|
25920
25928
|
this.logger.debug(`Successfully created DocDB DBInstance ${logicalId}: ${dbInstanceIdentifier}`);
|
|
25921
25929
|
if (process.env["CDKD_NO_WAIT"] !== "true") await this.waitForInstanceAvailable(dbInstanceIdentifier);
|
|
@@ -25925,7 +25933,7 @@ var DocDBProvider = class {
|
|
|
25925
25933
|
};
|
|
25926
25934
|
} catch (error) {
|
|
25927
25935
|
const thrown = error instanceof ProvisioningError ? error : new ProvisioningError(`Failed to create DocDB DBInstance ${logicalId}: ${error instanceof Error ? error.message : String(error)}`, resourceType, logicalId, dbInstanceIdentifier, error instanceof Error ? error : void 0);
|
|
25928
|
-
if (instanceCreated) markCreatedBeforeFailure(thrown, logicalId, resourceType, dbInstanceIdentifier);
|
|
25936
|
+
if (instanceCreated) markCreatedBeforeFailure(thrown, logicalId, resourceType, dbInstanceIdentifier, createdResourceId);
|
|
25929
25937
|
throw thrown;
|
|
25930
25938
|
}
|
|
25931
25939
|
}
|
|
@@ -25963,7 +25971,8 @@ var DocDBProvider = class {
|
|
|
25963
25971
|
if (isDocDBNotFoundError(error, "DBInstanceNotFoundFault")) {
|
|
25964
25972
|
const clientRegion = await this.getClient().config.region();
|
|
25965
25973
|
assertRegionMatch(clientRegion, context?.expectedRegion, resourceType, logicalId, physicalId);
|
|
25966
|
-
this.logger.
|
|
25974
|
+
if (context?.failedCreateOrphan === true) this.logger.info(safeMsg` DocDB DB instance ${physicalId} (${logicalId}), which a failed deploy created, is already gone; nothing to delete`);
|
|
25975
|
+
else this.logger.debug(`DocDB DBInstance ${physicalId} does not exist, skipping deletion`);
|
|
25967
25976
|
return;
|
|
25968
25977
|
}
|
|
25969
25978
|
const cause = error instanceof Error ? error : void 0;
|
|
@@ -25976,6 +25985,55 @@ var DocDBProvider = class {
|
|
|
25976
25985
|
async describeDBInstance(dbInstanceIdentifier) {
|
|
25977
25986
|
return (await this.getClient().send(new DescribeDBInstancesCommand$1({ DBInstanceIdentifier: dbInstanceIdentifier }))).DBInstances?.[0];
|
|
25978
25987
|
}
|
|
25988
|
+
async isSameResource(journaledPhysicalId, record, resourceType, context) {
|
|
25989
|
+
if (resourceType !== "AWS::DocDB::DBCluster" && resourceType !== "AWS::DocDB::DBInstance") return "unknown";
|
|
25990
|
+
if (!isDbIdentifier(journaledPhysicalId) || !isDbIdentifier(record.physicalId)) return "unknown";
|
|
25991
|
+
if (journaledPhysicalId.toLowerCase() === record.physicalId.toLowerCase()) return "same";
|
|
25992
|
+
if (await this.getClient().config.region() !== context.expectedRegion) return "unknown";
|
|
25993
|
+
const recordResourceId = await this.readDbResourceIdIfExists(resourceType, record.physicalId);
|
|
25994
|
+
if (recordResourceId === void 0) return "unknown";
|
|
25995
|
+
const journaledResourceId = await this.readDbResourceIdIfExists(resourceType, journaledPhysicalId);
|
|
25996
|
+
if (journaledResourceId === void 0) return "different";
|
|
25997
|
+
return journaledResourceId === recordResourceId ? "same" : "different";
|
|
25998
|
+
}
|
|
25999
|
+
async resourceIdentity(physicalId, resourceType, context) {
|
|
26000
|
+
if (resourceType !== "AWS::DocDB::DBCluster" && resourceType !== "AWS::DocDB::DBInstance") return;
|
|
26001
|
+
if (!isDbIdentifier(physicalId)) return void 0;
|
|
26002
|
+
if (await this.getClient().config.region() !== context.expectedRegion) return void 0;
|
|
26003
|
+
const live = await this.readDbResourceIdIfExists(resourceType, physicalId);
|
|
26004
|
+
return live === void 0 ? RESOURCE_NOT_FOUND : live;
|
|
26005
|
+
}
|
|
26006
|
+
async readDbResourceIdIfExists(resourceType, identifier) {
|
|
26007
|
+
const isCluster = resourceType === "AWS::DocDB::DBCluster";
|
|
26008
|
+
let found;
|
|
26009
|
+
try {
|
|
26010
|
+
if (isCluster) {
|
|
26011
|
+
const cluster = await this.describeDBCluster(identifier);
|
|
26012
|
+
found = cluster && {
|
|
26013
|
+
identifier: cluster.DBClusterIdentifier,
|
|
26014
|
+
engine: cluster.Engine,
|
|
26015
|
+
resourceId: cluster.DbClusterResourceId
|
|
26016
|
+
};
|
|
26017
|
+
} else {
|
|
26018
|
+
const instance = await this.describeDBInstance(identifier);
|
|
26019
|
+
found = instance && {
|
|
26020
|
+
identifier: instance.DBInstanceIdentifier,
|
|
26021
|
+
engine: instance.Engine,
|
|
26022
|
+
resourceId: instance.DbiResourceId
|
|
26023
|
+
};
|
|
26024
|
+
}
|
|
26025
|
+
} catch (error) {
|
|
26026
|
+
const notFound = isCluster ? "DBClusterNotFoundFault" : "DBInstanceNotFoundFault";
|
|
26027
|
+
if (error?.name === notFound) return void 0;
|
|
26028
|
+
throw error;
|
|
26029
|
+
}
|
|
26030
|
+
if (found === void 0) return void 0;
|
|
26031
|
+
const api = isCluster ? "DescribeDBClusters" : "DescribeDBInstances";
|
|
26032
|
+
if (found.identifier?.toLowerCase() !== identifier.toLowerCase()) throw new Error(`${api} answered for another identifier`);
|
|
26033
|
+
if (found.engine !== "docdb") throw new Error(`${api} answered with a resource of another engine`);
|
|
26034
|
+
if (typeof found.resourceId !== "string" || found.resourceId === "") throw new Error(`${api} returned no resource id`);
|
|
26035
|
+
return found.resourceId;
|
|
26036
|
+
}
|
|
25979
26037
|
async waitForClusterAvailable(dbClusterIdentifier, maxWaitMs = 18e5) {
|
|
25980
26038
|
const startTime = Date.now();
|
|
25981
26039
|
let delay = 5e3;
|
|
@@ -44284,4 +44342,4 @@ var ACMCertificateProvider = class {
|
|
|
44284
44342
|
|
|
44285
44343
|
//#endregion
|
|
44286
44344
|
export { ACMCertificateProvider, ASGProvider, AgentCoreBrowserProvider, AgentCoreCodeInterpreterProvider, AgentCoreEvaluatorProvider, AgentCoreRuntimeProvider, ApiGatewayProvider, ApiGatewayV2Provider, AppSyncProvider, BudgetsBudgetProvider, CloudFrontDistributionProvider, CloudFrontOACProvider, CloudFrontOAIProvider, CloudTrailProvider, CloudWatchAlarmProvider, CloudWatchAnomalyDetectorProvider, CodeBuildProvider, CodeCommitRepositoryProvider, CognitoUserPoolProvider, DLMLifecyclePolicyProvider, DocDBProvider, DocDBSubnetGroupProvider, DynamoDBGlobalTableProvider, DynamoDBTableProvider, EC2Provider, ECRProvider, ECSProvider, EFSProvider, ELBv2Provider, EMRClusterProvider, EMRInstanceFleetConfigProvider, EMRInstanceGroupConfigProvider, ElastiCacheProvider, EventBridgeBusProvider, EventBridgeRuleProvider, FSxFileSystemProvider, FirehoseProvider, GlueConnectionProvider, GlueCrawlerProvider, GlueJobProvider, GlueProvider, GlueSecurityConfigurationProvider, GlueTriggerProvider, GlueWorkflowProvider, IAMAccessKeyProvider, IAMInstanceProfileProvider, IAMManagedPolicyProvider, IAMPolicyProvider, IAMRoleProvider, IAMUserGroupProvider, KMSProvider, KinesisStreamConsumerProvider, KinesisStreamProvider, LambdaEventInvokeConfigProvider, LambdaEventSourceMappingProvider, LambdaFunctionProvider, LambdaLayerVersionProvider, LambdaMicrovmImageProvider, LambdaPermissionProvider, LambdaUrlProvider, LogsLogGroupProvider, NeptuneProvider, NestedStackProvider, PipesPipeProvider, RDSDBProxyEndpointProvider, RDSDBProxyProvider, RDSDBProxyTargetGroupProvider, RDSProvider, Route53Provider, S3BucketPolicyProvider, S3BucketProvider, S3DirectoryBucketProvider, S3TablesProvider, S3VectorsProvider, SNSSubscriptionProvider, SNSTopicPolicyProvider, SNSTopicProvider, SQSQueuePolicyProvider, SQSQueueProvider, SSMParameterProvider, SchedulerScheduleProvider, SecretsManagerSecretProvider, ServiceDiscoveryProvider, StepFunctionsProvider, WAFv2WebACLProvider, WaitConditionHandleProvider };
|
|
44287
|
-
//# sourceMappingURL=provider-classes-
|
|
44345
|
+
//# sourceMappingURL=provider-classes-Drnm0GAz.js.map
|