@cdkd/cli 0.352.5 → 0.352.6

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 (55) hide show
  1. package/dist/{ambient-client-defaults-COOu75wQ.js → ambient-client-defaults-D6q-PsWI.js} +4 -3
  2. package/dist/ambient-client-defaults-D6q-PsWI.js.map +1 -0
  3. package/dist/{asg-provider-BlvhI85g.js → asg-provider-DVPUxvJ4.js} +6 -6
  4. package/dist/{asg-provider-BlvhI85g.js.map → asg-provider-DVPUxvJ4.js.map} +1 -1
  5. package/dist/cli.js +3 -3
  6. package/dist/{custom-resource-runtime-Cvr-QlNR.js → custom-resource-runtime-DzWJeo88.js} +6 -6
  7. package/dist/{custom-resource-runtime-Cvr-QlNR.js.map → custom-resource-runtime-DzWJeo88.js.map} +1 -1
  8. package/dist/{db-associated-roles-CObvQJMj.js → db-associated-roles-DusVN-1E.js} +2 -2
  9. package/dist/{db-associated-roles-CObvQJMj.js.map → db-associated-roles-DusVN-1E.js.map} +1 -1
  10. package/dist/{delete-started-BpZMtyEd.js → delete-started-CU2YbrGM.js} +4 -4
  11. package/dist/{delete-started-BpZMtyEd.js.map → delete-started-CU2YbrGM.js.map} +1 -1
  12. package/dist/{deploy-engine-C8rwXBlr.js → deploy-engine-AmswiQ33.js} +94 -45
  13. package/dist/deploy-engine-AmswiQ33.js.map +1 -0
  14. package/dist/{diff-calculator-DcVlH1Go.js → diff-calculator-BY7C4zjP.js} +12 -12
  15. package/dist/{diff-calculator-DcVlH1Go.js.map → diff-calculator-BY7C4zjP.js.map} +1 -1
  16. package/dist/{ec2-termination-protection-BKKt6PdW.js → ec2-termination-protection-CbM5cRC2.js} +6 -6
  17. package/dist/{ec2-termination-protection-BKKt6PdW.js.map → ec2-termination-protection-CbM5cRC2.js.map} +1 -1
  18. package/dist/{ecr-uri-CIXafW4r.js → ecr-uri-xJ_dQFRd.js} +2 -2
  19. package/dist/{ecr-uri-CIXafW4r.js.map → ecr-uri-xJ_dQFRd.js.map} +1 -1
  20. package/dist/{expected-bucket-owner-ByWXInN8.js → expected-bucket-owner-DUOll_QH.js} +2 -2
  21. package/dist/{expected-bucket-owner-ByWXInN8.js.map → expected-bucket-owner-DUOll_QH.js.map} +1 -1
  22. package/dist/{iam-role-provider-DxEugJPc.js → iam-role-provider-BxoddeVw.js} +8 -8
  23. package/dist/{iam-role-provider-DxEugJPc.js.map → iam-role-provider-BxoddeVw.js.map} +1 -1
  24. package/dist/{image-plan-BN0nYgoQ.js → image-plan-l1rq5oTc.js} +8 -8
  25. package/dist/{image-plan-BN0nYgoQ.js.map → image-plan-l1rq5oTc.js.map} +1 -1
  26. package/dist/index.d.ts +1 -1
  27. package/dist/index.d.ts.map +1 -1
  28. package/dist/index.js +5 -5
  29. package/dist/{logger-D8OJkAgE.js → logger-3jnrgVV6.js} +2 -2
  30. package/dist/{logger-D8OJkAgE.js.map → logger-3jnrgVV6.js.map} +1 -1
  31. package/dist/{neptune-provider-B4x2miBY.js → neptune-provider-CoZPYMUA.js} +7 -7
  32. package/dist/{neptune-provider-B4x2miBY.js.map → neptune-provider-CoZPYMUA.js.map} +1 -1
  33. package/dist/{program-C8K2yI5F.js → program-BK0D4lXw.js} +100 -20
  34. package/dist/program-BK0D4lXw.js.map +1 -0
  35. package/dist/{provider-classes-CTUyynuJ.js → provider-classes-DHx4MeZb.js} +190 -151
  36. package/dist/provider-classes-DHx4MeZb.js.map +1 -0
  37. package/dist/{rds-provider-WiRimLjl.js → rds-provider-BRqq-zMM.js} +10 -10
  38. package/dist/{rds-provider-WiRimLjl.js.map → rds-provider-BRqq-zMM.js.map} +1 -1
  39. package/dist/{read-replica-BE_IEKzf.js → read-replica-DdJQcdo_.js} +3 -3
  40. package/dist/{read-replica-BE_IEKzf.js.map → read-replica-DdJQcdo_.js.map} +1 -1
  41. package/dist/{replacement-rules-CF-_BKrA.js → replacement-rules-Dc0xW46P.js} +3 -3
  42. package/dist/{replacement-rules-CF-_BKrA.js.map → replacement-rules-Dc0xW46P.js.map} +1 -1
  43. package/dist/{resource-deadline-DAdDceOc.js → resource-deadline-CbwFSZXC.js} +4 -4
  44. package/dist/{resource-deadline-DAdDceOc.js.map → resource-deadline-CbwFSZXC.js.map} +1 -1
  45. package/dist/{run-cli-580oPJW5.js → run-cli-BcmTwXmJ.js} +2 -2
  46. package/dist/{run-cli-580oPJW5.js.map → run-cli-BcmTwXmJ.js.map} +1 -1
  47. package/dist/{update-removal-CYrJHBvS.js → update-removal-CIWY-E-v.js} +4 -4
  48. package/dist/{update-removal-CYrJHBvS.js.map → update-removal-CIWY-E-v.js.map} +1 -1
  49. package/dist/{version-Daw3iRRc.js → version-CqgQyu4Z.js} +2 -2
  50. package/dist/{version-Daw3iRRc.js.map → version-CqgQyu4Z.js.map} +1 -1
  51. package/package.json +7 -7
  52. package/dist/ambient-client-defaults-COOu75wQ.js.map +0 -1
  53. package/dist/deploy-engine-C8rwXBlr.js.map +0 -1
  54. package/dist/program-C8K2yI5F.js.map +0 -1
  55. package/dist/provider-classes-CTUyynuJ.js.map +0 -1
@@ -1,20 +1,20 @@
1
- import { a as IamCreateClientCache, i as isEntityAlreadyExists, n as collectInlinePolicyNamesManagedBySiblings, r as iamEntityLeftByThisCreate, t as IAMRoleProvider } from "./iam-role-provider-DxEugJPc.js";
2
- import { A as configStringRefusal, B as generateResourceName, D as coerceCfnInteger, E as coerceCfnBoolean, F as requireConfigString, J as getCurrentStackName, M as replayWarn, N as requireConfigArray, O as configBooleanRefusal, P as requireConfigObject, U as recordedGeneratedNameKept, V as generateResourceNameWithFallback, Y as isBeforeStateRead, c as VERBOSE_POINTER, d as describeAwsStatusReason, f as isAwsAuthoredFailure, g as verbosePointerTail, h as verbosePointerSentence, j as readConfigString, k as configIntegerRefusal, n as getLogger, p as safeStringify, q as getCurrentStackInstanceId, u as describeAwsFailure, w as generatedNameFor } from "./logger-D8OJkAgE.js";
1
+ import { a as IamCreateClientCache, i as isEntityAlreadyExists, n as collectInlinePolicyNamesManagedBySiblings, r as iamEntityLeftByThisCreate, t as IAMRoleProvider } from "./iam-role-provider-BxoddeVw.js";
2
+ import { A as configStringRefusal, B as generateResourceName, D as coerceCfnInteger, E as coerceCfnBoolean, F as requireConfigString, J as getCurrentStackName, M as replayWarn, N as requireConfigArray, O as configBooleanRefusal, P as requireConfigObject, U as recordedGeneratedNameKept, V as generateResourceNameWithFallback, Y as isBeforeStateRead, c as VERBOSE_POINTER, d as describeAwsStatusReason, f as isAwsAuthoredFailure, g as verbosePointerTail, h as verbosePointerSentence, j as readConfigString, k as configIntegerRefusal, n as getLogger, p as safeStringify, q as getCurrentStackInstanceId, u as describeAwsFailure, w as generatedNameFor } from "./logger-3jnrgVV6.js";
3
3
  import { d as withApiGatewayPacing, l as s3ClientDefaults, r as getAwsClients } from "./aws-clients-DOkPjjAW.js";
