@go-to-k/cdkd 0.318.0 → 0.319.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.
Files changed (26) hide show
  1. package/dist/{asg-provider-kV8DYFjT.js → asg-provider-T9K-NVi8.js} +2 -2
  2. package/dist/{asg-provider-kV8DYFjT.js.map → asg-provider-T9K-NVi8.js.map} +1 -1
  3. package/dist/cli.js +2 -2
  4. package/dist/{deploy-engine-BnEvzfon.js → deploy-engine-CVYhHEgq.js} +68 -35
  5. package/dist/deploy-engine-CVYhHEgq.js.map +1 -0
  6. package/dist/{iam-role-provider-3w71Eu4a.js → iam-role-provider-qTIqSmlf.js} +40 -24
  7. package/dist/iam-role-provider-qTIqSmlf.js.map +1 -0
  8. package/dist/index.d.ts +0 -1
  9. package/dist/index.d.ts.map +1 -1
  10. package/dist/index.js +2 -2
  11. package/dist/{neptune-provider-D8tkFP12.js → neptune-provider-BsA7jGiV.js} +208 -26
  12. package/dist/neptune-provider-BsA7jGiV.js.map +1 -0
  13. package/dist/{program-CKm1Nk6t.js → program-DyYTFxF-.js} +11 -11
  14. package/dist/{program-CKm1Nk6t.js.map → program-DyYTFxF-.js.map} +1 -1
  15. package/dist/{provider-classes-CbiecOol.js → provider-classes-DOr3JVGp.js} +182 -51
  16. package/dist/provider-classes-DOr3JVGp.js.map +1 -0
  17. package/dist/{rds-provider-bEeid6uI.js → rds-provider-CIjO2Do5.js} +74 -5
  18. package/dist/rds-provider-CIjO2Do5.js.map +1 -0
  19. package/dist/{version-CFF8UOVj.js → version-C3yhae4b.js} +2 -2
  20. package/dist/{version-CFF8UOVj.js.map → version-C3yhae4b.js.map} +1 -1
  21. package/package.json +1 -1
  22. package/dist/deploy-engine-BnEvzfon.js.map +0 -1
  23. package/dist/iam-role-provider-3w71Eu4a.js.map +0 -1
  24. package/dist/neptune-provider-D8tkFP12.js.map +0 -1
  25. package/dist/provider-classes-CbiecOol.js.map +0 -1
  26. package/dist/rds-provider-bEeid6uI.js.map +0 -1
@@ -2,13 +2,13 @@ import { r as getAwsClients, s as withApiGatewayPacing } from "./aws-clients-DWp
2
2
  import { $ as safeMsg, A as isBeforeStateRead, E as generatedNameFor, J as displaySafe, N as recordedGeneratedNameKept, O as getCurrentStackInstanceId, Q as plainIdentOr, T as generateResourceNameWithFallback, V as SECRET_REF_MAX_CODE_POINTS, X as isPasteableIdent, Y as displayStackName, a as safeStringify, i as isAwsAuthoredFailure, n as describeAwsFailure, q as displayIdent, r as describeAwsStatusReason, s as getLogger, t as VERBOSE_POINTER, w as generateResourceName } from "./aws-failure-text-DiHodi76.js";
3
3
  import { $ as isTerminalDeleteFailure, A as setBounded, Ar as isThrottlingError, At as stateOrphanRecordRemedy, B as normalizeAwsTagsToCfn, C as AmbiguousCreateLatch, Cr as isExplicitDenyError, Ct as compositeIdFormatMessage, D as isInsideWindow, Dt as packCompositeId, E as createAttemptKey, Er as isTransientServerError, Et as logicalIdShown, F as assertRegionMatch, Fn as ResourceUpdateNotSupportedError, Ft as maskerOrIdentity, Gt as markAuxiliaryFailure, H as refusalTypeShown, I as VALUE_NOT_SHOWN, It as withDerivedNameMasks, J as deleteAfterProtectionFlipWithFinalSnapshot, K as ProtectionFlipRegistry, Kt as markCreatedBeforeFailure, L as isPlainImportJson, M as RESOURCE_NOT_FOUND, Mr as markRedactedCause, Mt as createMaskedRetryLogger, Nn as ProvisioningError, Nr as wrapMaskedAwsError, Nt as isSecretDerivedValue, O as replayFollowedAmbiguousAttempt, Or as THROTTLING_ERROR_NAMES, P as markNotGone, Pt as maskDeep, Q as isTerminalDbWaitStatus, Qn as pasteableCommand, R as isPlainImportValue, S as AMBIGUOUS_LATCH_TTL_MS, Sr as isAmbiguousOutcomeError, St as canonicalizeRoute53QueryName, T as ambiguousAttemptLead, Tr as isRetryableTransientError, Tt as compositeIdSkipResult, U as remedyLogicalId, Ut as isAuxiliaryFailure, V as quotedRemedyLogicalId, W as resolveExplicitPhysicalId, Xn as hasClauseBreak, Y as deleteWithProtectionCompensation, Yn as commandHole, Z as isProceedDbStatus, Zn as isInertUnquoted, b as withRemovalDefaults, bt as isInterruptedWaitError, ct as UNNAMEABLE_ID_CLAUSE, d as onlySecretDerived, dn as withPasteableAwsProfile, dt as pasteableAwsCommand, er as plainOrDescribed, et as logGroupProtectionSite, f as readPrincipalLists, fn as ambientClientDefaults, ft as protectedReplacementAdvice, g as clearOnUpdateRemoval, gn as AccountIdUnavailableError, hn as credentialFingerprint, hr as relayedNameCollision, ht as ElapsedBudgetRegistry, i as reportCreatedResource, ir as withheldTargetClause, j as withoutServerErrorRetries, jr as markNonRetryable, jt as createMaskedLogSinks, k as replayedSendWindow, kr as isMarkedNonRetryable, kt as segmentAfterAnchor, l as SECRET_DERIVED_READ_LIVE, lt as WITHHELD_AWS_COMMAND, m as recordedPrincipalsRepair, mn as clientDefaultsFor, mr as markReplayMayCollide, mt as ElapsedBudget, nt as protectionFlipKey, o as retractCreatedResource, on as injectiveKey, ot as userPoolProtectionSite, pn as ambientCredentialConfig, pr as markNameCollision, pt as renderDisableCommand, qt as markSupersedesEarlierCreate, rr as shellQuote, rt as rdsFamilyProtectionSite, sn as injectiveKeyPrefix, tt as observeThenDisableProtection, u as holdsSecretDerivedEntry, ut as isAwsCliLiteral, vn as CdkdError, w as RecentIdSet, wt as compositeIdSeparatorRefusal, xt as startInterruptWatch, y as removedTemplateKeys, yr as explicitDenyPolicyKind, z as isQuotableImportValue, zt as clearCreatedBeforeFailure } from "./created-resource-sink-BpB3iPvn.js";