4
- import { D as markReplayMayCollide, E as markNameCollision, F as isAmbiguousOutcomeError, G as markRedactedCause, H as isMarkedNonRetryable, I as isExplicitDenyError, K as wrapMaskedAwsError, M as explicitDenyPolicyKind, O as relayedNameCollision, Q as AccountIdUnavailableError, R as isRetryableTransientError, U as isThrottlingError, V as THROTTLING_ERROR_NAMES, W as markNonRetryable, _ as ResourceUpdateNotSupportedError, at as ProvisioningError, et as CdkdError, i as credentialFingerprint, n as ambientCredentialConfig, r as clientDefaultsFor, t as ambientClientDefaults, z as isTransientServerError } from "./ambient-client-defaults-COOu75wQ.js";
5
- import { $ as userPoolProtectionSite, A as replayedSendWindow, At as packCompositeId, B as refusalTypeShown, C as AmbiguousCreateLatch, Ct as isInterruptedWaitError, D as createAttemptKey, Dt as compositeIdSeparatorRefusal, E as ambiguousAttemptLead, Et as compositeIdFormatMessage, F as isPlainImportJson, Ft as createMaskedRetryLogger, H as resolveExplicitPhysicalId, Ht as clearCreatedBeforeFailure, I as isPlainImportValue, It as isSecretDerivedValue, J as deleteWithProtectionCompensation, Jt as markAuxiliaryFailure, K as markNotGone, Kt as isAuxiliaryFailure, L as isQuotableImportValue, Lt as maskDeep, M as withoutServerErrorRetries, Mt as segmentAfterAnchor, N as VALUE_NOT_SHOWN, Nt as stateOrphanRecordRemedy, O as isInsideWindow, Ot as compositeIdSkipResult, P as importRemedyCommand, Pt as createMaskedLogSinks, R as normalizeAwsTagsToCfn, Rt as maskerOrIdentity, S as AMBIGUOUS_LATCH_TTL_MS, T as RecentIdSet, Tt as canonicalizeRoute53QueryName, U as RESOURCE_NOT_FOUND, V as remedyLogicalId, W as assertRegionMatch, X as observeThenDisableProtection, Xt as markSupersedesEarlierCreate, Y as logGroupProtectionSite, Yt as markCreatedBeforeFailure, Z as rdsFamilyProtectionSite, _ as onlySecretDerived, _t as pasteableAwsCommand, a as withRemovalDefaults, b as recordedPrincipalsRepair, ct as protectionFlipKey, dt as ElapsedBudgetRegistry, et as PROTECTION_FLIP_RETRY_WAIT_MS, f as retractCreatedResource, g as holdsSecretDerivedEntry, gt as isAwsCliLiteral, h as SECRET_DERIVED_READ_LIVE, hn as withPasteableAwsProfile, ht as WITHHELD_AWS_COMMAND, i as removedTemplateKeys, it as isTerminalDbWaitStatus, j as setBounded, k as replayFollowedAmbiguousAttempt, kt as logicalIdShown, ln as injectiveKey, mt as UNNAMEABLE_ID_CLAUSE, ot as ProtectionFlipRegistry, rt as isProceedDbStatus, st as isTerminalDeleteFailure, t as clearOnUpdateRemoval, tt as deleteAfterProtectionFlipWithFinalSnapshot, u as reportCreatedResource, un as injectiveKeyPrefix, ut as ElapsedBudget, v as readPrincipalLists, vt as protectedReplacementAdvice, w as CREATION_DATE_SKEW_MARGIN_MS, wt as startInterruptWatch, yt as renderDisableCommand, z as quotedRemedyLogicalId, zt as withDerivedNameMasks } from "./update-removal-CYrJHBvS.js";
6
- import { A as displayStackName, N as plainIdentOr, O as displayIdent, P as safeMsg, S as SECRET_REF_MAX_CODE_POINTS, T as asIsMessage, _ as shellQuote, c as deployReplaceCommand, d as pasteableCommand, j as isPasteableIdent, k as displaySafe, l as hasClauseBreak, m as proseQuoted, o as cdkdRemedy, p as plainOrDescribed, s as commandHole, u as isInertUnquoted, v as withheldTargetClause } from "./version-Daw3iRRc.js";
7
- import { gt as slowCcOperationTimeoutMs, n as isRefusedByName, r as markDeleteStarted } from "./delete-started-BpZMtyEd.js";
8
- import { a as resolveSecretDerivedPrincipals, i as isResolvableSecretPrincipalList, n as runDestroyForStack, o as canonicalizeIpProtocolValue, r as holdsUnprovenSecretPrincipalToken, t as canonicalizeIpv4Cidr } from "./program-C8K2yI5F.js";
9
- import { $ as isTtlAlreadyDisabled, $a as APPSYNC_APIKEY_ARN_RESOURCE_PATH, $t as lookupEachName, Ar as REDACTED_DELETE_ADDRESS_SKIP_REASON, At as maskedLogger, Bo as outputReferenceProvenanceOf, C as isAbsoluteAssetPath, Co as s3BucketDomainName, Cs as passedParameterClassesOf, Ct as deleteBudgetKey, Dt as INDEX_SETTLE_POLL_INTERVAL_MS, Eo as s3BucketWebsiteUrl, Et as DELETE_INDEX_WAIT_PROCEED_NOTE, Fa as waitForLambdaFunctionActive, Ft as hasCdkAutoDeleteTag, G as declaredStreamTagsMember, Ga as withIndeterminateGuard, Gc as withoutSdkUnwiredProperties, H as STREAM_POLICY_KEY, Hc as findSdkUnwiredProperties, Io as parseWebACLArn, It as isTruthyCfnBoolean, J as streamDeclaresPolicy, Jt as getPriorAttempts, K as planStreamMemberOps, Ki as secretNamedAttributeNamesOf, Kl as decodeListingKey, Ko as getAccountInfo, La as waitForGoneAfterDelete, Mr as redactedDeleteAddressFields, Mt as waitForIndexesSettled, Nc as accountArgs, Nr as redactedDeleteAddressSkip, Nt as ECR_AUTO_DELETE_IMAGES_TAG, Oc as refuseMalformedResourcesForDestroy, Ot as TABLE_INDEX_NOUN, Pc as withheldAccountClause, Pt as S3_AUTO_DELETE_OBJECTS_TAG, Q as streamTagsMatchDeclared, Qa as isSettledInstanceState, Qt as isAccessDeniedError, Ra as resolvedResourceTimeoutMs, S as findNestedTemplateTreeDefect, So as s3BucketArn, St as compensateRemovedDeletionProtection, T as renderNestedTemplateTreeDefect, Ta as getCurrentResourceSecrets, To as s3BucketRegionalDomainName, Tt as resolveDynamoDbDeleteBudgetMs, U as STREAM_TAGS_KEY, V as DynamoDBGlobalTableProvider, W as declaredStreamPolicyMember, Wa as deleteSkipReason, Wr as getCurrentProducerRegions, X as streamMemberRefusals, Y as streamDeclaresTags, Yt as markRefusedBeforeApplying, Z as streamPolicyMatchesDeclared, Zt as chunks, _t as stripIndexContributorInsights, at as readbackVectorIndexes, au as renderAssemblyPathEscape, bt as DYNAMODB_DELETE_POLL_COST_MS, ca as collectManagedPolicyArnsAttachedBySiblings, ct as vectorIndexesShapeDetail, da as withoutSiblingAttachedArns, dr as earliestDefined, dt as indexDeclaresContributorInsights, en as withApiLimit, eo as maskedSecretSegment, et as isTtlRateLimited, fa as withoutSiblingOwned, fl as stringifyValue, fs as WARM_THROUGHPUT_MEMBERS, ft as planContributorInsightsOp, gi as getStackRecords, gs as toFiniteNumber, gt as reverseMapTableContributorInsights, hn as withNestedStackContext, hr as acquireIdempotencyToken, hs as toCfnInteger, ht as reverseMapIndexContributorInsights, it as planVectorIndexUpdates, jr as isRedactedRecordedValue, jt as relayedIndexBusyDelete, kt as deleteTableWithIndexBusyRetry, la as collectPrincipalsAttachingPolicy, lt as CONTRIBUTOR_INSIGHTS_KEY, mi as awaitInFlightSibling, mn as getCurrentNestedStackContext, ms as isWarmThroughputDecrease, mt as readContributorInsightsSpec, nt as readTtlSpec, nu as describeFileReadFailure, ot as vectorIndexesForCreate, ou as resolveAssemblyPath, pr as reserveStackCreateToken, ps as coerceWarmThroughput$1, pt as planIndexContributorInsightsOps, q as reverseMapStreamPolicy, rt as sendTtlWaitingOutRateLimit, ru as displayAssemblyPath, sa as collectGroupsAddedBySiblings, sn as getNestedRevertRun, st as vectorIndexesSettled, t as DeployEngine, tt as planTimeToLive, un as revertNestedChildFromJournal, ut as contributorInsightsRefusals, vc as refuseMalformedNestedChildOutputs, vi as replacedDeleteFailureVerdict, vt as DYNAMODB_DELETE_DEADLINE_MARGIN_MS, w as listNestedTemplateRows, wo as s3BucketDualStackDomainName, wt as resolveDynamoDbDeleteBudgetClock, xl as rewriteTemplateAssetReferences, xt as beginDeleteWait, yt as DYNAMODB_DELETE_MIN_RESOURCE_TIMEOUT_MS } from "./deploy-engine-C8rwXBlr.js";
10
- import { _ as isModifyNotAvailableRefusal, b as stringifyIfAssigned, c as refuseRestoreFromItself, d as DBPROXY_TAG_OPTIONS, f as planTagDiff, g as tagPlanWarning, h as tagMapAsList, m as refuseMalformedDesiredTags, n as enclosingDeadlineRemainingMs, p as readTagList, t as enclosingDeadlineExpired, u as DBPROXY_TAGS_WHAT, v as modifyDbInstanceWhenAvailable, x as isUsableAttemptedName, y as definedAttributes } from "./resource-deadline-DAdDceOc.js";
11
- import { O as timePhase, a as reDisableInstanceApiTermination, c as unchangedBehindSecretReference, i as observeThenDisableInstanceApiTermination, n as ec2InstanceProtectionSite, o as reEnableInstanceApiTermination, r as isTerminationProtectionPropagationError, s as onlySecretReferencesDiffer, x as withRetry } from "./ec2-termination-protection-BKKt6PdW.js";
4
+ import { D as markReplayMayCollide, E as markNameCollision, F as isAmbiguousOutcomeError, G as markRedactedCause, H as isMarkedNonRetryable, I as isExplicitDenyError, K as wrapMaskedAwsError, M as explicitDenyPolicyKind, O as relayedNameCollision, Q as AccountIdUnavailableError, R as isRetryableTransientError, U as isThrottlingError, V as THROTTLING_ERROR_NAMES, W as markNonRetryable, _ as ResourceUpdateNotSupportedError, at as ProvisioningError, et as CdkdError, i as credentialFingerprint, n as ambientCredentialConfig, r as clientDefaultsFor, t as ambientClientDefaults, z as isTransientServerError } from "./ambient-client-defaults-D6q-PsWI.js";
5
+ import { $ as userPoolProtectionSite, A as replayedSendWindow, At as packCompositeId, B as refusalTypeShown, C as AmbiguousCreateLatch, Ct as isInterruptedWaitError, D as createAttemptKey, Dt as compositeIdSeparatorRefusal, E as ambiguousAttemptLead, Et as compositeIdFormatMessage, F as isPlainImportJson, Ft as createMaskedRetryLogger, H as resolveExplicitPhysicalId, Ht as clearCreatedBeforeFailure, I as isPlainImportValue, It as isSecretDerivedValue, J as deleteWithProtectionCompensation, Jt as markAuxiliaryFailure, K as markNotGone, Kt as isAuxiliaryFailure, L as isQuotableImportValue, Lt as maskDeep, M as withoutServerErrorRetries, Mt as segmentAfterAnchor, N as VALUE_NOT_SHOWN, Nt as stateOrphanRecordRemedy, O as isInsideWindow, Ot as compositeIdSkipResult, P as importRemedyCommand, Pt as createMaskedLogSinks, R as normalizeAwsTagsToCfn, Rt as maskerOrIdentity, S as AMBIGUOUS_LATCH_TTL_MS, T as RecentIdSet, Tt as canonicalizeRoute53QueryName, U as RESOURCE_NOT_FOUND, V as remedyLogicalId, W as assertRegionMatch, X as observeThenDisableProtection, Xt as markSupersedesEarlierCreate, Y as logGroupProtectionSite, Yt as markCreatedBeforeFailure, Z as rdsFamilyProtectionSite, _ as onlySecretDerived, _t as pasteableAwsCommand, a as withRemovalDefaults, b as recordedPrincipalsRepair, ct as protectionFlipKey, dt as ElapsedBudgetRegistry, et as PROTECTION_FLIP_RETRY_WAIT_MS, f as retractCreatedResource, g as holdsSecretDerivedEntry, gt as isAwsCliLiteral, h as SECRET_DERIVED_READ_LIVE, hn as withPasteableAwsProfile, ht as WITHHELD_AWS_COMMAND, i as removedTemplateKeys, it as isTerminalDbWaitStatus, j as setBounded, k as replayFollowedAmbiguousAttempt, kt as logicalIdShown, ln as injectiveKey, mt as UNNAMEABLE_ID_CLAUSE, ot as ProtectionFlipRegistry, rt as isProceedDbStatus, st as isTerminalDeleteFailure, t as clearOnUpdateRemoval, tt as deleteAfterProtectionFlipWithFinalSnapshot, u as reportCreatedResource, un as injectiveKeyPrefix, ut as ElapsedBudget, v as readPrincipalLists, vt as protectedReplacementAdvice, w as CREATION_DATE_SKEW_MARGIN_MS, wt as startInterruptWatch, yt as renderDisableCommand, z as quotedRemedyLogicalId, zt as withDerivedNameMasks } from "./update-removal-CIWY-E-v.js";
6
+ import { A as displayStackName, N as plainIdentOr, O as displayIdent, P as safeMsg, S as SECRET_REF_MAX_CODE_POINTS, T as asIsMessage, _ as shellQuote, c as deployReplaceCommand, d as pasteableCommand, j as isPasteableIdent, k as displaySafe, l as hasClauseBreak, m as proseQuoted, o as cdkdRemedy, p as plainOrDescribed, s as commandHole, u as isInertUnquoted, v as withheldTargetClause } from "./version-CqgQyu4Z.js";
7
+ import { gt as slowCcOperationTimeoutMs, n as isRefusedByName, r as markDeleteStarted } from "./delete-started-CU2YbrGM.js";
8
+ import { a as resolveSecretDerivedPrincipals, i as isResolvableSecretPrincipalList, n as runDestroyForStack, o as canonicalizeIpProtocolValue, r as holdsUnprovenSecretPrincipalToken, t as canonicalizeIpv4Cidr } from "./program-BK0D4lXw.js";
9
+ import { $ as isTtlAlreadyDisabled, $a as APPSYNC_APIKEY_ARN_RESOURCE_PATH, $t as lookupEachName, Ar as REDACTED_DELETE_ADDRESS_SKIP_REASON, At as maskedLogger, Bo as outputReferenceProvenanceOf, C as isAbsoluteAssetPath, Co as s3BucketDomainName, Cs as passedParameterClassesOf, Ct as deleteBudgetKey, Dt as INDEX_SETTLE_POLL_INTERVAL_MS, Eo as s3BucketWebsiteUrl, Et as DELETE_INDEX_WAIT_PROCEED_NOTE, Fa as waitForLambdaFunctionActive, Ft as hasCdkAutoDeleteTag, G as declaredStreamTagsMember, Ga as withIndeterminateGuard, Gc as withoutSdkUnwiredProperties, H as STREAM_POLICY_KEY, Hc as findSdkUnwiredProperties, Io as parseWebACLArn, It as isTruthyCfnBoolean, J as streamDeclaresPolicy, Jt as getPriorAttempts, K as planStreamMemberOps, Ki as secretNamedAttributeNamesOf, Kl as decodeListingKey, Ko as getAccountInfo, La as waitForGoneAfterDelete, Mr as redactedDeleteAddressFields, Mt as waitForIndexesSettled, Nc as accountArgs, Nr as redactedDeleteAddressSkip, Nt as ECR_AUTO_DELETE_IMAGES_TAG, Oc as refuseMalformedResourcesForDestroy, Ot as TABLE_INDEX_NOUN, Pc as withheldAccountClause, Pt as S3_AUTO_DELETE_OBJECTS_TAG, Q as streamTagsMatchDeclared, Qa as isSettledInstanceState, Qt as isAccessDeniedError, Ra as resolvedResourceTimeoutMs, S as findNestedTemplateTreeDefect, So as s3BucketArn, St as compensateRemovedDeletionProtection, T as renderNestedTemplateTreeDefect, Ta as getCurrentResourceSecrets, To as s3BucketRegionalDomainName, Tt as resolveDynamoDbDeleteBudgetMs, U as STREAM_TAGS_KEY, V as DynamoDBGlobalTableProvider, W as declaredStreamPolicyMember, Wa as deleteSkipReason, Wr as getCurrentProducerRegions, X as streamMemberRefusals, Y as streamDeclaresTags, Yt as markRefusedBeforeApplying, Z as streamPolicyMatchesDeclared, Zt as chunks, _t as stripIndexContributorInsights, at as readbackVectorIndexes, au as renderAssemblyPathEscape, bt as DYNAMODB_DELETE_POLL_COST_MS, ca as collectManagedPolicyArnsAttachedBySiblings, ct as vectorIndexesShapeDetail, da as withoutSiblingAttachedArns, dr as earliestDefined, dt as indexDeclaresContributorInsights, en as withApiLimit, eo as maskedSecretSegment, et as isTtlRateLimited, fa as withoutSiblingOwned, fl as stringifyValue, fs as WARM_THROUGHPUT_MEMBERS, ft as planContributorInsightsOp, gi as getStackRecords, gs as toFiniteNumber, gt as reverseMapTableContributorInsights, hn as withNestedStackContext, hr as acquireIdempotencyToken, hs as toCfnInteger, ht as reverseMapIndexContributorInsights, it as planVectorIndexUpdates, jr as isRedactedRecordedValue, jt as relayedIndexBusyDelete, kt as deleteTableWithIndexBusyRetry, la as collectPrincipalsAttachingPolicy, lt as CONTRIBUTOR_INSIGHTS_KEY, mi as awaitInFlightSibling, mn as getCurrentNestedStackContext, ms as isWarmThroughputDecrease, mt as readContributorInsightsSpec, nt as readTtlSpec, nu as describeFileReadFailure, ot as vectorIndexesForCreate, ou as resolveAssemblyPath, pr as reserveStackCreateToken, ps as coerceWarmThroughput$1, pt as planIndexContributorInsightsOps, q as reverseMapStreamPolicy, rt as sendTtlWaitingOutRateLimit, ru as displayAssemblyPath, sa as collectGroupsAddedBySiblings, sn as getNestedRevertRun, st as vectorIndexesSettled, t as DeployEngine, tt as planTimeToLive, un as revertNestedChildFromJournal, ut as contributorInsightsRefusals, vc as refuseMalformedNestedChildOutputs, vi as replacedDeleteFailureVerdict, vt as DYNAMODB_DELETE_DEADLINE_MARGIN_MS, w as listNestedTemplateRows, wo as s3BucketDualStackDomainName, wt as resolveDynamoDbDeleteBudgetClock, xl as rewriteTemplateAssetReferences, xt as beginDeleteWait, yt as DYNAMODB_DELETE_MIN_RESOURCE_TIMEOUT_MS } from "./deploy-engine-AmswiQ33.js";
10
+ import { _ as isModifyNotAvailableRefusal, b as stringifyIfAssigned, c as refuseRestoreFromItself, d as DBPROXY_TAG_OPTIONS, f as planTagDiff, g as tagPlanWarning, h as tagMapAsList, m as refuseMalformedDesiredTags, n as enclosingDeadlineRemainingMs, p as readTagList, t as enclosingDeadlineExpired, u as DBPROXY_TAGS_WHAT, v as modifyDbInstanceWhenAvailable, x as isUsableAttemptedName, y as definedAttributes } from "./resource-deadline-CbwFSZXC.js";
11
+ import { O as timePhase, a as reDisableInstanceApiTermination, c as unchangedBehindSecretReference, i as observeThenDisableInstanceApiTermination, n as ec2InstanceProtectionSite, o as reEnableInstanceApiTermination, r as isTerminationProtectionPropagationError, s as onlySecretReferencesDiffer, x as withRetry } from "./ec2-termination-protection-CbM5cRC2.js";
12
12
  import { n as canonicalizeRegion, r as derivePartitionAndUrlSuffix } from "./aws-partition-DA0r2sr-.js";
13
13
  import { f as ambientRegion } from "./aws-client-defaults-DAebi99J.js";
14
- import { $ as snapshotPassProvenance, At as withoutPhysicalNameCopies, C as passedNoEchoParametersOf, I as markSameGenerationBag, Nt as dynamicReferenceTokens, W as redactForState, Z as recordReferenceProvenanceEntry, a as emrClusterInstancesReplaced, cn as recordAttributeIdCopy, i as ecsServiceLaunchTypeSetOrChanged, it as hasMaskableValues, l as sameLambdaFunctionAddress, mn as carriesSecretMask, n as blockDeviceMappingsDifferOnlyInDeleteOnTermination, o as canonicalLambdaFunctionName, on as recoverMaskedOutput, s as lambdaFunctionNameForMask, sn as physicalNameCopiesOf } from "./replacement-rules-CF-_BKrA.js";
15
- import { RDSProvider } from "./rds-provider-WiRimLjl.js";
16
- import { NeptuneProvider } from "./neptune-provider-B4x2miBY.js";
17
- import { ASGProvider } from "./asg-provider-BlvhI85g.js";
14
+ import { $ as snapshotPassProvenance, At as withoutPhysicalNameCopies, C as passedNoEchoParametersOf, I as markSameGenerationBag, Nt as dynamicReferenceTokens, W as redactForState, Z as recordReferenceProvenanceEntry, a as emrClusterInstancesReplaced, cn as recordAttributeIdCopy, i as ecsServiceLaunchTypeSetOrChanged, it as hasMaskableValues, l as sameLambdaFunctionAddress, mn as carriesSecretMask, n as blockDeviceMappingsDifferOnlyInDeleteOnTermination, o as canonicalLambdaFunctionName, on as recoverMaskedOutput, s as lambdaFunctionNameForMask, sn as physicalNameCopiesOf } from "./replacement-rules-Dc0xW46P.js";
15
+ import { RDSProvider } from "./rds-provider-BRqq-zMM.js";
16
+ import { NeptuneProvider } from "./neptune-provider-CoZPYMUA.js";
17
+ import { ASGProvider } from "./asg-provider-DVPUxvJ4.js";
18
18
  import { createHash, randomUUID } from "node:crypto";