4
4
  import { c as ambientRegion } from "./aws-client-defaults-BLXFsfMa.js";
5
- import { $ as sendTtlWaitingOutRateLimit, A as DYNAMODB_DELETE_MIN_RESOURCE_TIMEOUT_MS, Aa as isUsableAttemptedName, As as refuseMalformedResourcesForDestroy, B as deleteTableWithIndexBusyRetry, Ba as s3BucketDomainName, Bi as markDeleteStarted, Br as getStackRecords, C as planContributorInsightsOp, Ca as ec2InstanceProtectionSite, Cc as ecsServiceLaunchTypeSetOrChanged, Ct as enclosingDeadlineExpired, D as reverseMapTableContributorInsights, Da as reEnableInstanceApiTermination, Dc as sameLambdaFunctionAddress, E as reverseMapIndexContributorInsights, Ea as reDisableInstanceApiTermination, Ec as lambdaFunctionNameForMask, F as resolveDynamoDbDeleteBudgetClock, Fd as renderAssemblyPathEscape, Fi as acquireIdempotencyToken, Fo as accountArgs, G as readbackVectorIndexes, Gc as markSameGenerationBag, Gi as refuseMalformedDesiredTags, Gn as isRedactedRecordedValue, Gs as findSilentDropProperties, H as relayedIndexBusyDelete, Ha as s3BucketRegionalDomainName, Hi as DBPROXY_TAG_OPTIONS, Hn as getCurrentProducerRegions, Hr as replacedDeleteFailureVerdict, Hs as withheldAccountClause, I as resolveDynamoDbDeleteBudgetMs, Id as resolveAssemblyPath, J as vectorIndexesShapeDetail, Ja as outputReferenceProvenanceOf, Jc as snapshotPassProvenance, Ji as definedAttributes, Jt as getCurrentNestedStackContext, K as vectorIndexesForCreate, Kc as redactForState, Ki as tagMapAsList, Kn as redactedDeleteAddressFields, L as DELETE_INDEX_WAIT_PROCEED_NOTE, M as beginDeleteWait, N as compensateRemovedDeletionProtection, Nd as describeFileReadFailure, Ni as reserveStackCreateToken, O as stripIndexContributorInsights, Oo as passedParameterClassesOf, P as deleteBudgetKey, Pd as displayAssemblyPath, Q as readTtlSpec, R as INDEX_SETTLE_POLL_INTERVAL_MS, Ra as isSettledInstanceState, Rr as awaitInFlightSibling, S as indexDeclaresContributorInsights, Sl as recordAttributeIdCopy, T as readContributorInsightsSpec, Ta as observeThenDisableInstanceApiTermination, Tc as canonicalLambdaFunctionName, Tl as carriesSecretMask, To as parseWebACLArn, U as waitForIndexesSettled, Ua as s3BucketWebsiteUrl, Ui as planTagDiff, V as maskedLogger, Va as s3BucketDualStackDomainName, Vi as DBPROXY_TAGS_WHAT, Vt as getNestedRevertRun, W as planVectorIndexUpdates, Wi as readTagList, Wn as REDACTED_DELETE_ADDRESS_SKIP_REASON, Wt as revertNestedChildFromJournal, X as isTtlRateLimited, Y as isTtlAlreadyDisabled, Yi as stringifyIfAssigned, Yt as withNestedStackContext, Z as planTimeToLive, Zc as hasMaskableValues, _ as streamMemberRefusals, _t as renderNestedTemplateTreeDefect, _u as rewriteTemplateAssetReferences, aa as getCurrentResourceSecrets, ac as toCfnInteger, an as chunks, at as markRefusedBeforeApplying, b as CONTRIBUTOR_INSIGHTS_KEY, ba as isWaitAbandonedError, bc as withRetry, bd as derivePartitionAndUrlSuffix, bl as recoverMaskedOutput, c as DynamoDBGlobalTableProvider, cc as coerceCfnInteger, cn as withApiLimit, d as declaredStreamPolicyMember, da as slowCcOperationTimeoutMs, dc as configStringRefusal, dl as withoutPhysicalNameCopies, et as ECR_AUTO_DELETE_IMAGES_TAG, f as declaredStreamTagsMember, fa as onlySecretReferencesDiffer, fc as readConfigString, fu as stringifyValue, g as streamDeclaresTags, gc as requireConfigString, gd as decodeListingKey, gt as listNestedTemplateRows, h as streamDeclaresPolicy, hc as requireConfigObject, ht as isAbsoluteAssetPath, ic as isWarmThroughputDecrease, it as getPriorAttempts, j as DYNAMODB_DELETE_POLL_COST_MS, ji as earliestDefined, k as DYNAMODB_DELETE_DEADLINE_MARGIN_MS, l as STREAM_POLICY_KEY, lc as configBooleanRefusal, lu as timePhase, m as reverseMapStreamPolicy, mc as requireConfigArray, mo as getAccountInfo, mt as findNestedTemplateTreeDefect, nc as WARM_THROUGHPUT_MEMBERS, nt as hasCdkAutoDeleteTag, oc as toFiniteNumber, on as isAccessDeniedError, p as planStreamMemberOps, pa as unchangedBehindSecretReference, pc as replayWarn, pl as dynamicReferenceTokens, q as vectorIndexesSettled, qc as recordReferenceProvenanceEntry, qi as tagPlanWarning, qn as redactedDeleteAddressSkip, qs as withoutSilentDropProperties, rc as coerceWarmThroughput$1, rt as isTruthyCfnBoolean, sc as coerceCfnBoolean, sn as lookupEachName, t as DeployEngine, ta as waitForLambdaFunctionActive, tt as S3_AUTO_DELETE_OBJECTS_TAG, u as STREAM_TAGS_KEY, uc as configIntegerRefusal, us as refuseMalformedNestedChildOutputs, v as streamPolicyMatchesDeclared, va as deleteSkipReason, vi as secretNamedAttributeNamesOf, w as planIndexContributorInsightsOps, wa as isTerminationProtectionPropagationError, wc as emrClusterInstancesReplaced, wt as enclosingDeadlineRemainingMs, x as contributorInsightsRefusals, xa as markWaitAbandoned, xc as blockDeviceMappingsDifferOnlyInDeleteOnTermination, xl as physicalNameCopiesOf, y as streamTagsMatchDeclared, ya as withIndeterminateGuard, yd as canonicalizeRegion, z as TABLE_INDEX_NOUN, za as s3BucketArn, zc as passedNoEchoParametersOf, zi as isRefusedByName } from "./deploy-engine-BnEvzfon.js";
6
- import { n as collectInlinePolicyNamesManagedBySiblings, r as IamCreateClientCache, t as IAMRoleProvider } from "./iam-role-provider-3w71Eu4a.js";
7
- import { a as resolveSecretDerivedPrincipals, i as isResolvableSecretPrincipalList, n as runDestroyForStack, o as canonicalizeIpProtocolValue, r as holdsUnprovenSecretPrincipalToken, s as resolvedResourceTimeoutMs, t as canonicalizeIpv4Cidr } from "./program-CKm1Nk6t.js";
5
+ import { $ as sendTtlWaitingOutRateLimit, A as DYNAMODB_DELETE_MIN_RESOURCE_TIMEOUT_MS, B as deleteTableWithIndexBusyRetry, Ba as s3BucketArn, Bc as passedNoEchoParametersOf, Bi as isRefusedByName, C as planContributorInsightsOp, Cl as recordAttributeIdCopy, Ct as enclosingDeadlineExpired, D as reverseMapTableContributorInsights, Da as reDisableInstanceApiTermination, Dc as lambdaFunctionNameForMask, E as reverseMapIndexContributorInsights, Ea as observeThenDisableInstanceApiTermination, Ec as canonicalLambdaFunctionName, El as carriesSecretMask, Eo as parseWebACLArn, F as resolveDynamoDbDeleteBudgetClock, Fd as displayAssemblyPath, G as readbackVectorIndexes, Gi as readTagList, Gn as isRedactedRecordedValue, H as relayedIndexBusyDelete, Ha as s3BucketDualStackDomainName, Hi as DBPROXY_TAGS_WHAT, Hn as getCurrentProducerRegions, I as resolveDynamoDbDeleteBudgetMs, Id as renderAssemblyPathEscape, Ii as acquireIdempotencyToken, Io as accountArgs, J as vectorIndexesShapeDetail, Jc as recordReferenceProvenanceEntry, Ji as tagPlanWarning, Js as withoutSilentDropProperties, Jt as getCurrentNestedStackContext, K as vectorIndexesForCreate, Kc as markSameGenerationBag, Ki as refuseMalformedDesiredTags, Kn as redactedDeleteAddressFields, Ks as findSilentDropProperties, L as DELETE_INDEX_WAIT_PROCEED_NOTE, Ld as resolveAssemblyPath, M as beginDeleteWait, Mi as earliestDefined, N as compensateRemovedDeletionProtection, O as stripIndexContributorInsights, Oa as reEnableInstanceApiTermination, Oc as sameLambdaFunctionAddress, P as deleteBudgetKey, Pd as describeFileReadFailure, Pi as reserveStackCreateToken, Q as readTtlSpec, Qc as hasMaskableValues, R as INDEX_SETTLE_POLL_INTERVAL_MS, S as indexDeclaresContributorInsights, Sa as markWaitAbandoned, Sc as blockDeviceMappingsDifferOnlyInDeleteOnTermination, Sl as physicalNameCopiesOf, T as readContributorInsightsSpec, Ta as isTerminationProtectionPropagationError, Tc as emrClusterInstancesReplaced, U as waitForIndexesSettled, Ua as s3BucketRegionalDomainName, Ui as DBPROXY_TAG_OPTIONS, Ur as replacedDeleteFailureVerdict, Us as withheldAccountClause, V as maskedLogger, Va as s3BucketDomainName, Vi as markDeleteStarted, Vr as getStackRecords, Vt as getNestedRevertRun, W as planVectorIndexUpdates, Wa as s3BucketWebsiteUrl, Wi as planTagDiff, Wn as REDACTED_DELETE_ADDRESS_SKIP_REASON, Wt as revertNestedChildFromJournal, X as isTtlRateLimited, Xi as stringifyIfAssigned, Y as isTtlAlreadyDisabled, Ya as outputReferenceProvenanceOf, Yc as snapshotPassProvenance, Yi as definedAttributes, Yt as withNestedStackContext, Z as planTimeToLive, _ as streamMemberRefusals, _c as requireConfigString, _d as decodeListingKey, _t as renderNestedTemplateTreeDefect, ac as isWarmThroughputDecrease, an as chunks, at as markRefusedBeforeApplying, b as CONTRIBUTOR_INSIGHTS_KEY, ba as withIndeterminateGuard, bd as canonicalizeRegion, c as DynamoDBGlobalTableProvider, cc as coerceCfnBoolean, cn as withApiLimit, d as declaredStreamPolicyMember, dc as configIntegerRefusal, ds as refuseMalformedNestedChildOutputs, et as ECR_AUTO_DELETE_IMAGES_TAG, f as declaredStreamTagsMember, fa as slowCcOperationTimeoutMs, fc as configStringRefusal, fl as withoutPhysicalNameCopies, g as streamDeclaresTags, gc as requireConfigObject, gt as listNestedTemplateRows, h as streamDeclaresPolicy, hc as requireConfigArray, ho as getAccountInfo, ht as isAbsoluteAssetPath, ic as coerceWarmThroughput$1, it as getPriorAttempts, j as DYNAMODB_DELETE_POLL_COST_MS, ja as isUsableAttemptedName, js as refuseMalformedResourcesForDestroy, k as DYNAMODB_DELETE_DEADLINE_MARGIN_MS, ko as passedParameterClassesOf, l as STREAM_POLICY_KEY, lc as coerceCfnInteger, m as reverseMapStreamPolicy, ma as unchangedBehindSecretReference, mc as replayWarn, ml as dynamicReferenceTokens, mt as findNestedTemplateTreeDefect, na as waitForLambdaFunctionActive, nt as hasCdkAutoDeleteTag, oa as getCurrentResourceSecrets, oc as toCfnInteger, on as isAccessDeniedError, p as planStreamMemberOps, pa as onlySecretReferencesDiffer, pc as readConfigString, pu as stringifyValue, q as vectorIndexesSettled, qc as redactForState, qi as tagMapAsList, qn as redactedDeleteAddressSkip, rc as WARM_THROUGHPUT_MEMBERS, rt as isTruthyCfnBoolean, sc as toFiniteNumber, sn as lookupEachName, t as DeployEngine, tt as S3_AUTO_DELETE_OBJECTS_TAG, u as STREAM_TAGS_KEY, uc as configBooleanRefusal, uu as timePhase, v as streamPolicyMatchesDeclared, vu as rewriteTemplateAssetReferences, w as planIndexContributorInsightsOps, wa as ec2InstanceProtectionSite, wc as ecsServiceLaunchTypeSetOrChanged, wt as enclosingDeadlineRemainingMs, x as contributorInsightsRefusals, xa as isWaitAbandonedError, xc as withRetry, xd as derivePartitionAndUrlSuffix, xl as recoverMaskedOutput, y as streamTagsMatchDeclared, ya as deleteSkipReason, yi as secretNamedAttributeNamesOf, z as TABLE_INDEX_NOUN, za as isSettledInstanceState, zr as awaitInFlightSibling } from "./deploy-engine-CVYhHEgq.js";
6
+ import { a as IamCreateClientCache, i as isEntityAlreadyExists, n as collectInlinePolicyNamesManagedBySiblings, r as iamEntityLeftByThisCreate, t as IAMRoleProvider } from "./iam-role-provider-qTIqSmlf.js";
7
+ import { a as resolveSecretDerivedPrincipals, i as isResolvableSecretPrincipalList, n as runDestroyForStack, o as canonicalizeIpProtocolValue, r as holdsUnprovenSecretPrincipalToken, s as resolvedResourceTimeoutMs, t as canonicalizeIpv4Cidr } from "./program-DyYTFxF-.js";
8
8
  import { n as modifyDbInstanceWhenAvailable } from "./db-instance-modify-retry-CspmK57I.js";