19
19
  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";
20
20
  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";
@@ -24119,6 +24119,154 @@ const tagsErrorsMethods = {
24119
24119
  isNotFoundError: isNotFoundError$3
24120
24120
  };
24121
24121
 
24122
+ // src/provisioning/providers/ec2/read-instance-state.ts
24123
+ async function readInstanceCurrentState(physicalId, properties) {
24124
+ const instance = (await this.ec2Client.send(new DescribeInstancesCommand({ InstanceIds: [physicalId] }))).Reservations?.[0]?.Instances?.[0];
24125
+ if (!instance || instance.State?.Name === "terminated" || instance.State?.Name === "shutting-down") return RESOURCE_NOT_FOUND;
24126
+ const result = {};
24127
+ if (instance.ImageId !== void 0) result["ImageId"] = instance.ImageId;
24128
+ if (instance.InstanceType !== void 0) result["InstanceType"] = instance.InstanceType;
24129
+ if (instance.KeyName !== void 0) result["KeyName"] = instance.KeyName;
24130
+ if (instance.SubnetId !== void 0) result["SubnetId"] = instance.SubnetId;
24131
+ result["SecurityGroupIds"] = (instance.SecurityGroups ?? []).map((g) => g.GroupId).filter((id) => typeof id === "string").sort();
24132
+ if (instance.PrivateIpAddress !== void 0) result["PrivateIpAddress"] = instance.PrivateIpAddress;
24133
+ if (instance.SourceDestCheck !== void 0) result["SourceDestCheck"] = instance.SourceDestCheck;
24134
+ if (instance.Placement?.AvailabilityZone !== void 0) result["AvailabilityZone"] = instance.Placement.AvailabilityZone;
24135
+ const monitoringState = instance.Monitoring?.State;
24136
+ result["Monitoring"] = monitoringState === "enabled" || monitoringState === "pending";
24137
+ if (instance.EbsOptimized !== void 0) result["EbsOptimized"] = instance.EbsOptimized;
24138
+ const md = instance.MetadataOptions;
24139
+ if (md !== void 0) {
24140
+ const out = {};
24141
+ if (md.HttpTokens !== void 0) out["HttpTokens"] = md.HttpTokens;
24142
+ if (md.HttpPutResponseHopLimit !== void 0) out["HttpPutResponseHopLimit"] = md.HttpPutResponseHopLimit;
24143
+ if (md.HttpEndpoint !== void 0) out["HttpEndpoint"] = md.HttpEndpoint;
24144
+ if (md.HttpProtocolIpv6 !== void 0) out["HttpProtocolIpv6"] = md.HttpProtocolIpv6;
24145
+ if (md.InstanceMetadataTags !== void 0) out["InstanceMetadataTags"] = md.InstanceMetadataTags;
24146
+ if (Object.keys(out).length > 0) result["MetadataOptions"] = out;
24147
+ }
24148
+ if (instance.CpuOptions !== void 0) {
24149
+ const cpu = {};
24150
+ if (instance.CpuOptions.CoreCount !== void 0) cpu["CoreCount"] = instance.CpuOptions.CoreCount;
24151
+ if (instance.CpuOptions.ThreadsPerCore !== void 0) cpu["ThreadsPerCore"] = instance.CpuOptions.ThreadsPerCore;
24152
+ if (Object.keys(cpu).length > 0) result["CpuOptions"] = cpu;
24153
+ }
24154
+ if (instance.HibernationOptions?.Configured !== void 0) result["HibernationOptions"] = { Configured: instance.HibernationOptions.Configured };
24155
+ const dnsOptions = instance.PrivateDnsNameOptions;
24156
+ if (dnsOptions !== void 0) {
24157
+ const dns = {};
24158
+ if (dnsOptions.HostnameType !== void 0) dns["HostnameType"] = dnsOptions.HostnameType;
24159
+ if (dnsOptions.EnableResourceNameDnsARecord !== void 0) dns["EnableResourceNameDnsARecord"] = dnsOptions.EnableResourceNameDnsARecord;
24160
+ if (dnsOptions.EnableResourceNameDnsAAAARecord !== void 0) dns["EnableResourceNameDnsAAAARecord"] = dnsOptions.EnableResourceNameDnsAAAARecord;
24161
+ if (Object.keys(dns).length > 0) result["PrivateDnsNameOptions"] = dns;
24162
+ }
24163
+ if (instance.Placement?.Tenancy !== void 0) result["Tenancy"] = instance.Placement.Tenancy;
24164
+ if (typeof instance.Placement?.GroupName === "string" && instance.Placement.GroupName !== "") result["PlacementGroupName"] = instance.Placement.GroupName;
24165
+ const placementReads = [
24166
+ ["Affinity", instance.Placement?.Affinity],
24167
+ ["HostId", instance.Placement?.HostId],
24168
+ ["HostResourceGroupArn", instance.Placement?.HostResourceGroupArn],
24169
+ ["KernelId", instance.KernelId],
24170
+ ["RamdiskId", instance.RamdiskId]
24171
+ ];
24172
+ for (const [key, value] of placementReads) if (typeof value === "string" && value !== "") result[key] = value;
24173
+ if (instance.EnclaveOptions?.Enabled !== void 0) result["EnclaveOptions"] = { Enabled: instance.EnclaveOptions.Enabled };
24174
+ if (instance.IamInstanceProfile?.Arn !== void 0) result["IamInstanceProfile"] = instance.IamInstanceProfile.Arn;
24175
+ else if (process.env["CDKD_NO_WAIT"] === "true" && instance.State?.Name === "pending") try {
24176
+ const live = (await this.ec2Client.send(new DescribeIamInstanceProfileAssociationsCommand({ Filters: [{
24177
+ Name: "instance-id",
24178
+ Values: [physicalId]
24179
+ }] }))).IamInstanceProfileAssociations?.find((a) => a.State === "associated" || a.State === "associating");
24180
+ if (live?.IamInstanceProfile?.Arn !== void 0) result["IamInstanceProfile"] = live.IamInstanceProfile.Arn;
24181
+ } catch (error) {
24182
+ const backfillHead = `Could not backfill IamInstanceProfile for ${physicalId} during the --no-wait capture: `;
24183
+ this.logger.warn(`${backfillHead}${this.warnFailureSentence(backfillHead, error, (t) => t)} The field is omitted from the observed snapshot.`);
24184
+ }
24185
+ const volumeIds = (instance.BlockDeviceMappings ?? []).filter((m) => m.Ebs?.VolumeId !== void 0).map((m) => m.Ebs.VolumeId);
24186
+ let volumesById = /* @__PURE__ */ new Map();
24187
+ if (volumeIds.length > 0) try {
24188
+ const volResp = await this.ec2Client.send(new DescribeVolumesCommand({ VolumeIds: volumeIds }));
24189
+ for (const v of volResp.Volumes ?? []) if (v.VolumeId !== void 0) volumesById.set(v.VolumeId, v);
24190
+ } catch (err) {
24191
+ this.logger.debug(`DescribeVolumes(${volumeIds.join(",")}) failed: ${describeAwsFailure(err).detail}`);
24192
+ volumesById = /* @__PURE__ */ new Map();
24193
+ }
24194
+ const blockMappings = [];
24195
+ for (const m of instance.BlockDeviceMappings ?? []) {
24196
+ const out = {};
24197
+ if (m.DeviceName !== void 0) out["DeviceName"] = m.DeviceName;
24198
+ if (m.Ebs?.VolumeId !== void 0) {
24199
+ const ebs = {};
24200
+ if (m.Ebs.DeleteOnTermination !== void 0) ebs["DeleteOnTermination"] = m.Ebs.DeleteOnTermination;
24201
+ const vol = volumesById.get(m.Ebs.VolumeId);
24202
+ if (vol !== void 0) {
24203
+ if (vol.VolumeType !== void 0) ebs["VolumeType"] = vol.VolumeType;
24204
+ if (vol.Size !== void 0) ebs["VolumeSize"] = vol.Size;
24205
+ if (vol.Iops !== void 0) ebs["Iops"] = vol.Iops;
24206
+ if (vol.Throughput !== void 0) ebs["Throughput"] = vol.Throughput;
24207
+ if (vol.Encrypted !== void 0) ebs["Encrypted"] = vol.Encrypted;
24208
+ if (vol.KmsKeyId !== void 0) ebs["KmsKeyId"] = vol.KmsKeyId;
24209
+ if (vol.SnapshotId !== void 0) ebs["SnapshotId"] = vol.SnapshotId;
24210
+ }
24211
+ out["Ebs"] = ebs;
24212
+ }
24213
+ blockMappings.push(out);
24214
+ }
24215
+ const declaredDevices = declaredBlockDeviceNames(properties);
24216
+ const isDeclared = (m) => declaredDevices !== void 0 && typeof m["DeviceName"] === "string" && declaredDevices.has(m["DeviceName"]);
24217
+ result["BlockDeviceMappings"] = blockMappings.some(isDeclared) ? blockMappings.filter(isDeclared) : blockMappings;
24218
+ if (Array.isArray(properties?.["Volumes"]) && instanceVolumesRefusal(properties["Volumes"], "AWS::EC2::Instance") === void 0) {
24219
+ const declaredIds = instanceVolumeEntries(properties["Volumes"]).map((v) => v.VolumeId).filter((id) => typeof id === "string");
24220
+ result["Volumes"] = (instance.BlockDeviceMappings ?? []).filter((m) => m.Ebs?.VolumeId !== void 0 && m.DeviceName !== void 0 && declaredIds.includes(m.Ebs.VolumeId)).sort((a, b) => declaredIds.indexOf(a.Ebs.VolumeId) - declaredIds.indexOf(b.Ebs.VolumeId)).map((m) => ({
24221
+ Device: m.DeviceName,
24222
+ VolumeId: m.Ebs.VolumeId
24223
+ }));
24224
+ }
24225
+ if (Array.isArray(properties?.["SsmAssociations"]) && instanceSsmAssociationsRefusal(properties["SsmAssociations"], "AWS::EC2::Instance") === void 0) {
24226
+ const read = await this.readInstanceSsmAssociations(physicalId, instanceSsmAssociationEntries(properties["SsmAssociations"]));
24227
+ if (read !== void 0) result["SsmAssociations"] = read;
24228
+ }
24229
+ result["Tags"] = normalizeAwsTagsToCfn(instance.Tags);
24230
+ try {
24231
+ const attrResp = await this.ec2Client.send(new DescribeInstanceAttributeCommand({
24232
+ InstanceId: physicalId,
24233
+ Attribute: "disableApiTermination"
24234
+ }));
24235
+ if (attrResp.DisableApiTermination?.Value !== void 0) result["DisableApiTermination"] = attrResp.DisableApiTermination.Value;
24236
+ } catch (err) {
24237
+ this.logger.debug(`DescribeInstanceAttribute(disableApiTermination, ${physicalId}) failed: ${describeAwsFailure(err).detail}`);
24238
+ }
24239
+ if (properties?.["InstanceInitiatedShutdownBehavior"] !== void 0) try {
24240
+ const attrResp = await this.ec2Client.send(new DescribeInstanceAttributeCommand({
24241
+ InstanceId: physicalId,
24242
+ Attribute: "instanceInitiatedShutdownBehavior"
24243
+ }));
24244
+ if (attrResp.InstanceInitiatedShutdownBehavior?.Value !== void 0) result["InstanceInitiatedShutdownBehavior"] = attrResp.InstanceInitiatedShutdownBehavior.Value;
24245
+ } catch (err) {
24246
+ this.logger.debug(safeMsg`DescribeInstanceAttribute(instanceInitiatedShutdownBehavior, ${physicalId}) failed: ${describeAwsFailure(err).detail}`);
24247
+ }
24248
+ try {
24249
+ const cpuCredits = (await this.ec2Client.send(new DescribeInstanceCreditSpecificationsCommand({ InstanceIds: [physicalId] }))).InstanceCreditSpecifications?.[0]?.CpuCredits;
24250
+ if (cpuCredits !== void 0) result["CreditSpecification"] = { CPUCredits: cpuCredits };
24251
+ } catch (err) {
24252
+ this.logger.debug(`DescribeInstanceCreditSpecifications(${physicalId}) failed: ${describeAwsFailure(err).detail}`);
24253
+ }
24254
+ return result;
24255
+ }
24256
+ function declaredBlockDeviceNames(properties) {
24257
+ const declared = properties?.["BlockDeviceMappings"];
24258
+ if (!Array.isArray(declared)) return void 0;
24259
+ const names = /* @__PURE__ */ new Set();
24260
+ for (const entry of declared) {
24261
+ if (entry === null || typeof entry !== "object" || Array.isArray(entry)) return void 0;
24262
+ const name = entry["DeviceName"];
24263
+ if (typeof name !== "string") return void 0;
24264
+ names.add(name);
24265
+ }
24266
+ return names;
24267
+ }
24268
+ const readInstanceStateMethods = { readInstanceCurrentState };
24269
+
24122
24270
  // src/provisioning/providers/ec2/drift.ts