9
- import { RDSProvider } from "./rds-provider-bEeid6uI.js";
10
- import { NeptuneProvider } from "./neptune-provider-D8tkFP12.js";
11
- import { ASGProvider } from "./asg-provider-kV8DYFjT.js";
9
+ import { RDSProvider } from "./rds-provider-CIjO2Do5.js";
10
+ import { NeptuneProvider } from "./neptune-provider-BsA7jGiV.js";
11
+ import { ASGProvider } from "./asg-provider-T9K-NVi8.js";
12
12
  import { createHash, randomUUID } from "node:crypto";
13
13
  import { CreateBucketCommand, CreateBucketMetadataConfigurationCommand, DeleteBucketAnalyticsConfigurationCommand, DeleteBucketCommand, DeleteBucketCorsCommand, DeleteBucketEncryptionCommand, DeleteBucketIntelligentTieringConfigurationCommand, DeleteBucketInventoryConfigurationCommand, DeleteBucketLifecycleCommand, DeleteBucketMetadataConfigurationCommand, DeleteBucketMetricsConfigurationCommand, DeleteBucketOwnershipControlsCommand, DeleteBucketPolicyCommand, DeleteBucketReplicationCommand, DeleteBucketTaggingCommand, DeleteBucketWebsiteCommand, DeleteObjectsCommand, GetBucketAbacCommand, GetBucketAccelerateConfigurationCommand, GetBucketCorsCommand, GetBucketEncryptionCommand, GetBucketLifecycleConfigurationCommand, GetBucketLocationCommand, GetBucketLoggingCommand, GetBucketMetadataConfigurationCommand, GetBucketNotificationConfigurationCommand, GetBucketOwnershipControlsCommand, GetBucketPolicyCommand, GetBucketReplicationCommand, GetBucketTaggingCommand, GetBucketVersioningCommand, GetBucketWebsiteCommand, GetObjectCommand, GetObjectLockConfigurationCommand, GetPublicAccessBlockCommand, HeadBucketCommand, ListBucketAnalyticsConfigurationsCommand, ListBucketIntelligentTieringConfigurationsCommand, ListBucketInventoryConfigurationsCommand, ListBucketMetricsConfigurationsCommand, ListBucketsCommand, ListObjectVersionsCommand, ListObjectsV2Command, NoSuchBucket, PutBucketAbacCommand, PutBucketAccelerateConfigurationCommand, PutBucketAnalyticsConfigurationCommand, PutBucketCorsCommand, PutBucketEncryptionCommand, PutBucketIntelligentTieringConfigurationCommand, PutBucketInventoryConfigurationCommand, PutBucketLifecycleConfigurationCommand, PutBucketLoggingCommand, PutBucketMetricsConfigurationCommand, PutBucketNotificationConfigurationCommand, PutBucketOwnershipControlsCommand, PutBucketPolicyCommand, PutBucketReplicationCommand, PutBucketTaggingCommand, PutBucketVersioningCommand, PutBucketWebsiteCommand, PutObjectLockConfigurationCommand, PutPublicAccessBlockCommand, S3Client, UpdateBucketMetadataAnnotationTableConfigurationCommand, UpdateBucketMetadataInventoryTableConfigurationCommand, UpdateBucketMetadataJournalTableConfigurationCommand } from "@aws-sdk/client-s3";
14
14
  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, UpdateGroupCommand, UpdateLoginProfileCommand, UpdateUserCommand } from "@aws-sdk/client-iam";
@@ -650,17 +650,39 @@ var IAMManagedPolicyProvider = class {
650
650
  if (properties["Description"]) createParams.Description = properties["Description"];
651
651
  if (properties["Path"]) createParams.Path = properties["Path"];
652
652
  if (tags.length > 0) createParams.Tags = tags;
653
- const response = await (await this.createClient.get()).send(new CreatePolicyCommand(createParams));
654
- const policyArn = response.Policy?.Arn;
655
- if (!policyArn) throw new ProvisioningError(`CreatePolicy succeeded but no Arn returned for ${logicalId}`, resourceType, logicalId, policyName);
653
+ const createClient = await this.createClient.get();
654
+ let policy;
655
+ let adopted = false;
656
+ try {
657
+ policy = (await createClient.send(new CreatePolicyCommand(createParams))).Policy;
658
+ } catch (createError) {
659
+ const expectedArnTail = `:policy${createParams.Path ?? "/"}${policyName}`;
660
+ policy = await iamEntityLeftByThisCreate({
661
+ logicalId,
662
+ resourceType,
663
+ noun: "managed policy",
664
+ displayName: policyName,
665
+ createError,
666
+ namesThisEntity: (reported) => reported.endsWith(expectedArnTail),
667
+ read: async (reportedArn) => (await this.iamClient.send(new GetPolicyCommand({ PolicyArn: reportedArn }))).Policy,
668
+ identityOf: (live) => policyIdentityToken(live?.PolicyId),
669
+ log
670
+ });
671
+ if (policy === void 0) throw createError;
672
+ adopted = true;
673
+ }
674
+ const policyArn = policy?.Arn;
675
+ if (!policyArn) throw new ProvisioningError(`${adopted ? "GetPolicy" : "CreatePolicy"} succeeded but no Arn returned for ${logicalId}`, resourceType, logicalId, policyName);
656
676
  leftBehindArn = policyArn;
657
- createdPolicyIdentity = policyIdentityToken(response.Policy?.PolicyId);
658
- reportCreatedResource(logicalId, resourceType, policyArn, createdPolicyIdentity);
659
- log.debug(`Created IAM managed policy: ${v(policyArn)}`);
677
+ createdPolicyIdentity = policyIdentityToken(policy?.PolicyId);
678
+ if (!adopted) {
679
+ reportCreatedResource(logicalId, resourceType, policyArn, createdPolicyIdentity);
680
+ log.debug(`Created IAM managed policy: ${v(policyArn)}`);
681
+ }
660
682
  try {
661
683
  await this.attachToPrincipals(policyArn, principals.lists.Groups, principals.lists.Roles, principals.lists.Users, log);
662
684
  } catch (innerError) {
663
- try {
685
+ if (!adopted) try {
664
686
  await this.detachAllPrincipals(policyArn);
665
687
  await this.deleteAllNonDefaultVersions(policyArn);
666
688
  await this.iamClient.send(new DeletePolicyCommand({ PolicyArn: policyArn }));
@@ -1257,17 +1279,40 @@ var IAMInstanceProfileProvider = class {
1257
1279
  let leftBehind = false;
1258
1280
  let createdProfileIdentity;
1259
1281
  try {
1260
- const response = await (await this.createClient.get()).send(new CreateInstanceProfileCommand({
1261
- InstanceProfileName: instanceProfileName,
1262
- Path: path
1263
- }));
1282
+ const createClient = await this.createClient.get();
1283
+ let profile;
1284
+ let adopted = false;
1285
+ try {
1286
+ profile = (await createClient.send(new CreateInstanceProfileCommand({
1287
+ InstanceProfileName: instanceProfileName,
1288
+ Path: path
1289
+ }))).InstanceProfile;
1290
+ } catch (createError) {
1291
+ profile = await iamEntityLeftByThisCreate({
1292
+ logicalId,
1293
+ resourceType,
1294
+ noun: "instance profile",
1295
+ displayName: instanceProfileName,
1296
+ createError,
1297
+ namesThisEntity: (reported) => reported === instanceProfileName,
1298
+ read: async () => (await this.iamClient.send(new GetInstanceProfileCommand({ InstanceProfileName: instanceProfileName }))).InstanceProfile,
1299
+ identityOf: (live) => instanceProfileIdentityToken(live?.InstanceProfileId),
1300
+ log
1301
+ });
1302
+ if (profile === void 0) throw createError;
1303
+ adopted = true;
1304
+ }
1264
1305
  leftBehind = true;
1265
- createdProfileIdentity = instanceProfileIdentityToken(response.InstanceProfile?.InstanceProfileId);
1266
- reportCreatedResource(logicalId, resourceType, instanceProfileName, createdProfileIdentity);
1267
- log.debug(`Created IAM instance profile: ${v(instanceProfileName)}`);
1306
+ createdProfileIdentity = instanceProfileIdentityToken(profile?.InstanceProfileId);
1307
+ if (!adopted) {
1308
+ reportCreatedResource(logicalId, resourceType, instanceProfileName, createdProfileIdentity);
1309
+ log.debug(`Created IAM instance profile: ${v(instanceProfileName)}`);
1310
+ }
1268
1311
  const attachedRoles = [];
1312
+ const heldRoles = new Set(profile?.Roles?.map((role) => role.RoleName?.toLowerCase()));
1269
1313
  try {
1270
1314
  if (roles && Array.isArray(roles)) for (const roleName of roles) {
1315
+ if (heldRoles.has(roleName.toLowerCase())) continue;
1271
1316
  await this.iamClient.send(new AddRoleToInstanceProfileCommand({
1272
1317
  InstanceProfileName: instanceProfileName,
1273
1318
  RoleName: roleName
@@ -1276,7 +1321,7 @@ var IAMInstanceProfileProvider = class {
1276
1321
  log.debug(`Added role ${v(roleName)} to instance profile ${v(instanceProfileName)}`);
1277
1322
  }
1278
1323
  } catch (innerError) {
1279
- try {
1324
+ if (!adopted) try {
1280
1325
  for (const roleName of attachedRoles) try {
1281
1326
  await this.iamClient.send(new RemoveRoleFromInstanceProfileCommand({
1282
1327
  InstanceProfileName: instanceProfileName,
@@ -1301,7 +1346,7 @@ var IAMInstanceProfileProvider = class {
1301
1346
  log.debug(`Successfully created IAM instance profile ${logicalId}: ${v(instanceProfileName)}`);
1302
1347
  return {
1303
1348
  physicalId: instanceProfileName,
1304
- attributes: { Arn: response.InstanceProfile?.Arn }
1349
+ attributes: { Arn: profile?.Arn }
1305
1350
  };
1306
1351
  } catch (error) {
1307
1352
  const cause = error instanceof Error ? error : void 0;
@@ -1803,6 +1848,8 @@ function isUserOrGroupType(resourceType) {
1803
1848
  function userOrGroupIdentityToken(id) {
1804
1849
  return typeof id === "string" && id !== "" ? id : void 0;
1805
1850
  }
1851
+ const PROFILE_SETTLING_ERROR = "EntityTemporarilyUnmodifiableException";
1852
+ const LOGIN_PROFILE_SETTLING_MESSAGE = "IAM cannot modify the login profile yet: a concurrent update operation has not settled";
1806
1853
  const MEMBERSHIP_NO_PROPERTIES_SKIP_REASON = "no properties in state — group membership not removed";
1807
1854
  const MEMBERSHIP_MISSING_FIELDS_SKIP_REASON = "GroupName/Users missing from state — membership not removed";
1808
1855
  const MEMBERSHIP_MALFORMED_USERS_SKIP_REASON = "malformed Users in state — membership not removed";
@@ -1938,10 +1985,29 @@ var IAMUserGroupProvider = class {
1938
1985
  const createParams = { UserName: userName };
1939
1986
  if (properties["Path"]) createParams.Path = properties["Path"];
1940
1987
  if (properties["Tags"] !== void 0 && properties["Tags"] !== null) createParams.Tags = desiredTags;
1941
- const response = await (await this.createClient.get()).send(new CreateUserCommand(createParams));
1988
+ const createClient = await this.createClient.get();
1989
+ let user;
1990
+ let adopted = false;
1991
+ try {
1992
+ user = (await createClient.send(new CreateUserCommand(createParams))).User;
1993
+ } catch (createError) {
1994
+ user = await iamEntityLeftByThisCreate({
1995
+ logicalId,
1996
+ resourceType,
1997
+ noun: "user",
1998
+ displayName: userName,
1999
+ createError,
2000
+ namesThisEntity: (reported) => reported === userName,
2001
+ read: async () => (await this.iamClient.send(new GetUserCommand({ UserName: userName }))).User,
2002
+ identityOf: (live) => userOrGroupIdentityToken(live?.UserId),
2003
+ log
2004
+ });
2005
+ if (user === void 0) throw createError;
2006
+ adopted = true;
2007
+ }
1942
2008
  leftBehind = true;
1943
- createdUserIdentity = userOrGroupIdentityToken(response.User?.UserId);
1944
- reportCreatedResource(logicalId, resourceType, userName, createdUserIdentity);
2009
+ createdUserIdentity = userOrGroupIdentityToken(user?.UserId);
2010
+ if (!adopted) reportCreatedResource(logicalId, resourceType, userName, createdUserIdentity);
1945
2011
  try {
1946
2012
  const permissionsBoundary = properties["PermissionsBoundary"];
1947
2013
  if (permissionsBoundary) {
@@ -1953,12 +2019,24 @@ var IAMUserGroupProvider = class {
1953
2019
  }
1954
2020
  const loginProfile = properties["LoginProfile"];
1955
2021
  if (loginProfile) {
1956
- await this.iamClient.send(new CreateLoginProfileCommand({
2022
+ const profile = {
1957
2023
  UserName: userName,
1958
2024
  Password: loginProfile.Password,
1959
2025
  PasswordResetRequired: loginProfile.PasswordResetRequired ?? false
1960
- }));
1961
- log.debug(`Created login profile for user ${v(userName)}`);
2026
+ };
2027
+ try {
2028
+ await this.iamClient.send(new CreateLoginProfileCommand(profile));
2029
+ log.debug(`Created login profile for user ${v(userName)}`);
2030
+ } catch (profileError) {
2031
+ if (!adopted || !isEntityAlreadyExists(profileError)) throw profileError;
2032
+ try {
2033
+ await this.iamClient.send(new UpdateLoginProfileCommand(profile));
2034
+ } catch (updateError) {
2035
+ if (updateError?.name !== PROFILE_SETTLING_ERROR) throw updateError;
2036
+ throw new Error(LOGIN_PROFILE_SETTLING_MESSAGE, { cause: updateError });
2037
+ }
2038
+ log.debug(`Updated login profile for user ${v(userName)}`);
2039
+ }
1962
2040
  }
1963
2041
  const managedPolicyArns = properties["ManagedPolicyArns"];
1964
2042
  if (managedPolicyArns && Array.isArray(managedPolicyArns)) for (const policyArn of managedPolicyArns) {
@@ -1987,7 +2065,7 @@ var IAMUserGroupProvider = class {
1987
2065
  log.debug(`Added inline policy ${v(policy.PolicyName)} to user ${v(userName)}`);
1988
2066
  }
1989
2067
  } catch (innerError) {
1990
- try {
2068
+ if (!adopted) try {
1991
2069
  await this.removeUserFromAllGroups(userName, log);
1992
2070
  await this.detachAllUserPolicies(userName, log);
1993
2071
  await this.deleteAllUserInlinePolicies(userName, log);
@@ -2015,7 +2093,7 @@ var IAMUserGroupProvider = class {
2015
2093
  log.debug(`Successfully created IAM user ${logicalId}: ${v(userName)}`);
2016
2094
  return {
2017
2095
  physicalId: userName,
2018
- attributes: { Arn: response.User?.Arn }
2096
+ attributes: { Arn: user?.Arn }
2019
2097
  };
2020
2098
  } catch (error) {
2021
2099
  const cause = error instanceof Error ? error : void 0;
@@ -2342,10 +2420,32 @@ var IAMUserGroupProvider = class {
2342
2420
  try {
2343
2421
  const createParams = { GroupName: groupName };
2344
2422
  if (properties["Path"]) createParams.Path = properties["Path"];
2345
- const response = await (await this.createClient.get()).send(new CreateGroupCommand(createParams));
2423
+ const createClient = await this.createClient.get();
2424
+ let group;
2425
+ let adopted = false;
2426
+ try {
2427
+ group = (await createClient.send(new CreateGroupCommand(createParams))).Group;
2428
+ } catch (createError) {
2429
+ group = await iamEntityLeftByThisCreate({
2430
+ logicalId,
2431
+ resourceType,
2432
+ noun: "group",
2433
+ displayName: groupName,
2434
+ createError,
2435
+ namesThisEntity: (reported) => reported === groupName,
2436
+ read: async () => (await this.iamClient.send(new GetGroupCommand({
2437
+ GroupName: groupName,
2438
+ MaxItems: 1
2439
+ }))).Group,
2440
+ identityOf: (live) => userOrGroupIdentityToken(live?.GroupId),
2441
+ log
2442
+ });
2443
+ if (group === void 0) throw createError;
2444
+ adopted = true;
2445
+ }
2346
2446
  leftBehind = true;
2347
- createdGroupIdentity = userOrGroupIdentityToken(response.Group?.GroupId);
2348
- reportCreatedResource(logicalId, resourceType, groupName, createdGroupIdentity);
2447
+ createdGroupIdentity = userOrGroupIdentityToken(group?.GroupId);
2448
+ if (!adopted) reportCreatedResource(logicalId, resourceType, groupName, createdGroupIdentity);
2349
2449
  try {
2350
2450
  const managedPolicyArns = properties["ManagedPolicyArns"];
2351
2451
  if (managedPolicyArns && Array.isArray(managedPolicyArns)) for (const policyArn of managedPolicyArns) {
@@ -2366,7 +2466,7 @@ var IAMUserGroupProvider = class {
2366
2466
  log.debug(`Added inline policy ${v(policy.PolicyName)} to group ${v(groupName)}`);
2367
2467
  }
2368
2468
  } catch (innerError) {
2369
- try {
2469
+ if (!adopted) try {
2370
2470
  await this.detachAllGroupPolicies(groupName, log);
2371
2471
  await this.deleteAllGroupInlinePolicies(groupName, log);
2372
2472
  await this.iamClient.send(new DeleteGroupCommand({ GroupName: groupName }));
@@ -2383,7 +2483,7 @@ var IAMUserGroupProvider = class {
2383
2483
  log.debug(`Successfully created IAM group ${logicalId}: ${v(groupName)}`);
2384
2484
  return {
2385
2485
  physicalId: groupName,
2386
- attributes: { Arn: response.Group?.Arn }
2486
+ attributes: { Arn: group?.Arn }
2387
2487
  };
2388
2488
  } catch (error) {
2389
2489
  const cause = error instanceof Error ? error : void 0;
@@ -32854,6 +32954,10 @@ const VPCS_KEPT_ON_REMOVAL_NOTE = "A private hosted zone stays private and keeps
32854
32954
  function declaresNoVpcs(vpcs) {
32855
32955
  return vpcs == null || Array.isArray(vpcs) && vpcs.length === 0;
32856
32956
  }
32957
+ function declaredVpcIds(vpcs) {
32958
+ if (!Array.isArray(vpcs)) return [];
32959
+ return vpcs.map((vpc) => vpc?.["VPCId"]);
32960
+ }
32857
32961
  function sentence$1(text) {
32858
32962
  return text.endsWith(".") ? text : `${text}.`;
32859
32963
  }
@@ -33020,7 +33124,7 @@ var Route53Provider = class {
33020
33124
  }));
33021
33125
  }
33022
33126
  await this.applyHostedZoneTags(zoneId, properties, logicalId, void 0, mask);
33023
- await this.applyQueryLoggingConfig(zoneId, properties, logicalId);
33127
+ await this.applyQueryLoggingConfig(zoneId, properties, logicalId, void 0, mask);
33024
33128
  if (declaresAcceleratedRecovery(properties)) {
33025
33129
  try {
33026
33130
  await this.getClient().send(new UpdateHostedZoneFeaturesCommand({
@@ -33120,8 +33224,8 @@ var Route53Provider = class {
33120
33224
  Comment: comment
33121
33225
  }));
33122
33226
  await this.applyHostedZoneTags(physicalId, properties, logicalId, previousProperties, mask);
33123
- await this.applyQueryLoggingConfig(physicalId, properties, logicalId, previousProperties);
33124
- await this.syncVPCAssociations(physicalId, properties, logicalId);
33227
+ await this.applyQueryLoggingConfig(physicalId, properties, logicalId, previousProperties, mask, context?.markUnsettled);
33228
+ await this.syncVPCAssociations(physicalId, properties, logicalId, previousProperties, mask, context);
33125
33229
  const prevEnabled = declaresAcceleratedRecovery(previousProperties, true);
33126
33230
  const nextEnabled = declaresAcceleratedRecovery(properties, context?.desiredFromAwsReadback === true);
33127
33231
  if (prevEnabled !== nextEnabled) {
@@ -33133,7 +33237,7 @@ var Route53Provider = class {
33133
33237
  }
33134
33238
  const nameServers = (await this.getClient().send(new GetHostedZoneCommand({ Id: physicalId }))).DelegationSet?.NameServers ?? [];
33135
33239
  this.logger.debug(`Successfully updated hosted zone ${logicalId}`);
33136
- if (context?.desiredFromAwsReadback !== true && declaresNoVpcs(properties["VPCs"]) && Array.isArray(previousProperties["VPCs"]) && previousProperties["VPCs"].length > 0) this.logger.warn(context?.replayingState ? safeMsg`${logicalId} (AWS::Route53::HostedZone): VPCs is absent from the state being restored, so the rollback leaves the zone's VPC associations in place. ${VPCS_KEPT_ON_REMOVAL_NOTE}` : safeMsg`${logicalId} (AWS::Route53::HostedZone): VPCs was removed from the template, and the zone keeps its current VPC associations, as CloudFormation leaves them. ${VPCS_KEPT_ON_REMOVAL_NOTE}`);
33240
+ if (context?.desiredFromAwsReadback !== true && declaresNoVpcs(properties["VPCs"]) && (Array.isArray(previousProperties["VPCs"]) && previousProperties["VPCs"].length > 0 || context?.unsettledProperties?.has("VPCs") === true)) this.logger.warn(context?.replayingState ? safeMsg`${logicalId} (AWS::Route53::HostedZone): VPCs is absent from the state being restored, so the rollback leaves the zone's VPC associations in place. ${VPCS_KEPT_ON_REMOVAL_NOTE}` : safeMsg`${logicalId} (AWS::Route53::HostedZone): VPCs was removed from the template, and the zone keeps its current VPC associations, as CloudFormation leaves them. ${VPCS_KEPT_ON_REMOVAL_NOTE}`);
33137
33241
  return {
33138
33242
  physicalId,
33139
33243
  wasReplaced: false,
@@ -33539,7 +33643,7 @@ var Route53Provider = class {
33539
33643
  return typeof entry.Key === "string" && typeof entry.Value === "string";
33540
33644
  });
33541
33645
  }
33542
- async applyQueryLoggingConfig(zoneId, properties, logicalId, previousProperties) {
33646
+ async applyQueryLoggingConfig(zoneId, properties, logicalId, previousProperties, mask, markUnsettled) {
33543
33647
  const cloudWatchLogsLogGroupArn = this.readQueryLogGroupArn(properties);
33544
33648
  const desiredBlock = properties["QueryLoggingConfig"];
33545
33649
  const desiredBlockIsObject = typeof desiredBlock === "object" && desiredBlock !== null && !Array.isArray(desiredBlock);
@@ -33551,13 +33655,16 @@ var Route53Provider = class {
33551
33655
  if (cloudWatchLogsLogGroupArn === void 0) {
33552
33656
  if (previousProperties !== void 0 && this.readQueryLogGroupArn(previousProperties)) {
33553
33657
  this.logger.debug(`QueryLoggingConfig removed from template for hosted zone ${logicalId}; deleting the live config`);
33658
+ markUnsettled?.("QueryLoggingConfig");
33554
33659
  await this.deleteQueryLoggingConfigForZone(zoneId, logicalId);
33555
33660
  const remaining = await this.listQueryLoggingConfigIds(zoneId);
33556
33661
  if (remaining.length > 0) throw new ProvisioningError(`QueryLoggingConfig was removed from the template for hosted zone ${logicalId} but the live config (${remaining.join(", ")}) is still present. The removal will NOT be retried on the next deploy (state no longer records the property), so it is reported instead of ignored.`, "AWS::Route53::HostedZone", logicalId, zoneId);
33557
33662
  }
33558
33663
  return;
33559
33664
  }
33665
+ if (previousProperties !== void 0 && this.readQueryLogGroupArn(previousProperties) === cloudWatchLogsLogGroupArn) return;
33560
33666
  try {
33667
+ markUnsettled?.("QueryLoggingConfig");
33561
33668
  await this.deleteQueryLoggingConfigForZone(zoneId, logicalId);
33562
33669
  await this.getClient().send(new CreateQueryLoggingConfigCommand({
33563
33670
  HostedZoneId: zoneId,
@@ -33565,11 +33672,12 @@ var Route53Provider = class {
33565
33672
  }));
33566
33673
  this.logger.debug(`Applied query logging config to hosted zone ${logicalId}`);
33567
33674
  } catch (error) {
33568
- if (error instanceof Error && error.name === "QueryLoggingConfigAlreadyExists") {
33675
+ if (previousProperties === void 0 && error instanceof Error && error.name === "QueryLoggingConfigAlreadyExists") {
33569
33676
  this.logger.debug(`Query logging config already exists for hosted zone ${logicalId}`);
33570
33677
  return;
33571
33678
  }
33572
- this.logger.warn(`Failed to apply query logging config to hosted zone ${logicalId}: ${describeAwsFailure(error).detail}`);
33679
+ const cause = error instanceof Error ? error : void 0;
33680
+ throw this.wrapCaughtError(mask, error, (text) => new ProvisioningError(`Failed to apply query logging config to hosted zone ${logicalId}: ${text}`, "AWS::Route53::HostedZone", logicalId, zoneId, cause));
33573
33681
  }
33574
33682
  }
33575
33683
  readQueryLogGroupArn(properties) {
@@ -33605,7 +33713,7 @@ var Route53Provider = class {
33605
33713
  this.logger.warn(`Failed to delete query logging config for hosted zone ${logicalId}: ${describeAwsFailure(error).detail}`);
33606
33714
  }
33607
33715
  }
33608
- async syncVPCAssociations(zoneId, properties, logicalId) {
33716
+ async syncVPCAssociations(zoneId, properties, logicalId, previousProperties, mask, marks) {
33609
33717
  const desiredVpcs = properties["VPCs"];
33610
33718
  if (!desiredVpcs || desiredVpcs.length === 0) return;
33611
33719
  try {
@@ -33616,6 +33724,7 @@ var Route53Provider = class {
33616
33724
  const vpcId = vpc["VPCId"];
33617
33725
  if (!currentVpcIds.has(vpcId)) {
33618
33726
  this.logger.debug(`Associating VPC ${vpcId} with hosted zone ${zoneId}`);
33727
+ marks?.markUnsettled?.("VPCs");
33619
33728
  await this.getClient().send(new AssociateVPCWithHostedZoneCommand({
33620
33729
  HostedZoneId: zoneId,
33621
33730
  VPC: {
@@ -33623,14 +33732,14 @@ var Route53Provider = class {
33623
33732
  VPCRegion: vpc["VPCRegion"]
33624
33733
  }
33625
33734
  }));
33735
+ marks?.markAttempted?.("VPCs", [vpcId]);
33736
+ currentVpcIds.add(vpcId);
33626
33737
  }
33627
33738
  }
33628
- for (const vpc of currentVpcs) if (vpc.VPCId && !desiredVpcIds.has(vpc.VPCId)) {
33629
- if (currentVpcs.length <= 1) {
33630
- this.logger.warn(`Cannot disassociate last VPC ${vpc.VPCId} from hosted zone ${logicalId}`);
33631
- continue;
33632
- }
33739
+ const previousVpcIds = new Set(declaredVpcIds(previousProperties["VPCs"]));
33740
+ for (const vpc of currentVpcs) if (vpc.VPCId && previousVpcIds.has(vpc.VPCId) && !desiredVpcIds.has(vpc.VPCId)) {
33633
33741
  this.logger.debug(`Disassociating VPC ${vpc.VPCId} from hosted zone ${zoneId}`);
33742
+ marks?.markUnsettled?.("VPCs");
33634
33743
  await this.getClient().send(new DisassociateVPCFromHostedZoneCommand({
33635
33744
  HostedZoneId: zoneId,
33636
33745
  VPC: {
@@ -33640,7 +33749,8 @@ var Route53Provider = class {
33640
33749
  }));
33641
33750
  }
33642
33751
  } catch (error) {
33643
- this.logger.warn(`Failed to sync VPC associations for hosted zone ${logicalId}: ${describeAwsFailure(error).detail}`);
33752
+ const cause = error instanceof Error ? error : void 0;
33753
+ throw this.wrapCaughtError(mask, error, (text) => new ProvisioningError(`Failed to sync VPC associations for hosted zone ${logicalId}: ${text}`, "AWS::Route53::HostedZone", logicalId, zoneId, cause));
33644
33754
  }
33645
33755
  }
33646
33756
  async resolveHostedZoneId(properties, logicalId, resourceType, physicalId, options) {
@@ -33718,7 +33828,27 @@ var Route53Provider = class {
33718
33828
  default: return;
33719
33829
  }
33720
33830
  }
33721
- async readHostedZone(physicalId, properties) {
33831
+ async readUnsettled(physicalId, logicalId, resourceType, names, recordedProperties, desiredProperties, attemptedItems) {
33832
+ if (resourceType !== "AWS::Route53::HostedZone") return this.readCurrentState(physicalId, logicalId, resourceType, recordedProperties);
33833
+ const live = await this.readHostedZone(physicalId, recordedProperties, names.has("QueryLoggingConfig"));
33834
+ if (live === void 0 || live === RESOURCE_NOT_FOUND) return live;
33835
+ if (!names.has("VPCs") || !Array.isArray(live["VPCs"])) return live;
33836
+ const { VPCs: liveVpcs, ...rest } = live;
33837
+ if (declaresNoVpcs(desiredProperties?.["VPCs"])) return rest;
33838
+ const named = /* @__PURE__ */ new Set([
33839
+ ...declaredVpcIds(recordedProperties?.["VPCs"]),
33840
+ ...declaredVpcIds(desiredProperties?.["VPCs"]),
33841
+ ...[...attemptedItems?.get("VPCs") ?? []].filter(isUsableAttemptedName)
33842
+ ]);
33843
+ return {
33844
+ ...rest,
33845
+ VPCs: liveVpcs.filter((vpc) => named.has(vpc["VPCId"]))
33846
+ };
33847
+ }
33848
+ getDriftUnorderedPaths(resourceType) {
33849
+ return resourceType === "AWS::Route53::HostedZone" ? ["VPCs"] : [];
33850
+ }
33851
+ async readHostedZone(physicalId, properties, throwOnFailedQueryLoggingRead = false) {
33722
33852
  let resp;
33723
33853
  try {
33724
33854
  resp = await this.getClient().send(new GetHostedZoneCommand({ Id: physicalId }));
@@ -33762,6 +33892,7 @@ var Route53Provider = class {
33762
33892
  else result["QueryLoggingConfig"] = {};
33763
33893
  } catch (err) {
33764
33894
  this.logger.debug(`Route53 ListQueryLoggingConfigs(${idTail}) failed: ${describeAwsFailure(err).detail}`);
33895
+ if (throwOnFailedQueryLoggingRead) throw err;
33765
33896
  result["QueryLoggingConfig"] = {};
33766
33897
  }
33767
33898
  return result;
@@ -54914,4 +55045,4 @@ var ACMCertificateProvider = class {
54914
55045
  };
54915
55046
 
54916
55047
  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, LambdaNetworkConnectorProvider, LambdaPermissionProvider, LambdaUrlProvider, LambdaWebFunctionEndpointProvider, LambdaWebFunctionRevisionProvider, 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 };
54917
- //# sourceMappingURL=provider-classes-CbiecOol.js.map
55048
+ //# sourceMappingURL=provider-classes-DOr3JVGp.js.map