24123
24271
  function subnetIpv6InTransition(subnet) {
24124
24272
  return (subnet.Ipv6CidrBlockAssociationSet ?? []).some((association) => {
@@ -24139,7 +24287,32 @@ async function readUnsettled$5(physicalId, logicalId, resourceType, names, recor
24139
24287
  if (resourceType === "AWS::EC2::Subnet") return this.readSubnetCurrentState(physicalId, names, recordedProperties);
24140
24288
  return this.readCurrentState(physicalId, logicalId, resourceType, recordedProperties);
24141
24289
  }
24142
- async function canonicalizeDriftPair$3(resourceType, baseline, aws) {
24290
+ async function canonicalizeDriftPair$3(resourceType, baseline, aws, properties) {
24291
+ if (resourceType === "AWS::EC2::Instance") {
24292
+ const declared = declaredBlockDeviceNames(properties);
24293
+ const recorded = baseline["BlockDeviceMappings"];
24294
+ const live = aws["BlockDeviceMappings"];
24295
+ const isDeclared = (m) => {
24296
+ const name = m?.["DeviceName"];
24297
+ return declared !== void 0 && typeof name === "string" && declared.has(name);
24298
+ };
24299
+ if (Array.isArray(recorded) && Array.isArray(live) && live.some(isDeclared)) {
24300
+ const kept = recorded.filter((m) => {
24301
+ return typeof m?.["DeviceName"] !== "string" || isDeclared(m);
24302
+ });
24303
+ if (kept.length !== recorded.length) return {
24304
+ baseline: {
24305
+ ...baseline,
24306
+ BlockDeviceMappings: kept
24307
+ },
24308
+ aws
24309
+ };
24310
+ }
24311
+ return {
24312
+ baseline,
24313
+ aws
24314
+ };
24315
+ }
24143
24316
  const key = "Ipv6CidrBlock";
24144
24317
  if (resourceType === "AWS::EC2::Subnet") {
24145
24318
  const old = baseline[key];
@@ -24650,140 +24823,6 @@ const readStateMethods = {
24650
24823
  readSubnetNetworkAclAssociationCurrentState
24651
24824
  };
24652
24825
 
24653
- // src/provisioning/providers/ec2/read-instance-state.ts
24654
- async function readInstanceCurrentState(physicalId, properties) {
24655
- const instance = (await this.ec2Client.send(new DescribeInstancesCommand({ InstanceIds: [physicalId] }))).Reservations?.[0]?.Instances?.[0];
24656
- if (!instance || instance.State?.Name === "terminated" || instance.State?.Name === "shutting-down") return RESOURCE_NOT_FOUND;
24657
- const result = {};
24658
- if (instance.ImageId !== void 0) result["ImageId"] = instance.ImageId;
24659
- if (instance.InstanceType !== void 0) result["InstanceType"] = instance.InstanceType;
24660
- if (instance.KeyName !== void 0) result["KeyName"] = instance.KeyName;
24661
- if (instance.SubnetId !== void 0) result["SubnetId"] = instance.SubnetId;
24662
- result["SecurityGroupIds"] = (instance.SecurityGroups ?? []).map((g) => g.GroupId).filter((id) => typeof id === "string").sort();
24663
- if (instance.PrivateIpAddress !== void 0) result["PrivateIpAddress"] = instance.PrivateIpAddress;
24664
- if (instance.SourceDestCheck !== void 0) result["SourceDestCheck"] = instance.SourceDestCheck;
24665
- if (instance.Placement?.AvailabilityZone !== void 0) result["AvailabilityZone"] = instance.Placement.AvailabilityZone;
24666
- const monitoringState = instance.Monitoring?.State;
24667
- result["Monitoring"] = monitoringState === "enabled" || monitoringState === "pending";
24668
- if (instance.EbsOptimized !== void 0) result["EbsOptimized"] = instance.EbsOptimized;
24669
- const md = instance.MetadataOptions;
24670
- if (md !== void 0) {
24671
- const out = {};
24672
- if (md.HttpTokens !== void 0) out["HttpTokens"] = md.HttpTokens;
24673
- if (md.HttpPutResponseHopLimit !== void 0) out["HttpPutResponseHopLimit"] = md.HttpPutResponseHopLimit;
24674
- if (md.HttpEndpoint !== void 0) out["HttpEndpoint"] = md.HttpEndpoint;
24675
- if (md.HttpProtocolIpv6 !== void 0) out["HttpProtocolIpv6"] = md.HttpProtocolIpv6;
24676
- if (md.InstanceMetadataTags !== void 0) out["InstanceMetadataTags"] = md.InstanceMetadataTags;
24677
- if (Object.keys(out).length > 0) result["MetadataOptions"] = out;
24678
- }
24679
- if (instance.CpuOptions !== void 0) {
24680
- const cpu = {};
24681
- if (instance.CpuOptions.CoreCount !== void 0) cpu["CoreCount"] = instance.CpuOptions.CoreCount;
24682
- if (instance.CpuOptions.ThreadsPerCore !== void 0) cpu["ThreadsPerCore"] = instance.CpuOptions.ThreadsPerCore;
24683
- if (Object.keys(cpu).length > 0) result["CpuOptions"] = cpu;
24684
- }
24685
- if (instance.HibernationOptions?.Configured !== void 0) result["HibernationOptions"] = { Configured: instance.HibernationOptions.Configured };
24686
- const dnsOptions = instance.PrivateDnsNameOptions;
24687
- if (dnsOptions !== void 0) {
24688
- const dns = {};
24689
- if (dnsOptions.HostnameType !== void 0) dns["HostnameType"] = dnsOptions.HostnameType;
24690
- if (dnsOptions.EnableResourceNameDnsARecord !== void 0) dns["EnableResourceNameDnsARecord"] = dnsOptions.EnableResourceNameDnsARecord;
24691
- if (dnsOptions.EnableResourceNameDnsAAAARecord !== void 0) dns["EnableResourceNameDnsAAAARecord"] = dnsOptions.EnableResourceNameDnsAAAARecord;
24692
- if (Object.keys(dns).length > 0) result["PrivateDnsNameOptions"] = dns;
24693
- }
24694
- if (instance.Placement?.Tenancy !== void 0) result["Tenancy"] = instance.Placement.Tenancy;
24695
- if (typeof instance.Placement?.GroupName === "string" && instance.Placement.GroupName !== "") result["PlacementGroupName"] = instance.Placement.GroupName;
24696
- const placementReads = [
24697
- ["Affinity", instance.Placement?.Affinity],
24698
- ["HostId", instance.Placement?.HostId],
24699
- ["HostResourceGroupArn", instance.Placement?.HostResourceGroupArn],
24700
- ["KernelId", instance.KernelId],
24701
- ["RamdiskId", instance.RamdiskId]
24702
- ];
24703
- for (const [key, value] of placementReads) if (typeof value === "string" && value !== "") result[key] = value;
24704
- if (instance.EnclaveOptions?.Enabled !== void 0) result["EnclaveOptions"] = { Enabled: instance.EnclaveOptions.Enabled };
24705
- if (instance.IamInstanceProfile?.Arn !== void 0) result["IamInstanceProfile"] = instance.IamInstanceProfile.Arn;
24706
- else if (process.env["CDKD_NO_WAIT"] === "true" && instance.State?.Name === "pending") try {
24707
- const live = (await this.ec2Client.send(new DescribeIamInstanceProfileAssociationsCommand({ Filters: [{
24708
- Name: "instance-id",
24709
- Values: [physicalId]
24710
- }] }))).IamInstanceProfileAssociations?.find((a) => a.State === "associated" || a.State === "associating");
24711
- if (live?.IamInstanceProfile?.Arn !== void 0) result["IamInstanceProfile"] = live.IamInstanceProfile.Arn;
24712
- } catch (error) {
24713
- const backfillHead = `Could not backfill IamInstanceProfile for ${physicalId} during the --no-wait capture: `;
24714
- this.logger.warn(`${backfillHead}${this.warnFailureSentence(backfillHead, error, (t) => t)} The field is omitted from the observed snapshot.`);
24715
- }
24716
- const volumeIds = (instance.BlockDeviceMappings ?? []).filter((m) => m.Ebs?.VolumeId !== void 0).map((m) => m.Ebs.VolumeId);
24717
- let volumesById = /* @__PURE__ */ new Map();
24718
- if (volumeIds.length > 0) try {
24719
- const volResp = await this.ec2Client.send(new DescribeVolumesCommand({ VolumeIds: volumeIds }));
24720
- for (const v of volResp.Volumes ?? []) if (v.VolumeId !== void 0) volumesById.set(v.VolumeId, v);
24721
- } catch (err) {
24722
- this.logger.debug(`DescribeVolumes(${volumeIds.join(",")}) failed: ${describeAwsFailure(err).detail}`);
24723
- volumesById = /* @__PURE__ */ new Map();
24724
- }
24725
- const blockMappings = [];
24726
- for (const m of instance.BlockDeviceMappings ?? []) {
24727
- const out = {};
24728
- if (m.DeviceName !== void 0) out["DeviceName"] = m.DeviceName;
24729
- if (m.Ebs?.VolumeId !== void 0) {
24730
- const ebs = {};
24731
- if (m.Ebs.DeleteOnTermination !== void 0) ebs["DeleteOnTermination"] = m.Ebs.DeleteOnTermination;
24732
- const vol = volumesById.get(m.Ebs.VolumeId);
24733
- if (vol !== void 0) {
24734
- if (vol.VolumeType !== void 0) ebs["VolumeType"] = vol.VolumeType;
24735
- if (vol.Size !== void 0) ebs["VolumeSize"] = vol.Size;
24736
- if (vol.Iops !== void 0) ebs["Iops"] = vol.Iops;
24737
- if (vol.Throughput !== void 0) ebs["Throughput"] = vol.Throughput;
24738
- if (vol.Encrypted !== void 0) ebs["Encrypted"] = vol.Encrypted;
24739
- if (vol.KmsKeyId !== void 0) ebs["KmsKeyId"] = vol.KmsKeyId;
24740
- if (vol.SnapshotId !== void 0) ebs["SnapshotId"] = vol.SnapshotId;
24741
- }
24742
- out["Ebs"] = ebs;
24743
- }
24744
- blockMappings.push(out);
24745
- }
24746
- result["BlockDeviceMappings"] = blockMappings;
24747
- if (Array.isArray(properties?.["Volumes"]) && instanceVolumesRefusal(properties["Volumes"], "AWS::EC2::Instance") === void 0) {
24748
- const declaredIds = instanceVolumeEntries(properties["Volumes"]).map((v) => v.VolumeId).filter((id) => typeof id === "string");
24749
- result["Volumes"] = (instance.BlockDeviceMappings ?? []).filter((m) => m.Ebs?.VolumeId !== void 0 && m.DeviceName !== void 0 && declaredIds.includes(m.Ebs.VolumeId)).sort((a, b) => declaredIds.indexOf(a.Ebs.VolumeId) - declaredIds.indexOf(b.Ebs.VolumeId)).map((m) => ({
24750
- Device: m.DeviceName,
24751
- VolumeId: m.Ebs.VolumeId
24752
- }));
24753
- }
24754
- if (Array.isArray(properties?.["SsmAssociations"]) && instanceSsmAssociationsRefusal(properties["SsmAssociations"], "AWS::EC2::Instance") === void 0) {
24755
- const read = await this.readInstanceSsmAssociations(physicalId, instanceSsmAssociationEntries(properties["SsmAssociations"]));
24756
- if (read !== void 0) result["SsmAssociations"] = read;
24757
- }
24758
- result["Tags"] = normalizeAwsTagsToCfn(instance.Tags);
24759
- try {
24760
- const attrResp = await this.ec2Client.send(new DescribeInstanceAttributeCommand({
24761
- InstanceId: physicalId,
24762
- Attribute: "disableApiTermination"
24763
- }));
24764
- if (attrResp.DisableApiTermination?.Value !== void 0) result["DisableApiTermination"] = attrResp.DisableApiTermination.Value;
24765
- } catch (err) {
24766
- this.logger.debug(`DescribeInstanceAttribute(disableApiTermination, ${physicalId}) failed: ${describeAwsFailure(err).detail}`);
24767
- }
24768
- if (properties?.["InstanceInitiatedShutdownBehavior"] !== void 0) try {
24769
- const attrResp = await this.ec2Client.send(new DescribeInstanceAttributeCommand({
24770
- InstanceId: physicalId,
24771
- Attribute: "instanceInitiatedShutdownBehavior"
24772
- }));
24773
- if (attrResp.InstanceInitiatedShutdownBehavior?.Value !== void 0) result["InstanceInitiatedShutdownBehavior"] = attrResp.InstanceInitiatedShutdownBehavior.Value;
24774
- } catch (err) {
24775
- this.logger.debug(safeMsg`DescribeInstanceAttribute(instanceInitiatedShutdownBehavior, ${physicalId}) failed: ${describeAwsFailure(err).detail}`);
24776
- }
24777
- try {
24778
- const cpuCredits = (await this.ec2Client.send(new DescribeInstanceCreditSpecificationsCommand({ InstanceIds: [physicalId] }))).InstanceCreditSpecifications?.[0]?.CpuCredits;
24779
- if (cpuCredits !== void 0) result["CreditSpecification"] = { CPUCredits: cpuCredits };
24780
- } catch (err) {
24781
- this.logger.debug(`DescribeInstanceCreditSpecifications(${physicalId}) failed: ${describeAwsFailure(err).detail}`);
24782
- }
24783
- return result;
24784
- }
24785
- const readInstanceStateMethods = { readInstanceCurrentState };
24786
-
24787
24826
  // src/provisioning/providers/ec2/verify-explicit.ts
24788
24827
  async function verifyExplicit(logicalId, resourceType, physicalId, properties) {
24789
24828
  try {
@@ -62501,7 +62540,7 @@ async function create$1(logicalId, resourceType, properties, context) {
62501
62540
  const ctx = this.requireContext();
62502
62541
  this.requireDeployContext(ctx, "create");
62503
62542
  const childTemplatePath = ctx.nestedTemplates[logicalId];
62504
- if (!childTemplatePath) throw markNonRetryable(/* @__PURE__ */ new Error(`Nested template file not found for AWS::CloudFormation::Stack ${displayIdent(logicalId)} under parent ${displayStackName(ctx.parentStackName)}. Verify the synth output emits Metadata['aws:asset:path'] on this resource (CDK 2.x cdk.NestedStack does so by default).`));
62543
+ if (!childTemplatePath) throw markNonRetryable(/* @__PURE__ */ new Error(`Nested template file not found for AWS::CloudFormation::Stack ${displayIdent(logicalId)} under parent ${displayStackName(ctx.parentStackName)}: the resource has no Metadata['aws:asset:path']. If it is a cdk.NestedStack synthesized with asset metadata disabled (aws:cdk:enable-asset-metadata false, or cdk synth --no-asset-metadata), re-enable it. A nested stack with a remote TemplateURL (such as the one a CDK HostedRotation generates) is not supported.`));
62505
62544
  this.refuseMalformedNestedTemplateTree(ctx, logicalId, childTemplatePath);
62506
62545
  const { template: childTemplate, grandchildTemplates } = this.readChildTemplate(childTemplatePath, ctx.assetRedirect);
62507
62546
  const childStackName = this.deriveChildStackName(ctx.parentStackName, logicalId);
@@ -63385,4 +63424,4 @@ var ACMCertificateProvider = class {
63385
63424
  };
63386
63425
 
63387
63426
  export { ACMCertificateProvider, ASGProvider, AgentCoreBrowserProvider, AgentCoreCodeInterpreterProvider, AgentCoreEvaluatorProvider, AgentCoreRuntimeProvider, ApiGatewayProvider, ApiGatewayV2Provider, AppConfigEnvironmentProvider, 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 };
63388
- //# sourceMappingURL=provider-classes-CTUyynuJ.js.map
63427
+ //# sourceMappingURL=provider-classes-DHx4MeZb.js.map