@go-to-k/cdkd 0.301.2 → 0.301.4

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 (31) hide show
  1. package/dist/{asg-provider--t5d-gjf.js → asg-provider--GY-B-zI.js} +8 -15
  2. package/dist/asg-provider--GY-B-zI.js.map +1 -0
  3. package/dist/cli.js +2 -2
  4. package/dist/{deploy-engine--5XWdjW3.js → deploy-engine-BIPU9Xdh.js} +1524 -1184
  5. package/dist/deploy-engine-BIPU9Xdh.js.map +1 -0
  6. package/dist/{iam-policy-targets-DFk7zr0Q.js → iam-policy-targets-BkeM7IXi.js} +6 -3
  7. package/dist/iam-policy-targets-BkeM7IXi.js.map +1 -0
  8. package/dist/{iam-role-provider-Bwgqyn6-.js → iam-role-provider-C58oW5zG.js} +7 -6
  9. package/dist/iam-role-provider-C58oW5zG.js.map +1 -0
  10. package/dist/index.d.ts +3 -5
  11. package/dist/index.d.ts.map +1 -1
  12. package/dist/index.js +3 -3
  13. package/dist/{neptune-provider-DjEVKBcV.js → neptune-provider-DoKgbZCz.js} +14 -16
  14. package/dist/neptune-provider-DoKgbZCz.js.map +1 -0
  15. package/dist/{program-DEPit8lD.js → program-DYfZCsxM.js} +131 -260
  16. package/dist/program-DYfZCsxM.js.map +1 -0
  17. package/dist/{provider-classes-CDxfoC_T.js → provider-classes-BSUoljqw.js} +383 -414
  18. package/dist/provider-classes-BSUoljqw.js.map +1 -0
  19. package/dist/{rds-provider-BvZhdkOC.js → rds-provider-DI_O0_iG.js} +14 -14
  20. package/dist/rds-provider-DI_O0_iG.js.map +1 -0
  21. package/dist/{version-DUYEmFtp.js → version-Bft5jrTk.js} +2 -2
  22. package/dist/{version-DUYEmFtp.js.map → version-Bft5jrTk.js.map} +1 -1
  23. package/package.json +2 -2
  24. package/dist/asg-provider--t5d-gjf.js.map +0 -1
  25. package/dist/deploy-engine--5XWdjW3.js.map +0 -1
  26. package/dist/iam-policy-targets-DFk7zr0Q.js.map +0 -1
  27. package/dist/iam-role-provider-Bwgqyn6-.js.map +0 -1
  28. package/dist/neptune-provider-DjEVKBcV.js.map +0 -1
  29. package/dist/program-DEPit8lD.js.map +0 -1
  30. package/dist/provider-classes-CDxfoC_T.js.map +0 -1
  31. package/dist/rds-provider-BvZhdkOC.js.map +0 -1
@@ -1,8 +1,8 @@
1
1
  import { r as getAwsClients, s as __exportAll } from "./aws-clients-B_CEQGE1.js";
2
2
  import { A as UNRENDERABLE, B as safeMsg, C as looksLikeCdkdGeneratedName, D as SAFE_MSG_ALTERED_CHAR, E as withoutGeneratedFallbackName, F as displaySafe, H as terminalSafe, I as displayStackName, L as isPasteableIdent, N as displayAwsMessage, O as SECRET_REF_MAX_CODE_POINTS, P as displayIdent, S as getCurrentStackName, T as withStackName, U as truncateCodePoints, a as getLogger, b as generateResourceNameWithFallback, d as installLogLineMaskerSource, f as getLiveRenderer, g as applyDefaultNameForFallback, j as asIsMessage, k as STACK_REF_MAX_CODE_POINTS, o as isStdoutReservedForPayload, r as safeStringify$1, t as describeAwsFailure, u as currentLogLineMasker, v as explicitNamePropertyFor, w as withSkipPrefix, x as getCurrentSkipPrefix, y as generateResourceName, z as plainIdentOr } from "./aws-failure-text-BEQfs6za.js";
3
- import { $ as protectedReplacementAdvice, $t as ambientCredentialConfig, A as isQuotableImportValue, An as SHELL_ACTIVE, At as isAuxiliaryMarkOf, B as isTerminalDeleteFailure, Bn as shellBoundedDisplay, Bt as formatLockOperation, Cn as StateError, Ct as RETRY_AUXILIARY_OWNER, Dn as normalizeAwsError, Dt as createdResourceIdentityBeforeFailure, E as assertRegionMatch, Et as createdBeforeFailure, F as resolveExplicitPhysicalId, Fn as isInertUnquoted, Ft as UNREPRODUCIBLE_LOCK_CLAUSE, G as runDeleteAttempt, Gn as isUpdateUnsupportedError, Gt as DEFAULT_STATE_PREFIX, H as observeThenDisableProtection, Hn as withheldTargetClause, Ht as recoveryCommandFlags, In as pasteableCommand, It as buildForceUnlockCommand, J as DELETION_PROTECTION_DOC_POINTER, Jn as isNameCooldownError, Kn as hasReplayMayCollide, Kt as injectiveKey, L as ProtectionFlipRegistry, Ln as physicalIdShownBesideCommand, M as quotedRemedyLogicalId, Mn as UNSHOWABLE_VALUE, Mt as markCreatedBeforeFailure, N as refusalTypeShown, Nn as commandHole, Ot as hasCreatedBeforeFailure, Pt as replayMadeAnotherResource, Q as pasteableAwsCommand, Qn as markReplayMayCollide, Qt as ambientClientDefaults, R as compensateProtectionFlip, Rn as plainOrDescribed, St as withDerivedNameMasks, T as RESOURCE_NOT_FOUND, U as protectionFlipKey, Ut as sanitizeRecoveryValue, Vn as shellQuote, Vt as formatLockOwner, Wt as CUSTOM_RESOURCE_RESPONSE_PREFIX, Xn as isReplayedNameCollisionFrom, Yn as isRecreateRetryableError, Yt as producerRecordKey, Zt as withPasteableAwsProfile, _t as createMaskedLogSinks, ar as isRetryableTransientError, at as startInterruptWatch, bn as ResourceUpdateNotSupportedError, bt as maskDeep, ct as canonicalizeRoute53QueryName, d as prepareRemovalForUpdate, dr as markNonRetryable, en as clientDefaultsFor, er as formatRetryClassificationSignals, f as removalWarning, fr as markRedactedCause, ft as logicalIdShown, gt as stateOrphanRecordRemedy, hn as MalformedProducerRecordRefusalError, ht as segmentAfterAnchor, i as holdsSecretDerivedEntry, in as CdkdError, ir as isIamPropagationError, it as isInterruptedWaitError, j as normalizeAwsTagsToCfn, jn as SHELL_ACTIVE_WHY, jt as markAuxiliaryFailure, kt as isAuxiliaryFailure, l as withUnchangedSecretPrincipalLists, ln as DynamicReferenceRegionAmbiguousError, lr as isMarkedNonRetryable, m as withoutInjectedRemovals, mn as MacroExpansionError, mt as resourceTypeShown, nn as AccountIdUnavailableError, nr as isAmbiguousOutcomeError, on as CrossAccountSecretRefusalError, or as isTransientServerError, ot as ElapsedBudgetRegistry, pn as LockError, pr as wrapMaskedAwsError, qn as isNameCollisionErrorFrom, rn as AssetError, sn as DependencyError, sr as retryClassificationText, st as monotonicNowMs, tn as credentialFingerprint, tr as isAmbiguousCcHandlerErrorCode, un as IntrinsicResolutionRefusalError, ur as isThrottlingError, ut as compositeIdSeparatorRefusal, vn as ProvisioningError, vt as createMaskedRetryLogger, w as withoutServerErrorRetries, wn as SynthesisError, wt as carryCreatedBeforeFailure, xt as maskerOrIdentity, yn as ResourceTimeoutError, yt as isSecretDerivedValue, z as deleteWithProtectionCompensation, zn as quotedOrDescribed, zt as formatLockExpiry } from "./iam-policy-targets-DFk7zr0Q.js";
3
+ import { $ as protectedReplacementAdvice, $t as ambientCredentialConfig, A as isQuotableImportValue, An as SHELL_ACTIVE, At as isAuxiliaryMarkOf, B as isTerminalDeleteFailure, Bn as shellBoundedDisplay, Bt as formatLockOperation, Cn as StateError, Ct as RETRY_AUXILIARY_OWNER, Dn as normalizeAwsError, Dt as createdResourceIdentityBeforeFailure, E as assertRegionMatch, Et as createdBeforeFailure, F as resolveExplicitPhysicalId, Fn as isInertUnquoted, Ft as UNREPRODUCIBLE_LOCK_CLAUSE, G as runDeleteAttempt, Gn as isUpdateUnsupportedError, Gt as DEFAULT_STATE_PREFIX, H as observeThenDisableProtection, Hn as withheldTargetClause, Ht as recoveryCommandFlags, In as pasteableCommand, It as buildForceUnlockCommand, J as DELETION_PROTECTION_DOC_POINTER, Jn as isNameCooldownError, Kn as hasReplayMayCollide, Kt as injectiveKey, L as ProtectionFlipRegistry, Ln as physicalIdShownBesideCommand, M as quotedRemedyLogicalId, Mn as UNSHOWABLE_VALUE, Mt as markCreatedBeforeFailure, N as refusalTypeShown, Nn as commandHole, Ot as hasCreatedBeforeFailure, Pt as replayMadeAnotherResource, Q as pasteableAwsCommand, Qn as markReplayMayCollide, Qt as ambientClientDefaults, R as compensateProtectionFlip, Rn as plainOrDescribed, St as withDerivedNameMasks, T as RESOURCE_NOT_FOUND, U as protectionFlipKey, Ut as sanitizeRecoveryValue, Vn as shellQuote, Vt as formatLockOwner, Wt as CUSTOM_RESOURCE_RESPONSE_PREFIX, Xn as isReplayedNameCollisionFrom, Yn as isRecreateRetryableError, Yt as producerRecordKey, Zt as withPasteableAwsProfile, _t as createMaskedLogSinks, ar as isRetryableTransientError, at as startInterruptWatch, bn as ResourceUpdateNotSupportedError, bt as maskDeep, ct as canonicalizeRoute53QueryName, d as prepareRemovalForUpdate, dr as markNonRetryable, en as clientDefaultsFor, er as formatRetryClassificationSignals, f as removalWarning, fr as markRedactedCause, ft as logicalIdShown, gt as stateOrphanRecordRemedy, hn as MalformedProducerRecordRefusalError, ht as segmentAfterAnchor, i as holdsSecretDerivedEntry, in as CdkdError, ir as isIamPropagationError, it as isInterruptedWaitError, j as normalizeAwsTagsToCfn, jn as SHELL_ACTIVE_WHY, jt as markAuxiliaryFailure, kt as isAuxiliaryFailure, l as withUnchangedSecretPrincipalLists, ln as DynamicReferenceRegionAmbiguousError, lr as isMarkedNonRetryable, m as withoutInjectedRemovals, mn as MacroExpansionError, mt as resourceTypeShown, nn as AccountIdUnavailableError, nr as isAmbiguousOutcomeError, on as CrossAccountSecretRefusalError, or as isTransientServerError, ot as ElapsedBudgetRegistry, pn as LockError, pr as wrapMaskedAwsError, qn as isNameCollisionErrorFrom, rn as AssetError, sn as DependencyError, sr as retryClassificationText, st as monotonicNowMs, tn as credentialFingerprint, tr as isAmbiguousCcHandlerErrorCode, un as IntrinsicResolutionRefusalError, ur as isThrottlingError, ut as compositeIdSeparatorRefusal, vn as ProvisioningError, vt as createMaskedRetryLogger, w as withoutServerErrorRetries, wn as SynthesisError, wt as carryCreatedBeforeFailure, xt as maskerOrIdentity, yn as ResourceTimeoutError, yt as isSecretDerivedValue, z as deleteWithProtectionCompensation, zn as quotedOrDescribed, zt as formatLockExpiry } from "./iam-policy-targets-BkeM7IXi.js";
4
4
  import { a as setAssumedRoleCredentials, i as getPreAssumeEnvCredentials, n as awsClientDefaults, o as setPreAssumeEnvCredentials, r as getAssumedRoleCredentials, s as ambientRegion, t as SECOND_ROLE_PUBLISH_REFUSAL } from "./aws-client-defaults-DBXBcg0J.js";
5
- import { t as getCdkdVersion } from "./version-DUYEmFtp.js";
5
+ import { t as getCdkdVersion } from "./version-Bft5jrTk.js";
6
6
  import { createHash, randomUUID } from "node:crypto";
7
7
  import { AsyncLocalStorage } from "node:async_hooks";
8
8
  import { CreateBucketCommand, DeleteObjectCommand, DeleteObjectsCommand, GetBucketLifecycleConfigurationCommand, GetBucketLocationCommand, GetBucketReplicationCommand, GetObjectCommand, HeadBucketCommand, HeadObjectCommand, ListObjectVersionsCommand, ListObjectsV2Command, NoSuchKey, PutBucketEncryptionCommand, PutBucketLifecycleConfigurationCommand, PutBucketPolicyCommand, PutObjectCommand, PutPublicAccessBlockCommand, S3Client, S3ServiceException } from "@aws-sdk/client-s3";
@@ -7888,6 +7888,10 @@ function isStrictlyInsideASpan(spans, start, end) {
7888
7888
  return spans.some((span) => span.start <= start && end <= span.end && (span.start !== start || span.end !== end));
7889
7889
  }
7890
7890
  function embedsNeedleOutsideReferences(leaf, needles, secrets) {
7891
+ return needleOccurrencesOutsideReferences(leaf, needles, secrets, true).length > 0;
7892
+ }
7893
+ function needleOccurrencesOutsideReferences(leaf, needles, secrets, first) {
7894
+ const found = [];
7891
7895
  let spans;
7892
7896
  let names;
7893
7897
  for (const needle of needles) for (let at = leaf.indexOf(needle); at >= 0; at = leaf.indexOf(needle, at + 1)) {
@@ -7896,9 +7900,19 @@ function embedsNeedleOutsideReferences(leaf, needles, secrets) {
7896
7900
  names ??= physicalNameSpans(physicalNameCopiesOf.get(secrets), leaf);
7897
7901
  const end = at + needle.length;
7898
7902
  if (names.some((n) => n.start <= at && end <= n.end)) continue;
7899
- return true;
7903
+ found.push({
7904
+ start: at,
7905
+ end
7906
+ });
7907
+ if (first) return found;
7900
7908
  }
7901
- return false;
7909
+ return found;
7910
+ }
7911
+ function cutsContainmentNeedle(leaf, secrets, redacted) {
7912
+ if (redacted.length === 0) return false;
7913
+ const needles = containmentNeedlesOf(secrets);
7914
+ if (needles.length === 0) return false;
7915
+ return needleOccurrencesOutsideReferences(leaf, needles, secrets, false).some((c) => redacted.some((m) => m.start < c.end && c.start < m.end && !(m.start <= c.start && c.end <= m.end)));
7902
7916
  }
7903
7917
  function flattenEmbeddedNoEchoLeaves(value, secrets) {
7904
7918
  const needles = containmentNeedlesOf(secrets);
@@ -9253,14 +9267,29 @@ function redactSecretsForStatePasses(bag, secrets, source, rules) {
9253
9267
  const physicalNames = physicalNameCopiesOf.get(secrets);
9254
9268
  let vouched;
9255
9269
  const vouchedExpressions = () => vouched ??= new Set(secrets.values());
9270
+ const expressionFor = (match) => {
9271
+ return secrets.get(match) ?? "***";
9272
+ };
9256
9273
  const scanLeaf = (value, needles) => {
9257
9274
  const spans = isDynamicReferenceString(value) ? resolvableReferenceSpans(value, vouchedExpressions()) : [];
9258
9275
  const names = physicalNameSpans(physicalNames, value);
9276
+ const kept = (start, end) => isStrictlyInsideASpan(spans, start, end) || names.some((n) => n.start <= start && end <= n.end);
9277
+ if (!legacyOverlapScan.has(secrets)) {
9278
+ const matches = everyMatch(value, needles);
9279
+ const redacted = matches.filter((m) => !kept(m.start, m.end));
9280
+ if (cutsContainmentNeedle(value, secrets, redacted)) {
9281
+ overlapAnswered.add(secrets);
9282
+ return "***";
9283
+ }
9284
+ const overlapping = redactOverlappingMatches(value, matches, redacted, expressionFor);
9285
+ if (overlapping !== void 0) {
9286
+ overlapAnswered.add(secrets);
9287
+ return overlapping;
9288
+ }
9289
+ }
9259
9290
  return value.replace(needles, (match, offset) => {
9260
- if (isStrictlyInsideASpan(spans, offset, offset + match.length)) return match;
9261
- const end = offset + match.length;
9262
- if (names.some((n) => n.start <= offset && end <= n.end)) return match;
9263
- return secrets.get(match) ?? "***";
9291
+ if (kept(offset, offset + match.length)) return match;
9292
+ return expressionFor(match);
9264
9293
  });
9265
9294
  };
9266
9295
  const walk = (value) => {
@@ -9290,6 +9319,113 @@ function redactSecretsForStatePasses(bag, secrets, source, rules) {
9290
9319
  };
9291
9320
  return walk(bag);
9292
9321
  }
9322
+ const legacyOverlapScan = /* @__PURE__ */ new WeakSet();
9323
+ const overlapAnswered = /* @__PURE__ */ new WeakSet();
9324
+ function overlapRuleAnswered(secrets) {
9325
+ return overlapAnswered.has(secrets);
9326
+ }
9327
+ function withLegacyOverlapScan(secrets, run) {
9328
+ if (legacyOverlapScan.has(secrets)) return run();
9329
+ legacyOverlapScan.add(secrets);
9330
+ try {
9331
+ return run();
9332
+ } finally {
9333
+ legacyOverlapScan.delete(secrets);
9334
+ }
9335
+ }
9336
+ function differingStringLeaves(legacy, current, out = []) {
9337
+ if (typeof legacy === "string" && typeof current === "string") {
9338
+ if (legacy !== current) out.push([legacy, current]);
9339
+ return out;
9340
+ }
9341
+ if (Array.isArray(legacy) && Array.isArray(current) && legacy.length === current.length) {
9342
+ legacy.forEach((item, i) => differingStringLeaves(item, current[i], out));
9343
+ return out;
9344
+ }
9345
+ if (legacy !== null && current !== null && typeof legacy === "object" && typeof current === "object" && !Array.isArray(legacy) && !Array.isArray(current)) {
9346
+ const c = current;
9347
+ for (const [key, value] of Object.entries(legacy)) if (Object.hasOwn(c, key)) differingStringLeaves(value, c[key], out);
9348
+ }
9349
+ return out;
9350
+ }
9351
+ function legacyReferenceLeavesOnly(legacy) {
9352
+ if (typeof legacy === "string") return legacy.includes("{{resolve:") ? legacy : void 0;
9353
+ if (Array.isArray(legacy)) return legacy.map(legacyReferenceLeavesOnly);
9354
+ if (legacy !== null && typeof legacy === "object") {
9355
+ const out = Object.create(null);
9356
+ for (const [key, value] of Object.entries(legacy)) out[key] = legacyReferenceLeavesOnly(value);
9357
+ return out;
9358
+ }
9359
+ return legacy;
9360
+ }
9361
+ function replaceWholeLeaves(value, pairs) {
9362
+ if (pairs.length === 0) return value;
9363
+ if (typeof value === "string") {
9364
+ const hit = pairs.find(([legacy]) => legacy === value);
9365
+ return hit === void 0 ? value : hit[1];
9366
+ }
9367
+ if (Array.isArray(value)) {
9368
+ let changed = false;
9369
+ const out = value.map((item) => {
9370
+ const next = replaceWholeLeaves(item, pairs);
9371
+ if (next !== item) changed = true;
9372
+ return next;
9373
+ });
9374
+ return changed ? out : value;
9375
+ }
9376
+ if (value !== null && typeof value === "object") {
9377
+ let out;
9378
+ for (const [key, item] of Object.entries(value)) {
9379
+ const next = replaceWholeLeaves(item, pairs);
9380
+ if (next !== item) {
9381
+ out ??= Object.assign(Object.create(null), value);
9382
+ out[key] = next;
9383
+ }
9384
+ }
9385
+ return out ?? value;
9386
+ }
9387
+ return value;
9388
+ }
9389
+ function everyMatch(value, needles) {
9390
+ const matches = [];
9391
+ needles.lastIndex = 0;
9392
+ for (let m = needles.exec(value); m !== null; m = needles.exec(value)) {
9393
+ matches.push({
9394
+ start: m.index,
9395
+ end: m.index + m[0].length
9396
+ });
9397
+ needles.lastIndex = m.index + 1;
9398
+ }
9399
+ needles.lastIndex = 0;
9400
+ return matches;
9401
+ }
9402
+ function redactOverlappingMatches(value, matches, redacted, expressionFor) {
9403
+ let reach = 0;
9404
+ let overlap = false;
9405
+ for (const m of matches) {
9406
+ if (m.start < reach) overlap = true;
9407
+ reach = Math.max(reach, m.end);
9408
+ }
9409
+ if (!overlap) return void 0;
9410
+ let out = "";
9411
+ let cursor = 0;
9412
+ for (let i = 0; i < redacted.length;) {
9413
+ let end = redacted[i].end;
9414
+ let j = i + 1;
9415
+ for (; j < redacted.length && redacted[j].start < end; j++) end = Math.max(end, redacted[j].end);
9416
+ const cluster = redacted.slice(i, j);
9417
+ out += value.slice(cursor, cluster[0].start);
9418
+ for (let at = cluster[0].start; at < end;) {
9419
+ const tile = cluster.find((m) => m.start === at);
9420
+ if (tile === void 0) return "***";
9421
+ out += expressionFor(value.slice(tile.start, tile.end));
9422
+ at = tile.end;
9423
+ }
9424
+ cursor = end;
9425
+ i = j;
9426
+ }
9427
+ return out + value.slice(cursor);
9428
+ }
9293
9429
  function scrubResourceRecord(record, secrets, sourceProperties, observedRules) {
9294
9430
  if (secrets.size === 0 && sourceProperties === void 0 && !record.observedProperties) return record;
9295
9431
  const next = { ...record };
@@ -10421,6 +10557,43 @@ function noEchoCoordinatesOf(template, resolved, sources, onCoordinate) {
10421
10557
  walk(template, resolved, []);
10422
10558
  return coordinates;
10423
10559
  }
10560
+ function noEchoParameterNodesAt(templateProperties, shape, noEchoParameters, conditions) {
10561
+ const nodes = /* @__PURE__ */ new Map();
10562
+ noEchoCoordinatesOf(templateProperties ?? {}, shape, {
10563
+ parameters: noEchoParameters,
10564
+ ...conditions !== void 0 && { conditions }
10565
+ }, (coordinate, node) => nodes.set(canonicalJson$3(coordinate), {
10566
+ coordinate,
10567
+ node
10568
+ }));
10569
+ return nodes;
10570
+ }
10571
+ function recordedNoEchoValuesOf(templateProperties, record, noEchoParameterNames, conditions) {
10572
+ const bag = /* @__PURE__ */ new Map();
10573
+ const properties = record?.properties;
10574
+ if (properties === null || typeof properties !== "object") return bag;
10575
+ const coordinates = /* @__PURE__ */ new Map();
10576
+ if (noEchoParameterNames.size > 0 && templateProperties !== void 0) for (const [key, { coordinate }] of noEchoParameterNodesAt(templateProperties, properties, noEchoParameterNames, conditions)) coordinates.set(key, coordinate);
10577
+ for (const coordinate of noEchoLeavesOf(record ?? {}) ?? []) coordinates.set(canonicalJson$3(coordinate), coordinate);
10578
+ const recordLeaf = (leaf) => {
10579
+ if (typeof leaf === "string") {
10580
+ if (leaf === "***" || leaf.includes("{{resolve:")) return;
10581
+ recordLogOnlyValue(bag, leaf);
10582
+ } else if (typeof leaf === "number") recordLogOnlyValue(bag, String(leaf));
10583
+ };
10584
+ const seen = /* @__PURE__ */ new Set();
10585
+ const walk = (value) => {
10586
+ if (value === null || typeof value !== "object") {
10587
+ recordLeaf(value);
10588
+ return;
10589
+ }
10590
+ if (seen.has(value)) return;
10591
+ seen.add(value);
10592
+ for (const child of Object.values(value)) walk(child);
10593
+ };
10594
+ for (const coordinate of coordinates.values()) walk(valueAtCoordinate(properties, coordinate));
10595
+ return bag;
10596
+ }
10424
10597
  function maskWholeValue(value) {
10425
10598
  if (value === null || value === void 0) return value;
10426
10599
  if (typeof value === "string" && isSingleDynamicReferenceToken(value)) return value;
@@ -15007,6 +15180,7 @@ const PROPERTY_COVERAGE_BY_TYPE = /* @__PURE__ */ new Map([
15007
15180
  "Unit"
15008
15181
  ]),
15009
15182
  silentDrop: /* @__PURE__ */ new Map([
15183
+ ["ActionConfiguration", "not yet implemented by cdkd"],
15010
15184
  ["EvaluationCriteria", "Absent from both the SDK PutMetricAlarm input and the aws-cdk-lib CfnAlarm L1 (a newer CFn-schema-only property ahead of SDK/CDK support); no wire path to forward it and no CDK app can emit it."],
15011
15185
  ["EvaluationInterval", "Absent from both the SDK PutMetricAlarm input and the aws-cdk-lib CfnAlarm L1 (a newer CFn-schema-only property ahead of SDK/CDK support); no wire path to forward it and no CDK app can emit it."],
15012
15186
  ["EvaluationWindow", "not yet implemented by cdkd"],
@@ -21515,7 +21689,7 @@ function withheldRemedy(context) {
21515
21689
  if (context?.attributeHealer?.readOnly === true) return `This preview re-read the resource through Cloud Control, but withheld the value: ${confirm} Grant the credentials the preview runs with cloudformation:DescribeType and run the diff again (a deploy's own read needs the same permission); if they already have it, the name is a writable property rather than an attribute — reference the value the template sets instead.`;
21516
21690
  return `cdkd re-read the resource through Cloud Control, but withheld the value: ${confirm} Grant the deploy role cloudformation:DescribeType and deploy again; if the role already has it, the name is a writable property rather than an attribute — reference the value the template sets instead.`;
21517
21691
  }
21518
- async function healStaleAttributes$1(logicalId, resource, context) {
21692
+ async function healStaleAttributes(logicalId, resource, context) {
21519
21693
  if (context.attributeHealer === void 0) return void 0;
21520
21694
  try {
21521
21695
  return await context.attributeHealer(logicalId, resource);
@@ -24428,7 +24602,7 @@ IntrinsicFunctionResolver.prototype.staleRecordRemedy = staleRecordRemedy;
24428
24602
  IntrinsicFunctionResolver.prototype.unenrichedRemedy = unenrichedRemedy;
24429
24603
  IntrinsicFunctionResolver.prototype.healWithheld = healWithheld;
24430
24604
  IntrinsicFunctionResolver.prototype.withheldRemedy = withheldRemedy;
24431
- IntrinsicFunctionResolver.prototype.healStaleAttributes = healStaleAttributes$1;
24605
+ IntrinsicFunctionResolver.prototype.healStaleAttributes = healStaleAttributes;
24432
24606
  IntrinsicFunctionResolver.prototype.usableHealedAttribute = usableHealedAttribute;
24433
24607
  IntrinsicFunctionResolver.prototype.serveHealedAttribute = serveHealedAttribute;
24434
24608
  IntrinsicFunctionResolver.prototype.constructWithStaleRecordHeal = constructWithStaleRecordHeal;
@@ -26878,7 +27052,7 @@ var CloudControlProvider = class {
26878
27052
  const indeterminateGuard = await this.confirmDeleteTargetIdentity(logicalId, resourceType, physicalId, context);
26879
27053
  if (context?.removeProtection === true && resourceType === "AWS::AutoScaling::AutoScalingGroup") {
26880
27054
  this.logger.debug(`Delegating protected AutoScalingGroup ${logicalId} delete to the SDK ASGProvider (Cloud Control cannot force-delete a protected ASG)`);
26881
- const { ASGProvider } = await import("./asg-provider--t5d-gjf.js");
27055
+ const { ASGProvider } = await import("./asg-provider--GY-B-zI.js");
26882
27056
  const delegateRegion = ambientRegion();
26883
27057
  let asgProvider = this.asgDeleteDelegates.get(delegateRegion);
26884
27058
  if (asgProvider === void 0) {
@@ -26984,7 +27158,7 @@ var CloudControlProvider = class {
26984
27158
  const family = SDK_DELETE_FAMILIES.get(resourceType);
26985
27159
  const cached = this.sdkDeleteDelegates.get(family);
26986
27160
  if (cached !== void 0 && cached.region === ccRegion) return cached.provider;
26987
- const provider = family === "rds" ? new (await (import("./rds-provider-BvZhdkOC.js"))).RDSProvider({ region: ccRegion }) : new (await (import("./neptune-provider-DjEVKBcV.js"))).NeptuneProvider({ region: ccRegion });
27161
+ const provider = family === "rds" ? new (await (import("./rds-provider-DI_O0_iG.js"))).RDSProvider({ region: ccRegion }) : new (await (import("./neptune-provider-DoKgbZCz.js"))).NeptuneProvider({ region: ccRegion });
26988
27162
  this.sdkDeleteDelegates.set(family, {
26989
27163
  region: ccRegion,
26990
27164
  provider
@@ -27813,7 +27987,7 @@ var IdScrubLog = class {
27813
27987
  ...masked.filter((m, i) => m !== "" && m !== raw[i] && m !== "***")
27814
27988
  ])].sort((a, b) => b.length - a.length);
27815
27989
  }
27816
- scrub = (text) => this.needles.reduce((out, needle) => out.split(needle).join("***"), this.mask(text));
27990
+ scrub = (text) => maskMatchSpans(this.mask(text), this.needles, "***");
27817
27991
  scrubKeepingResume(text, requestTokens) {
27818
27992
  const tokens = requestTokens.filter((token) => token !== "");
27819
27993
  if (tokens.length === 0) return this.scrub(text);
@@ -28143,14 +28317,6 @@ function recordLeaves(bag, value) {
28143
28317
  }
28144
28318
  recordLogOnlyParameterValue(bag, value);
28145
28319
  }
28146
- function templateNodesAt(templateProperties, shape, noEchoParameters, conditions) {
28147
- const nodes = /* @__PURE__ */ new Map();
28148
- noEchoCoordinatesOf(templateProperties ?? {}, shape, {
28149
- parameters: noEchoParameters,
28150
- ...conditions !== void 0 && { conditions }
28151
- }, (coordinate, node) => nodes.set(canonicalJson$3(coordinate), node));
28152
- return nodes;
28153
- }
28154
28320
  async function fingerprintsUnchanged(record, templateProperties, coordinate, fingerprinter) {
28155
28321
  const key = coordinate[0];
28156
28322
  if (typeof key !== "string") return false;
@@ -28172,7 +28338,7 @@ async function noEchoDeleteValuesFromResolved(options) {
28172
28338
  if (masked.length === 0 || templateResource === void 0 || resolvedProperties === void 0) return;
28173
28339
  if (templateResource.Type !== record.resourceType) return void 0;
28174
28340
  if (carriesResolvedSecret(options.secrets)) return void 0;
28175
- const nodes = templateNodesAt(templateResource.Properties, resolvedProperties, options.noEchoParameters, options.conditions);
28341
+ const nodes = noEchoParameterNodesAt(templateResource.Properties, resolvedProperties, options.noEchoParameters, options.conditions);
28176
28342
  const bag = new Map(options.secrets);
28177
28343
  carryLogOnlyValues(options.secrets, bag);
28178
28344
  const templateProps = isRecord(templateResource.Properties) ? templateResource.Properties : {};
@@ -28337,6 +28503,11 @@ var TemplateNoEchoReresolver = class TemplateNoEchoReresolver {
28337
28503
  }
28338
28504
  return bag;
28339
28505
  }
28506
+ recordedNoEchoValuesFor(logicalId, record) {
28507
+ const resources = this.options.template.Resources;
28508
+ const templateResource = resources !== void 0 && resources !== null && Object.hasOwn(resources, logicalId) ? resources[logicalId] : void 0;
28509
+ return recordedNoEchoValuesOf(templateResource?.Type === record?.resourceType ? templateResource?.Properties : void 0, record, this.noEchoParameters, void 0);
28510
+ }
28340
28511
  async valuesFor(logicalId, record) {
28341
28512
  const masked = maskedNoEchoCoordinates(record.properties, noEchoLeavesOf(record));
28342
28513
  if (masked.length === 0) return void 0;
@@ -28345,7 +28516,7 @@ var TemplateNoEchoReresolver = class TemplateNoEchoReresolver {
28345
28516
  if (templateResource?.Type !== record.resourceType) return void 0;
28346
28517
  const parameters = await this.boundParameters();
28347
28518
  if (parameters === void 0) return void 0;
28348
- const nodes = templateNodesAt(templateResource.Properties, record.properties, this.noEchoParameters, void 0);
28519
+ const nodes = noEchoParameterNodesAt(templateResource.Properties, record.properties, this.noEchoParameters, void 0);
28349
28520
  const declared = new Set(Object.keys(this.options.template.Parameters ?? {}));
28350
28521
  const templateProps = isRecord(templateResource.Properties) ? templateResource.Properties : {};
28351
28522
  const fingerprinter = inputFingerprinter(templateProps, this.inputSources(parameters));
@@ -28355,7 +28526,7 @@ var TemplateNoEchoReresolver = class TemplateNoEchoReresolver {
28355
28526
  for (const coordinate of masked) {
28356
28527
  const key = canonicalJson$3(coordinate);
28357
28528
  if (!nodes.has(key)) continue;
28358
- const node = nodes.get(key);
28529
+ const node = nodes.get(key)?.node;
28359
28530
  if (!readsParametersOnly(node, declared, refused)) continue;
28360
28531
  if (!await fingerprintsUnchanged(record, templateProps, coordinate, fingerprinter)) continue;
28361
28532
  let value;
@@ -28656,6 +28827,22 @@ function describeWaiterFailure(error, rejections) {
28656
28827
  if (withheld !== void 0) return withheld;
28657
28828
  return `${error instanceof Error ? error.name : "Error"} (no function status reported). The waiter's raw payload is withheld because it embeds the whole GetFunction response, environment variables included; run \`aws lambda get-function\` for the detail.`;
28658
28829
  }
28830
+ async function waitForLambdaFunctionActive(client, functionArn, abortSignal) {
28831
+ const rejections = new WaiterRejections();
28832
+ try {
28833
+ await waitUntilFunctionActiveV2({
28834
+ client: observingLambdaClient(client, rejections),
28835
+ maxWaitTime: 600,
28836
+ minDelay: 1,
28837
+ maxDelay: 5,
28838
+ ...abortSignal ? { abortSignal } : {}
28839
+ }, { FunctionName: functionArn });
28840
+ } catch (error) {
28841
+ const log = getLogger().child("LambdaActiveWait");
28842
+ for (const line of waiterRejectionDebugLines(rejections)) log.debug(safeMsg`Active waiter for ${functionArn} observed ${line}`);
28843
+ throw markNonRetryable(new Error(`Lambda function ${functionArn} did not reach the Active state: ${describeWaiterFailure(error, rejections)}`, { cause: error }));
28844
+ }
28845
+ }
28659
28846
  const CR_TRANSIENT_AUTHZ_SIGNALS = [
28660
28847
  "not authorized to perform",
28661
28848
  "no identity-based policy allows",
@@ -28847,7 +29034,7 @@ var CustomResourceProvider = class CustomResourceProvider {
28847
29034
  } catch (error) {
28848
29035
  markAuxiliaryFailure(error, logicalId);
28849
29036
  const cause = error instanceof Error ? error : void 0;
28850
- throw new ProvisioningError(`Failed to create custom resource ${logicalId}: ${error instanceof Error ? error.message : String(error)}`, resourceType, logicalId, void 0, cause);
29037
+ throw new ProvisioningError(`Failed to create custom resource ${logicalId}: ${describeAwsFailure(error).detail}`, resourceType, logicalId, void 0, cause);
28851
29038
  }
28852
29039
  }
28853
29040
  async update(logicalId, physicalId, resourceType, properties, previousProperties, context) {
@@ -28881,7 +29068,7 @@ var CustomResourceProvider = class CustomResourceProvider {
28881
29068
  };
28882
29069
  } catch (error) {
28883
29070
  const cause = error instanceof Error ? error : void 0;
28884
- throw new ProvisioningError(`Failed to update custom resource ${logicalId}: ${error instanceof Error ? error.message : String(error)}`, resourceType, logicalId, physicalId, cause);
29071
+ throw new ProvisioningError(`Failed to update custom resource ${logicalId}: ${describeAwsFailure(error).detail}`, resourceType, logicalId, physicalId, cause);
28885
29072
  }
28886
29073
  }
28887
29074
  async delete(logicalId, physicalId, resourceType, properties, context) {
@@ -29220,7 +29407,7 @@ var CustomResourceProvider = class CustomResourceProvider {
29220
29407
  sleep: customResourceRetryDelays.sleep
29221
29408
  });
29222
29409
  } catch (error) {
29223
- throw markNonRetryable(error instanceof Error ? error : new Error(String(error)));
29410
+ throw markNonRetryable(error instanceof Error ? error : new Error(safeStringify$1(error)));
29224
29411
  }
29225
29412
  const command = new PutObjectCommand({
29226
29413
  Bucket: this.responseBucket,
@@ -29460,6 +29647,17 @@ const NESTED_REQUIRED = /* @__PURE__ */ new Map([
29460
29647
  ["EvaluatorConfig.LlmAsAJudge.ModelConfig.BedrockEvaluatorModelConfig", ["ModelId"]],
29461
29648
  ["EvaluatorConfig.LlmAsAJudge.ModelConfig.ResponsesEvaluatorModelConfig", ["ModelId"]],
29462
29649
  ["EvaluatorConfig.LlmAsAJudge.RatingScale.Categorical", ["Definition", "Label"]],
29650
+ ["EvaluatorConfig.LlmAsAJudge.RatingScale.MultiDimensional", [
29651
+ "DimensionInstruction",
29652
+ "DimensionName",
29653
+ "DimensionRatingScale"
29654
+ ]],
29655
+ ["EvaluatorConfig.LlmAsAJudge.RatingScale.MultiDimensional.DimensionRatingScale.Categorical", ["Definition", "Label"]],
29656
+ ["EvaluatorConfig.LlmAsAJudge.RatingScale.MultiDimensional.DimensionRatingScale.Numerical", [
29657
+ "Definition",
29658
+ "Label",
29659
+ "Value"
29660
+ ]],
29463
29661
  ["EvaluatorConfig.LlmAsAJudge.RatingScale.Numerical", [
29464
29662
  "Definition",
29465
29663
  "Label",
@@ -29569,6 +29767,7 @@ const NESTED_REQUIRED = /* @__PURE__ */ new Map([
29569
29767
  ["Tags", ["Key", "Value"]]
29570
29768
  ])],
29571
29769
  ["AWS::CloudWatch::Alarm", /* @__PURE__ */ new Map([
29770
+ ["ActionConfiguration.AlarmTagsPropagation", ["Enabled"]],
29572
29771
  ["Dimensions", ["Name", "Value"]],
29573
29772
  ["Metrics", ["Id"]],
29574
29773
  ["Metrics.MetricStat", [
@@ -30894,7 +31093,7 @@ const PROPERTY_SHAPES = /* @__PURE__ */ new Map([
30894
31093
  ["AWS::AppSync::GraphQLApi", "{\"AdditionalAuthenticationProviders\":\"array\",\"AdditionalAuthenticationProviders[]\":\"object\",\"AdditionalAuthenticationProviders[].LambdaAuthorizerConfig\":\"object\",\"AdditionalAuthenticationProviders[].OpenIDConnectConfig\":\"object\",\"AdditionalAuthenticationProviders[].UserPoolConfig\":\"object\",\"EnhancedMetricsConfig\":\"object\",\"EnvironmentVariables\":\"object\",\"LambdaAuthorizerConfig\":\"object\",\"LogConfig\":\"object\",\"OpenIDConnectConfig\":\"object\",\"Tags\":\"array\",\"Tags[]\":\"object\",\"UserPoolConfig\":\"object\"}"],
30895
31094
  ["AWS::AppSync::Resolver", "{\"CachingConfig\":\"object\",\"CachingConfig.CachingKeys\":\"array\",\"PipelineConfig\":\"object\",\"PipelineConfig.Functions\":\"array\",\"Runtime\":\"object\",\"SyncConfig\":\"object\",\"SyncConfig.LambdaConflictHandlerConfig\":\"object\"}"],
30896
31095
  ["AWS::AutoScaling::AutoScalingGroup", "{\"AvailabilityZoneDistribution\":\"object\",\"AvailabilityZoneIds\":\"array\",\"AvailabilityZoneImpairmentPolicy\":\"object\",\"AvailabilityZones\":\"array\",\"CapacityReservationSpecification\":\"object\",\"CapacityReservationSpecification.CapacityReservationTarget\":\"object\",\"CapacityReservationSpecification.CapacityReservationTarget.CapacityReservationIds\":\"array\",\"CapacityReservationSpecification.CapacityReservationTarget.CapacityReservationResourceGroupArns\":\"array\",\"InstanceLifecyclePolicy\":\"object\",\"InstanceLifecyclePolicy.RetentionTriggers\":\"object\",\"InstanceMaintenancePolicy\":\"object\",\"LaunchTemplate\":\"object\",\"LifecycleHookSpecificationList\":\"array\",\"LifecycleHookSpecificationList[]\":\"object\",\"LoadBalancerNames\":\"array\",\"MetricsCollection\":\"array\",\"MetricsCollection[]\":\"object\",\"MetricsCollection[].Metrics\":\"array\",\"MixedInstancesPolicy\":\"object\",\"MixedInstancesPolicy.InstancesDistribution\":\"object\",\"MixedInstancesPolicy.InstancesDistribution.DistributionSegments\":\"array\",\"MixedInstancesPolicy.InstancesDistribution.DistributionSegments[]\":\"object\",\"MixedInstancesPolicy.InstancesDistribution.DistributionSegments[].TargetCapacityTypes\":\"array\",\"MixedInstancesPolicy.LaunchTemplate\":\"object\",\"MixedInstancesPolicy.LaunchTemplate.LaunchTemplateSpecification\":\"object\",\"MixedInstancesPolicy.LaunchTemplate.Overrides\":\"array\",\"MixedInstancesPolicy.LaunchTemplate.Overrides[]\":\"object\",\"MixedInstancesPolicy.LaunchTemplate.Overrides[].InstanceRequirements\":\"object\",\"MixedInstancesPolicy.LaunchTemplate.Overrides[].InstanceRequirements.AcceleratorCount\":\"object\",\"MixedInstancesPolicy.LaunchTemplate.Overrides[].InstanceRequirements.AcceleratorManufacturers\":\"array\",\"MixedInstancesPolicy.LaunchTemplate.Overrides[].InstanceRequirements.AcceleratorNames\":\"array\",\"MixedInstancesPolicy.LaunchTemplate.Overrides[].InstanceRequirements.AcceleratorTotalMemoryMiB\":\"object\",\"MixedInstancesPolicy.LaunchTemplate.Overrides[].InstanceRequirements.AcceleratorTypes\":\"array\",\"MixedInstancesPolicy.LaunchTemplate.Overrides[].InstanceRequirements.AllowedInstanceTypes\":\"array\",\"MixedInstancesPolicy.LaunchTemplate.Overrides[].InstanceRequirements.BaselineEbsBandwidthMbps\":\"object\",\"MixedInstancesPolicy.LaunchTemplate.Overrides[].InstanceRequirements.BaselinePerformanceFactors\":\"object\",\"MixedInstancesPolicy.LaunchTemplate.Overrides[].InstanceRequirements.BaselinePerformanceFactors.Cpu\":\"object\",\"MixedInstancesPolicy.LaunchTemplate.Overrides[].InstanceRequirements.BaselinePerformanceFactors.Cpu.References\":\"array\",\"MixedInstancesPolicy.LaunchTemplate.Overrides[].InstanceRequirements.BaselinePerformanceFactors.Cpu.References[]\":\"object\",\"MixedInstancesPolicy.LaunchTemplate.Overrides[].InstanceRequirements.CpuManufacturers\":\"array\",\"MixedInstancesPolicy.LaunchTemplate.Overrides[].InstanceRequirements.ExcludedInstanceTypes\":\"array\",\"MixedInstancesPolicy.LaunchTemplate.Overrides[].InstanceRequirements.InstanceGenerations\":\"array\",\"MixedInstancesPolicy.LaunchTemplate.Overrides[].InstanceRequirements.LocalStorageTypes\":\"array\",\"MixedInstancesPolicy.LaunchTemplate.Overrides[].InstanceRequirements.MemoryGiBPerVCpu\":\"object\",\"MixedInstancesPolicy.LaunchTemplate.Overrides[].InstanceRequirements.MemoryMiB\":\"object\",\"MixedInstancesPolicy.LaunchTemplate.Overrides[].InstanceRequirements.NetworkBandwidthGbps\":\"object\",\"MixedInstancesPolicy.LaunchTemplate.Overrides[].InstanceRequirements.NetworkInterfaceCount\":\"object\",\"MixedInstancesPolicy.LaunchTemplate.Overrides[].InstanceRequirements.TotalLocalStorageGB\":\"object\",\"MixedInstancesPolicy.LaunchTemplate.Overrides[].InstanceRequirements.VCpuCount\":\"object\",\"MixedInstancesPolicy.LaunchTemplate.Overrides[].LaunchTemplateSpecification\":\"object\",\"NotificationConfiguration\":\"object\",\"NotificationConfiguration.NotificationTypes\":\"array\",\"NotificationConfigurations\":\"array\",\"NotificationConfigurations[]\":\"object\",\"NotificationConfigurations[].NotificationTypes\":\"array\",\"Tags\":\"array\",\"Tags[]\":\"object\",\"TargetGroupARNs\":\"array\",\"TerminationPolicies\":\"array\",\"TrafficSources\":\"array\",\"TrafficSources[]\":\"object\",\"VPCZoneIdentifier\":\"array\"}"],
30897
- ["AWS::BedrockAgentCore::Evaluator", "{\"EvaluatorConfig\":\"object\",\"EvaluatorConfig.CodeBased\":\"object\",\"EvaluatorConfig.CodeBased.LambdaConfig\":\"object\",\"EvaluatorConfig.Derived\":\"object\",\"EvaluatorConfig.Derived.ModelConfig\":\"object\",\"EvaluatorConfig.Derived.ModelConfig.BedrockEvaluatorModelConfig\":\"object\",\"EvaluatorConfig.Derived.ModelConfig.BedrockEvaluatorModelConfig.AdditionalModelRequestFields\":\"object\",\"EvaluatorConfig.Derived.ModelConfig.BedrockEvaluatorModelConfig.InferenceConfig\":\"object\",\"EvaluatorConfig.Derived.ModelConfig.BedrockEvaluatorModelConfig.InferenceConfig.StopSequences\":\"array\",\"EvaluatorConfig.Derived.ModelConfig.ResponsesEvaluatorModelConfig\":\"object\",\"EvaluatorConfig.Derived.ModelConfig.ResponsesEvaluatorModelConfig.Reasoning\":\"object\",\"EvaluatorConfig.LlmAsAJudge\":\"object\",\"EvaluatorConfig.LlmAsAJudge.ModelConfig\":\"object\",\"EvaluatorConfig.LlmAsAJudge.ModelConfig.BedrockEvaluatorModelConfig\":\"object\",\"EvaluatorConfig.LlmAsAJudge.ModelConfig.BedrockEvaluatorModelConfig.AdditionalModelRequestFields\":\"object\",\"EvaluatorConfig.LlmAsAJudge.ModelConfig.BedrockEvaluatorModelConfig.InferenceConfig\":\"object\",\"EvaluatorConfig.LlmAsAJudge.ModelConfig.BedrockEvaluatorModelConfig.InferenceConfig.StopSequences\":\"array\",\"EvaluatorConfig.LlmAsAJudge.ModelConfig.ResponsesEvaluatorModelConfig\":\"object\",\"EvaluatorConfig.LlmAsAJudge.ModelConfig.ResponsesEvaluatorModelConfig.Reasoning\":\"object\",\"EvaluatorConfig.LlmAsAJudge.RatingScale\":\"object\",\"EvaluatorConfig.LlmAsAJudge.RatingScale.Categorical\":\"array\",\"EvaluatorConfig.LlmAsAJudge.RatingScale.Categorical[]\":\"object\",\"EvaluatorConfig.LlmAsAJudge.RatingScale.Numerical\":\"array\",\"EvaluatorConfig.LlmAsAJudge.RatingScale.Numerical[]\":\"object\",\"Tags\":\"array\",\"Tags[]\":\"object\"}"],
31096
+ ["AWS::BedrockAgentCore::Evaluator", "{\"EvaluatorConfig\":\"object\",\"EvaluatorConfig.CodeBased\":\"object\",\"EvaluatorConfig.CodeBased.LambdaConfig\":\"object\",\"EvaluatorConfig.Derived\":\"object\",\"EvaluatorConfig.Derived.ModelConfig\":\"object\",\"EvaluatorConfig.Derived.ModelConfig.BedrockEvaluatorModelConfig\":\"object\",\"EvaluatorConfig.Derived.ModelConfig.BedrockEvaluatorModelConfig.AdditionalModelRequestFields\":\"object\",\"EvaluatorConfig.Derived.ModelConfig.BedrockEvaluatorModelConfig.InferenceConfig\":\"object\",\"EvaluatorConfig.Derived.ModelConfig.BedrockEvaluatorModelConfig.InferenceConfig.StopSequences\":\"array\",\"EvaluatorConfig.Derived.ModelConfig.ResponsesEvaluatorModelConfig\":\"object\",\"EvaluatorConfig.Derived.ModelConfig.ResponsesEvaluatorModelConfig.Reasoning\":\"object\",\"EvaluatorConfig.LlmAsAJudge\":\"object\",\"EvaluatorConfig.LlmAsAJudge.ModelConfig\":\"object\",\"EvaluatorConfig.LlmAsAJudge.ModelConfig.BedrockEvaluatorModelConfig\":\"object\",\"EvaluatorConfig.LlmAsAJudge.ModelConfig.BedrockEvaluatorModelConfig.AdditionalModelRequestFields\":\"object\",\"EvaluatorConfig.LlmAsAJudge.ModelConfig.BedrockEvaluatorModelConfig.InferenceConfig\":\"object\",\"EvaluatorConfig.LlmAsAJudge.ModelConfig.BedrockEvaluatorModelConfig.InferenceConfig.StopSequences\":\"array\",\"EvaluatorConfig.LlmAsAJudge.ModelConfig.ResponsesEvaluatorModelConfig\":\"object\",\"EvaluatorConfig.LlmAsAJudge.ModelConfig.ResponsesEvaluatorModelConfig.Reasoning\":\"object\",\"EvaluatorConfig.LlmAsAJudge.RatingScale\":\"object\",\"EvaluatorConfig.LlmAsAJudge.RatingScale.Categorical\":\"array\",\"EvaluatorConfig.LlmAsAJudge.RatingScale.Categorical[]\":\"object\",\"EvaluatorConfig.LlmAsAJudge.RatingScale.MultiDimensional\":\"array\",\"EvaluatorConfig.LlmAsAJudge.RatingScale.MultiDimensional[]\":\"object\",\"EvaluatorConfig.LlmAsAJudge.RatingScale.MultiDimensional[].DimensionRatingScale\":\"object\",\"EvaluatorConfig.LlmAsAJudge.RatingScale.MultiDimensional[].DimensionRatingScale.Categorical\":\"array\",\"EvaluatorConfig.LlmAsAJudge.RatingScale.MultiDimensional[].DimensionRatingScale.Categorical[]\":\"object\",\"EvaluatorConfig.LlmAsAJudge.RatingScale.MultiDimensional[].DimensionRatingScale.Numerical\":\"array\",\"EvaluatorConfig.LlmAsAJudge.RatingScale.MultiDimensional[].DimensionRatingScale.Numerical[]\":\"object\",\"EvaluatorConfig.LlmAsAJudge.RatingScale.Numerical\":\"array\",\"EvaluatorConfig.LlmAsAJudge.RatingScale.Numerical[]\":\"object\",\"Tags\":\"array\",\"Tags[]\":\"object\"}"],
30898
31097
  ["AWS::BedrockAgentCore::Runtime", "{\"AgentRuntimeArtifact\":\"object\",\"AgentRuntimeArtifact.CodeConfiguration\":\"object\",\"AgentRuntimeArtifact.CodeConfiguration.Code\":\"object\",\"AgentRuntimeArtifact.CodeConfiguration.Code.S3\":\"object\",\"AgentRuntimeArtifact.CodeConfiguration.EntryPoint\":\"array\",\"AgentRuntimeArtifact.ContainerConfiguration\":\"object\",\"AuthorizerConfiguration\":\"object\",\"AuthorizerConfiguration.CustomJWTAuthorizer\":\"object\",\"AuthorizerConfiguration.CustomJWTAuthorizer.AllowedAudience\":\"array\",\"AuthorizerConfiguration.CustomJWTAuthorizer.AllowedClients\":\"array\",\"AuthorizerConfiguration.CustomJWTAuthorizer.AllowedScopes\":\"array\",\"AuthorizerConfiguration.CustomJWTAuthorizer.AllowedWorkloadConfiguration\":\"object\",\"AuthorizerConfiguration.CustomJWTAuthorizer.AllowedWorkloadConfiguration.HostingEnvironments\":\"array\",\"AuthorizerConfiguration.CustomJWTAuthorizer.AllowedWorkloadConfiguration.HostingEnvironments[]\":\"object\",\"AuthorizerConfiguration.CustomJWTAuthorizer.AllowedWorkloadConfiguration.WorkloadIdentities\":\"array\",\"AuthorizerConfiguration.CustomJWTAuthorizer.CustomClaims\":\"array\",\"AuthorizerConfiguration.CustomJWTAuthorizer.CustomClaims[]\":\"object\",\"AuthorizerConfiguration.CustomJWTAuthorizer.CustomClaims[].AuthorizingClaimMatchValue\":\"object\",\"AuthorizerConfiguration.CustomJWTAuthorizer.CustomClaims[].AuthorizingClaimMatchValue.ClaimMatchValue\":\"object\",\"AuthorizerConfiguration.CustomJWTAuthorizer.CustomClaims[].AuthorizingClaimMatchValue.ClaimMatchValue.MatchValueStringList\":\"array\",\"AuthorizerConfiguration.CustomJWTAuthorizer.PrivateEndpoint\":\"object\",\"AuthorizerConfiguration.CustomJWTAuthorizer.PrivateEndpoint.ManagedVpcResource\":\"object\",\"AuthorizerConfiguration.CustomJWTAuthorizer.PrivateEndpoint.ManagedVpcResource.SecurityGroupIds\":\"array\",\"AuthorizerConfiguration.CustomJWTAuthorizer.PrivateEndpoint.ManagedVpcResource.SubnetIds\":\"array\",\"AuthorizerConfiguration.CustomJWTAuthorizer.PrivateEndpoint.ManagedVpcResource.Tags\":\"object\",\"AuthorizerConfiguration.CustomJWTAuthorizer.PrivateEndpoint.SelfManagedLatticeResource\":\"object\",\"AuthorizerConfiguration.CustomJWTAuthorizer.PrivateEndpointOverrides\":\"array\",\"AuthorizerConfiguration.CustomJWTAuthorizer.PrivateEndpointOverrides[]\":\"object\",\"AuthorizerConfiguration.CustomJWTAuthorizer.PrivateEndpointOverrides[].PrivateEndpoint\":\"object\",\"AuthorizerConfiguration.CustomJWTAuthorizer.PrivateEndpointOverrides[].PrivateEndpoint.ManagedVpcResource\":\"object\",\"AuthorizerConfiguration.CustomJWTAuthorizer.PrivateEndpointOverrides[].PrivateEndpoint.ManagedVpcResource.SecurityGroupIds\":\"array\",\"AuthorizerConfiguration.CustomJWTAuthorizer.PrivateEndpointOverrides[].PrivateEndpoint.ManagedVpcResource.SubnetIds\":\"array\",\"AuthorizerConfiguration.CustomJWTAuthorizer.PrivateEndpointOverrides[].PrivateEndpoint.ManagedVpcResource.Tags\":\"object\",\"AuthorizerConfiguration.CustomJWTAuthorizer.PrivateEndpointOverrides[].PrivateEndpoint.SelfManagedLatticeResource\":\"object\",\"CapacityProviderConfiguration\":\"object\",\"EnvironmentVariables\":\"object\",\"FilesystemConfigurations\":\"array\",\"FilesystemConfigurations[]\":\"object\",\"FilesystemConfigurations[].CapacityProviderVolume\":\"object\",\"FilesystemConfigurations[].EfsAccessPoint\":\"object\",\"FilesystemConfigurations[].S3FilesAccessPoint\":\"object\",\"FilesystemConfigurations[].SessionStorage\":\"object\",\"LifecycleConfiguration\":\"object\",\"NetworkConfiguration\":\"object\",\"NetworkConfiguration.NetworkModeConfig\":\"object\",\"NetworkConfiguration.NetworkModeConfig.SecurityGroups\":\"array\",\"NetworkConfiguration.NetworkModeConfig.Subnets\":\"array\",\"RequestHeaderConfiguration\":\"object\",\"RequestHeaderConfiguration.RequestHeaderAllowlist\":\"array\",\"Tags\":\"object\",\"WorkloadIdentityDetails\":\"object\"}"],
30899
31098
  ["AWS::Budgets::Budget", "{\"Budget\":\"object\",\"Budget.AutoAdjustData\":\"object\",\"Budget.AutoAdjustData.HistoricalOptions\":\"object\",\"Budget.BudgetLimit\":\"object\",\"Budget.CostFilters\":\"object\",\"Budget.CostTypes\":\"object\",\"Budget.FilterExpression\":\"object\",\"Budget.FilterExpression.And\":\"array\",\"Budget.FilterExpression.CostCategories\":\"object\",\"Budget.FilterExpression.CostCategories.MatchOptions\":\"array\",\"Budget.FilterExpression.CostCategories.Values\":\"array\",\"Budget.FilterExpression.Dimensions\":\"object\",\"Budget.FilterExpression.Dimensions.MatchOptions\":\"array\",\"Budget.FilterExpression.Dimensions.Values\":\"array\",\"Budget.FilterExpression.Or\":\"array\",\"Budget.FilterExpression.Tags\":\"object\",\"Budget.FilterExpression.Tags.MatchOptions\":\"array\",\"Budget.FilterExpression.Tags.Values\":\"array\",\"Budget.Metrics\":\"array\",\"Budget.PlannedBudgetLimits\":\"object\",\"Budget.TimePeriod\":\"object\",\"NotificationsWithSubscribers\":\"array\",\"NotificationsWithSubscribers[]\":\"object\",\"NotificationsWithSubscribers[].Notification\":\"object\",\"NotificationsWithSubscribers[].Subscribers\":\"array\",\"NotificationsWithSubscribers[].Subscribers[]\":\"object\",\"ResourceTags\":\"array\",\"ResourceTags[]\":\"object\"}"],
30900
31099
  ["AWS::CertificateManager::Certificate", "{\"DomainValidationOptions\":\"array\",\"DomainValidationOptions[]\":\"object\",\"SubjectAlternativeNames\":\"array\",\"Tags\":\"array\",\"Tags[]\":\"object\"}"],
@@ -30903,7 +31102,7 @@ const PROPERTY_SHAPES = /* @__PURE__ */ new Map([
30903
31102
  ["AWS::CloudFront::Distribution", "{\"DistributionConfig\":\"object\",\"DistributionConfig.Aliases\":\"array\",\"DistributionConfig.CNAMEs\":\"array\",\"DistributionConfig.CacheBehaviors\":\"array\",\"DistributionConfig.CacheBehaviors[]\":\"object\",\"DistributionConfig.CacheBehaviors[].AllowedMethods\":\"array\",\"DistributionConfig.CacheBehaviors[].CachedMethods\":\"array\",\"DistributionConfig.CacheBehaviors[].ForwardedValues\":\"object\",\"DistributionConfig.CacheBehaviors[].ForwardedValues.Cookies\":\"object\",\"DistributionConfig.CacheBehaviors[].ForwardedValues.Cookies.WhitelistedNames\":\"array\",\"DistributionConfig.CacheBehaviors[].ForwardedValues.Headers\":\"array\",\"DistributionConfig.CacheBehaviors[].ForwardedValues.QueryStringCacheKeys\":\"array\",\"DistributionConfig.CacheBehaviors[].FunctionAssociations\":\"array\",\"DistributionConfig.CacheBehaviors[].FunctionAssociations[]\":\"object\",\"DistributionConfig.CacheBehaviors[].GrpcConfig\":\"object\",\"DistributionConfig.CacheBehaviors[].LambdaFunctionAssociations\":\"array\",\"DistributionConfig.CacheBehaviors[].LambdaFunctionAssociations[]\":\"object\",\"DistributionConfig.CacheBehaviors[].TrustedKeyGroups\":\"array\",\"DistributionConfig.CacheBehaviors[].TrustedSigners\":\"array\",\"DistributionConfig.CacheTagConfig\":\"object\",\"DistributionConfig.ConnectionFunctionAssociation\":\"object\",\"DistributionConfig.CustomErrorResponses\":\"array\",\"DistributionConfig.CustomErrorResponses[]\":\"object\",\"DistributionConfig.CustomOrigin\":\"object\",\"DistributionConfig.CustomOrigin.OriginSSLProtocols\":\"array\",\"DistributionConfig.DefaultCacheBehavior\":\"object\",\"DistributionConfig.DefaultCacheBehavior.AllowedMethods\":\"array\",\"DistributionConfig.DefaultCacheBehavior.CachedMethods\":\"array\",\"DistributionConfig.DefaultCacheBehavior.ForwardedValues\":\"object\",\"DistributionConfig.DefaultCacheBehavior.ForwardedValues.Cookies\":\"object\",\"DistributionConfig.DefaultCacheBehavior.ForwardedValues.Cookies.WhitelistedNames\":\"array\",\"DistributionConfig.DefaultCacheBehavior.ForwardedValues.Headers\":\"array\",\"DistributionConfig.DefaultCacheBehavior.ForwardedValues.QueryStringCacheKeys\":\"array\",\"DistributionConfig.DefaultCacheBehavior.FunctionAssociations\":\"array\",\"DistributionConfig.DefaultCacheBehavior.FunctionAssociations[]\":\"object\",\"DistributionConfig.DefaultCacheBehavior.GrpcConfig\":\"object\",\"DistributionConfig.DefaultCacheBehavior.LambdaFunctionAssociations\":\"array\",\"DistributionConfig.DefaultCacheBehavior.LambdaFunctionAssociations[]\":\"object\",\"DistributionConfig.DefaultCacheBehavior.TrustedKeyGroups\":\"array\",\"DistributionConfig.DefaultCacheBehavior.TrustedSigners\":\"array\",\"DistributionConfig.Logging\":\"object\",\"DistributionConfig.OriginGroups\":\"object\",\"DistributionConfig.OriginGroups.Items\":\"array\",\"DistributionConfig.OriginGroups.Items[]\":\"object\",\"DistributionConfig.OriginGroups.Items[].FailoverCriteria\":\"object\",\"DistributionConfig.OriginGroups.Items[].FailoverCriteria.StatusCodes\":\"object\",\"DistributionConfig.OriginGroups.Items[].FailoverCriteria.StatusCodes.Items\":\"array\",\"DistributionConfig.OriginGroups.Items[].Members\":\"object\",\"DistributionConfig.OriginGroups.Items[].Members.Items\":\"array\",\"DistributionConfig.OriginGroups.Items[].Members.Items[]\":\"object\",\"DistributionConfig.Origins\":\"array\",\"DistributionConfig.Origins[]\":\"object\",\"DistributionConfig.Origins[].CustomOriginConfig\":\"object\",\"DistributionConfig.Origins[].CustomOriginConfig.OriginMtlsConfig\":\"object\",\"DistributionConfig.Origins[].CustomOriginConfig.OriginSSLProtocols\":\"array\",\"DistributionConfig.Origins[].OriginCustomHeaders\":\"array\",\"DistributionConfig.Origins[].OriginCustomHeaders[]\":\"object\",\"DistributionConfig.Origins[].OriginShield\":\"object\",\"DistributionConfig.Origins[].S3OriginConfig\":\"object\",\"DistributionConfig.Origins[].VpcOriginConfig\":\"object\",\"DistributionConfig.Restrictions\":\"object\",\"DistributionConfig.Restrictions.GeoRestriction\":\"object\",\"DistributionConfig.Restrictions.GeoRestriction.Locations\":\"array\",\"DistributionConfig.S3Origin\":\"object\",\"DistributionConfig.TenantConfig\":\"object\",\"DistributionConfig.TenantConfig.ParameterDefinitions\":\"array\",\"DistributionConfig.TenantConfig.ParameterDefinitions[]\":\"object\",\"DistributionConfig.TenantConfig.ParameterDefinitions[].Definition\":\"object\",\"DistributionConfig.TenantConfig.ParameterDefinitions[].Definition.StringSchema\":\"object\",\"DistributionConfig.ViewerCertificate\":\"object\",\"DistributionConfig.ViewerMtlsConfig\":\"object\",\"DistributionConfig.ViewerMtlsConfig.TrustStoreConfig\":\"object\",\"Tags\":\"array\",\"Tags[]\":\"object\"}"],
30904
31103
  ["AWS::CloudFront::OriginAccessControl", "{\"OriginAccessControlConfig\":\"object\"}"],
30905
31104
  ["AWS::CloudTrail::Trail", "{\"AdvancedEventSelectors\":\"array\",\"AdvancedEventSelectors[]\":\"object\",\"AdvancedEventSelectors[].FieldSelectors\":\"array\",\"AdvancedEventSelectors[].FieldSelectors[]\":\"object\",\"AdvancedEventSelectors[].FieldSelectors[].EndsWith\":\"array\",\"AdvancedEventSelectors[].FieldSelectors[].Equals\":\"array\",\"AdvancedEventSelectors[].FieldSelectors[].NotEndsWith\":\"array\",\"AdvancedEventSelectors[].FieldSelectors[].NotEquals\":\"array\",\"AdvancedEventSelectors[].FieldSelectors[].NotStartsWith\":\"array\",\"AdvancedEventSelectors[].FieldSelectors[].StartsWith\":\"array\",\"AggregationConfigurations\":\"array\",\"AggregationConfigurations[]\":\"object\",\"AggregationConfigurations[].Templates\":\"array\",\"EventSelectors\":\"array\",\"EventSelectors[]\":\"object\",\"EventSelectors[].DataResources\":\"array\",\"EventSelectors[].DataResources[]\":\"object\",\"EventSelectors[].DataResources[].Values\":\"array\",\"EventSelectors[].ExcludeManagementEventSources\":\"array\",\"InsightSelectors\":\"array\",\"InsightSelectors[]\":\"object\",\"InsightSelectors[].EventCategories\":\"array\",\"Tags\":\"array\",\"Tags[]\":\"object\"}"],
30906
- ["AWS::CloudWatch::Alarm", "{\"AlarmActions\":\"array\",\"Dimensions\":\"array\",\"Dimensions[]\":\"object\",\"EvaluationCriteria\":\"object\",\"EvaluationCriteria.PromQLCriteria\":\"object\",\"EvaluationWindow\":\"object\",\"EvaluationWindow.SlidingWindow\":\"object\",\"EvaluationWindow.WallClockWindow\":\"object\",\"InsufficientDataActions\":\"array\",\"Metrics\":\"array\",\"Metrics[]\":\"object\",\"Metrics[].MetricStat\":\"object\",\"Metrics[].MetricStat.Metric\":\"object\",\"Metrics[].MetricStat.Metric.Dimensions\":\"array\",\"Metrics[].MetricStat.Metric.Dimensions[]\":\"object\",\"OKActions\":\"array\",\"Tags\":\"array\",\"Tags[]\":\"object\",\"WarmUpConfiguration\":\"object\"}"],
31105
+ ["AWS::CloudWatch::Alarm", "{\"ActionConfiguration\":\"object\",\"ActionConfiguration.AlarmTagsPropagation\":\"object\",\"ActionConfiguration.AlarmTagsPropagation.ExcludedTagKeys\":\"array\",\"ActionConfiguration.AlarmTagsPropagation.IncludedTagKeys\":\"array\",\"AlarmActions\":\"array\",\"Dimensions\":\"array\",\"Dimensions[]\":\"object\",\"EvaluationCriteria\":\"object\",\"EvaluationCriteria.PromQLCriteria\":\"object\",\"EvaluationWindow\":\"object\",\"EvaluationWindow.SlidingWindow\":\"object\",\"EvaluationWindow.WallClockWindow\":\"object\",\"InsufficientDataActions\":\"array\",\"Metrics\":\"array\",\"Metrics[]\":\"object\",\"Metrics[].MetricStat\":\"object\",\"Metrics[].MetricStat.Metric\":\"object\",\"Metrics[].MetricStat.Metric.Dimensions\":\"array\",\"Metrics[].MetricStat.Metric.Dimensions[]\":\"object\",\"OKActions\":\"array\",\"Tags\":\"array\",\"Tags[]\":\"object\",\"WarmUpConfiguration\":\"object\"}"],
30907
31106
  ["AWS::CodeCommit::Repository", "{\"Code\":\"object\",\"Code.S3\":\"object\",\"Tags\":\"array\",\"Tags[]\":\"object\",\"Triggers\":\"array\",\"Triggers[]\":\"object\",\"Triggers[].Branches\":\"array\",\"Triggers[].Events\":\"array\"}"],
30908
31107
  ["AWS::Cognito::UserPool", "{\"AccountRecoverySetting\":\"object\",\"AccountRecoverySetting.RecoveryMechanisms\":\"array\",\"AccountRecoverySetting.RecoveryMechanisms[]\":\"object\",\"AdminCreateUserConfig\":\"object\",\"AdminCreateUserConfig.InviteMessageTemplate\":\"object\",\"AliasAttributes\":\"array\",\"AutoVerifiedAttributes\":\"array\",\"DeviceConfiguration\":\"object\",\"EmailConfiguration\":\"object\",\"EnabledMfas\":\"array\",\"IssuerConfiguration\":\"object\",\"KeyConfiguration\":\"object\",\"LambdaConfig\":\"object\",\"LambdaConfig.CustomEmailSender\":\"object\",\"LambdaConfig.CustomSMSSender\":\"object\",\"LambdaConfig.InboundFederation\":\"object\",\"LambdaConfig.PreTokenGenerationConfig\":\"object\",\"Policies\":\"object\",\"Policies.PasswordPolicy\":\"object\",\"Policies.SignInPolicy\":\"object\",\"Policies.SignInPolicy.AllowedFirstAuthFactors\":\"array\",\"Schema\":\"array\",\"Schema[]\":\"object\",\"Schema[].NumberAttributeConstraints\":\"object\",\"Schema[].StringAttributeConstraints\":\"object\",\"SmsConfiguration\":\"object\",\"SmsConfiguration.EumsSms\":\"object\",\"UserAttributeUpdateSettings\":\"object\",\"UserAttributeUpdateSettings.AttributesRequireVerificationBeforeUpdate\":\"array\",\"UserPoolAddOns\":\"object\",\"UserPoolAddOns.AdvancedSecurityAdditionalFlows\":\"object\",\"UserPoolTags\":\"object\",\"UsernameAttributes\":\"array\",\"UsernameConfiguration\":\"object\",\"VerificationMessageTemplate\":\"object\"}"],
30909
31108
  ["AWS::DLM::LifecyclePolicy", "{\"CrossRegionCopyTargets\":\"array\",\"CrossRegionCopyTargets[]\":\"object\",\"Exclusions\":\"object\",\"Exclusions.ExcludeTags\":\"array\",\"Exclusions.ExcludeTags[]\":\"object\",\"Exclusions.ExcludeVolumeTypes\":\"array\",\"PolicyDetails\":\"object\",\"PolicyDetails.Actions\":\"array\",\"PolicyDetails.Actions[]\":\"object\",\"PolicyDetails.Actions[].CrossRegionCopy\":\"array\",\"PolicyDetails.Actions[].CrossRegionCopy[]\":\"object\",\"PolicyDetails.Actions[].CrossRegionCopy[].EncryptionConfiguration\":\"object\",\"PolicyDetails.Actions[].CrossRegionCopy[].RetainRule\":\"object\",\"PolicyDetails.CrossRegionCopyTargets\":\"array\",\"PolicyDetails.CrossRegionCopyTargets[]\":\"object\",\"PolicyDetails.EventSource\":\"object\",\"PolicyDetails.EventSource.Parameters\":\"object\",\"PolicyDetails.EventSource.Parameters.SnapshotOwner\":\"array\",\"PolicyDetails.Exclusions\":\"object\",\"PolicyDetails.Exclusions.ExcludeTags\":\"array\",\"PolicyDetails.Exclusions.ExcludeTags[]\":\"object\",\"PolicyDetails.Exclusions.ExcludeVolumeTypes\":\"array\",\"PolicyDetails.Parameters\":\"object\",\"PolicyDetails.Parameters.ExcludeDataVolumeTags\":\"array\",\"PolicyDetails.Parameters.ExcludeDataVolumeTags[]\":\"object\",\"PolicyDetails.ResourceLocations\":\"array\",\"PolicyDetails.ResourceTypes\":\"array\",\"PolicyDetails.Schedules\":\"array\",\"PolicyDetails.Schedules[]\":\"object\",\"PolicyDetails.Schedules[].ArchiveRule\":\"object\",\"PolicyDetails.Schedules[].ArchiveRule.RetainRule\":\"object\",\"PolicyDetails.Schedules[].ArchiveRule.RetainRule.RetentionArchiveTier\":\"object\",\"PolicyDetails.Schedules[].CreateRule\":\"object\",\"PolicyDetails.Schedules[].CreateRule.Scripts\":\"array\",\"PolicyDetails.Schedules[].CreateRule.Scripts[]\":\"object\",\"PolicyDetails.Schedules[].CreateRule.Scripts[].Stages\":\"array\",\"PolicyDetails.Schedules[].CreateRule.Times\":\"array\",\"PolicyDetails.Schedules[].CrossRegionCopyRules\":\"array\",\"PolicyDetails.Schedules[].CrossRegionCopyRules[]\":\"object\",\"PolicyDetails.Schedules[].CrossRegionCopyRules[].DeprecateRule\":\"object\",\"PolicyDetails.Schedules[].CrossRegionCopyRules[].RetainRule\":\"object\",\"PolicyDetails.Schedules[].DeprecateRule\":\"object\",\"PolicyDetails.Schedules[].FastRestoreRule\":\"object\",\"PolicyDetails.Schedules[].FastRestoreRule.AvailabilityZoneIds\":\"array\",\"PolicyDetails.Schedules[].FastRestoreRule.AvailabilityZones\":\"array\",\"PolicyDetails.Schedules[].RetainRule\":\"object\",\"PolicyDetails.Schedules[].ShareRules\":\"array\",\"PolicyDetails.Schedules[].ShareRules[]\":\"object\",\"PolicyDetails.Schedules[].ShareRules[].TargetAccounts\":\"array\",\"PolicyDetails.Schedules[].TagsToAdd\":\"array\",\"PolicyDetails.Schedules[].TagsToAdd[]\":\"object\",\"PolicyDetails.Schedules[].VariableTags\":\"array\",\"PolicyDetails.Schedules[].VariableTags[]\":\"object\",\"PolicyDetails.TargetTags\":\"array\",\"PolicyDetails.TargetTags[]\":\"object\",\"Tags\":\"array\",\"Tags[]\":\"object\"}"],
@@ -32023,96 +32222,103 @@ function deepEqualValue(a, b) {
32023
32222
 
32024
32223
  //#endregion
32025
32224
  //#region src/deployment/deploy-engine/provenance-capture.ts
32026
- function kickOffProvenanceCapture(args) {
32027
- const { noChange, resources, template } = args;
32028
- let chain = Promise.resolve();
32029
- for (const logicalId of noChange) {
32030
- const record = Object.hasOwn(resources, logicalId) ? resources[logicalId] : void 0;
32031
- if (record === void 0 || hasReferenceProvenanceField(record)) continue;
32032
- const tokens = recordReferenceTokens(record);
32033
- if (tokens.size === 0) continue;
32034
- const properties = (Object.hasOwn(template.Resources, logicalId) ? template.Resources[logicalId] : void 0)?.Properties ?? {};
32035
- const task = chain.then(() => captureOne(this, logicalId, record, tokens, properties, args)).catch(() => ({
32036
- record,
32037
- field: void 0
32038
- }));
32039
- chain = task;
32040
- this.provenanceCaptureTasks.set(logicalId, task);
32041
- }
32042
- }
32043
- function warnUnattributed(engine, logicalId) {
32044
- engine.logger.warn(safeMsg`Could not record where the secret reference(s) in ${logicalId} were resolved (state schema v12 migration). cdkd keeps its previous handling of them; update ${logicalId} to record it.`);
32045
- }
32046
- async function captureOne(engine, logicalId, record, tokens, properties, args) {
32047
- const bag = /* @__PURE__ */ new Map();
32048
- const { attributeHealer: _healer, ...base } = engine.buildResolverContext({
32049
- template: args.template,
32050
- resources: { ...args.resources },
32051
- ...args.parameters && { parameters: args.parameters },
32052
- ...args.conditions && { conditions: args.conditions }
32053
- }, args.stackName);
32054
- const { producerSecrets: _producer, ...withoutRecorders } = base;
32055
- const context = {
32056
- ...withoutRecorders,
32057
- recordedSecretValues: bag,
32058
- recordedImports: [],
32059
- recordedOutputReads: [],
32060
- staleAttributeHeal: { phase: "probe" },
32061
- printingSecrets: /* @__PURE__ */ new Map(),
32062
- provenanceCapture: true
32063
- };
32064
- const stored = record.properties ?? {};
32065
- for (const [key, value] of Object.entries(properties)) {
32066
- if (!Object.hasOwn(stored, key) || recordReferenceTokens({ properties: stored[key] }).size === 0) continue;
32067
- try {
32068
- await engine.resolver.resolve(structuredClone(value), context);
32069
- } catch (error) {
32070
- if (isThrottlingError(error)) return {
32225
+ var ProvenanceCapture = class {
32226
+ tasks = /* @__PURE__ */ new Map();
32227
+ deps;
32228
+ constructor(deps) {
32229
+ this.deps = deps;
32230
+ }
32231
+ kickOffProvenanceCapture(args) {
32232
+ const { noChange, resources, template } = args;
32233
+ let chain = Promise.resolve();
32234
+ for (const logicalId of noChange) {
32235
+ const record = Object.hasOwn(resources, logicalId) ? resources[logicalId] : void 0;
32236
+ if (record === void 0 || hasReferenceProvenanceField(record)) continue;
32237
+ const tokens = recordReferenceTokens(record);
32238
+ if (tokens.size === 0) continue;
32239
+ const properties = (Object.hasOwn(template.Resources, logicalId) ? template.Resources[logicalId] : void 0)?.Properties ?? {};
32240
+ const task = chain.then(() => this.captureOne(logicalId, record, tokens, properties, args)).catch(() => ({
32071
32241
  record,
32072
32242
  field: void 0
32073
- };
32243
+ }));
32244
+ chain = task;
32245
+ this.tasks.set(logicalId, task);
32074
32246
  }
32075
32247
  }
32076
- const physicalId = typeof record.physicalId === "string" ? record.physicalId.toLowerCase() : "";
32077
- const field = {};
32078
- let unattributed = false;
32079
- for (const token of [...tokens].sort()) {
32080
- const pass = passProvenanceFor(bag, token);
32081
- const plaintext = resolvedPlaintextOf(bag, token);
32082
- const named = plaintext !== void 0 && plaintext.length >= 4 && physicalId.includes(plaintext.toLowerCase());
32083
- const entry = validateReferenceProvenance(token, {
32084
- ...pass?.region !== void 0 && { region: pass.region },
32085
- ...named && pass?.versions !== void 0 && { versions: pass.versions }
32086
- }) ?? {};
32087
- if (entry.region === void 0 && entry.versions === void 0) unattributed = true;
32088
- field[token] = entry;
32089
- }
32090
- if (unattributed) warnUnattributed(engine, logicalId);
32091
- return {
32092
- record,
32093
- field
32094
- };
32095
- }
32096
- async function drainProvenanceCaptures(stateResources) {
32097
- if (this.provenanceCaptureTasks.size === 0) return 0;
32098
- const entries = [...this.provenanceCaptureTasks.entries()];
32099
- this.provenanceCaptureTasks.clear();
32100
- const outcomes = await Promise.all(entries.map(([, task]) => task));
32101
- let installed = 0;
32102
- for (let i = 0; i < entries.length; i++) {
32103
- const logicalId = entries[i][0];
32104
- const { record, field } = outcomes[i];
32105
- if (field === void 0) continue;
32106
- const target = Object.hasOwn(stateResources, logicalId) ? stateResources[logicalId] : void 0;
32107
- if (target === void 0 || target.physicalId !== record.physicalId || target.resourceType !== record.resourceType) continue;
32108
- stateResources[logicalId] = {
32109
- ...target,
32110
- referenceProvenance: field
32248
+ warnUnattributed(logicalId) {
32249
+ this.deps.logger.warn(safeMsg`Could not record where the secret reference(s) in ${logicalId} were resolved (state schema v12 migration). cdkd keeps its previous handling of them; update ${logicalId} to record it.`);
32250
+ }
32251
+ async captureOne(logicalId, record, tokens, properties, args) {
32252
+ const bag = /* @__PURE__ */ new Map();
32253
+ const { attributeHealer: _healer, ...base } = this.deps.buildResolverContext({
32254
+ template: args.template,
32255
+ resources: { ...args.resources },
32256
+ ...args.parameters && { parameters: args.parameters },
32257
+ ...args.conditions && { conditions: args.conditions }
32258
+ }, args.stackName);
32259
+ const { producerSecrets: _producer, ...withoutRecorders } = base;
32260
+ const context = {
32261
+ ...withoutRecorders,
32262
+ recordedSecretValues: bag,
32263
+ recordedImports: [],
32264
+ recordedOutputReads: [],
32265
+ staleAttributeHeal: { phase: "probe" },
32266
+ printingSecrets: /* @__PURE__ */ new Map(),
32267
+ provenanceCapture: true
32268
+ };
32269
+ const stored = record.properties ?? {};
32270
+ for (const [key, value] of Object.entries(properties)) {
32271
+ if (!Object.hasOwn(stored, key) || recordReferenceTokens({ properties: stored[key] }).size === 0) continue;
32272
+ try {
32273
+ await this.deps.resolver.resolve(structuredClone(value), context);
32274
+ } catch (error) {
32275
+ if (isThrottlingError(error)) return {
32276
+ record,
32277
+ field: void 0
32278
+ };
32279
+ }
32280
+ }
32281
+ const physicalId = typeof record.physicalId === "string" ? record.physicalId.toLowerCase() : "";
32282
+ const field = {};
32283
+ let unattributed = false;
32284
+ for (const token of [...tokens].sort()) {
32285
+ const pass = passProvenanceFor(bag, token);
32286
+ const plaintext = resolvedPlaintextOf(bag, token);
32287
+ const named = plaintext !== void 0 && plaintext.length >= 4 && physicalId.includes(plaintext.toLowerCase());
32288
+ const entry = validateReferenceProvenance(token, {
32289
+ ...pass?.region !== void 0 && { region: pass.region },
32290
+ ...named && pass?.versions !== void 0 && { versions: pass.versions }
32291
+ }) ?? {};
32292
+ if (entry.region === void 0 && entry.versions === void 0) unattributed = true;
32293
+ field[token] = entry;
32294
+ }
32295
+ if (unattributed) this.warnUnattributed(logicalId);
32296
+ return {
32297
+ record,
32298
+ field
32111
32299
  };
32112
- installed++;
32113
32300
  }
32114
- return installed;
32115
- }
32301
+ async drainProvenanceCaptures(stateResources) {
32302
+ if (this.tasks.size === 0) return 0;
32303
+ const entries = [...this.tasks.entries()];
32304
+ this.tasks.clear();
32305
+ const outcomes = await Promise.all(entries.map(([, task]) => task));
32306
+ let installed = 0;
32307
+ for (let i = 0; i < entries.length; i++) {
32308
+ const logicalId = entries[i][0];
32309
+ const { record, field } = outcomes[i];
32310
+ if (field === void 0) continue;
32311
+ const target = Object.hasOwn(stateResources, logicalId) ? stateResources[logicalId] : void 0;
32312
+ if (target === void 0 || target.physicalId !== record.physicalId || target.resourceType !== record.resourceType) continue;
32313
+ stateResources[logicalId] = {
32314
+ ...target,
32315
+ referenceProvenance: field
32316
+ };
32317
+ installed++;
32318
+ }
32319
+ return installed;
32320
+ }
32321
+ };
32116
32322
  function provenanceBaselineOf(state, tokenFree) {
32117
32323
  return {
32118
32324
  outputs: state.outputs,
@@ -32963,8 +33169,32 @@ function secretNameNeedlesOf(logicalId, record, secrets, options) {
32963
33169
  for (const needle of printingCorpusOf(embeddedBag).keys()) if (needle !== "" && (needle === physicalId || needle.length >= 4 && physicalId.includes(needle))) add(needle);
32964
33170
  }
32965
33171
  if (physicalId !== void 0) for (const spelling of finalSnapshotSpellingsOf(physicalId, record?.resourceType, needles)) add(spelling);
33172
+ for (const leaf of secretNamedAttributeLeavesOf(record)) add(leaf);
32966
33173
  return needles.size > 0 ? needles : void 0;
32967
33174
  }
33175
+ function secretNamedAttributeLeavesOf(record) {
33176
+ if (record?.resourceType !== "AWS::CloudFormation::Stack") return [];
33177
+ const names = record.secretNamedAttributes;
33178
+ const attributes = record.attributes;
33179
+ if (!Array.isArray(names) || attributes === null || typeof attributes !== "object") return [];
33180
+ const leaves = [];
33181
+ for (const name of names) {
33182
+ if (typeof name !== "string" || !Object.hasOwn(attributes, name)) continue;
33183
+ for (const leaf of wholeStringLeavesOf(attributes[name])) if (leaf !== "" && leaf !== "***" && !leaf.includes("{{resolve:")) leaves.push(leaf);
33184
+ }
33185
+ return leaves;
33186
+ }
33187
+ function secretNamedAttributeNamesOf(attributes, childResources, secrets) {
33188
+ const needles = [...printingCorpusOf(secretNamedRecordNeedles(childResources, secrets)).keys()];
33189
+ if (needles.length === 0) return [];
33190
+ const names = [];
33191
+ for (const [name, value] of Object.entries(attributes)) {
33192
+ const leaves = [...wholeStringLeavesOf(value)].filter((leaf) => leaf !== "");
33193
+ if (leaves.length === 0) continue;
33194
+ if (needles.some((needle) => leavesHoldNeedle(leaves, needle))) names.push(name);
33195
+ }
33196
+ return names.sort();
33197
+ }
32968
33198
  function finalSnapshotSpellingsOf(physicalId, resourceType, needles) {
32969
33199
  if (typeof resourceType !== "string" || !(ATOMIC_FINAL_SNAPSHOT_TYPES.has(resourceType) || PRE_DELETE_SNAPSHOT_TYPES.has(resourceType))) return [];
32970
33200
  const { prefix, sanitized, kept } = finalSnapshotNameCut(physicalId, resourceType);
@@ -32980,6 +33210,20 @@ function finalSnapshotSpellingsOf(physicalId, resourceType, needles) {
32980
33210
  }
32981
33211
  return spellings;
32982
33212
  }
33213
+ function namingBagOf(secrets, logicalId) {
33214
+ const bag = typeof secrets === "function" ? secrets(logicalId) : secrets;
33215
+ return bag !== void 0 && hasMaskableValues(bag) ? bag : void 0;
33216
+ }
33217
+ function namingSecretsWithRecordedNoEcho(base, recorded) {
33218
+ const memo = /* @__PURE__ */ new Map();
33219
+ return (logicalId) => {
33220
+ if (memo.has(logicalId)) return memo.get(logicalId);
33221
+ const own = recorded(logicalId);
33222
+ const bag = own === void 0 || !hasMaskableValues(own) ? base : unionOfSecretBags([base, own]);
33223
+ memo.set(logicalId, bag);
33224
+ return bag;
33225
+ };
33226
+ }
32983
33227
  function secretNamesReadBy(logicalId, record, resources, judge = () => ({
32984
33228
  secrets: void 0,
32985
33229
  embedded: void 0
@@ -33000,7 +33244,7 @@ function leavesHoldNeedle(leaves, needle) {
33000
33244
  return leaves.some((leaf) => leaf === needle || needle.length >= 4 && leaf.includes(needle));
33001
33245
  }
33002
33246
  function stateSecretNameNeedles(resources, secrets) {
33003
- return (logicalId) => secretNameNeedlesOf(logicalId, Object.hasOwn(resources, logicalId) ? resources[logicalId] : void 0, secrets, { embedded: void 0 });
33247
+ return (logicalId) => secretNameNeedlesOf(logicalId, Object.hasOwn(resources, logicalId) ? resources[logicalId] : void 0, namingBagOf(secrets, logicalId), { embedded: void 0 });
33004
33248
  }
33005
33249
  function storedRecordNameNeedles(logicalId, record, secrets) {
33006
33250
  const needles = secretNameNeedlesOf(logicalId, record, secrets, { embedded: void 0 });
@@ -33017,7 +33261,7 @@ function storedRecordNameNeedles(logicalId, record, secrets) {
33017
33261
  function storedSecretNameNeedles(resources, secrets, bag = /* @__PURE__ */ new Map(), outputs) {
33018
33262
  const named = [];
33019
33263
  for (const [logicalId, record] of Object.entries(resources)) {
33020
- const needles = storedRecordNameNeedles(logicalId, record, secrets);
33264
+ const needles = storedRecordNameNeedles(logicalId, record, namingBagOf(secrets, logicalId));
33021
33265
  if (needles !== void 0) named.push([logicalId, needles]);
33022
33266
  }
33023
33267
  if (named.length === 0) return bag;
@@ -33038,19 +33282,18 @@ function secretNamesStoredIn(record, needles) {
33038
33282
  return [...needles].filter((needle) => leavesHoldNeedle(leaves, needle));
33039
33283
  }
33040
33284
  function secretNamedRecordNeedles(resources, secrets, bag = /* @__PURE__ */ new Map()) {
33041
- for (const [logicalId, record] of Object.entries(resources)) for (const needle of storedRecordNameNeedles(logicalId, record, secrets) ?? []) recordLogOnlyValue(bag, needle);
33285
+ for (const [logicalId, record] of Object.entries(resources)) for (const needle of storedRecordNameNeedles(logicalId, record, namingBagOf(secrets, logicalId)) ?? []) recordLogOnlyValue(bag, needle);
33042
33286
  return bag;
33043
33287
  }
33044
33288
  function secretNamePrintingBag(logicalId, resources) {
33045
33289
  return secretNamePrintingBags(resources, void 0)(logicalId);
33046
33290
  }
33047
33291
  function secretNamePrintingBags(resources, noEchoValues) {
33048
- const secrets = noEchoValues !== void 0 && hasMaskableValues(noEchoValues) ? noEchoValues : void 0;
33049
33292
  const judged = /* @__PURE__ */ new Map();
33050
33293
  const needlesOf = (logicalId, record) => {
33051
33294
  const hit = judged.get(logicalId);
33052
33295
  if (hit !== void 0 && hit.record === record) return hit.needles;
33053
- const needles = secretNameNeedlesOf(logicalId, record, secrets, { embedded: void 0 });
33296
+ const needles = secretNameNeedlesOf(logicalId, record, namingBagOf(noEchoValues, logicalId), { embedded: void 0 });
33054
33297
  judged.set(logicalId, {
33055
33298
  record,
33056
33299
  needles
@@ -33059,6 +33302,7 @@ function secretNamePrintingBags(resources, noEchoValues) {
33059
33302
  };
33060
33303
  return (logicalId) => {
33061
33304
  const bag = /* @__PURE__ */ new Map();
33305
+ const secrets = namingBagOf(noEchoValues, logicalId);
33062
33306
  if (secrets !== void 0) carryLogOnlyValues(secrets, bag);
33063
33307
  const record = Object.hasOwn(resources, logicalId) ? resources[logicalId] : void 0;
33064
33308
  for (const needle of needlesOf(logicalId, record) ?? []) recordLogOnlyValue(bag, needle);
@@ -33159,56 +33403,6 @@ function maskEventTextWithBoundBags(event) {
33159
33403
  const DEFAULT_RESOURCE_WARN_AFTER_MS = 3e5;
33160
33404
  const DEFAULT_RESOURCE_TIMEOUT_MS = 18e5;
33161
33405
 
33162
- //#endregion
33163
- //#region src/deployment/deploy-engine/name-collision.ts
33164
- function replacementNameOrigin(logicalId, physicalId) {
33165
- if (looksLikeCdkdGeneratedName(physicalId, logicalId, getCurrentStackName())) return {
33166
- descriptor: `The physical name (${physicalId}) was GENERATED by cdkd from the construct's logical id rather than declared in your template, and that derivation has no random component — so the new resource asks for exactly the name the existing one still holds`,
33167
- remedy: "Either give the resource an explicit physical name in your CDK code, or rename the CONSTRUCT (its id feeds the generated name — note that this replaces the resource rather than renaming it in place)"
33168
- };
33169
- return {
33170
- descriptor: `The resource has a user-supplied physical name (${physicalId})`,
33171
- remedy: "Either rename the resource in your CDK code (a fresh name lets the safe create-first order proceed)"
33172
- };
33173
- }
33174
- function orphanedNameCollisionAdvice(changeType, logicalId, error) {
33175
- if (changeType !== "CREATE") return void 0;
33176
- if (!(error instanceof ProvisioningError)) return void 0;
33177
- const physicalId = error.physicalId;
33178
- if (!physicalId) return void 0;
33179
- const replayed = isReplayedNameCollisionFrom(error, logicalId, (link) => isAuxiliaryMarkOf(link, RETRY_AUXILIARY_OWNER));
33180
- if (!replayed && !isNameCollisionErrorFrom(error, logicalId)) return void 0;
33181
- const stackName = getCurrentStackName();
33182
- if (!looksLikeCdkdGeneratedName(physicalId, logicalId, stackName)) return void 0;
33183
- if (!stackName) return void 0;
33184
- const safeId = displaySafe(physicalId, { asciiOnly: true });
33185
- const safeStack = displaySafe(stackName, { asciiOnly: true });
33186
- const safeLogicalId = displaySafe(logicalId, { asciiOnly: true });
33187
- const idShown = isInertUnquoted(safeId);
33188
- const shownId = idShown ? safeId : "a name that cannot be shown safely here";
33189
- const shownLogicalId = isInertUnquoted(safeLogicalId) ? safeLogicalId : "A resource whose logical id cannot be shown safely here";
33190
- const diagnosis = replayed ? `${shownLogicalId}: the name AWS reports as taken (${shownId}) is most likely held by a resource THIS create made. An earlier attempt of it ended without a clear verdict (a server error, a dropped connection or a timeout, or a failure after the create call itself may have succeeded), and the retry then found the name taken. A dropped connection can also happen before the request reached AWS, so the holder may be another resource: confirm it is yours before deleting or importing it. cdkd records a resource only once its create succeeds, so this one is in no state file: no rollback or cdkd destroy will remove it, and re-running collides with it again.` : `${shownLogicalId}: the name AWS reports as taken (${shownId}) is one cdkd DERIVED from the logical id, and that derivation has no random component — so this is most likely a resource an earlier cdkd run left behind. A rollback leaves a resource carrying DeletionPolicy: Retain in AWS and drops it from state, as CloudFormation does; what differs is the name. CloudFormation would generate a fresh one for an unnamed resource and redeploy clean, whereas cdkd asks again for the name the orphan still holds — so re-running does not clear this.`;
33191
- const deleteArm = `If it is not a resource you want to keep, delete ${idShown ? safeId : "it"} in AWS — after confirming it holds nothing you need${replayed ? "" : ", since Retain is what kept it"} — and re-deploy.`;
33192
- let canImport;
33193
- try {
33194
- canImport = typeof this.providerRegistry.getProvider(error.resourceType).import === "function";
33195
- } catch {
33196
- canImport = false;
33197
- }
33198
- const commandNamesTheRightResource = safeId === physicalId && safeStack === stackName && safeLogicalId === logicalId;
33199
- const importableTarget = !stackName.includes("~");
33200
- if (!canImport || !commandNamesTheRightResource || !importableTarget) return `${diagnosis} ${!canImport ? `cdkd cannot adopt ${displaySafe(error.resourceType, { asciiOnly: true })} back into state (its provider implements no import)` : !importableTarget ? `this is a nested-stack child, whose stack name cdkd import cannot resolve` : `cdkd cannot render an import command that provably names this resource`}, so the way forward is to delete it. ${deleteArm}`;
33201
- const adopt = pasteableCommand("cdkd import", [{
33202
- value: stackName,
33203
- hole: "stack"
33204
- }, {
33205
- flag: "--resource",
33206
- value: `${logicalId}=${physicalId}`,
33207
- hole: "logicalId=physicalId"
33208
- }]);
33209
- return `${diagnosis} To recover, adopt it back into state instead of re-creating it, with the command below (a selective import merges into existing state and needs no --force while the resource is absent from it). CONFIRM IT IS YOURS FIRST — a name cdkd derives is predictable, so for a globally-namespaced type it can belong to another account, and the same stack deployed in another region derives the same name. ${deleteArm}${adopt.withheld.length === 0 ? "" : " The command below prints a quoted hole in place of a value cdkd will not name on a command line; replace it whole, quotes included, with your stack name or '<logicalId>=<name>', shell-quoted."}\nAdopt with: ${adopt.command}`;
33210
- }
33211
-
33212
33406
  //#endregion
33213
33407
  //#region src/analyzer/skipped-outputs.ts
33214
33408
  function canonicalJson$1(value) {
@@ -33458,9 +33652,7 @@ function stateKeySecretExposure(key, secrets) {
33458
33652
  return secretsPresentIn(key, secrets);
33459
33653
  }
33460
33654
  function maskEveryOccurrence(text, exposure) {
33461
- let out = text;
33462
- for (const value of Array.from(exposure.keys()).sort((a, b) => b.length - a.length)) out = out.split(value).join("***");
33463
- return out;
33655
+ return maskMatchSpans(text, Array.from(exposure.keys()).filter((value) => value !== ""), "***");
33464
33656
  }
33465
33657
 
33466
33658
  //#endregion
@@ -33544,6 +33736,18 @@ function exportAliasCollisionScrubWarning(outputKey, exportName, secrets) {
33544
33736
 
33545
33737
  //#endregion
33546
33738
  //#region src/deployment/deploy-engine/outputs.ts
33739
+ var OutputsRunState = class {
33740
+ outputSecrets = /* @__PURE__ */ new Map();
33741
+ outputsPassSecretMaps = [];
33742
+ outputsTemplateSource = Object.create(null);
33743
+ resolvedExportNames = [];
33744
+ carriedExportAliasRefusal;
33745
+ skippedOutputs;
33746
+ outputsSourceUsable = true;
33747
+ outputProvenanceSinks = /* @__PURE__ */ new Map();
33748
+ outputsResolvedThisRun = /* @__PURE__ */ new WeakSet();
33749
+ resolvedOutputsBag = void 0;
33750
+ };
33547
33751
  var ForwardingSecrets = class extends Map {
33548
33752
  target;
33549
33753
  constructor(target) {
@@ -33556,25 +33760,25 @@ var ForwardingSecrets = class extends Map {
33556
33760
  return this;
33557
33761
  }
33558
33762
  };
33559
- function handleOutputResolutionFailure(error, outputKey, outputs, secrets, inheritedSecrets) {
33763
+ function handleOutputResolutionFailure(deps, error, outputKey, outputs, secrets, inheritedSecrets) {
33560
33764
  const union = unionOfSecretBags([inheritedSecrets, secrets]);
33561
33765
  const detail = maskSecretsInText(error instanceof Error ? error.message || error.name : String(error), union);
33562
- if (this.options.strictGetAtt) {
33766
+ if (deps.options.strictGetAtt) {
33563
33767
  const cause = typeof error === "string" ? maskSecretsInText(error, union) : maskSecretsInError(error, union);
33564
33768
  throw new Error(safeMsg`Failed to resolve output ${outputKey} ` + `(--strict-getatt promotes output resolution failures to deploy errors; ` + safeMsg`drop the flag to skip the output instead): ${asIsMessage(detail)}`, cause instanceof Error || typeof cause === "string" ? { cause } : {});
33565
33769
  }
33566
- this.logger.warn(safeMsg`Failed to resolve output ${outputKey}: ${asIsMessage(detail)}`);
33770
+ deps.logger.warn(safeMsg`Failed to resolve output ${outputKey}: ${asIsMessage(detail)}`);
33567
33771
  outputs[outputKey] = void 0;
33568
33772
  }
33569
- async function resolveOutputs(template, resources, stackName, digestSource, parameterValues, conditions) {
33570
- this.resolvedExportNames = [];
33571
- this.carriedExportAliasRefusal = void 0;
33773
+ async function resolveOutputs(run, deps, template, resources, stackName, digestSource, parameterValues, conditions) {
33774
+ run.resolvedExportNames = [];
33775
+ run.carriedExportAliasRefusal = void 0;
33572
33776
  if (!template.Outputs) {
33573
- this.carriedExportAliasRefusal = seedOnlyAliasRefusal(noEchoParameterValueSeed(template.Parameters, parameterValues, this.options.inheritedSecrets, this.options.parameters));
33777
+ run.carriedExportAliasRefusal = seedOnlyAliasRefusal(noEchoParameterValueSeed(template.Parameters, parameterValues, deps.options.inheritedSecrets, deps.options.parameters));
33574
33778
  return {};
33575
33779
  }
33576
33780
  const outputs = Object.create(null);
33577
- const context = this.buildResolverContext({
33781
+ const context = deps.buildResolverContext({
33578
33782
  template,
33579
33783
  resources,
33580
33784
  ...parameterValues && { parameters: parameterValues },
@@ -33589,37 +33793,37 @@ async function resolveOutputs(template, resources, stackName, digestSource, para
33589
33793
  const outputsPassSecrets = context.recordedSecretValues ?? EMPTY_SECRETS;
33590
33794
  const outputsPassInherited = context.inheritedSecrets ?? EMPTY_SECRETS;
33591
33795
  if (context.recordedSecretValues) {
33592
- this.outputsPassSecretMaps.push(context.recordedSecretValues);
33593
- mirrorInheritedParameterReads(context.recordedSecretValues, this.outputSecrets);
33594
- if (this.options.inheritedSecrets && this.options.inheritedSecrets.size > 0) inheritNestedStackParameterAssociations(this.outputSecrets, this.options.inheritedSecrets);
33796
+ run.outputsPassSecretMaps.push(context.recordedSecretValues);
33797
+ mirrorInheritedParameterReads(context.recordedSecretValues, run.outputSecrets);
33798
+ if (deps.options.inheritedSecrets && deps.options.inheritedSecrets.size > 0) inheritNestedStackParameterAssociations(run.outputSecrets, deps.options.inheritedSecrets);
33595
33799
  }
33596
33800
  const publishedOutputNames = collectPublishedOutputNames(template.Outputs, conditions);
33597
33801
  let outputsPassCompleted = false;
33598
33802
  try {
33599
33803
  for (const [outputKey, output] of Object.entries(template.Outputs)) {
33600
33804
  if (isOutputSuppressedByCondition(output, conditions)) {
33601
- this.logger.debug(safeMsg`Skipping output ${outputKey} — condition ${output.Condition} is false`);
33805
+ deps.logger.debug(safeMsg`Skipping output ${outputKey} — condition ${output.Condition} is false`);
33602
33806
  continue;
33603
33807
  }
33604
33808
  const ownReads = [];
33605
33809
  const provenanceSink = /* @__PURE__ */ new Map();
33606
- this.outputProvenanceSinks.set(outputKey, provenanceSink);
33810
+ run.outputProvenanceSinks.set(outputKey, provenanceSink);
33607
33811
  try {
33608
- const resolved = await this.resolver.resolve(output.Value, {
33812
+ const resolved = await deps.resolver.resolve(output.Value, {
33609
33813
  ...context,
33610
33814
  redactedAttributeReads: ownReads,
33611
33815
  provenanceSink
33612
33816
  });
33613
33817
  refuseMaskedOutputReads(outputKey, ownReads);
33614
- if (resolved === void 0 && this.options.strictGetAtt) throw markNonRetryable(/* @__PURE__ */ new Error("the value resolved to nothing"));
33818
+ if (resolved === void 0 && deps.options.strictGetAtt) throw markNonRetryable(/* @__PURE__ */ new Error("the value resolved to nothing"));
33615
33819
  outputs[outputKey] = resolved;
33616
33820
  } catch (error) {
33617
- this.handleOutputResolutionFailure(error, outputKey, outputs, outputsPassSecrets, outputsPassInherited);
33821
+ handleOutputResolutionFailure(deps, error, outputKey, outputs, outputsPassSecrets, outputsPassInherited);
33618
33822
  }
33619
33823
  }
33620
- const noEchoSeed = noEchoParameterValueSeed(template.Parameters, parameterValues, context.inheritedSecrets, this.options.parameters);
33621
- const noEchoSources = this.noEchoPositionSources(resources, template, conditions);
33622
- this.carriedExportAliasRefusal = (outputKey, exportName) => {
33824
+ const noEchoSeed = noEchoParameterValueSeed(template.Parameters, parameterValues, context.inheritedSecrets, deps.options.parameters);
33825
+ const noEchoSources = deps.noEchoPositionSources(resources, template, conditions);
33826
+ run.carriedExportAliasRefusal = (outputKey, exportName) => {
33623
33827
  const verdict = carriedExportAliasExposure(exportName, outputsPassSecrets, noEchoSeed);
33624
33828
  if (verdict === void 0) return void 0;
33625
33829
  return secretBearingExportNameWarning(outputKey, exportName, verdict.exposure, context.recordedSecretValues, verdict.noEchoOnly);
@@ -33635,14 +33839,14 @@ async function resolveOutputs(template, resources, stackName, digestSource, para
33635
33839
  const nameReads = [];
33636
33840
  let exportName;
33637
33841
  try {
33638
- exportName = typeof output.Export.Name === "string" ? output.Export.Name : await this.resolver.resolve(output.Export.Name, {
33842
+ exportName = typeof output.Export.Name === "string" ? output.Export.Name : await deps.resolver.resolve(output.Export.Name, {
33639
33843
  ...context,
33640
33844
  recordedSecretValues: nameSecrets,
33641
33845
  redactedAttributeReads: nameReads
33642
33846
  });
33643
33847
  refuseMaskedOutputReads(outputKey, nameReads);
33644
33848
  } catch (error) {
33645
- this.handleOutputResolutionFailure(error, outputKey, outputs, outputsPassSecrets, outputsPassInherited);
33849
+ handleOutputResolutionFailure(deps, error, outputKey, outputs, outputsPassSecrets, outputsPassInherited);
33646
33850
  continue;
33647
33851
  }
33648
33852
  if (typeof exportName !== "string") continue;
@@ -33658,28 +33862,28 @@ async function resolveOutputs(template, resources, stackName, digestSource, para
33658
33862
  for (const { outputKey, exportName, value, outputValue, nameSource, nameSecrets } of resolvedNames) {
33659
33863
  const noEchoParameters = exportNameNoEchoParameters(nameSource, noEchoSources);
33660
33864
  const exposure = noEchoParameters.length > 0 ? void 0 : exportNameSecretExposure(exportName, nameSecrets, context.recordedSecretValues, noEchoSeed);
33661
- if (noEchoParameters.length > 0) this.logger.warn(noEchoParameterExportNameWarning(outputKey, noEchoParameters, outputsPassSecrets));
33662
- else if (exposure) this.logger.warn(secretBearingExportNameWarning(outputKey, exportName, exposure, context.recordedSecretValues, isNoEchoOnlyExposure(exposure, nameSecrets, context.recordedSecretValues)));
33663
- else if (isExportAliasCollision(exportName, outputKey, publishedOutputNames)) this.logger.warn(exportAliasCollisionWarning(outputKey, exportName, outputsPassSecrets));
33865
+ if (noEchoParameters.length > 0) deps.logger.warn(noEchoParameterExportNameWarning(outputKey, noEchoParameters, outputsPassSecrets));
33866
+ else if (exposure) deps.logger.warn(secretBearingExportNameWarning(outputKey, exportName, exposure, context.recordedSecretValues, isNoEchoOnlyExposure(exposure, nameSecrets, context.recordedSecretValues)));
33867
+ else if (isExportAliasCollision(exportName, outputKey, publishedOutputNames)) deps.logger.warn(exportAliasCollisionWarning(outputKey, exportName, outputsPassSecrets));
33664
33868
  else {
33665
33869
  outputs[exportName] = value;
33666
- const aliasedSink = this.outputProvenanceSinks.get(outputKey);
33667
- if (aliasedSink !== void 0) this.outputProvenanceSinks.set(exportName, aliasedSink);
33668
- if (!this.resolvedExportNames.includes(exportName)) this.resolvedExportNames.push(exportName);
33669
- this.outputsTemplateSource[exportName] = outputValue;
33870
+ const aliasedSink = run.outputProvenanceSinks.get(outputKey);
33871
+ if (aliasedSink !== void 0) run.outputProvenanceSinks.set(exportName, aliasedSink);
33872
+ if (!run.resolvedExportNames.includes(exportName)) run.resolvedExportNames.push(exportName);
33873
+ run.outputsTemplateSource[exportName] = outputValue;
33670
33874
  }
33671
33875
  }
33672
33876
  outputsPassCompleted = true;
33673
33877
  } finally {
33674
- if (!outputsPassCompleted) this.outputsSourceUsable = false;
33878
+ if (!outputsPassCompleted) run.outputsSourceUsable = false;
33675
33879
  }
33676
33880
  for (const [outputKey, output] of Object.entries(template.Outputs)) {
33677
33881
  if (!publishedOutputNames.has(outputKey)) continue;
33678
- this.outputsTemplateSource[outputKey] = output.Value;
33882
+ run.outputsTemplateSource[outputKey] = output.Value;
33679
33883
  }
33680
- this.skippedOutputs = collectSkippedOutputs(digestSource, outputs);
33681
- this.outputsResolvedThisRun.add(outputs);
33682
- this.resolvedOutputsBag = outputs;
33884
+ run.skippedOutputs = collectSkippedOutputs(digestSource, outputs);
33885
+ run.outputsResolvedThisRun.add(outputs);
33886
+ run.resolvedOutputsBag = outputs;
33683
33887
  return markSameGenerationBag(outputs);
33684
33888
  }
33685
33889
  function buildDisplayOutputs(template, resolvedOutputs) {
@@ -34739,7 +34943,7 @@ var ReplayPins = class {
34739
34943
  function refuseMaskedReplayBaseline(props, logicalId, inert = []) {
34740
34944
  if (props === void 0 || !carriesSecretMask(props)) return;
34741
34945
  if (inert.length > 0 && masksOnlyAt(props, inert)) return;
34742
- throw new CdkdError(`Cannot roll ${shownLogicalId(logicalId)} back: its recorded baseline holds the redaction mask ('${"***"}'), so cdkd would write that literal to the live resource. There are four ways a baseline comes to hold it. (1) A NoEcho custom-resource value was resolved there: restore the property with 'cdkd deploy' AFTER forcing that custom resource to update (change one of its properties, e.g. a nonce), so its handler runs again and supplies the real value — an ordinary re-deploy leaves the resource unchanged, so the handler does not run and the mask stays. (2) The Fn::Base64 encoding of a secret value (a {{resolve:...}} dynamic reference under Fn::Base64, such as EC2 UserData), which cdkd never records: restore the property with a 'cdkd deploy' that changes this resource, which sends it the encoded value again — a re-deploy that leaves this resource unchanged sends it nothing. Every rollback to such a baseline refuses, so to end this, stop encoding the secret into the property (have the resource read the secret at run time instead — not by writing the secret's plaintext into the template, which cdkd would then record in state in the clear). (3) The value was SPLICED from a masked record of ANOTHER resource — by 'cdkd orphan --force', or by 'cdkd import' resolving an Fn::GetAtt or a Ref over a value the Cloud Control fallback had masked. Repair the record that HOLDS the mask ('cdkd import <stack> --resource <logicalId>=<physicalId> --force', granting cloudformation:DescribeType first if the import warned that it could not read the schema), then re-run whichever command wrote this property. (4) A NoEcho template parameter's value, which cdkd stores only as the mask: restore the property with 'cdkd deploy', which sends the parameter's value again. See https://github.com/go-to-k/cdkd/issues/2449.`, "ROLLBACK_REDACTED_BASELINE");
34946
+ throw new CdkdError(`Cannot roll ${shownLogicalId(logicalId)} back: its recorded baseline holds the redaction mask ('${"***"}'), so cdkd would write that literal to the live resource. There are five ways a baseline comes to hold it. (1) A NoEcho custom-resource value was resolved there: restore the property with 'cdkd deploy' AFTER forcing that custom resource to update (change one of its properties, e.g. a nonce), so its handler runs again and supplies the real value — an ordinary re-deploy leaves the resource unchanged, so the handler does not run and the mask stays. (2) The Fn::Base64 encoding of a secret value (a {{resolve:...}} dynamic reference under Fn::Base64, such as EC2 UserData), which cdkd never records: restore the property with a 'cdkd deploy' that changes this resource, which sends it the encoded value again — a re-deploy that leaves this resource unchanged sends it nothing. Every rollback to such a baseline refuses, so to end this, stop encoding the secret into the property (have the resource read the secret at run time instead — not by writing the secret's plaintext into the template, which cdkd would then record in state in the clear). (3) The value was SPLICED from a masked record of ANOTHER resource — by 'cdkd orphan --force', or by 'cdkd import' resolving an Fn::GetAtt or a Ref over a value the Cloud Control fallback had masked. Repair the record that HOLDS the mask ('cdkd import <stack> --resource <logicalId>=<physicalId> --force', granting cloudformation:DescribeType first if the import warned that it could not read the schema), then re-run whichever command wrote this property. (4) A NoEcho template parameter's value, which cdkd stores only as the mask: restore the property with 'cdkd deploy', which sends the parameter's value again. (5) Two secret values cdkd resolved overlap inside the value, so no single {{resolve:...}} reference renders it and cdkd stored the mask rather than part of a secret: restore the property with a 'cdkd deploy' that changes this resource, which sends it the value again. Every rollback to such a baseline refuses while the two values still overlap there, so to end this, change the property (or rotate one of the secrets) so that they no longer overlap. See https://github.com/go-to-k/cdkd/issues/2449.`, "ROLLBACK_REDACTED_BASELINE");
34743
34947
  }
34744
34948
 
34745
34949
  //#endregion
@@ -37388,13 +37592,414 @@ function makeSiblingClaimReader(params) {
37388
37592
  };
37389
37593
  }
37390
37594
 
37595
+ //#endregion
37596
+ //#region src/deployment/read-only-attribute-healer.ts
37597
+ async function readRecordAttributes(input) {
37598
+ const { provider, logicalId, resource, stackName, region } = input;
37599
+ if (!provider.import) return { kind: "not-attempted" };
37600
+ if (!hasAddressablePhysicalId(resource)) return { kind: "not-attempted" };
37601
+ const found = await provider.import({
37602
+ logicalId,
37603
+ resourceType: resource.resourceType,
37604
+ stackName,
37605
+ region,
37606
+ properties: resource.properties,
37607
+ knownPhysicalId: resource.physicalId
37608
+ });
37609
+ if (found === null) return { kind: "not-found" };
37610
+ if (found.physicalId !== resource.physicalId) throw new Error(`the provider answered for a different resource (${found.physicalId}) than the one asked about (${resource.physicalId})`);
37611
+ const reported = Object.entries(normalizeHealedAttributes(found.attributes));
37612
+ const attributes = Object.fromEntries(reported.filter(([, value]) => !carriesSecretMask(value)));
37613
+ const withheldKeys = reported.filter(([, value]) => carriesSecretMask(value)).map(([key]) => key);
37614
+ return {
37615
+ kind: "read",
37616
+ attributes,
37617
+ ...withheldKeys.length > 0 && { withheldKeys }
37618
+ };
37619
+ }
37620
+ function createReadOnlyAttributeHealerFactory(options) {
37621
+ const logger = getLogger().child("ReadOnlyAttributeHealer");
37622
+ const memo = /* @__PURE__ */ new Map();
37623
+ const readOnce = (stackName, region, logicalId, resource) => {
37624
+ let key;
37625
+ try {
37626
+ if (isHealExcludedType(resource.resourceType)) return Promise.resolve({ kind: "not-attempted" });
37627
+ key = injectiveKey(stackName, region, logicalId, resource.physicalId);
37628
+ } catch (error) {
37629
+ return Promise.resolve({
37630
+ kind: "failed",
37631
+ error
37632
+ });
37633
+ }
37634
+ const inFlight = memo.get(key);
37635
+ if (inFlight) return inFlight;
37636
+ const heal = (async () => options.inRegion(region, () => readRecordAttributes({
37637
+ provider: options.getProvider(resource, region),
37638
+ logicalId,
37639
+ resource,
37640
+ stackName,
37641
+ region
37642
+ })))().then((outcome) => {
37643
+ if (outcome.kind === "read") try {
37644
+ logger.debug(safeMsg`Re-read the attributes of ${displaySafe(logicalId)} (${displaySafe(resource.resourceType)}) from AWS for this preview — its state record lacked one a Fn::GetAtt asked for; nothing is written: ${Object.keys(outcome.attributes).length} attribute(s) read`);
37645
+ } catch {}
37646
+ return outcome;
37647
+ }).catch((error) => ({
37648
+ kind: "failed",
37649
+ error
37650
+ }));
37651
+ memo.set(key, heal);
37652
+ return heal;
37653
+ };
37654
+ return (stackName, region) => Object.assign((logicalId, resource) => readOnce(stackName, region, logicalId, resource), { readOnly: true });
37655
+ }
37656
+
37657
+ //#endregion
37658
+ //#region src/deployment/deploy-engine/noecho.ts
37659
+ var NoEchoRunState = class {
37660
+ noEchoAttributeResources = /* @__PURE__ */ new Map();
37661
+ persistedNoEchoAttributes = /* @__PURE__ */ new Map();
37662
+ noEchoConditions = void 0;
37663
+ inheritedNoEchoParameters = /* @__PURE__ */ new Set();
37664
+ noEchoPhysicalIdWarned = /* @__PURE__ */ new Set();
37665
+ noEchoPositionedValues = /* @__PURE__ */ new Map();
37666
+ noEchoExactEchoes = /* @__PURE__ */ new Map();
37667
+ noEchoAttributeReads = /* @__PURE__ */ new Map();
37668
+ witnessConfirmedLeaves = /* @__PURE__ */ new Map();
37669
+ constructPathTemplate = void 0;
37670
+ };
37671
+ function noEchoExactEchoLeavesOf(record) {
37672
+ const field = record?.noEchoExactEchoLeaves;
37673
+ if (!Array.isArray(field)) return void 0;
37674
+ const out = [];
37675
+ for (const entry of field) {
37676
+ if (!Array.isArray(entry) || entry.length === 0) return void 0;
37677
+ if (!entry.every((segment) => typeof segment === "string")) return void 0;
37678
+ out.push([...entry]);
37679
+ }
37680
+ return out;
37681
+ }
37682
+ function echoFidelityCandidates(coordinates, resolved, createOnly) {
37683
+ const out = [];
37684
+ for (const coordinate of coordinates) {
37685
+ if (!coordinate.every((segment) => typeof segment === "string")) continue;
37686
+ const keys = coordinate;
37687
+ if (!createOnly.some((path) => path.length <= keys.length && path.every((s, i) => s === keys[i]))) continue;
37688
+ const plaintext = valueAtCoordinate(resolved, keys);
37689
+ if (typeof plaintext !== "string" || carriesSecretMask(plaintext)) continue;
37690
+ out.push({
37691
+ coordinate: keys,
37692
+ plaintext
37693
+ });
37694
+ }
37695
+ return out;
37696
+ }
37697
+ function reportedLeafAt(live, handed, candidate) {
37698
+ if (valueAtCoordinate(handed, candidate.coordinate) !== "***") return void 0;
37699
+ const leaf = valueAtCoordinate(live, candidate.coordinate);
37700
+ return typeof leaf === "string" && !carriesSecretMask(leaf) ? leaf : void 0;
37701
+ }
37702
+ function echoesExactlyAt(live, handed, candidate) {
37703
+ return reportedLeafAt(live, handed, candidate) === candidate.plaintext;
37704
+ }
37705
+ function provesEchoChangeAt(live, handed, candidate) {
37706
+ const reported = reportedLeafAt(live, handed, candidate);
37707
+ return reported !== void 0 && reported !== candidate.plaintext;
37708
+ }
37709
+ function noteNoEchoExactEchoes(run, logicalId, physicalId, read, handed, candidates, mode) {
37710
+ const exact = "failure" in read ? [] : candidates.filter((candidate) => echoesExactlyAt(read.live, handed, candidate)).map((candidate) => [...candidate.coordinate]);
37711
+ const noted = run.noEchoExactEchoes.get(logicalId);
37712
+ const previous = mode === "add" && noted?.physicalId === physicalId ? noted.coordinates : [];
37713
+ run.noEchoExactEchoes.set(logicalId, {
37714
+ physicalId,
37715
+ coordinates: sortedCoordinates([...previous, ...exact])
37716
+ });
37717
+ }
37718
+ function sortedCoordinates(coordinates) {
37719
+ const keyed = /* @__PURE__ */ new Map();
37720
+ for (const coordinate of coordinates) keyed.set(JSON.stringify(coordinate), [...coordinate]);
37721
+ return [...keyed.entries()].sort(([a], [b]) => a.localeCompare(b)).map(([, c]) => c);
37722
+ }
37723
+ async function establishNoEchoEchoFidelity(run, deps, logicalId, record, resolvedProps, stateResources, secrets) {
37724
+ run.noEchoExactEchoes.delete(logicalId);
37725
+ const templateProps = deps.perResourceTemplateProps().get(logicalId);
37726
+ const sources = noEchoPositionSources(run, stateResources);
37727
+ if (templateProps === void 0 || sources === void 0 || sources.parameters.size === 0) return;
37728
+ const coordinates = canonicalCoordinates(noEchoCoordinatesOf(templateProps, resolvedProps, {
37729
+ parameters: sources.parameters,
37730
+ ...sources.conditions !== void 0 && { conditions: sources.conditions }
37731
+ }));
37732
+ if (coordinates.length === 0) return;
37733
+ const candidates = echoFidelityCandidates(coordinates, resolvedProps, await getCreateOnlyPropertyPaths(record.resourceType).catch(() => []));
37734
+ if (candidates.length === 0) return;
37735
+ const handed = {
37736
+ ...record,
37737
+ properties: maskAtCoordinates(record.properties, coordinates)
37738
+ };
37739
+ const read = await deps.readReaderForFreshNoEchoCeiling(logicalId, handed, secrets);
37740
+ noteNoEchoExactEchoes(run, logicalId, record.physicalId, read, handed.properties, candidates, "set");
37741
+ }
37742
+ function withNoEchoExactEchoes(run, logicalId, record) {
37743
+ const noted = run.noEchoExactEchoes.get(logicalId);
37744
+ if (noted === void 0 || noted.coordinates.length === 0) return record;
37745
+ if (noted.physicalId !== record.physicalId) return record;
37746
+ const merged = sortedCoordinates([...noEchoExactEchoLeavesOf(record) ?? [], ...noted.coordinates]);
37747
+ return {
37748
+ ...record,
37749
+ noEchoExactEchoLeaves: merged
37750
+ };
37751
+ }
37752
+ function noEchoParameterNamesOf(template) {
37753
+ const names = /* @__PURE__ */ new Set();
37754
+ const declared = template?.Parameters;
37755
+ if (declared === null || typeof declared !== "object") return names;
37756
+ for (const [name, definition] of Object.entries(declared)) if (declaresNoEcho(definition)) names.add(name);
37757
+ return names;
37758
+ }
37759
+ function noEchoAttributeNamesOf(record) {
37760
+ const field = record?.noEchoAttributeNames;
37761
+ if (!Array.isArray(field) || !field.every((name) => typeof name === "string")) return void 0;
37762
+ return field;
37763
+ }
37764
+ function noEchoPositionSources(run, resources = {}, template = run.constructPathTemplate, conditions = run.noEchoConditions) {
37765
+ if (template === void 0) return void 0;
37766
+ const declared = run.noEchoAttributeResources;
37767
+ return {
37768
+ parameters: /* @__PURE__ */ new Set([...noEchoParameterNamesOf(template), ...run.inheritedNoEchoParameters]),
37769
+ attributeIsNoEcho: (logicalId, attribute) => {
37770
+ const live = declared.get(logicalId);
37771
+ if (live === true || live !== void 0 && live.has(attribute)) return true;
37772
+ if (noEchoAttributeNamesOf(Object.hasOwn(resources, logicalId) ? resources[logicalId] : void 0)?.includes(attribute) === true) return true;
37773
+ return run.persistedNoEchoAttributes.get(logicalId)?.has(attribute) === true;
37774
+ },
37775
+ ...conditions !== void 0 && { conditions }
37776
+ };
37777
+ }
37778
+ function noEchoLeavesFor(run, deps, logicalId, record, templateProps, sources) {
37779
+ if (templateProps !== void 0 && isWrittenFromDeployedTemplate(record.properties)) return canonicalCoordinates(noEchoCoordinatesOf(templateProps, record.properties, sources));
37780
+ const existing = noEchoLeavesOf(record);
37781
+ if (existing !== void 0) {
37782
+ const confirmed = run.witnessConfirmedLeaves.get(logicalId) ?? [];
37783
+ return canonicalCoordinates([...existing, ...confirmed]);
37784
+ }
37785
+ const resolvedAsSame = deps.perResourceResolvedType().get(logicalId) === record.resourceType;
37786
+ const source = (templateProps !== void 0 && resolvedAsSame ? templateProps : void 0) ?? templatePropertiesFor(run, logicalId, record.resourceType);
37787
+ if (source === void 0) return void 0;
37788
+ return canonicalCoordinates(noEchoCoordinatesOf(source, record.properties, sources));
37789
+ }
37790
+ function templatePropertiesFor(run, logicalId, resourceType) {
37791
+ const resources = run.constructPathTemplate?.Resources;
37792
+ if (resources === void 0 || !Object.hasOwn(resources, logicalId)) return void 0;
37793
+ const definition = resources[logicalId];
37794
+ if (definition?.Type !== resourceType) return void 0;
37795
+ const properties = definition.Properties;
37796
+ return properties !== null && typeof properties === "object" && !Array.isArray(properties) ? properties : void 0;
37797
+ }
37798
+ function noEchoAttributeNamesFor(run, logicalId, record, carried, leaves) {
37799
+ const attributes = record.attributes ?? {};
37800
+ const names = /* @__PURE__ */ new Set();
37801
+ let echoed = false;
37802
+ for (const coordinate of leaves ?? []) {
37803
+ const value = valueAtCoordinate(record.properties, coordinate);
37804
+ if (value === void 0 || carriesSecretMask(value)) continue;
37805
+ for (const [name, attribute] of Object.entries(attributes)) {
37806
+ if (carriesSecretMask(attribute)) continue;
37807
+ if (typeof attribute === "string" && attribute === record.physicalId) continue;
37808
+ const sameName = coordinate[0] === name && keyOrderFreeJson(attribute) === keyOrderFreeJson(value);
37809
+ const embeds = typeof value === "string" && typeof attribute === "string" && !attribute.startsWith("arn:") && value.length >= 4 && typeof attribute === "string" && attribute.includes(value);
37810
+ if (sameName || embeds) {
37811
+ names.add(name);
37812
+ echoed = true;
37813
+ }
37814
+ }
37815
+ }
37816
+ const declared = carried ? void 0 : run.noEchoAttributeResources.get(logicalId);
37817
+ if (declared === true) for (const name of Object.keys(attributes)) names.add(name);
37818
+ else if (declared !== void 0) {
37819
+ for (const name of declared) if (Object.hasOwn(attributes, name)) names.add(name);
37820
+ }
37821
+ const prior = noEchoAttributeNamesOf(record);
37822
+ for (const name of prior ?? []) if (Object.hasOwn(attributes, name) && carriesSecretMask(attributes[name])) names.add(name);
37823
+ if (declared === void 0 && prior === void 0 && !echoed) return void 0;
37824
+ return [...names].sort();
37825
+ }
37826
+ function applyNoEchoPersist(run, deps, logicalId, record, scrubbed, templateProps, resources, secrets, carried = false) {
37827
+ const sources = noEchoPositionSources(run, resources);
37828
+ if (sources === void 0) return scrubbed;
37829
+ const leaves = noEchoLeavesFor(run, deps, logicalId, record, templateProps, sources);
37830
+ const names = noEchoAttributeNamesFor(run, logicalId, record, carried, leaves);
37831
+ if (leaves === void 0 && names === void 0) return scrubbed;
37832
+ const next = { ...scrubbed };
37833
+ if (leaves !== void 0) {
37834
+ next.properties = maskAtCoordinates(scrubbed.properties, leaves);
37835
+ if (scrubbed.observedProperties !== void 0 && leaves.length > 0) Object.assign(next, { observedProperties: maskReadbackAtCoordinates(scrubbed.observedProperties, record.properties, leaves) });
37836
+ if (leaves.length > 0) next.noEchoLeaves = leaves;
37837
+ else delete next.noEchoLeaves;
37838
+ const marked = new Set(leaves.map((coordinate) => JSON.stringify(coordinate)));
37839
+ const exact = (noEchoExactEchoLeavesOf(scrubbed) ?? []).filter((coordinate) => marked.has(JSON.stringify(coordinate)));
37840
+ if (exact.length > 0) next.noEchoExactEchoLeaves = exact;
37841
+ else delete next.noEchoExactEchoLeaves;
37842
+ }
37843
+ if (names !== void 0) {
37844
+ if (scrubbed.attributes !== void 0 && names.length > 0) {
37845
+ const attributes = { ...scrubbed.attributes };
37846
+ for (const name of names) if (Object.hasOwn(attributes, name)) attributes[name] = maskWholeValue(attributes[name]);
37847
+ next.attributes = attributes;
37848
+ }
37849
+ if (names.length > 0) next.noEchoAttributeNames = names;
37850
+ else delete next.noEchoAttributeNames;
37851
+ }
37852
+ warnNoEchoPhysicalId(run, deps, logicalId, record, secrets);
37853
+ return next;
37854
+ }
37855
+ function warnNoEchoPhysicalId(run, deps, logicalId, record, secrets) {
37856
+ if (secrets === void 0 || run.noEchoPhysicalIdWarned.has(logicalId)) return;
37857
+ const values = noEchoParameterPlaintextsOf(secrets);
37858
+ if (values.length === 0 || typeof record.physicalId !== "string") return;
37859
+ if (!values.some((value) => record.physicalId.includes(value))) return;
37860
+ run.noEchoPhysicalIdWarned.add(logicalId);
37861
+ deps.logger.warn(deps.maskForResource(logicalId, safeMsg`${logicalId}: its physical id contains a NoEcho parameter value. AWS publishes a resource's name, so cdkd keeps the physical id in state as AWS returns it.`));
37862
+ }
37863
+ function seedPersistedNoEchoAttributes(run, resources) {
37864
+ run.persistedNoEchoAttributes = /* @__PURE__ */ new Map();
37865
+ for (const [logicalId, record] of Object.entries(resources)) {
37866
+ const names = noEchoAttributeNamesOf(record);
37867
+ if (names !== void 0 && names.length > 0) run.persistedNoEchoAttributes.set(logicalId, new Set(names));
37868
+ }
37869
+ }
37870
+ function maskOutputsByPosition(run, deps, outputs) {
37871
+ const sources = noEchoPositionSources(run);
37872
+ if (sources === void 0) return outputs;
37873
+ const templateValues = Object.create(null);
37874
+ for (const [name, definition] of Object.entries(run.constructPathTemplate?.Outputs ?? {})) templateValues[name] = definition?.Value;
37875
+ if (deps.outputsRun().outputsSourceUsable) for (const [name, value] of Object.entries(deps.outputsRun().outputsTemplateSource)) templateValues[name] = value;
37876
+ const coordinates = noEchoCoordinatesOf(templateValues, outputs, sources);
37877
+ if (coordinates.length === 0) return outputs;
37878
+ const maskedValues = new Set(coordinates.filter((coordinate) => coordinate.length === 1 && typeof coordinate[0] === "string").map((coordinate) => keyOrderFreeJson(outputs[coordinate[0]])));
37879
+ const aliasCoordinates = Object.keys(outputs).filter((key) => !Object.hasOwn(templateValues, key) && outputs[key] !== void 0 && !carriesSecretMask(outputs[key]) && maskedValues.has(keyOrderFreeJson(outputs[key]))).map((key) => [key]);
37880
+ return maskAtCoordinates(outputs, [...coordinates, ...aliasCoordinates]);
37881
+ }
37882
+ function getAttTargetsOf(node) {
37883
+ const targets = [];
37884
+ const seen = /* @__PURE__ */ new Set();
37885
+ const subVariable = /\$\{([^}!][^}]*)\}/g;
37886
+ const walk = (value) => {
37887
+ if (value === null || typeof value !== "object" || seen.has(value)) return;
37888
+ seen.add(value);
37889
+ if (Array.isArray(value)) {
37890
+ for (const item of value) walk(item);
37891
+ return;
37892
+ }
37893
+ const record = value;
37894
+ const getAtt = record["Fn::GetAtt"];
37895
+ if (typeof getAtt === "string" && getAtt.indexOf(".") > 0) {
37896
+ const dot = getAtt.indexOf(".");
37897
+ targets.push([getAtt.slice(0, dot), getAtt.slice(dot + 1)]);
37898
+ } else if (Array.isArray(getAtt) && typeof getAtt[0] === "string" && typeof getAtt[1] === "string") targets.push([getAtt[0], getAtt[1]]);
37899
+ const sub = record["Fn::Sub"];
37900
+ const text = typeof sub === "string" ? sub : Array.isArray(sub) ? sub[0] : void 0;
37901
+ if (typeof text === "string") for (const match of text.matchAll(subVariable)) {
37902
+ const name = match[1].trim();
37903
+ const dot = name.indexOf(".");
37904
+ if (dot > 0) targets.push([name.slice(0, dot), name.slice(dot + 1)]);
37905
+ }
37906
+ for (const child of Object.values(record)) walk(child);
37907
+ };
37908
+ walk(node);
37909
+ return targets;
37910
+ }
37911
+ async function noEchoAttributeOverridesFor(run, deps, desiredProps, stateResources, stackName) {
37912
+ const wanted = /* @__PURE__ */ new Map();
37913
+ for (const [logicalId, attribute] of getAttTargetsOf(desiredProps)) {
37914
+ const record = Object.hasOwn(stateResources, logicalId) ? stateResources[logicalId] : void 0;
37915
+ if (record === void 0) continue;
37916
+ if (noEchoAttributeNamesOf(record)?.includes(attribute) !== true) continue;
37917
+ if (!carriesSecretMask(record.attributes?.[attribute])) continue;
37918
+ if (!deps.perResourceSecrets().has(logicalId)) continue;
37919
+ const set = wanted.get(logicalId) ?? /* @__PURE__ */ new Set();
37920
+ set.add(attribute);
37921
+ wanted.set(logicalId, set);
37922
+ }
37923
+ if (wanted.size === 0) return void 0;
37924
+ const overrides = /* @__PURE__ */ new Map();
37925
+ for (const [logicalId, attributes] of wanted) {
37926
+ const record = stateResources[logicalId];
37927
+ let read = run.noEchoAttributeReads.get(logicalId);
37928
+ if (read === void 0) {
37929
+ read = (async () => {
37930
+ try {
37931
+ const { provider } = deps.providerRegistry.getProviderFor({
37932
+ resourceType: record.resourceType,
37933
+ properties: record.properties,
37934
+ provisionedBy: record.provisionedBy,
37935
+ previousProperties: record.properties
37936
+ });
37937
+ const outcome = await readRecordAttributes({
37938
+ provider,
37939
+ logicalId,
37940
+ resource: record,
37941
+ stackName,
37942
+ region: deps.stackRegion
37943
+ });
37944
+ return outcome.kind === "read" ? outcome.attributes : void 0;
37945
+ } catch {
37946
+ return;
37947
+ }
37948
+ })();
37949
+ run.noEchoAttributeReads.set(logicalId, read);
37950
+ }
37951
+ const live = await read;
37952
+ if (live === void 0) continue;
37953
+ const secrets = deps.perResourceSecrets().get(logicalId);
37954
+ const fresh = noEchoParameterPlaintextsOf(secrets);
37955
+ const positioned = run.noEchoPositionedValues.get(logicalId) ?? /* @__PURE__ */ new Set();
37956
+ const served = {};
37957
+ for (const attribute of attributes) {
37958
+ if (!Object.hasOwn(live, attribute)) continue;
37959
+ const value = live[attribute];
37960
+ if (typeof value === "string" && fresh.some((needle) => value === needle || value.includes(needle)) || value !== void 0 && positioned.has(keyOrderFreeJson(value))) served[attribute] = value;
37961
+ }
37962
+ if (Object.keys(served).length > 0) overrides.set(logicalId, served);
37963
+ }
37964
+ return overrides.size > 0 ? overrides : void 0;
37965
+ }
37966
+ function noEchoDiffComparison(run, deps, resources, template, conditions, parameterValues, stackName) {
37967
+ const sources = noEchoPositionSources(run, resources, template, conditions);
37968
+ if (sources === void 0) return void 0;
37969
+ const compare = noEchoComparison({
37970
+ sources,
37971
+ values: parameterValues,
37972
+ minNeedleLength: 4,
37973
+ publicTokens: /* @__PURE__ */ new Set([deps.stackRegion, ...stackName === void 0 ? [] : [stackName]])
37974
+ });
37975
+ return (input) => compare(input);
37976
+ }
37977
+ function freshNoEchoParametersWithDeclared(inherited, template) {
37978
+ const all = /* @__PURE__ */ new Set([...inherited ?? [], ...noEchoParameterNamesOf(template)]);
37979
+ return all.size > 0 ? all : void 0;
37980
+ }
37981
+ function noEchoComparisonForTemplate(template, knownConditions, values, resources, publicTokens, inheritedNoEchoParameters) {
37982
+ const sources = {
37983
+ parameters: /* @__PURE__ */ new Set([...noEchoParameterNamesOf(template), ...inheritedNoEchoParameters ?? []]),
37984
+ attributeIsNoEcho: (logicalId, attribute) => noEchoAttributeNamesOf(Object.hasOwn(resources, logicalId) ? resources[logicalId] : void 0)?.includes(attribute) === true,
37985
+ ...knownConditions !== void 0 && { conditions: knownConditions }
37986
+ };
37987
+ const compare = noEchoComparison({
37988
+ sources,
37989
+ values: values ?? {},
37990
+ minNeedleLength: 4,
37991
+ ...publicTokens !== void 0 && { publicTokens }
37992
+ });
37993
+ return (input) => compare(input);
37994
+ }
37995
+
37391
37996
  //#endregion
37392
37997
  //#region src/deployment/deploy-engine/rollback.ts
37393
37998
  function redactOperationsForJournal(operations) {
37394
37999
  return operations.map((op) => {
37395
38000
  const secrets = this.perResourceSecrets.get(op.logicalId);
37396
38001
  const templateProps = this.perResourceTemplateProps.get(op.logicalId);
37397
- const sources = templateProps === void 0 ? void 0 : this.noEchoPositionSources();
38002
+ const sources = templateProps === void 0 ? void 0 : noEchoPositionSources(this.noEchoRun);
37398
38003
  const byPosition = (bag) => sources === void 0 || templateProps === void 0 ? bag : maskAtCoordinates(bag, noEchoCoordinatesOf(templateProps, bag, sources));
37399
38004
  if ((!secrets || secrets.size === 0) && !op.previousState && sources === void 0) return op;
37400
38005
  const ownSecrets = secrets ?? /* @__PURE__ */ new Map();
@@ -37405,7 +38010,7 @@ function redactOperationsForJournal(operations) {
37405
38010
  const previous = next.previousState;
37406
38011
  const adopted = adoptedOrphanRecords.get(this);
37407
38012
  const loaded = adopted?.has(op.logicalId) ? adopted.get(op.logicalId) : previous;
37408
- next.previousState = this.applyNoEchoPersist(op.logicalId, previous, keepPersistedPlainRecordLeaves(scrubResourceRecord(previous, ownSecrets, void 0, STATE_SOURCED_READBACK_RULES), previous, loaded ?? {}), void 0, {}, void 0, true);
38013
+ next.previousState = applyNoEchoPersist(this.noEchoRun, this.noEchoDeps(), op.logicalId, previous, keepPersistedPlainRecordLeaves(scrubResourceRecord(previous, ownSecrets, void 0, STATE_SOURCED_READBACK_RULES), previous, loaded ?? {}), void 0, {}, void 0, true);
37409
38014
  }
37410
38015
  return next;
37411
38016
  });
@@ -37541,7 +38146,7 @@ function foreignHolderResolver(engine) {
37541
38146
  async function settleJournalAfterSuccess(stackName, completedOperations, previousState, finalResources, initialDeploy) {
37542
38147
  if (this.options.parentStackInfo) {
37543
38148
  await this.writeRollbackJournalSegment(stackName, completedOperations, [], NESTED_PENDING_PARENT_REASON, initialDeploy, nestedPendingSnapshot(previousState, (name) => {
37544
- const verdict = this.carriedExportAliasRefusal;
38149
+ const verdict = this.outputsRun.carriedExportAliasRefusal;
37545
38150
  const dropped = verdict === void 0 || verdict(name, name) !== void 0;
37546
38151
  if (dropped) this.logger.warn(verdict === void 0 ? "An export alias the previous record published was not kept for a revert of this nested stack: no export-name verdict is available." : "An export alias the previous record published was not kept for a revert of this nested stack: its name contains a NoEcho value.");
37547
38152
  return dropped;
@@ -37713,7 +38318,7 @@ async function writeRollbackJournalSegment(stackName, completedOperations, faile
37713
38318
  ...redactedFailed.length > 0 && { failedOperations: redactedFailed },
37714
38319
  ...nestedPending?.previousOutputs && { previousOutputs: {
37715
38320
  ...nestedPending.previousOutputs,
37716
- outputs: this.maskOutputsByPosition(nestedPending.previousOutputs.outputs)
38321
+ outputs: maskOutputsByPosition(this.noEchoRun, this.noEchoDeps(), nestedPending.previousOutputs.outputs)
37717
38322
  } },
37718
38323
  ...nestedPending?.previousCrossStackReads && { previousCrossStackReads: nestedPending.previousCrossStackReads }
37719
38324
  };
@@ -38046,42 +38651,158 @@ function recaptureMaskedBaseline(args) {
38046
38651
 
38047
38652
  //#endregion
38048
38653
  //#region src/deployment/deploy-engine/observed-capture.ts
38049
- function kickOffObservedCapture(provider, logicalId, physicalId, resourceType, resolvedProps, context, secrets, maskAt) {
38050
- if (this.options.captureObservedState !== true) return;
38051
- this.observedCaptureTasks.delete(logicalId);
38052
- if (!provider.readCurrentState) return;
38053
- const readCurrentState = provider.readCurrentState.bind(provider);
38054
- const read = () => readCurrentState(physicalId, logicalId, resourceType, resolvedProps, context).then((observed) => observed === RESOURCE_NOT_FOUND ? void 0 : maskAt === void 0 || observed === void 0 || maskAt.coordinates.length === 0 ? observed : maskReadbackAtCoordinates(observed, maskAt.properties, maskAt.coordinates), (err) => {
38055
- const mask = createUnionSecretMasker([
38056
- secrets,
38057
- this.printingSecretsFor(logicalId),
38058
- this.fingerprintNoEchoValues
38059
- ]);
38060
- this.logger.debug(safeMsg`observedProperties capture for ${mask(logicalId)} (${mask(resourceType)}) failed: ${asIsMessage(mask(err instanceof Error ? err.message : String(err)))} — drift will fall back to template properties for this resource until the next successful deploy.`);
38061
- });
38062
- const promise = secrets === void 0 ? read() : withCurrentResourceSecrets(secrets, read);
38063
- this.observedCaptureTasks.set(logicalId, promise);
38064
- }
38065
- async function drainObservedCaptures(stateResources) {
38066
- const captured = await this.drainProvenanceCaptures(stateResources);
38067
- if (this.observedCaptureTasks.size === 0) return captured;
38068
- const entries = Array.from(this.observedCaptureTasks.entries());
38069
- this.observedCaptureTasks.clear();
38070
- const resolved = await Promise.all(entries.map(([, p]) => p));
38071
- let installed = 0;
38072
- for (let i = 0; i < entries.length; i++) {
38073
- const logicalId = entries[i][0];
38074
- const observed = resolved[i];
38075
- const target = stateResources[logicalId];
38076
- const recapturedFrom = observed === void 0 ? void 0 : this.recapturedBaselines.get(observed);
38077
- if (recapturedFrom !== void 0 && target?.observedProperties !== recapturedFrom) continue;
38078
- if (target && observed !== void 0) {
38079
- installed++;
38080
- target.observedProperties = recapturedFrom !== void 0 ? observed : markSameGenerationBag({ ...observed });
38654
+ var ObservedCapture = class {
38655
+ observedCaptureTasks = /* @__PURE__ */ new Map();
38656
+ recapturedBaselines = /* @__PURE__ */ new WeakMap();
38657
+ deps;
38658
+ constructor(deps) {
38659
+ this.deps = deps;
38660
+ }
38661
+ kickOffObservedCapture(provider, logicalId, physicalId, resourceType, resolvedProps, context, secrets, maskAt) {
38662
+ if (this.deps.options.captureObservedState !== true) return;
38663
+ this.observedCaptureTasks.delete(logicalId);
38664
+ if (!provider.readCurrentState) return;
38665
+ const readCurrentState = provider.readCurrentState.bind(provider);
38666
+ const read = () => readCurrentState(physicalId, logicalId, resourceType, resolvedProps, context).then((observed) => observed === RESOURCE_NOT_FOUND ? void 0 : maskAt === void 0 || observed === void 0 || maskAt.coordinates.length === 0 ? observed : maskReadbackAtCoordinates(observed, maskAt.properties, maskAt.coordinates), (err) => {
38667
+ const mask = createUnionSecretMasker([
38668
+ secrets,
38669
+ this.deps.printingSecretsFor(logicalId),
38670
+ this.deps.fingerprintNoEchoValues()
38671
+ ]);
38672
+ this.deps.logger.debug(safeMsg`observedProperties capture for ${mask(logicalId)} (${mask(resourceType)}) failed: ${asIsMessage(mask(err instanceof Error ? err.message : String(err)))} — drift will fall back to template properties for this resource until the next successful deploy.`);
38673
+ });
38674
+ const promise = secrets === void 0 ? read() : withCurrentResourceSecrets(secrets, read);
38675
+ this.observedCaptureTasks.set(logicalId, promise);
38676
+ }
38677
+ async drainObservedCaptures(stateResources) {
38678
+ const captured = await this.deps.provenanceCapture().drainProvenanceCaptures(stateResources);
38679
+ if (this.observedCaptureTasks.size === 0) return captured;
38680
+ const entries = Array.from(this.observedCaptureTasks.entries());
38681
+ this.observedCaptureTasks.clear();
38682
+ const resolved = await Promise.all(entries.map(([, p]) => p));
38683
+ let installed = 0;
38684
+ for (let i = 0; i < entries.length; i++) {
38685
+ const logicalId = entries[i][0];
38686
+ const observed = resolved[i];
38687
+ const target = stateResources[logicalId];
38688
+ const recapturedFrom = observed === void 0 ? void 0 : this.recapturedBaselines.get(observed);
38689
+ if (recapturedFrom !== void 0 && target?.observedProperties !== recapturedFrom) continue;
38690
+ if (target && observed !== void 0) {
38691
+ installed++;
38692
+ target.observedProperties = recapturedFrom !== void 0 ? observed : markSameGenerationBag({ ...observed });
38693
+ }
38694
+ }
38695
+ return installed + captured;
38696
+ }
38697
+ kickOffAutoRefreshObservedProperties(stateResources, crossStackReads) {
38698
+ if (this.deps.options.captureObservedState !== true) return;
38699
+ if (this.deps.options.dryRun === true) return;
38700
+ let toRefresh = 0;
38701
+ let refused = 0;
38702
+ const candidates = [];
38703
+ const masked = [];
38704
+ for (const [logicalId, resource] of Object.entries(stateResources)) {
38705
+ if (!hasAddressablePhysicalId(resource)) continue;
38706
+ if (resource.observedProperties !== void 0) {
38707
+ if (isMaskedBaselineRecaptureCandidate(resource)) masked.push({
38708
+ logicalId,
38709
+ resource
38710
+ });
38711
+ continue;
38712
+ }
38713
+ if (resource.observedBaselineRefused === true) {
38714
+ refused++;
38715
+ continue;
38716
+ }
38717
+ candidates.push({
38718
+ logicalId,
38719
+ resource
38720
+ });
38721
+ }
38722
+ if (refused > 0) this.deps.logger.debug(safeMsg`observed-properties auto-refresh SKIPPED for ${refused} resource(s) whose baseline a 'cdkd import' run refused: their recorded properties cannot position the redaction, so capturing an AWS readback against them could persist a resolved secret in plaintext. A deploy that actually CHANGES one of them restores its baseline, unless the refusal is an unverifiable-parameter one (only a replacement or a proving re-import discharges that); a NO_CHANGE deploy never does.`);
38723
+ if (candidates.length === 0 && masked.length === 0) return;
38724
+ const allSiblings = {};
38725
+ for (const [lid, res] of Object.entries(stateResources)) allSiblings[lid] = {
38726
+ resourceType: res.resourceType,
38727
+ properties: res.properties ?? {}
38728
+ };
38729
+ for (const { logicalId, resource } of candidates) {
38730
+ let provider;
38731
+ try {
38732
+ provider = this.deps.providerRegistry.getProviderFor({
38733
+ resourceType: resource.resourceType,
38734
+ provisionedBy: resource.provisionedBy
38735
+ }).provider;
38736
+ } catch {
38737
+ continue;
38738
+ }
38739
+ if (!provider.readCurrentState) continue;
38740
+ const siblings = { ...allSiblings };
38741
+ delete siblings[logicalId];
38742
+ const recordProperties = resource.properties ?? {};
38743
+ const maskCoordinates = [...maskedLeafCoordinatesOf(recordProperties), ...noEchoLeavesOf(resource) ?? []];
38744
+ this.kickOffObservedCapture(provider, logicalId, resource.physicalId, resource.resourceType, recordProperties, { siblings }, void 0, maskCoordinates.length > 0 ? {
38745
+ properties: recordProperties,
38746
+ coordinates: maskCoordinates
38747
+ } : void 0);
38748
+ toRefresh++;
38749
+ }
38750
+ if (toRefresh > 0) this.deps.logger.warn(safeMsg`cdkd state schema upgrade detected — refreshing observed-properties baseline for ${toRefresh} resource(s) (one-time, runs in parallel with deploy)`);
38751
+ let producerRegions = [];
38752
+ if (masked.length > 0) try {
38753
+ producerRegions = producerRegionsFromState(crossStackReads);
38754
+ } catch {
38755
+ this.deps.logger.debug(safeMsg`Masked observed baseline re-capture skipped for ${masked.length} resource(s): the record's cross-stack reads could not be read.`);
38756
+ masked.length = 0;
38081
38757
  }
38758
+ for (const { logicalId, resource } of masked) {
38759
+ let provider;
38760
+ try {
38761
+ provider = this.deps.providerRegistry.getProviderFor({
38762
+ resourceType: resource.resourceType,
38763
+ provisionedBy: resource.provisionedBy
38764
+ }).provider;
38765
+ } catch {
38766
+ continue;
38767
+ }
38768
+ if (!provider.readCurrentState) continue;
38769
+ const siblings = { ...allSiblings };
38770
+ delete siblings[logicalId];
38771
+ this.kickOffMaskedBaselineRecapture(provider, logicalId, resource, producerRegions, { siblings });
38772
+ }
38773
+ }
38774
+ kickOffMaskedBaselineRecapture(provider, logicalId, resource, producerRegions, context) {
38775
+ const previous = resource.observedProperties;
38776
+ const readCurrentState = provider.readCurrentState?.bind(provider);
38777
+ if (previous === void 0 || readCurrentState === void 0) return;
38778
+ const properties = resource.properties ?? {};
38779
+ const task = (async () => {
38780
+ const secrets = await resolveRecordSecrets(properties, (token, own) => this.deps.resolver.resolveDynamicReferences(token, persistedTokenResolverContext(own, producerRegions)));
38781
+ if (secrets === void 0 || secrets.size === 0) {
38782
+ this.deps.logger.debug(safeMsg`Masked observed baseline of ${logicalId} kept: its recorded references did not all resolve to distinct values.`);
38783
+ return;
38784
+ }
38785
+ const readback = await withCurrentResourceSecrets(secrets, () => readCurrentState(resource.physicalId, logicalId, resource.resourceType, properties, context));
38786
+ if (readback === void 0 || readback === RESOURCE_NOT_FOUND) return void 0;
38787
+ const recaptured = recaptureMaskedBaseline({
38788
+ previous,
38789
+ readback,
38790
+ properties,
38791
+ secrets
38792
+ });
38793
+ if (recaptured === void 0) {
38794
+ this.deps.logger.debug(safeMsg`Masked observed baseline of ${logicalId} kept: no masked position could be certified, or the resource no longer reads back as its baseline records.`);
38795
+ return;
38796
+ }
38797
+ this.recapturedBaselines.set(recaptured, previous);
38798
+ this.deps.logger.debug(safeMsg`Re-captured the masked observed baseline of ${logicalId}.`);
38799
+ return recaptured;
38800
+ })().catch(() => {
38801
+ this.deps.logger.debug(safeMsg`Masked observed baseline of ${logicalId} kept: the re-capture failed.`);
38802
+ });
38803
+ this.observedCaptureTasks.set(logicalId, task);
38082
38804
  }
38083
- return installed + captured;
38084
- }
38805
+ };
38085
38806
  const STANDALONE_SIBLING = {
38086
38807
  Roles: {
38087
38808
  type: "AWS::IAM::RolePolicy",
@@ -38096,8 +38817,8 @@ const STANDALONE_SIBLING = {
38096
38817
  field: "GroupName"
38097
38818
  }
38098
38819
  };
38099
- async function buildObservedCaptureSiblings(resourceType, capturedLogicalId, capturedPhysicalId, template, stateResources, stackName, parameterValues, conditions) {
38100
- if (this.options.captureObservedState !== true) return void 0;
38820
+ async function buildObservedCaptureSiblings(deps, resourceType, capturedLogicalId, capturedPhysicalId, template, stateResources, stackName, parameterValues, conditions) {
38821
+ if (deps.options.captureObservedState !== true) return void 0;
38101
38822
  const attachmentField = resourceType === "AWS::IAM::Role" ? "Roles" : resourceType === "AWS::IAM::User" ? "Users" : resourceType === "AWS::IAM::Group" ? "Groups" : void 0;
38102
38823
  if (!attachmentField) return void 0;
38103
38824
  const resources = template?.Resources;
@@ -38115,14 +38836,14 @@ async function buildObservedCaptureSiblings(resourceType, capturedLogicalId, cap
38115
38836
  if (!attachments.some((a) => isRefTo(a, capturedLogicalId) || a === capturedPhysicalId)) continue;
38116
38837
  let policyName = props["PolicyName"];
38117
38838
  if (policyName !== void 0 && typeof policyName !== "string") {
38118
- resolverContext ??= this.buildResolverContext({
38839
+ resolverContext ??= deps.buildResolverContext({
38119
38840
  template,
38120
38841
  resources: stateResources,
38121
38842
  ...parameterValues && { parameters: parameterValues },
38122
38843
  ...conditions && { conditions }
38123
38844
  }, stackName);
38124
38845
  try {
38125
- policyName = await this.resolver.resolve(policyName, resolverContext);
38846
+ policyName = await deps.resolver.resolve(policyName, resolverContext);
38126
38847
  } catch {
38127
38848
  continue;
38128
38849
  }
@@ -38138,7 +38859,7 @@ async function buildObservedCaptureSiblings(resourceType, capturedLogicalId, cap
38138
38859
  }
38139
38860
  return Object.keys(siblings).length > 0 ? { siblings } : void 0;
38140
38861
  }
38141
- function stampReasonlessParameterRefusals(stateResources, template) {
38862
+ function stampReasonlessParameterRefusals(logger, stateResources, template) {
38142
38863
  let namesParameter;
38143
38864
  let stamped = 0;
38144
38865
  for (const [logicalId, resource] of Object.entries(stateResources)) {
@@ -38151,116 +38872,8 @@ function stampReasonlessParameterRefusals(stateResources, template) {
38151
38872
  };
38152
38873
  stamped++;
38153
38874
  }
38154
- if (namesParameter?.failedClosed !== void 0) this.logger.debug(safeMsg`The template's parameter dependence could not be judged (${namesParameter.failedClosed}): every observed-baseline refusal recorded without a reason is treated as an unverifiable-parameter refusal (${stamped} stamped).`);
38155
- if (stamped > 0) this.logger.debug(safeMsg`${stamped} resource(s) carry an observed-baseline refusal recorded without a reason by an older cdkd, and their template definition reads a template parameter: treated as an unverifiable-parameter refusal (kept until the resource is replaced or re-imported against a CloudFormation stack that proves the parameter).`);
38156
- }
38157
- function kickOffAutoRefreshObservedProperties(stateResources, crossStackReads) {
38158
- if (this.options.captureObservedState !== true) return;
38159
- if (this.options.dryRun === true) return;
38160
- let toRefresh = 0;
38161
- let refused = 0;
38162
- const candidates = [];
38163
- const masked = [];
38164
- for (const [logicalId, resource] of Object.entries(stateResources)) {
38165
- if (!hasAddressablePhysicalId(resource)) continue;
38166
- if (resource.observedProperties !== void 0) {
38167
- if (isMaskedBaselineRecaptureCandidate(resource)) masked.push({
38168
- logicalId,
38169
- resource
38170
- });
38171
- continue;
38172
- }
38173
- if (resource.observedBaselineRefused === true) {
38174
- refused++;
38175
- continue;
38176
- }
38177
- candidates.push({
38178
- logicalId,
38179
- resource
38180
- });
38181
- }
38182
- if (refused > 0) this.logger.debug(safeMsg`observed-properties auto-refresh SKIPPED for ${refused} resource(s) whose baseline a 'cdkd import' run refused: their recorded properties cannot position the redaction, so capturing an AWS readback against them could persist a resolved secret in plaintext. A deploy that actually CHANGES one of them restores its baseline, unless the refusal is an unverifiable-parameter one (only a replacement or a proving re-import discharges that); a NO_CHANGE deploy never does.`);
38183
- if (candidates.length === 0 && masked.length === 0) return;
38184
- const allSiblings = {};
38185
- for (const [lid, res] of Object.entries(stateResources)) allSiblings[lid] = {
38186
- resourceType: res.resourceType,
38187
- properties: res.properties ?? {}
38188
- };
38189
- for (const { logicalId, resource } of candidates) {
38190
- let provider;
38191
- try {
38192
- provider = this.providerRegistry.getProviderFor({
38193
- resourceType: resource.resourceType,
38194
- provisionedBy: resource.provisionedBy
38195
- }).provider;
38196
- } catch {
38197
- continue;
38198
- }
38199
- if (!provider.readCurrentState) continue;
38200
- const siblings = { ...allSiblings };
38201
- delete siblings[logicalId];
38202
- const recordProperties = resource.properties ?? {};
38203
- const maskCoordinates = [...maskedLeafCoordinatesOf(recordProperties), ...noEchoLeavesOf(resource) ?? []];
38204
- this.kickOffObservedCapture(provider, logicalId, resource.physicalId, resource.resourceType, recordProperties, { siblings }, void 0, maskCoordinates.length > 0 ? {
38205
- properties: recordProperties,
38206
- coordinates: maskCoordinates
38207
- } : void 0);
38208
- toRefresh++;
38209
- }
38210
- if (toRefresh > 0) this.logger.warn(safeMsg`cdkd state schema upgrade detected — refreshing observed-properties baseline for ${toRefresh} resource(s) (one-time, runs in parallel with deploy)`);
38211
- let producerRegions = [];
38212
- if (masked.length > 0) try {
38213
- producerRegions = producerRegionsFromState(crossStackReads);
38214
- } catch {
38215
- this.logger.debug(safeMsg`Masked observed baseline re-capture skipped for ${masked.length} resource(s): the record's cross-stack reads could not be read.`);
38216
- masked.length = 0;
38217
- }
38218
- for (const { logicalId, resource } of masked) {
38219
- let provider;
38220
- try {
38221
- provider = this.providerRegistry.getProviderFor({
38222
- resourceType: resource.resourceType,
38223
- provisionedBy: resource.provisionedBy
38224
- }).provider;
38225
- } catch {
38226
- continue;
38227
- }
38228
- if (!provider.readCurrentState) continue;
38229
- const siblings = { ...allSiblings };
38230
- delete siblings[logicalId];
38231
- this.kickOffMaskedBaselineRecapture(provider, logicalId, resource, producerRegions, { siblings });
38232
- }
38233
- }
38234
- function kickOffMaskedBaselineRecapture(provider, logicalId, resource, producerRegions, context) {
38235
- const previous = resource.observedProperties;
38236
- const readCurrentState = provider.readCurrentState?.bind(provider);
38237
- if (previous === void 0 || readCurrentState === void 0) return;
38238
- const properties = resource.properties ?? {};
38239
- const task = (async () => {
38240
- const secrets = await resolveRecordSecrets(properties, (token, own) => this.resolver.resolveDynamicReferences(token, persistedTokenResolverContext(own, producerRegions)));
38241
- if (secrets === void 0 || secrets.size === 0) {
38242
- this.logger.debug(safeMsg`Masked observed baseline of ${logicalId} kept: its recorded references did not all resolve to distinct values.`);
38243
- return;
38244
- }
38245
- const readback = await withCurrentResourceSecrets(secrets, () => readCurrentState(resource.physicalId, logicalId, resource.resourceType, properties, context));
38246
- if (readback === void 0 || readback === RESOURCE_NOT_FOUND) return void 0;
38247
- const recaptured = recaptureMaskedBaseline({
38248
- previous,
38249
- readback,
38250
- properties,
38251
- secrets
38252
- });
38253
- if (recaptured === void 0) {
38254
- this.logger.debug(safeMsg`Masked observed baseline of ${logicalId} kept: no masked position could be certified, or the resource no longer reads back as its baseline records.`);
38255
- return;
38256
- }
38257
- this.recapturedBaselines.set(recaptured, previous);
38258
- this.logger.debug(safeMsg`Re-captured the masked observed baseline of ${logicalId}.`);
38259
- return recaptured;
38260
- })().catch(() => {
38261
- this.logger.debug(safeMsg`Masked observed baseline of ${logicalId} kept: the re-capture failed.`);
38262
- });
38263
- this.observedCaptureTasks.set(logicalId, task);
38875
+ if (namesParameter?.failedClosed !== void 0) logger.debug(safeMsg`The template's parameter dependence could not be judged (${namesParameter.failedClosed}): every observed-baseline refusal recorded without a reason is treated as an unverifiable-parameter refusal (${stamped} stamped).`);
38876
+ if (stamped > 0) logger.debug(safeMsg`${stamped} resource(s) carry an observed-baseline refusal recorded without a reason by an older cdkd, and their template definition reads a template parameter: treated as an unverifiable-parameter refusal (kept until the resource is replaced or re-imported against a CloudFormation stack that proves the parameter).`);
38264
38877
  }
38265
38878
 
38266
38879
  //#endregion
@@ -38282,7 +38895,7 @@ function diffLogMasker(diffSecrets, template, parameterValues, resources) {
38282
38895
  return (text) => {
38283
38896
  if (!judged) {
38284
38897
  judged = true;
38285
- storedSecretNameNeedles(resources, this.fingerprintNoEchoValues, stateNames);
38898
+ storedSecretNameNeedles(resources, this.stateNamingSecrets(), stateNames);
38286
38899
  }
38287
38900
  return union(text);
38288
38901
  };
@@ -38312,34 +38925,34 @@ function rememberRecoverableMaskedOutputs(stackName, resolved, redacted) {
38312
38925
  }
38313
38926
  }
38314
38927
  function absorbOutputsPassSecrets() {
38315
- for (const passSecrets of this.outputsPassSecretMaps) {
38316
- for (const [value, expr] of passSecrets) this.outputSecrets.set(value, expr);
38317
- mergeResolvedPairs(passSecrets, this.outputSecrets);
38318
- for (const physicalId of physicalNameCopiesOf.get(passSecrets) ?? []) recordPhysicalNameCopy(this.outputSecrets, physicalId);
38928
+ for (const passSecrets of this.outputsRun.outputsPassSecretMaps) {
38929
+ for (const [value, expr] of passSecrets) this.outputsRun.outputSecrets.set(value, expr);
38930
+ mergeResolvedPairs(passSecrets, this.outputsRun.outputSecrets);
38931
+ for (const physicalId of physicalNameCopiesOf.get(passSecrets) ?? []) recordPhysicalNameCopy(this.outputsRun.outputSecrets, physicalId);
38319
38932
  }
38320
38933
  }
38321
38934
  function redactOutputs(outputs) {
38322
38935
  const redacted = redactOutputsBag.call(this, outputs);
38323
- if (this.outputsResolvedThisRun.has(outputs)) this.outputsResolvedThisRun.add(redacted);
38936
+ if (this.outputsRun.outputsResolvedThisRun.has(outputs)) this.outputsRun.outputsResolvedThisRun.add(redacted);
38324
38937
  return redacted;
38325
38938
  }
38326
38939
  function redactOutputsBag(outputs) {
38327
38940
  this.absorbOutputsPassSecrets();
38328
- if (this.outputSecrets.size === 0) return this.maskOutputsByPosition(outputs);
38329
- return this.maskOutputsByPosition(redactSecretsForState(outputs, this.outputSecrets, this.outputsSourceUsable ? this.outputsTemplateSource : void 0, TEMPLATE_SOURCED_RULES));
38941
+ if (this.outputsRun.outputSecrets.size === 0) return maskOutputsByPosition(this.noEchoRun, this.noEchoDeps(), outputs);
38942
+ return maskOutputsByPosition(this.noEchoRun, this.noEchoDeps(), redactSecretsForState(outputs, this.outputsRun.outputSecrets, this.outputsRun.outputsSourceUsable ? this.outputsRun.outputsTemplateSource : void 0, TEMPLATE_SOURCED_RULES));
38330
38943
  }
38331
38944
  function registerNoEchoAttributes(logicalId, result, secrets, ownProperties) {
38332
38945
  const declared = recordNoEchoAttributeValues(result, secrets, ownProperties);
38333
38946
  const echoed = echoedNoEchoAttributes(this, logicalId, result.attributes, secrets, ownProperties, result.physicalId);
38334
- if (declared === true) this.noEchoAttributeResources.set(logicalId, true);
38335
- else if (declared !== void 0 || echoed.size > 0) this.noEchoAttributeResources.set(logicalId, /* @__PURE__ */ new Set([...declared ?? [], ...echoed]));
38947
+ if (declared === true) this.noEchoRun.noEchoAttributeResources.set(logicalId, true);
38948
+ else if (declared !== void 0 || echoed.size > 0) this.noEchoRun.noEchoAttributeResources.set(logicalId, /* @__PURE__ */ new Set([...declared ?? [], ...echoed]));
38336
38949
  }
38337
38950
  function echoedNoEchoAttributes(engine, logicalId, attributes, secrets, ownProperties, physicalId) {
38338
38951
  const echoed = /* @__PURE__ */ new Set();
38339
38952
  if (attributes === void 0) return echoed;
38340
38953
  const fresh = [...freshNoEchoValuesOf.get(secrets) ?? []].filter((value) => isMaskOnlyPlaintext(secrets, value));
38341
38954
  const templateProps = engine.perResourceTemplateProps.get(logicalId);
38342
- const sources = engine.noEchoPositionSources();
38955
+ const sources = noEchoPositionSources(engine.noEchoRun);
38343
38956
  const positioned = /* @__PURE__ */ new Map();
38344
38957
  if (templateProps !== void 0 && ownProperties !== void 0 && sources !== void 0) for (const coordinate of noEchoCoordinatesOf(templateProps, ownProperties, {
38345
38958
  parameters: sources.parameters,
@@ -38373,12 +38986,12 @@ function refuseRedactedAttributeReads(logicalId, resourceType, context) {
38373
38986
  const producers = [...new Set(reads.map((read) => read.logicalId).filter((id) => !!id))];
38374
38987
  throw new ProvisioningError(safeMsg`Cannot resolve ${reads.map((read) => read.display).join(", ")} for ${logicalId}: ` + safeMsg`${producers.map((id) => displayIdent(id)).join(", ")} declared ${reads.length === 1 ? "that attribute" : "those attributes"} NoEcho, ` + safeMsg`so cdkd's recorded state holds only the redaction mask for ${reads.length === 1 ? "it" : "them"}, ` + `and cdkd does not re-run a producer to recover a value. Remedy: deploy a change to the ` + safeMsg`producer in the SAME run as ${logicalId} (for a custom resource, change one of its ` + "properties, e.g. a nonce / version property, so its handler runs again and supplies the value), or stop declaring the value NoEcho.", resourceType, logicalId);
38375
38988
  }
38376
- throw new ProvisioningError(safeMsg`Cannot resolve ${reads.map((read) => read.display).join(", ")} for ${logicalId}: cdkd's recorded state holds only the ` + `redaction mask there, and the value is not recoverable from state. There are three ways a record comes to hold the mask. (1) A custom resource handler declared its response NoEcho: true — the value is generated by the handler, so cdkd has nothing to re-derive it from and must not write the literal mask to AWS. Remedies: force that custom resource to update (change one of its properties, e.g. a nonce / version property) so its handler runs again and supplies the value in this same run; or stop setting NoEcho on that response. If the value comes from ANOTHER stack, the producer and this stack must deploy in ONE run (cdkd deploy --all, or cdkd deploy '**' when either is inside a CDK Stage) with the producer's custom resource actually running — re-deploying the producer by itself does not help, because it re-masks the value on the way into its own state. (2) The value holds the Fn::Base64 encoding of a secret value (a {{resolve:...}} dynamic reference under Fn::Base64, such as EC2 UserData), which cdkd never records — so a deploy that leaves the resource or output holding it unchanged reads the mask again, and a re-import does not recover it. Remedy: have this resource build the value itself from the SECRET's own reference (the {{resolve:secretsmanager:...}} or {{resolve:ssm-secure:...}} reference, or a {{resolve:ssm:...}} of a SecureString parameter, that the encoding was made from) under its own Fn::Base64, instead of reading it from another resource's attribute or another stack's output — not by a {{resolve:ssm:...}} read of a String parameter holding the encoding, which cdkd treats as public and would record in state in the clear. (3) The resource is recorded through the Cloud Control fallback (by a deploy or by 'cdkd import'), which keeps in the clear only the Fn::GetAtt attributes it can vouch for and masks the rest. If the name above is not an Fn::GetAtt attribute CloudFormation accepts for that resource type, no record will ever hold it: stop reading it. If it is one, 'cdkd import' masked it because it could not vouch for the value, or could not read the schema and warned about it when it happened (if that warning named a missing cloudformation:DescribeType permission, grant it first); a deploy that creates or updates the resource records it, unless its value came from a secret. See https://github.com/go-to-k/cdkd/issues/2449. ${DeployEngine.maskedRecordRemedyFor(reads, context.resources, true)}`, resourceType, logicalId);
38989
+ throw new ProvisioningError(safeMsg`Cannot resolve ${reads.map((read) => read.display).join(", ")} for ${logicalId}: cdkd's recorded state holds only the ` + `redaction mask there, and the value is not recoverable from state. There are four ways a record comes to hold the mask. (1) A custom resource handler declared its response NoEcho: true — the value is generated by the handler, so cdkd has nothing to re-derive it from and must not write the literal mask to AWS. Remedies: force that custom resource to update (change one of its properties, e.g. a nonce / version property) so its handler runs again and supplies the value in this same run; or stop setting NoEcho on that response. If the value comes from ANOTHER stack, the producer and this stack must deploy in ONE run (cdkd deploy --all, or cdkd deploy '**' when either is inside a CDK Stage) with the producer's custom resource actually running — re-deploying the producer by itself does not help, because it re-masks the value on the way into its own state. (2) The value holds the Fn::Base64 encoding of a secret value (a {{resolve:...}} dynamic reference under Fn::Base64, such as EC2 UserData), which cdkd never records — so a deploy that leaves the resource or output holding it unchanged reads the mask again, and a re-import does not recover it. Remedy: have this resource build the value itself from the SECRET's own reference (the {{resolve:secretsmanager:...}} or {{resolve:ssm-secure:...}} reference, or a {{resolve:ssm:...}} of a SecureString parameter, that the encoding was made from) under its own Fn::Base64, instead of reading it from another resource's attribute or another stack's output — not by a {{resolve:ssm:...}} read of a String parameter holding the encoding, which cdkd treats as public and would record in state in the clear. (3) The resource is recorded through the Cloud Control fallback (by a deploy or by 'cdkd import'), which keeps in the clear only the Fn::GetAtt attributes it can vouch for and masks the rest. If the name above is not an Fn::GetAtt attribute CloudFormation accepts for that resource type, no record will ever hold it: stop reading it. If it is one, 'cdkd import' masked it because it could not vouch for the value, or could not read the schema and warned about it when it happened (if that warning named a missing cloudformation:DescribeType permission, grant it first); a deploy that creates or updates the resource records it, unless its value came from a secret. (4) Two secret values cdkd resolved overlap inside the value, so no single {{resolve:...}} reference renders it and cdkd stored the mask rather than part of a secret: change the producer's value (or rotate one of the secrets) so that they no longer overlap, and deploy the producer in the same run as this resource. See https://github.com/go-to-k/cdkd/issues/2449. ${DeployEngine.maskedRecordRemedyFor(reads, context.resources, true)}`, resourceType, logicalId);
38377
38990
  }
38378
38991
  function allRecordedSecrets() {
38379
38992
  const all = /* @__PURE__ */ new Map();
38380
38993
  for (const bag of this.perResourceSecrets.values()) for (const [plaintext, expression] of bag) all.set(plaintext, expression);
38381
- for (const [plaintext, expression] of this.outputSecrets) all.set(plaintext, expression);
38994
+ for (const [plaintext, expression] of this.outputsRun.outputSecrets) all.set(plaintext, expression);
38382
38995
  return all;
38383
38996
  }
38384
38997
  async function readReaderForFreshNoEchoCeiling(logicalId, currentResource, secrets) {
@@ -38434,8 +39047,39 @@ function noteSecretNamedRecord(logicalId, record) {
38434
39047
  function namingSecretsFor(logicalId) {
38435
39048
  const own = this.perResourceSecrets.get(logicalId);
38436
39049
  const noEcho = this.fingerprintNoEchoValues;
38437
- if (!hasMaskableValues(noEcho)) return own;
38438
- return unionOfSecretBags([own, noEcho]);
39050
+ const stored = this.storedNoEchoNamingValues.get(logicalId);
39051
+ if (!hasMaskableValues(noEcho) && !hasMaskableValues(stored)) return own;
39052
+ return unionOfSecretBags([
39053
+ own,
39054
+ noEcho,
39055
+ stored
39056
+ ]);
39057
+ }
39058
+ function stateNamingSecrets() {
39059
+ const base = this.fingerprintNoEchoValues;
39060
+ const stored = this.storedNoEchoNamingValues;
39061
+ if (stored.size === 0) return base;
39062
+ const hit = namingSecretsMemo.get(stored);
39063
+ if (hit !== void 0 && hit.base === base) return hit.secrets;
39064
+ const secrets = namingSecretsWithRecordedNoEcho(base, (logicalId) => stored.get(logicalId));
39065
+ namingSecretsMemo.set(stored, {
39066
+ base,
39067
+ secrets
39068
+ });
39069
+ return secrets;
39070
+ }
39071
+ const namingSecretsMemo = /* @__PURE__ */ new WeakMap();
39072
+ function captureStoredNoEchoNamingValues(resources, template, conditions) {
39073
+ const names = new Set(this.noEchoRun.inheritedNoEchoParameters);
39074
+ for (const [name, definition] of Object.entries(template.Parameters ?? {})) if (declaresNoEcho(definition)) names.add(name);
39075
+ const templateResources = template.Resources ?? {};
39076
+ const captured = /* @__PURE__ */ new Map();
39077
+ for (const [logicalId, record] of Object.entries(resources)) {
39078
+ const templateResource = Object.hasOwn(templateResources, logicalId) ? templateResources[logicalId] : void 0;
39079
+ const bag = recordedNoEchoValuesOf(templateResource?.Type === record?.resourceType ? templateResource?.Properties : void 0, record, names, conditions);
39080
+ if (hasMaskableValues(bag)) captured.set(logicalId, bag);
39081
+ }
39082
+ this.storedNoEchoNamingValues = captured;
38439
39083
  }
38440
39084
  function noteSecretNamedReads(logicalId, record, resources) {
38441
39085
  const read = secretNamesReadBy(logicalId, record, resources, (otherId) => ({
@@ -38792,143 +39436,96 @@ function warnUnretriedReplacedDeletes(why) {
38792
39436
  }
38793
39437
 
38794
39438
  //#endregion
38795
- //#region src/deployment/read-only-attribute-healer.ts
38796
- async function readRecordAttributes(input) {
38797
- const { provider, logicalId, resource, stackName, region } = input;
38798
- if (!provider.import) return { kind: "not-attempted" };
38799
- if (!hasAddressablePhysicalId(resource)) return { kind: "not-attempted" };
38800
- const found = await provider.import({
38801
- logicalId,
38802
- resourceType: resource.resourceType,
38803
- stackName,
38804
- region,
38805
- properties: resource.properties,
38806
- knownPhysicalId: resource.physicalId
38807
- });
38808
- if (found === null) return { kind: "not-found" };
38809
- if (found.physicalId !== resource.physicalId) throw new Error(`the provider answered for a different resource (${found.physicalId}) than the one asked about (${resource.physicalId})`);
38810
- const reported = Object.entries(normalizeHealedAttributes(found.attributes));
38811
- const attributes = Object.fromEntries(reported.filter(([, value]) => !carriesSecretMask(value)));
38812
- const withheldKeys = reported.filter(([, value]) => carriesSecretMask(value)).map(([key]) => key);
38813
- return {
38814
- kind: "read",
38815
- attributes,
38816
- ...withheldKeys.length > 0 && { withheldKeys }
38817
- };
38818
- }
38819
- function createReadOnlyAttributeHealerFactory(options) {
38820
- const logger = getLogger().child("ReadOnlyAttributeHealer");
38821
- const memo = /* @__PURE__ */ new Map();
38822
- const readOnce = (stackName, region, logicalId, resource) => {
38823
- let key;
38824
- try {
38825
- if (isHealExcludedType(resource.resourceType)) return Promise.resolve({ kind: "not-attempted" });
38826
- key = injectiveKey(stackName, region, logicalId, resource.physicalId);
38827
- } catch (error) {
38828
- return Promise.resolve({
38829
- kind: "failed",
38830
- error
38831
- });
38832
- }
38833
- const inFlight = memo.get(key);
39439
+ //#region src/deployment/deploy-engine/attribute-healer.ts
39440
+ var AttributeHealer = class {
39441
+ heals = /* @__PURE__ */ new Map();
39442
+ healed = /* @__PURE__ */ new Map();
39443
+ deps;
39444
+ constructor(deps) {
39445
+ this.deps = deps;
39446
+ }
39447
+ get baseline() {
39448
+ return this.deps.baseline;
39449
+ }
39450
+ heal(logicalId, resource, stackName) {
39451
+ if (!this.isEligible(logicalId, resource)) return Promise.resolve({ kind: "not-attempted" });
39452
+ const key = injectiveKey(logicalId, resource.physicalId);
39453
+ const inFlight = this.heals.get(key);
38834
39454
  if (inFlight) return inFlight;
38835
- const heal = (async () => options.inRegion(region, () => readRecordAttributes({
38836
- provider: options.getProvider(resource, region),
38837
- logicalId,
38838
- resource,
38839
- stackName,
38840
- region
38841
- })))().then((outcome) => {
38842
- if (outcome.kind === "read") try {
38843
- logger.debug(safeMsg`Re-read the attributes of ${displaySafe(logicalId)} (${displaySafe(resource.resourceType)}) from AWS for this preview — its state record lacked one a Fn::GetAtt asked for; nothing is written: ${Object.keys(outcome.attributes).length} attribute(s) read`);
38844
- } catch {}
38845
- return outcome;
38846
- }).catch((error) => ({
39455
+ const heal = this.read(logicalId, resource, stackName).catch((error) => ({
38847
39456
  kind: "failed",
38848
39457
  error
38849
39458
  }));
38850
- memo.set(key, heal);
39459
+ this.heals.set(key, heal);
38851
39460
  return heal;
38852
- };
38853
- return (stackName, region) => Object.assign((logicalId, resource) => readOnce(stackName, region, logicalId, resource), { readOnly: true });
38854
- }
38855
-
38856
- //#endregion
38857
- //#region src/deployment/deploy-engine/heal.ts
38858
- function healStaleAttributes(logicalId, resource, stackName) {
38859
- if (!this.isHealEligible(logicalId, resource)) return Promise.resolve({ kind: "not-attempted" });
38860
- const key = injectiveKey(logicalId, resource.physicalId);
38861
- const inFlight = this.attributeHeals.get(key);
38862
- if (inFlight) return inFlight;
38863
- const heal = this.readStaleAttributes(logicalId, resource, stackName).catch((error) => ({
38864
- kind: "failed",
38865
- error
38866
- }));
38867
- this.attributeHeals.set(key, heal);
38868
- return heal;
38869
- }
38870
- function isHealEligible(logicalId, resource) {
38871
- const loaded = Object.hasOwn(this.healBaseline, logicalId) ? this.healBaseline[logicalId] : void 0;
38872
- return loaded !== void 0 && loaded.physicalId === resource.physicalId && loaded.attributes === resource.attributes && !isHealExcludedType(resource.resourceType);
38873
- }
39461
+ }
39462
+ isEligible(logicalId, resource) {
39463
+ const { baseline } = this.deps;
39464
+ const loaded = Object.hasOwn(baseline, logicalId) ? baseline[logicalId] : void 0;
39465
+ return loaded !== void 0 && loaded.physicalId === resource.physicalId && loaded.attributes === resource.attributes && !isHealExcludedType(resource.resourceType);
39466
+ }
39467
+ async read(logicalId, resource, stackName) {
39468
+ const { provider } = this.deps.providerRegistry.getProviderFor({
39469
+ resourceType: resource.resourceType,
39470
+ properties: resource.properties,
39471
+ provisionedBy: resource.provisionedBy,
39472
+ previousProperties: resource.properties
39473
+ });
39474
+ const outcome = await withPrintingSecrets(healPrintingBag(this.deps.baseline, logicalId, resource, this.deps.namingSecrets()), () => readRecordAttributes({
39475
+ provider,
39476
+ logicalId,
39477
+ resource,
39478
+ stackName,
39479
+ region: this.deps.stackRegion
39480
+ }));
39481
+ if (outcome.kind !== "read") return outcome;
39482
+ const { attributes } = outcome;
39483
+ if (Object.keys(attributes).length > 0) this.healed.set(logicalId, {
39484
+ physicalId: resource.physicalId,
39485
+ resourceType: resource.resourceType,
39486
+ attributes
39487
+ });
39488
+ this.deps.logger.debug(safeMsg`Re-read the attributes of ${displaySafe(logicalId)} (${displaySafe(resource.resourceType)}) from AWS — its state record lacked one a Fn::GetAtt asked for: ${Object.keys(attributes).length} attribute(s) read`);
39489
+ return outcome;
39490
+ }
39491
+ withHealedAttributes(logicalId, record) {
39492
+ const healed = this.healed.get(logicalId);
39493
+ if (healed === void 0 || healed.physicalId !== record.physicalId || healed.resourceType !== record.resourceType || !this.isEligible(logicalId, record)) return record;
39494
+ const merged = mergeHealedAttributes(record.attributes, healed.attributes, (key, value, healedValue) => isStalePlaceholderArnAttribute(record.resourceType, key, value) || isMaskedOwnIdCopy(record, key, value, healedValue, this.deps.resolvedSecretsOf(logicalId)));
39495
+ return merged === record.attributes || merged === void 0 ? record : {
39496
+ ...record,
39497
+ attributes: merged
39498
+ };
39499
+ }
39500
+ hasUnpersistedHeals(resources) {
39501
+ for (const logicalId of this.healed.keys()) {
39502
+ const record = Object.hasOwn(resources, logicalId) ? resources[logicalId] : void 0;
39503
+ if (record !== void 0 && this.withHealedAttributes(logicalId, record) !== record) return true;
39504
+ }
39505
+ return false;
39506
+ }
39507
+ };
38874
39508
  const healJudges = /* @__PURE__ */ new WeakMap();
38875
- function healPrintingBag(baseline, logicalId, resource) {
38876
- if (!Object.hasOwn(baseline, logicalId) || baseline[logicalId] !== resource) return secretNamePrintingBag(logicalId, {
39509
+ function healPrintingBag(baseline, logicalId, resource, namingSecrets) {
39510
+ if (!Object.hasOwn(baseline, logicalId) || baseline[logicalId] !== resource) return secretNamePrintingBags({
38877
39511
  ...baseline,
38878
39512
  [logicalId]: resource
38879
- });
38880
- let judge = healJudges.get(baseline);
38881
- if (judge === void 0) {
38882
- judge = secretNamePrintingBags(baseline, void 0);
38883
- healJudges.set(baseline, judge);
38884
- }
38885
- return judge(logicalId);
38886
- }
38887
- async function readStaleAttributes(logicalId, resource, stackName) {
38888
- const { provider } = this.providerRegistry.getProviderFor({
38889
- resourceType: resource.resourceType,
38890
- properties: resource.properties,
38891
- provisionedBy: resource.provisionedBy,
38892
- previousProperties: resource.properties
38893
- });
38894
- const outcome = await withPrintingSecrets(healPrintingBag(this.healBaseline, logicalId, resource), () => readRecordAttributes({
38895
- provider,
38896
- logicalId,
38897
- resource,
38898
- stackName,
38899
- region: this.stackRegion
38900
- }));
38901
- if (outcome.kind !== "read") return outcome;
38902
- const { attributes } = outcome;
38903
- if (Object.keys(attributes).length > 0) this.healedAttributes.set(logicalId, {
38904
- physicalId: resource.physicalId,
38905
- resourceType: resource.resourceType,
38906
- attributes
38907
- });
38908
- this.logger.debug(safeMsg`Re-read the attributes of ${displaySafe(logicalId)} (${displaySafe(resource.resourceType)}) from AWS — its state record lacked one a Fn::GetAtt asked for: ${Object.keys(attributes).length} attribute(s) read`);
38909
- return outcome;
38910
- }
38911
- function withHealedAttributes(logicalId, record) {
38912
- const healed = this.healedAttributes.get(logicalId);
38913
- if (healed === void 0 || healed.physicalId !== record.physicalId || healed.resourceType !== record.resourceType || !this.isHealEligible(logicalId, record)) return record;
38914
- const merged = mergeHealedAttributes(record.attributes, healed.attributes, (key, value, healedValue) => isStalePlaceholderArnAttribute(record.resourceType, key, value) || isMaskedOwnIdCopy(record, key, value, healedValue, this.perResourceSecrets.get(logicalId)));
38915
- return merged === record.attributes || merged === void 0 ? record : {
38916
- ...record,
38917
- attributes: merged
38918
- };
38919
- }
38920
- function hasUnpersistedHeals(resources) {
38921
- for (const logicalId of this.healedAttributes.keys()) {
38922
- const record = Object.hasOwn(resources, logicalId) ? resources[logicalId] : void 0;
38923
- if (record !== void 0 && this.withHealedAttributes(logicalId, record) !== record) return true;
39513
+ }, namingSecrets)(logicalId);
39514
+ let hit = healJudges.get(baseline);
39515
+ if (hit === void 0 || hit.namingSecrets !== namingSecrets) {
39516
+ hit = {
39517
+ namingSecrets,
39518
+ judge: secretNamePrintingBags(baseline, namingSecrets)
39519
+ };
39520
+ healJudges.set(baseline, hit);
38924
39521
  }
38925
- return false;
39522
+ return hit.judge(logicalId);
38926
39523
  }
38927
39524
 
38928
39525
  //#endregion
38929
39526
  //#region src/deployment/deploy-engine/record-shape.ts
38930
- function auditResolvedAssetReferences(logicalId, resourceType, resolvedProps) {
38931
- const redirect = this.options.assetRedirect;
39527
+ function auditResolvedAssetReferences(options, logicalId, resourceType, resolvedProps) {
39528
+ const redirect = options.assetRedirect;
38932
39529
  if (!redirect) return;
38933
39530
  const findings = findUnrewrittenAssetReferences(resolvedProps, redirect);
38934
39531
  if (findings.length === 0) return;
@@ -38963,6 +39560,57 @@ function acceptedCreateOnlyDropsField(recordedProperties, resourceType, provisio
38963
39560
  const names = findSilentDropProperties(resourceType, recordedProperties).map(({ property }) => property).filter((property) => createOnly.has(property) && (carried === void 0 || carried.has(property)));
38964
39561
  return { acceptedCreateOnlyDrops: names.length > 0 ? names : void 0 };
38965
39562
  }
39563
+ function secretNamedAttributesField(result, previous) {
39564
+ const reported = result.secretNamedAttributeNames;
39565
+ const source = reported !== void 0 ? reported : previous?.secretNamedAttributes;
39566
+ if (!Array.isArray(source)) return {};
39567
+ const names = source.filter((name) => typeof name === "string" && name !== "");
39568
+ return names.length > 0 ? { secretNamedAttributes: names } : {};
39569
+ }
39570
+
39571
+ //#endregion
39572
+ //#region src/deployment/label-routing.ts
39573
+ function deriveLabelRouting(change, existingState, registry, forceCcApi = false) {
39574
+ try {
39575
+ if (change.changeType === "DELETE") return existingState?.provisionedBy;
39576
+ return registry.getProviderFor({
39577
+ resourceType: change.resourceType,
39578
+ properties: change.desiredProperties ?? {},
39579
+ provisionedBy: existingState?.provisionedBy,
39580
+ previousProperties: existingState?.properties,
39581
+ forceCcApi
39582
+ }).provisionedBy;
39583
+ } catch {
39584
+ return;
39585
+ }
39586
+ }
39587
+
39588
+ //#endregion
39589
+ //#region src/deployment/deploy-engine/routing.ts
39590
+ function isPinnedToCcApi(options, stackName, logicalId) {
39591
+ return options.pinCcApi?.stackName === stackName && options.pinCcApi.logicalIds.has(logicalId);
39592
+ }
39593
+ function recreateDirectionFor(options, stackName, logicalId) {
39594
+ const targets = options.recreateTargets?.stackName === stackName ? options.recreateTargets : void 0;
39595
+ if (targets === void 0) return void 0;
39596
+ if (targets.viaCcApi.has(logicalId)) return "cc-api";
39597
+ if (targets.viaSdkProvider.has(logicalId)) return "sdk";
39598
+ }
39599
+ function peekRoutingForLabel(providerRegistry, options, change, existingState, stackName, logicalId, needsReplacement = false, recreateDirection) {
39600
+ if (needsReplacement) {
39601
+ const hintRecord = {
39602
+ ...recreateDirection !== void 0 && { provisionedBy: recreateDirection },
39603
+ ...existingState?.properties !== void 0 && { properties: existingState.properties }
39604
+ };
39605
+ return deriveLabelRouting(change, hintRecord, providerRegistry, recreateDirection === "cc-api");
39606
+ }
39607
+ return deriveLabelRouting(change, existingState, providerRegistry, isPinnedToCcApi(options, stackName, logicalId));
39608
+ }
39609
+ function preparePropertiesForCcApi(providerRegistry, resourceType, resolvedProps, logicalId) {
39610
+ const sdkProvider = providerRegistry.getRegisteredTypes().includes(resourceType) ? providerRegistry.getProvider(resourceType) : void 0;
39611
+ if (sdkProvider?.preparePropertiesForFallback) return sdkProvider.preparePropertiesForFallback(logicalId, resourceType, resolvedProps);
39612
+ return applyDefaultNameForFallback(logicalId, resourceType, resolvedProps);
39613
+ }
38966
39614
 
38967
39615
  //#endregion
38968
39616
  //#region src/utils/resource-line.ts
@@ -39063,12 +39711,12 @@ function buildResolverContext(base, stackName) {
39063
39711
  ...this.exportIndexStore && { exportIndex: this.exportIndexStore },
39064
39712
  recordedImports: this.recordedImports,
39065
39713
  recordedOutputReads: this.recordedOutputReads,
39066
- attributeHealer: (logicalId, resource) => this.healStaleAttributes(logicalId, resource, stackName),
39714
+ attributeHealer: (logicalId, resource) => this.attributeHealer.heal(logicalId, resource, stackName),
39067
39715
  ...this.options.inheritedSecrets && hasMaskableValues(this.options.inheritedSecrets) && { inheritedSecrets: this.options.inheritedSecrets },
39068
39716
  ...this.options.inheritedPhysicalNameCopies && { inheritedPhysicalNameCopies: this.options.inheritedPhysicalNameCopies },
39069
39717
  ...this.options.inheritedReferenceProvenance && { inheritedReferenceProvenance: this.options.inheritedReferenceProvenance },
39070
39718
  recordedSecretValues,
39071
- noEchoAttributeResources: this.noEchoAttributeResources,
39719
+ noEchoAttributeResources: this.noEchoRun.noEchoAttributeResources,
39072
39720
  secretNameNeedles: (logicalId) => this.noteSecretNamedRecord(logicalId, Object.hasOwn(base.resources, logicalId) ? base.resources[logicalId] : void 0),
39073
39721
  producerSecrets: (logicalId) => this.perResourceSecrets.get(logicalId),
39074
39722
  secretRegionEvidence: () => this.runProducerRegionEvidence?.(),
@@ -39143,7 +39791,7 @@ async function provisionCreate(logicalId, change, stateResources, stackName, tem
39143
39791
  redactedAttributeReads: []
39144
39792
  }, stackName);
39145
39793
  if (context.recordedSecretValues) this.perResourceSecrets.set(logicalId, context.recordedSecretValues);
39146
- const noEchoOverrides = await this.noEchoAttributeOverridesFor(desiredProps, stateResources, stackName);
39794
+ const noEchoOverrides = await noEchoAttributeOverridesFor(this.noEchoRun, this.noEchoDeps(), desiredProps, stateResources, stackName);
39147
39795
  if (noEchoOverrides !== void 0) context.noEchoAttributeOverrides = noEchoOverrides;
39148
39796
  printNestedStackReadsOnly(context, resourceType, this.secretNameBagFor(logicalId));
39149
39797
  const resolvedProps = await this.resolver.resolve(desiredProps, context);
@@ -39161,17 +39809,17 @@ async function provisionCreate(logicalId, change, stateResources, stackName, tem
39161
39809
  ]), inputFingerprinter(desiredProps, fingerprintSources)));
39162
39810
  this.perResourceResolvedType.set(logicalId, resourceType);
39163
39811
  const createSecrets = context.recordedSecretValues ?? /* @__PURE__ */ new Map();
39164
- if (resourceType === "AWS::CloudFormation::Stack") recordPassedNoEchoParameters(createSecrets, desiredProps["Parameters"], this.noEchoPositionSources(stateResources));
39812
+ if (resourceType === "AWS::CloudFormation::Stack") recordPassedNoEchoParameters(createSecrets, desiredProps["Parameters"], noEchoPositionSources(this.noEchoRun, stateResources));
39165
39813
  if (fingerprintSources !== void 0 && resourceType === "AWS::CloudFormation::Stack") recordPassedParameterClasses(createSecrets, await classifyPassedParameters(desiredProps["Parameters"], fingerprintSources));
39166
39814
  recordNestedStackParameterExpressions(createSecrets, resourceType, resolvedProps, desiredProps);
39167
- this.auditResolvedAssetReferences(logicalId, resourceType, resolvedProps);
39815
+ auditResolvedAssetReferences(this.options, logicalId, resourceType, resolvedProps);
39168
39816
  this.attemptedResolvedProps.set(logicalId, resolvedProps);
39169
39817
  const createDecision = this.providerRegistry.getProviderFor({
39170
39818
  resourceType,
39171
39819
  properties: resolvedProps
39172
39820
  });
39173
39821
  const createProvider = createDecision.provider;
39174
- const createProps = createDecision.provisionedBy === "cc-api" ? this.preparePropertiesForCcApi(resourceType, resolvedProps, logicalId) : resolvedProps;
39822
+ const createProps = createDecision.provisionedBy === "cc-api" ? preparePropertiesForCcApi(this.providerRegistry, resourceType, resolvedProps, logicalId) : resolvedProps;
39175
39823
  const resumed = await resumeAbandonedCreate.call(this, {
39176
39824
  logicalId,
39177
39825
  resourceType,
@@ -39214,23 +39862,28 @@ async function provisionCreate(logicalId, change, stateResources, stackName, tem
39214
39862
  }
39215
39863
  this.generatedNameGuard?.noteReturned(logicalId);
39216
39864
  this.registerNoEchoAttributes(logicalId, result, createSecrets, resolvedProps);
39217
- const dependencies = this.extractAllDependencies(template, logicalId);
39218
- const templateAttrs = this.extractTemplateAttributes(template, logicalId);
39219
- const recordedProperties = this.propertiesToRecord(resolvedProps, result, resourceType, createDecision.provisionedBy);
39865
+ const dependencies = extractAllDependencies(template, logicalId);
39866
+ const templateAttrs = extractTemplateAttributes(template, logicalId);
39867
+ const recordedProperties = propertiesToRecord(resolvedProps, result, resourceType, createDecision.provisionedBy);
39220
39868
  stateResources[logicalId] = {
39221
39869
  physicalId: result.physicalId,
39222
39870
  resourceType,
39223
39871
  properties: recordedProperties,
39224
39872
  ...acceptedCreateOnlyDropsField(recordedProperties, resourceType, createDecision.provisionedBy, "new-resource"),
39225
39873
  ...result.attributes && { attributes: result.attributes },
39874
+ ...secretNamedAttributesField(result),
39226
39875
  ...dependencies && dependencies.length > 0 && { dependencies },
39227
39876
  ...templateAttrs,
39228
39877
  provisionedBy: createDecision.provisionedBy
39229
39878
  };
39230
39879
  this.recordInlinePolicyWrite(logicalId, "create");
39231
- await this.establishNoEchoEchoFidelity(logicalId, stateResources[logicalId], resolvedProps, stateResources, createSecrets);
39232
- const createCaptureSiblings = await this.buildObservedCaptureSiblings(resourceType, logicalId, result.physicalId, template, stateResources, stackName, parameterValues, conditions);
39233
- this.kickOffObservedCapture(createProvider, logicalId, result.physicalId, resourceType, resolvedProps, {
39880
+ await establishNoEchoEchoFidelity(this.noEchoRun, this.noEchoDeps(), logicalId, stateResources[logicalId], resolvedProps, stateResources, createSecrets);
39881
+ const createCaptureSiblings = await buildObservedCaptureSiblings({
39882
+ options: this.options,
39883
+ buildResolverContext: (...args) => this.buildResolverContext(...args),
39884
+ resolver: this.resolver
39885
+ }, resourceType, logicalId, result.physicalId, template, stateResources, stackName, parameterValues, conditions);
39886
+ this.observedCapture.kickOffObservedCapture(createProvider, logicalId, result.physicalId, resourceType, resolvedProps, {
39234
39887
  ...createCaptureSiblings,
39235
39888
  afterOwnWrite: true
39236
39889
  }, createSecrets);
@@ -39722,7 +40375,7 @@ var DynamoDBGlobalTableProvider = class {
39722
40375
  warn(`AWS::DynamoDB::GlobalTable ${logicalId}: the state record declares no BillingMode, so this replay creates the table PAY_PER_REQUEST. If it was PROVISIONED, set the mode in the template and redeploy.`);
39723
40376
  }
39724
40377
  } catch (error) {
39725
- throw new ProvisioningError(log.mask(error instanceof Error ? error.message : String(error)), resourceType, logicalId, void 0, error instanceof Error ? error : void 0);
40378
+ throw new ProvisioningError(log.mask(describeAwsFailure(error).detail), resourceType, logicalId, void 0, error instanceof Error ? error : void 0);
39726
40379
  }
39727
40380
  const currentRegion = await this.dynamoDBClient.config.region() ?? "";
39728
40381
  const replicas = properties["Replicas"] ?? [];
@@ -39752,7 +40405,7 @@ var DynamoDBGlobalTableProvider = class {
39752
40405
  replayDowngrade(message);
39753
40406
  } } : {});
39754
40407
  } catch (error) {
39755
- throw new ProvisioningError(log.mask(error instanceof Error ? error.message : String(error)), resourceType, logicalId, void 0, error instanceof Error ? error : void 0);
40408
+ throw new ProvisioningError(log.mask(describeAwsFailure(error).detail), resourceType, logicalId, void 0, error instanceof Error ? error : void 0);
39756
40409
  }
39757
40410
  createParams.StreamSpecification = {
39758
40411
  StreamEnabled: true,
@@ -39783,7 +40436,7 @@ var DynamoDBGlobalTableProvider = class {
39783
40436
  onUnusableCreateIndexes(`${message} Omitting the malformed block, so this create carries NO indexes; the same value is REFUSED on a template-path create`);
39784
40437
  }), maskSecrets);
39785
40438
  } catch (error) {
39786
- throw new ProvisioningError(log.mask(error instanceof Error ? error.message : String(error)), resourceType, logicalId, void 0, error instanceof Error ? error : void 0);
40439
+ throw new ProvisioningError(log.mask(describeAwsFailure(error).detail), resourceType, logicalId, void 0, error instanceof Error ? error : void 0);
39787
40440
  }
39788
40441
  let wiringProperties = properties;
39789
40442
  if (indexesOmitted) {
@@ -40429,7 +41082,7 @@ var DynamoDBGlobalTableProvider = class {
40429
41082
  try {
40430
41083
  await this.dynamoDBClient.send(cmd);
40431
41084
  } catch (ttlErr) {
40432
- if ((ttlErr instanceof Error ? ttlErr.message : String(ttlErr)).includes("Time to live has been modified multiple times")) throw this.wrapMaskedError(log, ttlErr, (text) => new ProvisioningError(`AWS rejected TimeToLive update on ${log.value(physicalId)}: ${text}. AWS enforces a ~4-hour rate limit on TTL changes per table; wait and redeploy, or keep the previous TTL state in this deploy.`, resourceType, logicalId, physicalId, ttlErr instanceof Error ? ttlErr : void 0));
41085
+ if (describeAwsFailure(ttlErr).detail.includes("Time to live has been modified multiple times")) throw this.wrapMaskedError(log, ttlErr, (text) => new ProvisioningError(`AWS rejected TimeToLive update on ${log.value(physicalId)}: ${text}. AWS enforces a ~4-hour rate limit on TTL changes per table; wait and redeploy, or keep the previous TTL state in this deploy.`, resourceType, logicalId, physicalId, ttlErr instanceof Error ? ttlErr : void 0));
40433
41086
  throw ttlErr;
40434
41087
  }
40435
41088
  };
@@ -40876,7 +41529,7 @@ var DynamoDBGlobalTableProvider = class {
40876
41529
  return;
40877
41530
  }
40878
41531
  const cause = error instanceof Error ? error : void 0;
40879
- throw new ProvisioningError(`Failed to delete DynamoDB GlobalTable ${logicalId}: ${error instanceof Error ? error.message : String(error)}`, resourceType, logicalId, physicalId, cause);
41532
+ throw new ProvisioningError(`Failed to delete DynamoDB GlobalTable ${logicalId}: ${describeAwsFailure(error).detail}`, resourceType, logicalId, physicalId, cause);
40880
41533
  }
40881
41534
  }
40882
41535
  async isSameResource(journaledPhysicalId, record, resourceType, context) {
@@ -42263,333 +42916,6 @@ function withRefreshedReadVersions(record, unchanged) {
42263
42916
  return withReferenceProvenance(record, out);
42264
42917
  }
42265
42918
 
42266
- //#endregion
42267
- //#region src/deployment/deploy-engine/noecho.ts
42268
- function noEchoExactEchoLeavesOf(record) {
42269
- const field = record?.noEchoExactEchoLeaves;
42270
- if (!Array.isArray(field)) return void 0;
42271
- const out = [];
42272
- for (const entry of field) {
42273
- if (!Array.isArray(entry) || entry.length === 0) return void 0;
42274
- if (!entry.every((segment) => typeof segment === "string")) return void 0;
42275
- out.push([...entry]);
42276
- }
42277
- return out;
42278
- }
42279
- function echoFidelityCandidates(coordinates, resolved, createOnly) {
42280
- const out = [];
42281
- for (const coordinate of coordinates) {
42282
- if (!coordinate.every((segment) => typeof segment === "string")) continue;
42283
- const keys = coordinate;
42284
- if (!createOnly.some((path) => path.length <= keys.length && path.every((s, i) => s === keys[i]))) continue;
42285
- const plaintext = valueAtCoordinate(resolved, keys);
42286
- if (typeof plaintext !== "string" || carriesSecretMask(plaintext)) continue;
42287
- out.push({
42288
- coordinate: keys,
42289
- plaintext
42290
- });
42291
- }
42292
- return out;
42293
- }
42294
- function reportedLeafAt(live, handed, candidate) {
42295
- if (valueAtCoordinate(handed, candidate.coordinate) !== "***") return void 0;
42296
- const leaf = valueAtCoordinate(live, candidate.coordinate);
42297
- return typeof leaf === "string" && !carriesSecretMask(leaf) ? leaf : void 0;
42298
- }
42299
- function echoesExactlyAt(live, handed, candidate) {
42300
- return reportedLeafAt(live, handed, candidate) === candidate.plaintext;
42301
- }
42302
- function provesEchoChangeAt(live, handed, candidate) {
42303
- const reported = reportedLeafAt(live, handed, candidate);
42304
- return reported !== void 0 && reported !== candidate.plaintext;
42305
- }
42306
- function noteNoEchoExactEchoes(logicalId, physicalId, read, handed, candidates, mode) {
42307
- const exact = "failure" in read ? [] : candidates.filter((candidate) => echoesExactlyAt(read.live, handed, candidate)).map((candidate) => [...candidate.coordinate]);
42308
- const noted = this.noEchoExactEchoes.get(logicalId);
42309
- const previous = mode === "add" && noted?.physicalId === physicalId ? noted.coordinates : [];
42310
- this.noEchoExactEchoes.set(logicalId, {
42311
- physicalId,
42312
- coordinates: sortedCoordinates([...previous, ...exact])
42313
- });
42314
- }
42315
- function sortedCoordinates(coordinates) {
42316
- const keyed = /* @__PURE__ */ new Map();
42317
- for (const coordinate of coordinates) keyed.set(JSON.stringify(coordinate), [...coordinate]);
42318
- return [...keyed.entries()].sort(([a], [b]) => a.localeCompare(b)).map(([, c]) => c);
42319
- }
42320
- async function establishNoEchoEchoFidelity(logicalId, record, resolvedProps, stateResources, secrets) {
42321
- this.noEchoExactEchoes.delete(logicalId);
42322
- const templateProps = this.perResourceTemplateProps.get(logicalId);
42323
- const sources = this.noEchoPositionSources(stateResources);
42324
- if (templateProps === void 0 || sources === void 0 || sources.parameters.size === 0) return;
42325
- const coordinates = canonicalCoordinates(noEchoCoordinatesOf(templateProps, resolvedProps, {
42326
- parameters: sources.parameters,
42327
- ...sources.conditions !== void 0 && { conditions: sources.conditions }
42328
- }));
42329
- if (coordinates.length === 0) return;
42330
- const candidates = echoFidelityCandidates(coordinates, resolvedProps, await getCreateOnlyPropertyPaths(record.resourceType).catch(() => []));
42331
- if (candidates.length === 0) return;
42332
- const handed = {
42333
- ...record,
42334
- properties: maskAtCoordinates(record.properties, coordinates)
42335
- };
42336
- const read = await this.readReaderForFreshNoEchoCeiling(logicalId, handed, secrets);
42337
- this.noteNoEchoExactEchoes(logicalId, record.physicalId, read, handed.properties, candidates, "set");
42338
- }
42339
- function withNoEchoExactEchoes(logicalId, record) {
42340
- const noted = this.noEchoExactEchoes.get(logicalId);
42341
- if (noted === void 0 || noted.coordinates.length === 0) return record;
42342
- if (noted.physicalId !== record.physicalId) return record;
42343
- const merged = sortedCoordinates([...noEchoExactEchoLeavesOf(record) ?? [], ...noted.coordinates]);
42344
- return {
42345
- ...record,
42346
- noEchoExactEchoLeaves: merged
42347
- };
42348
- }
42349
- function noEchoParameterNamesOf(template) {
42350
- const names = /* @__PURE__ */ new Set();
42351
- const declared = template?.Parameters;
42352
- if (declared === null || typeof declared !== "object") return names;
42353
- for (const [name, definition] of Object.entries(declared)) if (declaresNoEcho(definition)) names.add(name);
42354
- return names;
42355
- }
42356
- function noEchoAttributeNamesOf(record) {
42357
- const field = record?.noEchoAttributeNames;
42358
- if (!Array.isArray(field) || !field.every((name) => typeof name === "string")) return void 0;
42359
- return field;
42360
- }
42361
- function noEchoPositionSources(resources = {}, template = this.constructPathTemplate, conditions = this.noEchoConditions) {
42362
- if (template === void 0) return void 0;
42363
- const declared = this.noEchoAttributeResources;
42364
- return {
42365
- parameters: /* @__PURE__ */ new Set([...noEchoParameterNamesOf(template), ...this.inheritedNoEchoParameters]),
42366
- attributeIsNoEcho: (logicalId, attribute) => {
42367
- const live = declared.get(logicalId);
42368
- if (live === true || live !== void 0 && live.has(attribute)) return true;
42369
- if (noEchoAttributeNamesOf(Object.hasOwn(resources, logicalId) ? resources[logicalId] : void 0)?.includes(attribute) === true) return true;
42370
- return this.persistedNoEchoAttributes.get(logicalId)?.has(attribute) === true;
42371
- },
42372
- ...conditions !== void 0 && { conditions }
42373
- };
42374
- }
42375
- function noEchoLeavesFor(logicalId, record, templateProps, sources) {
42376
- if (templateProps !== void 0 && isWrittenFromDeployedTemplate(record.properties)) return canonicalCoordinates(noEchoCoordinatesOf(templateProps, record.properties, sources));
42377
- const existing = noEchoLeavesOf(record);
42378
- if (existing !== void 0) {
42379
- const confirmed = this.witnessConfirmedLeaves.get(logicalId) ?? [];
42380
- return canonicalCoordinates([...existing, ...confirmed]);
42381
- }
42382
- const resolvedAsSame = this.perResourceResolvedType.get(logicalId) === record.resourceType;
42383
- const source = (templateProps !== void 0 && resolvedAsSame ? templateProps : void 0) ?? templatePropertiesFor(this, logicalId, record.resourceType);
42384
- if (source === void 0) return void 0;
42385
- return canonicalCoordinates(noEchoCoordinatesOf(source, record.properties, sources));
42386
- }
42387
- function templatePropertiesFor(engine, logicalId, resourceType) {
42388
- const resources = engine.constructPathTemplate?.Resources;
42389
- if (resources === void 0 || !Object.hasOwn(resources, logicalId)) return void 0;
42390
- const definition = resources[logicalId];
42391
- if (definition?.Type !== resourceType) return void 0;
42392
- const properties = definition.Properties;
42393
- return properties !== null && typeof properties === "object" && !Array.isArray(properties) ? properties : void 0;
42394
- }
42395
- function noEchoAttributeNamesFor(engine, logicalId, record, carried, leaves) {
42396
- const attributes = record.attributes ?? {};
42397
- const names = /* @__PURE__ */ new Set();
42398
- let echoed = false;
42399
- for (const coordinate of leaves ?? []) {
42400
- const value = valueAtCoordinate(record.properties, coordinate);
42401
- if (value === void 0 || carriesSecretMask(value)) continue;
42402
- for (const [name, attribute] of Object.entries(attributes)) {
42403
- if (carriesSecretMask(attribute)) continue;
42404
- if (typeof attribute === "string" && attribute === record.physicalId) continue;
42405
- const sameName = coordinate[0] === name && keyOrderFreeJson(attribute) === keyOrderFreeJson(value);
42406
- const embeds = typeof value === "string" && typeof attribute === "string" && !attribute.startsWith("arn:") && value.length >= 4 && typeof attribute === "string" && attribute.includes(value);
42407
- if (sameName || embeds) {
42408
- names.add(name);
42409
- echoed = true;
42410
- }
42411
- }
42412
- }
42413
- const declared = carried ? void 0 : engine.noEchoAttributeResources.get(logicalId);
42414
- if (declared === true) for (const name of Object.keys(attributes)) names.add(name);
42415
- else if (declared !== void 0) {
42416
- for (const name of declared) if (Object.hasOwn(attributes, name)) names.add(name);
42417
- }
42418
- const prior = noEchoAttributeNamesOf(record);
42419
- for (const name of prior ?? []) if (Object.hasOwn(attributes, name) && carriesSecretMask(attributes[name])) names.add(name);
42420
- if (declared === void 0 && prior === void 0 && !echoed) return void 0;
42421
- return [...names].sort();
42422
- }
42423
- function applyNoEchoPersist(logicalId, record, scrubbed, templateProps, resources, secrets, carried = false) {
42424
- const sources = this.noEchoPositionSources(resources);
42425
- if (sources === void 0) return scrubbed;
42426
- const leaves = this.noEchoLeavesFor(logicalId, record, templateProps, sources);
42427
- const names = noEchoAttributeNamesFor(this, logicalId, record, carried, leaves);
42428
- if (leaves === void 0 && names === void 0) return scrubbed;
42429
- const next = { ...scrubbed };
42430
- if (leaves !== void 0) {
42431
- next.properties = maskAtCoordinates(scrubbed.properties, leaves);
42432
- if (scrubbed.observedProperties !== void 0 && leaves.length > 0) Object.assign(next, { observedProperties: maskReadbackAtCoordinates(scrubbed.observedProperties, record.properties, leaves) });
42433
- if (leaves.length > 0) next.noEchoLeaves = leaves;
42434
- else delete next.noEchoLeaves;
42435
- const marked = new Set(leaves.map((coordinate) => JSON.stringify(coordinate)));
42436
- const exact = (noEchoExactEchoLeavesOf(scrubbed) ?? []).filter((coordinate) => marked.has(JSON.stringify(coordinate)));
42437
- if (exact.length > 0) next.noEchoExactEchoLeaves = exact;
42438
- else delete next.noEchoExactEchoLeaves;
42439
- }
42440
- if (names !== void 0) {
42441
- if (scrubbed.attributes !== void 0 && names.length > 0) {
42442
- const attributes = { ...scrubbed.attributes };
42443
- for (const name of names) if (Object.hasOwn(attributes, name)) attributes[name] = maskWholeValue(attributes[name]);
42444
- next.attributes = attributes;
42445
- }
42446
- if (names.length > 0) next.noEchoAttributeNames = names;
42447
- else delete next.noEchoAttributeNames;
42448
- }
42449
- this.warnNoEchoPhysicalId(logicalId, record, secrets);
42450
- return next;
42451
- }
42452
- function warnNoEchoPhysicalId(logicalId, record, secrets) {
42453
- if (secrets === void 0 || this.noEchoPhysicalIdWarned.has(logicalId)) return;
42454
- const values = noEchoParameterPlaintextsOf(secrets);
42455
- if (values.length === 0 || typeof record.physicalId !== "string") return;
42456
- if (!values.some((value) => record.physicalId.includes(value))) return;
42457
- this.noEchoPhysicalIdWarned.add(logicalId);
42458
- this.logger.warn(this.maskForResource(logicalId, safeMsg`${logicalId}: its physical id contains a NoEcho parameter value. AWS publishes a resource's name, so cdkd keeps the physical id in state as AWS returns it.`));
42459
- }
42460
- function seedPersistedNoEchoAttributes(resources) {
42461
- this.persistedNoEchoAttributes = /* @__PURE__ */ new Map();
42462
- for (const [logicalId, record] of Object.entries(resources)) {
42463
- const names = noEchoAttributeNamesOf(record);
42464
- if (names !== void 0 && names.length > 0) this.persistedNoEchoAttributes.set(logicalId, new Set(names));
42465
- }
42466
- }
42467
- function maskOutputsByPosition(outputs) {
42468
- const sources = this.noEchoPositionSources();
42469
- if (sources === void 0) return outputs;
42470
- const templateValues = Object.create(null);
42471
- for (const [name, definition] of Object.entries(this.constructPathTemplate?.Outputs ?? {})) templateValues[name] = definition?.Value;
42472
- if (this.outputsSourceUsable) for (const [name, value] of Object.entries(this.outputsTemplateSource)) templateValues[name] = value;
42473
- const coordinates = noEchoCoordinatesOf(templateValues, outputs, sources);
42474
- if (coordinates.length === 0) return outputs;
42475
- const maskedValues = new Set(coordinates.filter((coordinate) => coordinate.length === 1 && typeof coordinate[0] === "string").map((coordinate) => keyOrderFreeJson(outputs[coordinate[0]])));
42476
- const aliasCoordinates = Object.keys(outputs).filter((key) => !Object.hasOwn(templateValues, key) && outputs[key] !== void 0 && !carriesSecretMask(outputs[key]) && maskedValues.has(keyOrderFreeJson(outputs[key]))).map((key) => [key]);
42477
- return maskAtCoordinates(outputs, [...coordinates, ...aliasCoordinates]);
42478
- }
42479
- function getAttTargetsOf(node) {
42480
- const targets = [];
42481
- const seen = /* @__PURE__ */ new Set();
42482
- const subVariable = /\$\{([^}!][^}]*)\}/g;
42483
- const walk = (value) => {
42484
- if (value === null || typeof value !== "object" || seen.has(value)) return;
42485
- seen.add(value);
42486
- if (Array.isArray(value)) {
42487
- for (const item of value) walk(item);
42488
- return;
42489
- }
42490
- const record = value;
42491
- const getAtt = record["Fn::GetAtt"];
42492
- if (typeof getAtt === "string" && getAtt.indexOf(".") > 0) {
42493
- const dot = getAtt.indexOf(".");
42494
- targets.push([getAtt.slice(0, dot), getAtt.slice(dot + 1)]);
42495
- } else if (Array.isArray(getAtt) && typeof getAtt[0] === "string" && typeof getAtt[1] === "string") targets.push([getAtt[0], getAtt[1]]);
42496
- const sub = record["Fn::Sub"];
42497
- const text = typeof sub === "string" ? sub : Array.isArray(sub) ? sub[0] : void 0;
42498
- if (typeof text === "string") for (const match of text.matchAll(subVariable)) {
42499
- const name = match[1].trim();
42500
- const dot = name.indexOf(".");
42501
- if (dot > 0) targets.push([name.slice(0, dot), name.slice(dot + 1)]);
42502
- }
42503
- for (const child of Object.values(record)) walk(child);
42504
- };
42505
- walk(node);
42506
- return targets;
42507
- }
42508
- async function noEchoAttributeOverridesFor(desiredProps, stateResources, stackName) {
42509
- const wanted = /* @__PURE__ */ new Map();
42510
- for (const [logicalId, attribute] of getAttTargetsOf(desiredProps)) {
42511
- const record = Object.hasOwn(stateResources, logicalId) ? stateResources[logicalId] : void 0;
42512
- if (record === void 0) continue;
42513
- if (noEchoAttributeNamesOf(record)?.includes(attribute) !== true) continue;
42514
- if (!carriesSecretMask(record.attributes?.[attribute])) continue;
42515
- if (!this.perResourceSecrets.has(logicalId)) continue;
42516
- const set = wanted.get(logicalId) ?? /* @__PURE__ */ new Set();
42517
- set.add(attribute);
42518
- wanted.set(logicalId, set);
42519
- }
42520
- if (wanted.size === 0) return void 0;
42521
- const overrides = /* @__PURE__ */ new Map();
42522
- for (const [logicalId, attributes] of wanted) {
42523
- const record = stateResources[logicalId];
42524
- let read = this.noEchoAttributeReads.get(logicalId);
42525
- if (read === void 0) {
42526
- read = (async () => {
42527
- try {
42528
- const { provider } = this.providerRegistry.getProviderFor({
42529
- resourceType: record.resourceType,
42530
- properties: record.properties,
42531
- provisionedBy: record.provisionedBy,
42532
- previousProperties: record.properties
42533
- });
42534
- const outcome = await readRecordAttributes({
42535
- provider,
42536
- logicalId,
42537
- resource: record,
42538
- stackName,
42539
- region: this.stackRegion
42540
- });
42541
- return outcome.kind === "read" ? outcome.attributes : void 0;
42542
- } catch {
42543
- return;
42544
- }
42545
- })();
42546
- this.noEchoAttributeReads.set(logicalId, read);
42547
- }
42548
- const live = await read;
42549
- if (live === void 0) continue;
42550
- const secrets = this.perResourceSecrets.get(logicalId);
42551
- const fresh = noEchoParameterPlaintextsOf(secrets);
42552
- const positioned = this.noEchoPositionedValues.get(logicalId) ?? /* @__PURE__ */ new Set();
42553
- const served = {};
42554
- for (const attribute of attributes) {
42555
- if (!Object.hasOwn(live, attribute)) continue;
42556
- const value = live[attribute];
42557
- if (typeof value === "string" && fresh.some((needle) => value === needle || value.includes(needle)) || value !== void 0 && positioned.has(keyOrderFreeJson(value))) served[attribute] = value;
42558
- }
42559
- if (Object.keys(served).length > 0) overrides.set(logicalId, served);
42560
- }
42561
- return overrides.size > 0 ? overrides : void 0;
42562
- }
42563
- function noEchoDiffComparison(resources, template, conditions, parameterValues, stackName) {
42564
- const sources = this.noEchoPositionSources(resources, template, conditions);
42565
- if (sources === void 0) return void 0;
42566
- const compare = noEchoComparison({
42567
- sources,
42568
- values: parameterValues,
42569
- minNeedleLength: 4,
42570
- publicTokens: /* @__PURE__ */ new Set([this.stackRegion, ...stackName === void 0 ? [] : [stackName]])
42571
- });
42572
- return (input) => compare(input);
42573
- }
42574
- function freshNoEchoParametersWithDeclared(inherited, template) {
42575
- const all = /* @__PURE__ */ new Set([...inherited ?? [], ...noEchoParameterNamesOf(template)]);
42576
- return all.size > 0 ? all : void 0;
42577
- }
42578
- function noEchoComparisonForTemplate(template, knownConditions, values, resources, publicTokens, inheritedNoEchoParameters) {
42579
- const sources = {
42580
- parameters: /* @__PURE__ */ new Set([...noEchoParameterNamesOf(template), ...inheritedNoEchoParameters ?? []]),
42581
- attributeIsNoEcho: (logicalId, attribute) => noEchoAttributeNamesOf(Object.hasOwn(resources, logicalId) ? resources[logicalId] : void 0)?.includes(attribute) === true,
42582
- ...knownConditions !== void 0 && { conditions: knownConditions }
42583
- };
42584
- const compare = noEchoComparison({
42585
- sources,
42586
- values: values ?? {},
42587
- minNeedleLength: 4,
42588
- ...publicTokens !== void 0 && { publicTokens }
42589
- });
42590
- return (input) => compare(input);
42591
- }
42592
-
42593
42919
  //#endregion
42594
42920
  //#region src/analyzer/security-changes.ts
42595
42921
  const RESOURCE_SCRUTINY = {
@@ -44081,7 +44407,7 @@ async function provisionUpdate(logicalId, change, stateResources, stackName, tem
44081
44407
  }, stackName);
44082
44408
  const updateSecrets = context.recordedSecretValues ?? /* @__PURE__ */ new Map();
44083
44409
  this.perResourceSecrets.set(logicalId, updateSecrets);
44084
- const noEchoOverrides = await this.noEchoAttributeOverridesFor(desiredProps, stateResources, stackName);
44410
+ const noEchoOverrides = await noEchoAttributeOverridesFor(this.noEchoRun, this.noEchoDeps(), desiredProps, stateResources, stackName);
44085
44411
  if (noEchoOverrides !== void 0) context.noEchoAttributeOverrides = noEchoOverrides;
44086
44412
  printNestedStackReadsOnly(context, resourceType, this.secretNameBagFor(logicalId));
44087
44413
  const resolvedProps = await this.resolver.resolve(desiredProps, context);
@@ -44093,7 +44419,7 @@ async function provisionUpdate(logicalId, change, stateResources, stackName, tem
44093
44419
  this.perResourceTemplateProps.set(logicalId, desiredProps);
44094
44420
  this.perResourceResolvedType.set(logicalId, resourceType);
44095
44421
  recordNestedStackParameterExpressions(updateSecrets, resourceType, resolvedProps, desiredProps);
44096
- this.auditResolvedAssetReferences(logicalId, resourceType, resolvedProps);
44422
+ auditResolvedAssetReferences(this.options, logicalId, resourceType, resolvedProps);
44097
44423
  const lostCandidate = childLostWithRecreatedParent({
44098
44424
  resourceType,
44099
44425
  templateProperties: desiredProps,
@@ -44104,7 +44430,7 @@ async function provisionUpdate(logicalId, change, stateResources, stackName, tem
44104
44430
  const lostChild = lostCandidate?.mode === "reattach" || lostCandidate !== void 0 && Object.hasOwn(resolvedProps, lostCandidate.property) && Object.hasOwn(currentProps, lostCandidate.property) && keyOrderFreeJson(resolvedProps[lostCandidate.property]) === keyOrderFreeJson(currentProps[lostCandidate.property]) ? lostCandidate : void 0;
44105
44431
  const lostWithParent = lostChild?.mode === "recreate" ? lostChild.parent : void 0;
44106
44432
  this.registerNoEchoAttributes(logicalId, Object.assign(currentResource.attributes === void 0 ? {} : { attributes: currentResource.attributes }, { physicalId: currentResource.physicalId }), updateSecrets, resolvedProps);
44107
- const noEchoSources = this.noEchoPositionSources(stateResources, template, conditions);
44433
+ const noEchoSources = noEchoPositionSources(this.noEchoRun, stateResources, template, conditions);
44108
44434
  const parameterCoordinates = noEchoSources === void 0 ? [] : canonicalCoordinates(noEchoCoordinatesOf(desiredProps, resolvedProps, {
44109
44435
  parameters: noEchoSources.parameters,
44110
44436
  ...noEchoSources.conditions !== void 0 && { conditions: noEchoSources.conditions }
@@ -44121,7 +44447,7 @@ async function provisionUpdate(logicalId, change, stateResources, stackName, tem
44121
44447
  return resolved !== void 0 && !carriesSecretMask(resolved);
44122
44448
  });
44123
44449
  const comparisonCoordinates = canonicalCoordinates([...noEchoCoordinates, ...staleCoordinates]);
44124
- if (parameterCoordinates.length > 0) this.noEchoPositionedValues.set(logicalId, new Set(parameterCoordinates.map((coordinate) => keyOrderFreeJson(valueAtCoordinate(resolvedProps, coordinate)))));
44450
+ if (parameterCoordinates.length > 0) this.noEchoRun.noEchoPositionedValues.set(logicalId, new Set(parameterCoordinates.map((coordinate) => keyOrderFreeJson(valueAtCoordinate(resolvedProps, coordinate)))));
44125
44451
  const fingerprintSources = template && this.maskedInputSources(template, stateResources, conditions, stackName);
44126
44452
  const fingerprints = fingerprintSources && inputFingerprinter(desiredProps, fingerprintSources);
44127
44453
  const movedMasked = new Set(await movedMaskedProperties(currentResource, desiredProps, fingerprints));
@@ -44130,7 +44456,7 @@ async function provisionUpdate(logicalId, change, stateResources, stackName, tem
44130
44456
  this.fingerprintNoEchoValues,
44131
44457
  this.options.inheritedSecrets
44132
44458
  ]), fingerprints));
44133
- if (resourceType === "AWS::CloudFormation::Stack") recordPassedNoEchoParameters(updateSecrets, desiredProps["Parameters"], this.noEchoPositionSources(stateResources));
44459
+ if (resourceType === "AWS::CloudFormation::Stack") recordPassedNoEchoParameters(updateSecrets, desiredProps["Parameters"], noEchoPositionSources(this.noEchoRun, stateResources));
44134
44460
  if (fingerprintSources !== void 0 && resourceType === "AWS::CloudFormation::Stack") recordPassedParameterClasses(updateSecrets, await classifyPassedParameters(desiredProps["Parameters"], fingerprintSources));
44135
44461
  const desiredForSkipCheck = maskAtCoordinates(redactSecretsForState(markSameGenerationBag({ ...resolvedProps }), updateSecrets, desiredProps), comparisonCoordinates);
44136
44462
  const legacyDesired = withoutPhysicalNameCopies(updateSecrets, () => maskAtCoordinates(redactSecretsForState(markSameGenerationBag({ ...resolvedProps }), updateSecrets, desiredProps), comparisonCoordinates));
@@ -44146,6 +44472,23 @@ async function provisionUpdate(logicalId, change, stateResources, stackName, tem
44146
44472
  const repaired = repairEmbeddedPhysicalNamesTowards(repairPhysicalNameCopyLeaves(bag[key], legacyDesired[key], desiredForSkipCheck[key]), desiredForSkipCheck[key], embeddedRewrites);
44147
44473
  if (repaired !== bag[key]) bag[key] = repaired;
44148
44474
  }
44475
+ if (overlapRuleAnswered(updateSecrets)) {
44476
+ const legacyOverlapBag = withLegacyOverlapScan(updateSecrets, () => maskAtCoordinates(redactSecretsForState(markSameGenerationBag({ ...resolvedProps }), updateSecrets, desiredProps), comparisonCoordinates));
44477
+ const legacyOverlap = legacyReferenceLeavesOnly(legacyOverlapBag);
44478
+ for (const bag of new Set(repairable)) for (const key of Object.keys(bag)) {
44479
+ const repaired = repairPhysicalNameCopyLeaves(bag[key], legacyOverlap[key], desiredForSkipCheck[key]);
44480
+ if (repaired !== bag[key]) bag[key] = repaired;
44481
+ }
44482
+ const pairs = differingStringLeaves(legacyOverlap, desiredForSkipCheck);
44483
+ for (const field of ["attributes", "observedProperties"]) {
44484
+ const target = currentResource[field];
44485
+ if (target === void 0 || target === null || pairs.length === 0) continue;
44486
+ for (const key of Object.keys(target)) {
44487
+ const repaired = replaceWholeLeaves(target[key], pairs);
44488
+ if (repaired !== target[key]) target[key] = repaired;
44489
+ }
44490
+ }
44491
+ }
44149
44492
  const attributes = currentResource.attributes;
44150
44493
  if (attributes !== void 0 && attributes !== null && embeddedRewrites.length > 0) for (const key of Object.keys(attributes)) {
44151
44494
  const repaired = replaceEmbeddedPhysicalNameRewrites(attributes[key], embeddedRewrites);
@@ -44161,7 +44504,7 @@ async function provisionUpdate(logicalId, change, stateResources, stackName, tem
44161
44504
  const witness = todayAsWritten === void 0 ? void 0 : witnessNormalize(recordedAsWritten, todayAsWritten, desiredForSkipCheckAsWritten);
44162
44505
  const currentPropsAsWritten = witness === void 0 ? recordedAsWritten : witness.current;
44163
44506
  const witnessMigrates = unmarkedRecord || (witness?.confirmed.length ?? 0) > 0;
44164
- if (!unmarkedRecord && witness !== void 0 && witness.confirmed.length > 0) this.witnessConfirmedLeaves.set(logicalId, witness.confirmed.map((coordinate) => [...coordinate]));
44507
+ if (!unmarkedRecord && witness !== void 0 && witness.confirmed.length > 0) this.noEchoRun.witnessConfirmedLeaves.set(logicalId, witness.confirmed.map((coordinate) => [...coordinate]));
44165
44508
  for (const coordinate of witness?.differing ?? []) {
44166
44509
  const desiredAt = valueAtCoordinate(desiredForSkipCheckAsWritten, coordinate);
44167
44510
  recordPreviousNoEchoLeaves(this.secretNameBagFor(logicalId), valueAtCoordinate(recordedAsWritten, coordinate), scalarLeavesOf(desiredAt), updateSecrets, desiredAt !== "***");
@@ -44236,7 +44579,7 @@ async function provisionUpdate(logicalId, change, stateResources, stackName, tem
44236
44579
  this.logger.info(safeMsg` ↻ ${logicalId} (${resourceType}) attribute update: ${attrSummary}`);
44237
44580
  stateResources[logicalId] = {
44238
44581
  ...stateResources[logicalId] ?? currentResource,
44239
- ...this.extractTemplateAttributes(template, logicalId)
44582
+ ...extractTemplateAttributes(template, logicalId)
44240
44583
  };
44241
44584
  if (counts) counts.updated++;
44242
44585
  if (progress) progress.current++;
@@ -44252,7 +44595,7 @@ async function provisionUpdate(logicalId, change, stateResources, stackName, tem
44252
44595
  } : currentResource;
44253
44596
  let readback;
44254
44597
  const readOnce = () => readback ??= this.readReaderForFreshNoEchoCeiling(logicalId, readbackRecord, updateSecrets).then((read) => {
44255
- this.noteNoEchoExactEchoes(logicalId, currentResource.physicalId, read, readbackRecord.properties, echoCandidates, "add");
44598
+ noteNoEchoExactEchoes(this.noEchoRun, logicalId, currentResource.physicalId, read, readbackRecord.properties, echoCandidates, "add");
44256
44599
  return read;
44257
44600
  });
44258
44601
  const exactEchoCoordinates = new Set((noEchoExactEchoLeavesOf(currentResource) ?? []).map((c) => JSON.stringify(c)));
@@ -44304,7 +44647,7 @@ async function provisionUpdate(logicalId, change, stateResources, stackName, tem
44304
44647
  const lateReplacementDeclined = /* @__PURE__ */ new Set();
44305
44648
  const differsWhy = (key) => !lateReplacementDeclined.has(key) ? "differs; the provider is not known to report this property exactly, so the difference may be its normalization" : lateCrossPrefixRefused ? "differs; the replacement was refused: see the state-prefix warning above" : `differs; the replacement was not approved (--require-approval=${this.options.requireApproval ?? "never"})`;
44306
44649
  if (witnessMigrates && !typeChanged && echoCandidates.length > 0 && hasAddressablePhysicalId(currentResource)) await readOnce();
44307
- if (!typeChanged && !suppliesFreshMaskOnlyValue && lostChild === void 0 && this.recreateDirectionFor(stackName, logicalId) === void 0 && recordMatchesDesired) {
44650
+ if (!typeChanged && !suppliesFreshMaskOnlyValue && lostChild === void 0 && recreateDirectionFor(this.options, stackName, logicalId) === void 0 && recordMatchesDesired) {
44308
44651
  if (provenanceUnchanged.length > 0) stateResources[logicalId] = withRefreshedReadVersions(stateResources[logicalId] ?? currentResource, provenanceUnchanged);
44309
44652
  if (change.attributeChanges && change.attributeChanges.length > 0) {
44310
44653
  applyAttributeOnlyUpdate(change.attributeChanges);
@@ -44390,7 +44733,7 @@ async function provisionUpdate(logicalId, change, stateResources, stackName, tem
44390
44733
  };
44391
44734
  const lowered = [];
44392
44735
  const movedAt = (path) => movedMasked.has(path) || rewrittenPaths.has(path) || keyOrderFreeJson(desiredForSkipCheckAsWritten[path]) !== keyOrderFreeJson(currentPropsAsWritten[path]);
44393
- replacedAnyway = this.recreateDirectionFor(stackName, logicalId) !== void 0 || lostWithParent !== void 0 || (change.propertyChanges ?? []).some((other) => other.requiresReplacement && (!parameterCreateOnlyPaths.has(other.path) || movedAt(other.path)));
44736
+ replacedAnyway = recreateDirectionFor(this.options, stackName, logicalId) !== void 0 || lostWithParent !== void 0 || (change.propertyChanges ?? []).some((other) => other.requiresReplacement && (!parameterCreateOnlyPaths.has(other.path) || movedAt(other.path)));
44394
44737
  for (const pc of change.propertyChanges ?? []) {
44395
44738
  if (!parameterCreateOnlyPaths.has(pc.path)) {
44396
44739
  lowered.push(pc);
@@ -44437,7 +44780,7 @@ async function provisionUpdate(logicalId, change, stateResources, stackName, tem
44437
44780
  }
44438
44781
  }
44439
44782
  const confirmedPaths = /* @__PURE__ */ new Set([...noEchoHeldPaths, ...parameterSettledPaths]);
44440
- if (confirmedPaths.size > 0 && !typeChanged && lostChild === void 0 && this.recreateDirectionFor(stackName, logicalId) === void 0 && recordMatchesDesired && Object.keys(resolvedProps).every((key) => confirmedPaths.has(key) || otherFreshAt(key).length === 0 && !pendingParameterLeaves.has(key))) {
44783
+ if (confirmedPaths.size > 0 && !typeChanged && lostChild === void 0 && recreateDirectionFor(this.options, stackName, logicalId) === void 0 && recordMatchesDesired && Object.keys(resolvedProps).every((key) => confirmedPaths.has(key) || otherFreshAt(key).length === 0 && !pendingParameterLeaves.has(key))) {
44441
44784
  this.logger.debug(safeMsg`Skipping ${logicalId}: AWS already holds every NoEcho value it carries, and nothing else changed`);
44442
44785
  const staleHeld = staleCoordinates.filter((coordinate) => typeof coordinate[0] === "string" && parameterHeldKeys.has(coordinate[0]));
44443
44786
  if (staleHeld.length > 0) {
@@ -44480,7 +44823,7 @@ async function provisionUpdate(logicalId, change, stateResources, stackName, tem
44480
44823
  }
44481
44824
  const liveLabel = this.liveTaskLabels.get(logicalId);
44482
44825
  if (needsReplacement && liveLabel !== void 0 && !liveLabel.replacing) {
44483
- const label = `Replacing ${logicalId} (${resourceType})${this.peekRoutingForLabel(change, currentResource, stackName, logicalId, true, this.recreateDirectionFor(stackName, logicalId)) === "cc-api" ? " [CC API]" : ""}`;
44826
+ const label = `Replacing ${logicalId} (${resourceType})${peekRoutingForLabel(this.providerRegistry, this.options, change, currentResource, stackName, logicalId, true, recreateDirectionFor(this.options, stackName, logicalId)) === "cc-api" ? " [CC API]" : ""}`;
44484
44827
  this.liveTaskLabels.set(logicalId, {
44485
44828
  label,
44486
44829
  replacing: true,
@@ -44488,7 +44831,7 @@ async function provisionUpdate(logicalId, change, stateResources, stackName, tem
44488
44831
  });
44489
44832
  renderer.updateTaskLabel(logicalId, `${label}${liveLabel.warnSuffix ?? ""}`);
44490
44833
  } else if (!needsReplacement && liveLabel !== void 0 && liveLabel.replacing) {
44491
- const label = `Updating ${logicalId} (${resourceType})${this.peekRoutingForLabel(change, currentResource, stackName, logicalId, false, this.recreateDirectionFor(stackName, logicalId)) === "cc-api" ? " [CC API]" : ""}`;
44834
+ const label = `Updating ${logicalId} (${resourceType})${peekRoutingForLabel(this.providerRegistry, this.options, change, currentResource, stackName, logicalId, false, recreateDirectionFor(this.options, stackName, logicalId)) === "cc-api" ? " [CC API]" : ""}`;
44492
44835
  this.liveTaskLabels.set(logicalId, {
44493
44836
  label,
44494
44837
  replacing: false,
@@ -44496,7 +44839,7 @@ async function provisionUpdate(logicalId, change, stateResources, stackName, tem
44496
44839
  });
44497
44840
  renderer.updateTaskLabel(logicalId, `${label}${liveLabel.warnSuffix ?? ""}`);
44498
44841
  }
44499
- const dependencies = this.extractAllDependencies(template, logicalId);
44842
+ const dependencies = extractAllDependencies(template, logicalId);
44500
44843
  const updateReplacePolicy = template?.Resources?.[logicalId]?.UpdateReplacePolicy;
44501
44844
  const markRestored = (outcome) => {
44502
44845
  if (lostChild === void 0) return outcome;
@@ -44606,7 +44949,7 @@ function redactionRewrittenPaths(resolvedProps, desiredForSkipCheck, comparisonC
44606
44949
  return new Set(Object.keys(masked).filter((key) => keyOrderFreeJson(masked[key]) !== keyOrderFreeJson(desiredForSkipCheck[key])));
44607
44950
  }
44608
44951
  function readsProducerReplacedThisRun(template, logicalId, stateResources) {
44609
- return (this.extractAllDependencies(template, logicalId) ?? []).some((id) => {
44952
+ return (extractAllDependencies(template, logicalId) ?? []).some((id) => {
44610
44953
  const loaded = Object.hasOwn(this.healBaseline, id) ? this.healBaseline[id] : void 0;
44611
44954
  if (loaded === void 0) return false;
44612
44955
  const now = Object.hasOwn(stateResources, id) ? stateResources[id] : void 0;
@@ -44614,6 +44957,56 @@ function readsProducerReplacedThisRun(template, logicalId, stateResources) {
44614
44957
  });
44615
44958
  }
44616
44959
 
44960
+ //#endregion
44961
+ //#region src/deployment/deploy-engine/name-collision.ts
44962
+ function replacementNameOrigin(logicalId, physicalId) {
44963
+ if (looksLikeCdkdGeneratedName(physicalId, logicalId, getCurrentStackName())) return {
44964
+ descriptor: `The physical name (${physicalId}) was GENERATED by cdkd from the construct's logical id rather than declared in your template, and that derivation has no random component — so the new resource asks for exactly the name the existing one still holds`,
44965
+ remedy: "Either give the resource an explicit physical name in your CDK code, or rename the CONSTRUCT (its id feeds the generated name — note that this replaces the resource rather than renaming it in place)"
44966
+ };
44967
+ return {
44968
+ descriptor: `The resource has a user-supplied physical name (${physicalId})`,
44969
+ remedy: "Either rename the resource in your CDK code (a fresh name lets the safe create-first order proceed)"
44970
+ };
44971
+ }
44972
+ function orphanedNameCollisionAdvice(providerRegistry, changeType, logicalId, error) {
44973
+ if (changeType !== "CREATE") return void 0;
44974
+ if (!(error instanceof ProvisioningError)) return void 0;
44975
+ const physicalId = error.physicalId;
44976
+ if (!physicalId) return void 0;
44977
+ const replayed = isReplayedNameCollisionFrom(error, logicalId, (link) => isAuxiliaryMarkOf(link, RETRY_AUXILIARY_OWNER));
44978
+ if (!replayed && !isNameCollisionErrorFrom(error, logicalId)) return void 0;
44979
+ const stackName = getCurrentStackName();
44980
+ if (!looksLikeCdkdGeneratedName(physicalId, logicalId, stackName)) return void 0;
44981
+ if (!stackName) return void 0;
44982
+ const safeId = displaySafe(physicalId, { asciiOnly: true });
44983
+ const safeStack = displaySafe(stackName, { asciiOnly: true });
44984
+ const safeLogicalId = displaySafe(logicalId, { asciiOnly: true });
44985
+ const idShown = isInertUnquoted(safeId);
44986
+ const shownId = idShown ? safeId : "a name that cannot be shown safely here";
44987
+ const shownLogicalId = isInertUnquoted(safeLogicalId) ? safeLogicalId : "A resource whose logical id cannot be shown safely here";
44988
+ const diagnosis = replayed ? `${shownLogicalId}: the name AWS reports as taken (${shownId}) is most likely held by a resource THIS create made. An earlier attempt of it ended without a clear verdict (a server error, a dropped connection or a timeout, or a failure after the create call itself may have succeeded), and the retry then found the name taken. A dropped connection can also happen before the request reached AWS, so the holder may be another resource: confirm it is yours before deleting or importing it. cdkd records a resource only once its create succeeds, so this one is in no state file: no rollback or cdkd destroy will remove it, and re-running collides with it again.` : `${shownLogicalId}: the name AWS reports as taken (${shownId}) is one cdkd DERIVED from the logical id, and that derivation has no random component — so this is most likely a resource an earlier cdkd run left behind. A rollback leaves a resource carrying DeletionPolicy: Retain in AWS and drops it from state, as CloudFormation does; what differs is the name. CloudFormation would generate a fresh one for an unnamed resource and redeploy clean, whereas cdkd asks again for the name the orphan still holds — so re-running does not clear this.`;
44989
+ const deleteArm = `If it is not a resource you want to keep, delete ${idShown ? safeId : "it"} in AWS — after confirming it holds nothing you need${replayed ? "" : ", since Retain is what kept it"} — and re-deploy.`;
44990
+ let canImport;
44991
+ try {
44992
+ canImport = typeof providerRegistry.getProvider(error.resourceType).import === "function";
44993
+ } catch {
44994
+ canImport = false;
44995
+ }
44996
+ const commandNamesTheRightResource = safeId === physicalId && safeStack === stackName && safeLogicalId === logicalId;
44997
+ const importableTarget = !stackName.includes("~");
44998
+ if (!canImport || !commandNamesTheRightResource || !importableTarget) return `${diagnosis} ${!canImport ? `cdkd cannot adopt ${displaySafe(error.resourceType, { asciiOnly: true })} back into state (its provider implements no import)` : !importableTarget ? `this is a nested-stack child, whose stack name cdkd import cannot resolve` : `cdkd cannot render an import command that provably names this resource`}, so the way forward is to delete it. ${deleteArm}`;
44999
+ const adopt = pasteableCommand("cdkd import", [{
45000
+ value: stackName,
45001
+ hole: "stack"
45002
+ }, {
45003
+ flag: "--resource",
45004
+ value: `${logicalId}=${physicalId}`,
45005
+ hole: "logicalId=physicalId"
45006
+ }]);
45007
+ return `${diagnosis} To recover, adopt it back into state instead of re-creating it, with the command below (a selective import merges into existing state and needs no --force while the resource is absent from it). CONFIRM IT IS YOURS FIRST — a name cdkd derives is predictable, so for a globally-namespaced type it can belong to another account, and the same stack deployed in another region derives the same name. ${deleteArm}${adopt.withheld.length === 0 ? "" : " The command below prints a quoted hole in place of a value cdkd will not name on a command line; replace it whole, quotes included, with your stack name or '<logicalId>=<name>', shell-quoted."}\nAdopt with: ${adopt.command}`;
45008
+ }
45009
+
44617
45010
  //#endregion
44618
45011
  //#region src/deployment/deploy-engine/update-replace.ts
44619
45012
  async function updateByReplacement({ change, counts, currentProps, currentResource, dependencies, logicalId, oldResourceType, progress, propertyDrivenReplacement, recreateFlagged, recreateViaCcApi, recreateViaSdkProvider, renderer, resolvedProps, resourceType, stackName, stateResources, template, typeChanged, updateReplacePolicy, updateSecrets, lostWithParent }) {
@@ -44621,10 +45014,10 @@ async function updateByReplacement({ change, counts, currentProps, currentResour
44621
45014
  record: currentResource,
44622
45015
  templateResource: template?.Resources?.[logicalId],
44623
45016
  resolvedProperties: resolvedProps,
44624
- noEchoParameters: this.noEchoPositionSources(stateResources, template)?.parameters ?? /* @__PURE__ */ new Set(),
44625
- conditions: this.noEchoConditions,
45017
+ noEchoParameters: noEchoPositionSources(this.noEchoRun, stateResources, template)?.parameters ?? /* @__PURE__ */ new Set(),
45018
+ conditions: this.noEchoRun.noEchoConditions,
44626
45019
  secrets: updateSecrets,
44627
- inputSources: template && this.maskedInputSources(template, stateResources, this.noEchoConditions, stackName)
45020
+ inputSources: template && this.maskedInputSources(template, stateResources, this.noEchoRun.noEchoConditions, stackName)
44628
45021
  });
44629
45022
  if (propertyDrivenReplacement && !recreateFlagged && updateReplacePolicy !== "Retain") {
44630
45023
  const statefulReason = isStatefulRecreateTargetForReplace(oldResourceType, currentProps, currentResource.observedProperties);
@@ -44654,7 +45047,7 @@ async function updateByReplacement({ change, counts, currentProps, currentResour
44654
45047
  ...recreateViaCcApi && { forceCcApi: true }
44655
45048
  });
44656
45049
  const replaceProvider = replaceDecision.provider;
44657
- const replaceProps = replaceDecision.provisionedBy === "cc-api" ? this.preparePropertiesForCcApi(resourceType, resolvedProps, logicalId) : resolvedProps;
45050
+ const replaceProps = replaceDecision.provisionedBy === "cc-api" ? preparePropertiesForCcApi(this.providerRegistry, resourceType, resolvedProps, logicalId) : resolvedProps;
44658
45051
  const oldDeleteRoute = this.providerRegistry.getProviderFor({
44659
45052
  resourceType: oldResourceType,
44660
45053
  provisionedBy: currentResource.provisionedBy
@@ -44766,7 +45159,7 @@ async function updateByReplacement({ change, counts, currentProps, currentResour
44766
45159
  } catch (createError) {
44767
45160
  const createMsg = displayAwsMessage(maskSecretsInText(createError instanceof Error ? createError.message : String(createError), updateSecrets));
44768
45161
  if (!isNameCollisionErrorFrom(createError, logicalId)) throw createError;
44769
- const nameOrigin = this.replacementNameOrigin(logicalId, currentResource.physicalId);
45162
+ const nameOrigin = replacementNameOrigin(logicalId, currentResource.physicalId);
44770
45163
  const nameHeldElsewhere = replacementRequestsDifferentName({
44771
45164
  oldResourceType,
44772
45165
  newResourceType: resourceType,
@@ -44800,7 +45193,7 @@ async function updateByReplacement({ change, counts, currentProps, currentResour
44800
45193
  createResult = await this.replaceDeleteFirstAndRecreate(logicalId, resourceType, oldResourceType, currentResource, oldDeleteProvider, replaceProvider, replaceProps, updateSecrets, updateReplacePolicy, oldDeleteRoute.provisionedBy, noEchoDeleteValues);
44801
45194
  }
44802
45195
  if (equalIdIsSameResource && !deletedOldFirst && createResult.physicalId === currentResource.physicalId) {
44803
- const idempotentNameOrigin = this.replacementNameOrigin(logicalId, currentResource.physicalId);
45196
+ const idempotentNameOrigin = replacementNameOrigin(logicalId, currentResource.physicalId);
44804
45197
  if (updateReplacePolicy === "Retain") throw new CdkdError(safeMsg`${logicalId} (${resourceType}) requires replacement, but its Create API is ` + `name-idempotent: the create-first attempt returned the existing resource ` + safeMsg`(${currentResource.physicalId}) instead of creating a new one, and ` + `UpdateReplacePolicy: Retain pins that resource in place. ` + safeMsg`${idempotentNameOrigin.descriptor}. ${idempotentNameOrigin.remedy} — with ` + "Retain, the old resource keeps the name, so a same-name replacement can never proceed.", "NAMED_REPLACEMENT_IDEMPOTENT_CREATE");
44805
45198
  if (this.options.replace !== true) throw new CdkdError(safeMsg`${logicalId} (${resourceType}) requires replacement, but its Create API is ` + `name-idempotent: the create-first attempt returned the EXISTING resource ` + safeMsg`(${currentResource.physicalId}) instead of creating a new one, so deleting ` + `the "old" resource would silently destroy the resource the deploy just ` + safeMsg`reported as created. ${idempotentNameOrigin.descriptor}; ` + safeMsg`${idempotentNameOrigin.remedy}, or re-run with ` + "`cdkd deploy --replace` to delete the old resource FIRST and recreate it under the same name (the resource is briefly unavailable while it is recreated). Note: this branch is also reached when the old resource was deleted out-of-band and the physical id is name-derived — there the create was a genuine fresh create; `--replace` converges that case too.", "NAMED_REPLACEMENT_IDEMPOTENT_CREATE");
44806
45199
  this.logger.info(` Create-first returned the existing resource (name-idempotent Create API) ` + safeMsg`and --replace is set — deleting old ${logicalId} ` + safeMsg`(${currentResource.physicalId}) first...`);
@@ -44828,20 +45221,21 @@ async function updateByReplacement({ change, counts, currentProps, currentResour
44828
45221
  }
44829
45222
  this.registerNoEchoAttributes(logicalId, createResult, updateSecrets, resolvedProps);
44830
45223
  if (equalIdIsSameResource && createResult.physicalId === currentResource.physicalId) this.recreatedUnderSameId.add(logicalId);
44831
- const recordedReplacementProperties = this.propertiesToRecord(resolvedProps, createResult, resourceType, replaceDecision.provisionedBy);
45224
+ const recordedReplacementProperties = propertiesToRecord(resolvedProps, createResult, resourceType, replaceDecision.provisionedBy);
44832
45225
  stateResources[logicalId] = {
44833
45226
  physicalId: createResult.physicalId,
44834
45227
  resourceType,
44835
45228
  properties: recordedReplacementProperties,
44836
45229
  ...acceptedCreateOnlyDropsField(recordedReplacementProperties, resourceType, replaceDecision.provisionedBy, "new-resource"),
44837
45230
  ...createResult.attributes && { attributes: createResult.attributes },
45231
+ ...secretNamedAttributesField(createResult),
44838
45232
  ...dependencies && dependencies.length > 0 && { dependencies },
44839
- ...this.extractTemplateAttributes(template, logicalId),
45233
+ ...extractTemplateAttributes(template, logicalId),
44840
45234
  provisionedBy: replaceDecision.provisionedBy
44841
45235
  };
44842
45236
  this.recordInlinePolicyWrite(logicalId, "create");
44843
- await this.establishNoEchoEchoFidelity(logicalId, stateResources[logicalId], resolvedProps, stateResources, updateSecrets);
44844
- this.kickOffObservedCapture(replaceProvider, logicalId, createResult.physicalId, resourceType, resolvedProps, { afterOwnWrite: true }, updateSecrets);
45237
+ await establishNoEchoEchoFidelity(this.noEchoRun, this.noEchoDeps(), logicalId, stateResources[logicalId], resolvedProps, stateResources, updateSecrets);
45238
+ this.observedCapture.kickOffObservedCapture(replaceProvider, logicalId, createResult.physicalId, resourceType, resolvedProps, { afterOwnWrite: true }, updateSecrets);
44845
45239
  if (counts) counts.updated++;
44846
45240
  if (progress) progress.current++;
44847
45241
  const replacePrefix = progress ? `[${progress.current}/${progress.total}] ` : " ";
@@ -44880,7 +45274,7 @@ async function updateInPlace({ conditions, counts, currentProps, currentPropsAsW
44880
45274
  properties: resolvedProps,
44881
45275
  provisionedBy: currentResource.provisionedBy,
44882
45276
  previousProperties: currentResource.properties,
44883
- ...this.isPinnedToCcApi(stackName, logicalId) && { forceCcApi: true }
45277
+ ...isPinnedToCcApi(this.options, stackName, logicalId) && { forceCcApi: true }
44884
45278
  });
44885
45279
  if (updateDecision.sdkMigration === true) {
44886
45280
  const exemptMode = STICKY_CC_MIGRATION_EXEMPT.get(resourceType)?.mode;
@@ -44898,7 +45292,7 @@ async function updateInPlace({ conditions, counts, currentProps, currentPropsAsW
44898
45292
  this.logger.info(message);
44899
45293
  }
44900
45294
  const updateProvider = updateDecision.provider;
44901
- const updateProps = updateDecision.provisionedBy === "cc-api" ? withoutGeneratedFallbackName(resourceType, resolvedProps, this.preparePropertiesForCcApi(resourceType, resolvedProps, logicalId)) : resolvedProps;
45295
+ const updateProps = updateDecision.provisionedBy === "cc-api" ? withoutGeneratedFallbackName(resourceType, resolvedProps, preparePropertiesForCcApi(this.providerRegistry, resourceType, resolvedProps, logicalId)) : resolvedProps;
44902
45296
  const { previous: previousWithSecretsDropped, dropped: droppedPrincipalKinds } = withUnchangedSecretPrincipalLists(resourceType, currentResource.physicalId, noEchoHeldPaths.size === 0 ? currentPropsAsWritten : {
44903
45297
  ...currentPropsAsWritten,
44904
45298
  ...Object.fromEntries([...noEchoHeldPaths].filter((path) => Object.prototype.hasOwnProperty.call(updateProps, path)).map((path) => [path, updateProps[path]]))
@@ -44950,7 +45344,7 @@ async function updateInPlace({ conditions, counts, currentProps, currentPropsAsW
44950
45344
  previousProperties: currentResource.properties
44951
45345
  });
44952
45346
  const replProvider = replDecision.provider;
44953
- const replProps = replDecision.provisionedBy === "cc-api" ? this.preparePropertiesForCcApi(resourceType, resolvedProps, logicalId) : resolvedProps;
45347
+ const replProps = replDecision.provisionedBy === "cc-api" ? preparePropertiesForCcApi(this.providerRegistry, resourceType, resolvedProps, logicalId) : resolvedProps;
44954
45348
  const fallbackNameChange = await this.checkedReplacementNameChange({
44955
45349
  logicalId,
44956
45350
  resourceType,
@@ -44968,10 +45362,10 @@ async function updateInPlace({ conditions, counts, currentProps, currentPropsAsW
44968
45362
  record: currentResource,
44969
45363
  templateResource: template?.Resources?.[logicalId],
44970
45364
  resolvedProperties: resolvedProps,
44971
- noEchoParameters: this.noEchoPositionSources(stateResources, template)?.parameters ?? /* @__PURE__ */ new Set(),
44972
- conditions: this.noEchoConditions,
45365
+ noEchoParameters: noEchoPositionSources(this.noEchoRun, stateResources, template)?.parameters ?? /* @__PURE__ */ new Set(),
45366
+ conditions: this.noEchoRun.noEchoConditions,
44973
45367
  secrets: updateSecrets,
44974
- inputSources: template && this.maskedInputSources(template, stateResources, this.noEchoConditions, stackName)
45368
+ inputSources: template && this.maskedInputSources(template, stateResources, this.noEchoRun.noEchoConditions, stackName)
44975
45369
  });
44976
45370
  this.logger.info(retainOldOnReplace ? safeMsg`UPDATE not supported for ${logicalId} (${resourceType}), replacing ` + `(CREATE only — UpdateReplacePolicy: Retain keeps the old resource)` : createFirst ? safeMsg`UPDATE not supported for ${logicalId} (${resourceType}), replacing (CREATE → DELETE — the new name differs from the old resource's)` : safeMsg`UPDATE not supported for ${logicalId} (${resourceType}), replacing (DELETE → CREATE)`);
44977
45371
  if (retainOldOnReplace) await noteRetainedResource(resourceType, logicalId);
@@ -45046,7 +45440,7 @@ async function updateInPlace({ conditions, counts, currentProps, currentPropsAsW
45046
45440
  physicalId: currentResource.physicalId
45047
45441
  });
45048
45442
  if (nameHeldElsewhere !== void 0) throw markNonRetryable(new CdkdError(safeMsg`${logicalId} (${resourceType}) requires replacement because the ` + `provisioning layer cannot update it in place, but the create collided. ` + safeMsg`${renderNameHeldElsewhere(nameHeldElsewhere)} — so removing ` + "UpdateReplacePolicy: Retain would delete this resource and still collide. Choose a name no other resource holds, or delete the resource holding it if it is yours.", "NAMED_REPLACEMENT_COLLISION", createError instanceof Error ? createError : void 0));
45049
- const nameOrigin = this.replacementNameOrigin(logicalId, currentResource.physicalId);
45443
+ const nameOrigin = replacementNameOrigin(logicalId, currentResource.physicalId);
45050
45444
  throw markNonRetryable(new CdkdError(safeMsg`${logicalId} (${resourceType}) requires replacement because the ` + "provisioning layer cannot update it in place — but its physical name is still held by the existing resource AND UpdateReplacePolicy: Retain pins that resource in place. " + safeMsg`${nameOrigin.descriptor}. ${nameOrigin.remedy} — with Retain, the old ` + "resource keeps the name, so a same-name replacement can never proceed. Removing UpdateReplacePolicy: Retain lets cdkd delete the old resource first, which destroys it and any data it holds.", "NAMED_REPLACEMENT_COLLISION", createError instanceof Error ? createError : void 0));
45051
45445
  }
45052
45446
  if (!retainOldOnReplace && !createFirst && createResult.physicalId === currentResource.physicalId && !equalIdNamesDifferentResources({
@@ -45062,7 +45456,7 @@ async function updateInPlace({ conditions, counts, currentProps, currentPropsAsW
45062
45456
  oldProperties: currentResource.properties,
45063
45457
  newProperties: resolvedProps
45064
45458
  })) {
45065
- const idempotentNameOrigin = this.replacementNameOrigin(logicalId, currentResource.physicalId);
45459
+ const idempotentNameOrigin = replacementNameOrigin(logicalId, currentResource.physicalId);
45066
45460
  throw markNonRetryable(new CdkdError(safeMsg`${logicalId} (${resourceType}) requires replacement, but its Create ` + `API is name-idempotent: the create returned the existing resource ` + safeMsg`(${currentResource.physicalId}) instead of creating a new one, and ` + `UpdateReplacePolicy: Retain pins that resource in place, so the new ` + safeMsg`properties were not applied. ${idempotentNameOrigin.descriptor}. ` + safeMsg`${idempotentNameOrigin.remedy} — with Retain, the old resource keeps ` + `the name, so a same-name replacement can never proceed.`, "NAMED_REPLACEMENT_IDEMPOTENT_CREATE"));
45067
45461
  }
45068
45462
  this.retainedOldOnReplacement.add(logicalId);
@@ -45075,6 +45469,7 @@ async function updateInPlace({ conditions, counts, currentProps, currentPropsAsW
45075
45469
  ...createResult.attributes && { attributes: createResult.attributes },
45076
45470
  ...createResult.noEchoAttributes === true && { noEchoAttributes: true },
45077
45471
  ...createResult.noEchoAttributeNames && { noEchoAttributeNames: createResult.noEchoAttributeNames },
45472
+ ...createResult.secretNamedAttributeNames && { secretNamedAttributeNames: createResult.secretNamedAttributeNames },
45078
45473
  ...retainedSurvivorReason !== void 0 ? {
45079
45474
  outcome: "partial",
45080
45475
  reason: retainedSurvivorReason
@@ -45110,18 +45505,19 @@ async function updateInPlace({ conditions, counts, currentProps, currentPropsAsW
45110
45505
  ...result.noEchoAttributes === true && { noEchoAttributes: true },
45111
45506
  ...result.noEchoAttributeNames && { noEchoAttributeNames: result.noEchoAttributeNames }
45112
45507
  }, updateSecrets, resolvedProps);
45113
- const recordedProperties = this.propertiesToRecord(resolvedProps, result, resourceType, resultProvisionedBy);
45114
- if (result.wasReplaced) this.noEchoExactEchoes.delete(logicalId);
45508
+ const recordedProperties = propertiesToRecord(resolvedProps, result, resourceType, resultProvisionedBy);
45509
+ if (result.wasReplaced) this.noEchoRun.noEchoExactEchoes.delete(logicalId);
45115
45510
  stateResources[logicalId] = {
45116
45511
  physicalId: result.physicalId,
45117
45512
  resourceType,
45118
45513
  properties: recordedProperties,
45119
45514
  ...acceptedCreateOnlyDropsField(recordedProperties, resourceType, resultProvisionedBy, dischargedByReplacement ? "new-resource" : "in-place", currentResource),
45120
45515
  ...carriedAttributes && { attributes: carriedAttributes },
45516
+ ...secretNamedAttributesField(result, result.attributes === void 0 && !result.wasReplaced ? currentResource : void 0),
45121
45517
  ...!result.wasReplaced && currentResource.noEchoAttributeNames !== void 0 && { noEchoAttributeNames: currentResource.noEchoAttributeNames },
45122
45518
  ...!result.wasReplaced && currentResource.noEchoExactEchoLeaves !== void 0 && { noEchoExactEchoLeaves: currentResource.noEchoExactEchoLeaves },
45123
45519
  ...dependencies && dependencies.length > 0 && { dependencies },
45124
- ...this.extractTemplateAttributes(template, logicalId),
45520
+ ...extractTemplateAttributes(template, logicalId),
45125
45521
  provisionedBy: resultProvisionedBy,
45126
45522
  ...keepsParameterRefusal && {
45127
45523
  observedBaselineRefused: true,
@@ -45130,8 +45526,12 @@ async function updateInPlace({ conditions, counts, currentProps, currentPropsAsW
45130
45526
  };
45131
45527
  if (updatePartialReason(result) === void 0) this.recordInlinePolicyWrite(logicalId, "update");
45132
45528
  if (keepsParameterRefusal) this.logger.debug(safeMsg`observedProperties capture SKIPPED for updated ${logicalId} (${resourceType}): 'cdkd import' refused its baseline because a template parameter was not provably deployed at its 'Default', and this deploy bound the same 'Default' — an in-place update cannot show that AWS no longer holds the deployed value. The refusal stands until the resource is replaced or re-imported against a CloudFormation stack that proves the parameter.`);
45133
- const updateCaptureSiblings = keepsParameterRefusal ? void 0 : await this.buildObservedCaptureSiblings(resourceType, logicalId, result.physicalId, template, stateResources, stackName, parameterValues, conditions);
45134
- if (!keepsParameterRefusal) this.kickOffObservedCapture(captureProvider, logicalId, result.physicalId, resourceType, resolvedProps, {
45529
+ const updateCaptureSiblings = keepsParameterRefusal ? void 0 : await buildObservedCaptureSiblings({
45530
+ options: this.options,
45531
+ buildResolverContext: (...args) => this.buildResolverContext(...args),
45532
+ resolver: this.resolver
45533
+ }, resourceType, logicalId, result.physicalId, template, stateResources, stackName, parameterValues, conditions);
45534
+ if (!keepsParameterRefusal) this.observedCapture.kickOffObservedCapture(captureProvider, logicalId, result.physicalId, resourceType, resolvedProps, {
45135
45535
  ...updateCaptureSiblings,
45136
45536
  afterOwnWrite: true
45137
45537
  }, updateSecrets);
@@ -45391,11 +45791,11 @@ const NESTED_STACK_ROW_TYPE = "AWS::CloudFormation::Stack";
45391
45791
  async function provisionResource(logicalId, change, stateResources, stackName, template, parameterValues, conditions, counts, progress) {
45392
45792
  const resourceType = change.resourceType;
45393
45793
  const renderer = getLiveRenderer();
45394
- const labelRecreateDirection = this.recreateDirectionFor(stackName, logicalId);
45794
+ const labelRecreateDirection = recreateDirectionFor(this.options, stackName, logicalId);
45395
45795
  const labelRecordedType = stateResources[logicalId]?.resourceType;
45396
45796
  const needsReplacement = change.changeType === "UPDATE" && ((change.propertyChanges?.some((pc) => pc.requiresReplacement && !isReplacementCeiling(pc)) ?? false) || labelRecordedType !== void 0 && labelRecordedType !== resourceType) || labelRecreateDirection !== void 0;
45397
45797
  const verb = change.changeType === "CREATE" ? "Creating" : change.changeType === "DELETE" ? "Deleting" : needsReplacement ? "Replacing" : "Updating";
45398
- const labelRouting = this.peekRoutingForLabel(change, stateResources[logicalId], stackName, logicalId, needsReplacement, labelRecreateDirection);
45798
+ const labelRouting = peekRoutingForLabel(this.providerRegistry, this.options, change, stateResources[logicalId], stackName, logicalId, needsReplacement, labelRecreateDirection);
45399
45799
  const baseLabel = `${verb} ${logicalId} (${resourceType})${labelRouting === "cc-api" ? " [CC API]" : ""}`;
45400
45800
  renderer.addTask(logicalId, baseLabel);
45401
45801
  this.liveTaskLabels.set(logicalId, {
@@ -45527,7 +45927,7 @@ async function provisionResource(logicalId, change, stateResources, stackName, t
45527
45927
  const shownMessage = this.maskForResource(logicalId, message);
45528
45928
  const shownId = safeMsg`${logicalId}`;
45529
45929
  this.logger.error(this.maskForResource(logicalId, `Failed to ${change.changeType.toLowerCase()} ${shownId}: ${shownMessage}`));
45530
- const orphanAdvice = this.orphanedNameCollisionAdvice(change.changeType, logicalId, error);
45930
+ const orphanAdvice = orphanedNameCollisionAdvice(this.providerRegistry, change.changeType, logicalId, error);
45531
45931
  if (orphanAdvice) this.logger.error(this.maskForResource(logicalId, orphanAdvice));
45532
45932
  this.recordEvent({
45533
45933
  eventType: "RESOURCE_FAILED",
@@ -45671,6 +46071,131 @@ var DagExecutor = class {
45671
46071
  }
45672
46072
  };
45673
46073
 
46074
+ //#endregion
46075
+ //#region src/analyzer/implicit-delete-deps.ts
46076
+ const IMPLICIT_DELETE_DEPENDENCIES = {
46077
+ "AWS::EC2::InternetGateway": ["AWS::EC2::VPCGatewayAttachment", "AWS::EC2::NatGateway"],
46078
+ "AWS::EC2::VPCGatewayAttachment": ["AWS::EC2::NatGateway"],
46079
+ "AWS::Events::EventBus": ["AWS::Events::Rule"],
46080
+ "AWS::Athena::WorkGroup": ["AWS::Athena::NamedQuery"],
46081
+ "AWS::CloudFront::ResponseHeadersPolicy": ["AWS::CloudFront::Distribution"],
46082
+ "AWS::CloudFront::CachePolicy": ["AWS::CloudFront::Distribution"],
46083
+ "AWS::CloudFront::OriginAccessControl": ["AWS::CloudFront::Distribution"],
46084
+ "AWS::EC2::VPC": [
46085
+ "AWS::EC2::Subnet",
46086
+ "AWS::EC2::SecurityGroup",
46087
+ "AWS::EC2::InternetGateway",
46088
+ "AWS::EC2::EgressOnlyInternetGateway",
46089
+ "AWS::EC2::VPCGatewayAttachment",
46090
+ "AWS::EC2::RouteTable"
46091
+ ],
46092
+ "AWS::EC2::Subnet": ["AWS::EC2::SubnetRouteTableAssociation", "AWS::Lambda::Function"],
46093
+ "AWS::EC2::RouteTable": ["AWS::EC2::Route", "AWS::EC2::SubnetRouteTableAssociation"],
46094
+ "AWS::EC2::SecurityGroup": [
46095
+ "AWS::EC2::SecurityGroupIngress",
46096
+ "AWS::EC2::SecurityGroupEgress",
46097
+ "AWS::Lambda::Function"
46098
+ ]
46099
+ };
46100
+ const ALARM_RULE_FUNCTION_REGEX = /\b(?:ALARM|OK|INSUFFICIENT_DATA)\s*\(\s*([^)]*?)\s*\)/gi;
46101
+ function extractReferencedAlarmNames(alarmRule) {
46102
+ const names = /* @__PURE__ */ new Set();
46103
+ for (const match of alarmRule.matchAll(ALARM_RULE_FUNCTION_REGEX)) {
46104
+ let arg = (match[1] ?? "").trim();
46105
+ if (arg.length === 0) continue;
46106
+ if (arg.startsWith("\"") && arg.endsWith("\"") || arg.startsWith("'") && arg.endsWith("'")) arg = arg.slice(1, -1);
46107
+ if (arg.length === 0) continue;
46108
+ const arnAlarmMatch = /:alarm:(.+)$/.exec(arg);
46109
+ if (arnAlarmMatch?.[1]) names.add(arnAlarmMatch[1]);
46110
+ else names.add(arg);
46111
+ }
46112
+ return [...names];
46113
+ }
46114
+ function computeImplicitDeleteEdges(resources) {
46115
+ const edges = [];
46116
+ const alarmTypes = /* @__PURE__ */ new Set(["AWS::CloudWatch::Alarm", "AWS::CloudWatch::CompositeAlarm"]);
46117
+ const nameToLogicalId = /* @__PURE__ */ new Map();
46118
+ for (const [logicalId, resource] of Object.entries(resources)) {
46119
+ if (!alarmTypes.has(resource.resourceType)) continue;
46120
+ const alarmName = typeof resource.properties?.["AlarmName"] === "string" ? resource.properties["AlarmName"] : resource.physicalId;
46121
+ if (alarmName) nameToLogicalId.set(alarmName, logicalId);
46122
+ }
46123
+ for (const [logicalId, resource] of Object.entries(resources)) {
46124
+ if (resource.resourceType !== "AWS::CloudWatch::CompositeAlarm") continue;
46125
+ const alarmRule = resource.properties?.["AlarmRule"];
46126
+ if (typeof alarmRule !== "string") continue;
46127
+ for (const referencedName of extractReferencedAlarmNames(alarmRule)) {
46128
+ const referencedLogicalId = nameToLogicalId.get(referencedName);
46129
+ if (!referencedLogicalId || referencedLogicalId === logicalId) continue;
46130
+ edges.push({
46131
+ before: logicalId,
46132
+ after: referencedLogicalId
46133
+ });
46134
+ }
46135
+ }
46136
+ return edges;
46137
+ }
46138
+
46139
+ //#endregion
46140
+ //#region src/deployment/deploy-engine/dependencies.ts
46141
+ function hasPending(executor) {
46142
+ for (const node of executor.values()) if (node.state === "pending") return true;
46143
+ return false;
46144
+ }
46145
+ function buildDeletionDependencies(deleteIds, state, logger) {
46146
+ const dependedBy = /* @__PURE__ */ new Map();
46147
+ for (const id of deleteIds) dependedBy.set(id, /* @__PURE__ */ new Set());
46148
+ for (const id of deleteIds) {
46149
+ const resource = state.resources[id];
46150
+ if (!resource?.dependencies) continue;
46151
+ for (const dep of resource.dependencies) {
46152
+ if (!deleteIds.has(dep)) continue;
46153
+ dependedBy.get(dep).add(id);
46154
+ }
46155
+ }
46156
+ addImplicitDeleteDependencies(deleteIds, state, dependedBy, logger);
46157
+ return dependedBy;
46158
+ }
46159
+ function addImplicitDeleteDependencies(deleteIds, state, dependedBy, logger) {
46160
+ const typeToIds = /* @__PURE__ */ new Map();
46161
+ for (const id of deleteIds) {
46162
+ const resource = state.resources[id];
46163
+ if (!resource) continue;
46164
+ const ids = typeToIds.get(resource.resourceType) ?? [];
46165
+ ids.push(id);
46166
+ typeToIds.set(resource.resourceType, ids);
46167
+ }
46168
+ for (const id of deleteIds) {
46169
+ const resource = state.resources[id];
46170
+ if (!resource) continue;
46171
+ const mustDeleteAfter = IMPLICIT_DELETE_DEPENDENCIES[resource.resourceType];
46172
+ if (!mustDeleteAfter) continue;
46173
+ for (const depType of mustDeleteAfter) {
46174
+ const depIds = typeToIds.get(depType);
46175
+ if (!depIds) continue;
46176
+ for (const depId of depIds) {
46177
+ if (!dependedBy.has(id)) dependedBy.set(id, /* @__PURE__ */ new Set());
46178
+ if (!dependedBy.get(id).has(depId)) {
46179
+ dependedBy.get(id).add(depId);
46180
+ logger.debug(safeMsg`Implicit delete dependency: ${depId} (${depType}) must be deleted before ${id} (${resource.resourceType})`);
46181
+ }
46182
+ }
46183
+ }
46184
+ }
46185
+ const scoped = {};
46186
+ for (const id of deleteIds) {
46187
+ const resource = state.resources[id];
46188
+ if (resource) scoped[id] = resource;
46189
+ }
46190
+ for (const { before, after } of computeImplicitDeleteEdges(scoped)) {
46191
+ if (!dependedBy.has(after)) dependedBy.set(after, /* @__PURE__ */ new Set());
46192
+ if (!dependedBy.get(after).has(before)) {
46193
+ dependedBy.get(after).add(before);
46194
+ logger.debug(safeMsg`Implicit delete dependency: ${before} (${scoped[before]?.resourceType}) must be deleted before ${after} (${scoped[after]?.resourceType})`);
46195
+ }
46196
+ }
46197
+ }
46198
+
45674
46199
  //#endregion
45675
46200
  //#region src/deployment/deploy-engine/execute.ts
45676
46201
  const NO_REPLACEMENT_ORPHAN_TYPES = /* @__PURE__ */ new Set([
@@ -45846,13 +46371,13 @@ async function executeDeployment(template, currentState, changes, dag, execution
45846
46371
  provisionedBy: createdId !== void 0 ? "sdk" : pendingRequest !== void 0 ? "cc-api" : newResources[logicalId]?.provisionedBy ?? previousState?.provisionedBy,
45847
46372
  ...pendingRequest !== void 0 && {
45848
46373
  pendingCloudControlRequest: pendingRequest,
45849
- deletionPolicy: journaledOrphanPolicy(this.extractTemplateAttributes(template, logicalId).deletionPolicy)
46374
+ deletionPolicy: journaledOrphanPolicy(extractTemplateAttributes(template, logicalId).deletionPolicy)
45850
46375
  },
45851
46376
  ...previousState && { previousState },
45852
46377
  physicalId: createdId ?? statePhysicalId,
45853
46378
  ...createdId !== void 0 && {
45854
46379
  physicalIdRecoveredFromError: true,
45855
- deletionPolicy: journaledOrphanPolicy(this.extractTemplateAttributes(template, logicalId).deletionPolicy)
46380
+ deletionPolicy: journaledOrphanPolicy(extractTemplateAttributes(template, logicalId).deletionPolicy)
45856
46381
  },
45857
46382
  ...change.changeType === "UPDATE" && this.oldDeletedBeforeCreate.has(logicalId) && { oldDeletedBeforeCreate: true },
45858
46383
  ...orphanedBy !== void 0 && { replacementOrphaned: this.oldDeletedBeforeCreate.has(logicalId) ? "delete-first" : "create-first" },
@@ -45868,7 +46393,7 @@ async function executeDeployment(template, currentState, changes, dag, execution
45868
46393
  provisionedBy: "sdk",
45869
46394
  physicalId: orphanedBy.createdId,
45870
46395
  physicalIdRecoveredFromError: true,
45871
- deletionPolicy: journaledOrphanPolicy(this.extractTemplateAttributes(template, logicalId).deletionPolicy),
46396
+ deletionPolicy: journaledOrphanPolicy(extractTemplateAttributes(template, logicalId).deletionPolicy),
45872
46397
  replacedPhysicalId: orphanedBy.record.physicalId,
45873
46398
  replacedResourceType: orphanedBy.record.resourceType,
45874
46399
  ...this.oldDeletedBeforeCreate.has(logicalId) && { replacedResourceDeleted: true },
@@ -45915,11 +46440,11 @@ async function executeDeployment(template, currentState, changes, dag, execution
45915
46440
  } finally {
45916
46441
  await saveChain;
45917
46442
  }
45918
- if (this.interrupted && this.hasPending(createUpdateExecutor)) throw new InterruptedError(this.interruptCause ?? "user");
46443
+ if (this.interrupted && hasPending(createUpdateExecutor)) throw new InterruptedError(this.interruptCause ?? "user");
45919
46444
  }
45920
46445
  if (deleteChanges.size > 0) {
45921
46446
  this.logger.info(safeMsg`${red("Deleting")} ${red(deleteChanges.size)} resource(s)`);
45922
- const deleteDeps = this.buildDeletionDependencies(deleteChanges, currentState);
46447
+ const deleteDeps = buildDeletionDependencies(deleteChanges, currentState, this.logger);
45923
46448
  const deleteExecutor = new DagExecutor();
45924
46449
  for (const id of deleteChanges) deleteExecutor.add({
45925
46450
  id,
@@ -45961,7 +46486,7 @@ async function executeDeployment(template, currentState, changes, dag, execution
45961
46486
  } finally {
45962
46487
  await saveChain;
45963
46488
  }
45964
- if (this.interrupted && this.hasPending(deleteExecutor)) throw new InterruptedError(this.interruptCause ?? "user");
46489
+ if (this.interrupted && hasPending(deleteExecutor)) throw new InterruptedError(this.interruptCause ?? "user");
45965
46490
  }
45966
46491
  if (this.interrupted) this.warnUnretriedReplacedDeletes("interrupted");
45967
46492
  else try {
@@ -46125,7 +46650,7 @@ async function executeDeployment(template, currentState, changes, dag, execution
46125
46650
  }
46126
46651
  let outputs;
46127
46652
  try {
46128
- outputs = await withSharedDrainBudget(() => this.resolveOutputs(template, newResources, stackName, outputsDigestSource, parameterValues, conditions));
46653
+ outputs = await withSharedDrainBudget(() => resolveOutputs(this.outputsRun, this.outputsDeps(), template, newResources, stackName, outputsDigestSource, parameterValues, conditions));
46129
46654
  const resolvedOutputsBeforeRedaction = outputs;
46130
46655
  outputs = this.redactOutputs(outputs);
46131
46656
  this.rememberRecoverableMaskedOutputs(stackName, resolvedOutputsBeforeRedaction, outputs);
@@ -46142,8 +46667,8 @@ async function executeDeployment(template, currentState, changes, dag, execution
46142
46667
  resources: newResources,
46143
46668
  ...orphansCarriedFrom(currentState),
46144
46669
  outputs,
46145
- exportNames: [...this.resolvedExportNames],
46146
- ...this.skippedOutputs && { skippedOutputs: { ...this.skippedOutputs } },
46670
+ exportNames: [...this.outputsRun.resolvedExportNames],
46671
+ ...this.outputsRun.skippedOutputs && { skippedOutputs: { ...this.outputsRun.skippedOutputs } },
46147
46672
  ...this.recordedImports.length > 0 && { imports: [...this.recordedImports] },
46148
46673
  ...this.recordedOutputReads.length > 0 && { outputReads: [...this.recordedOutputReads] },
46149
46674
  lastModified: Date.now()
@@ -47529,7 +48054,7 @@ async function doDeployWithPrefetch(stackName, template, createOnlyPrefetch) {
47529
48054
  lastModified: Date.now()
47530
48055
  };
47531
48056
  const currentEtag = currentStateData?.etag;
47532
- this.healBaseline = currentState.resources ?? {};
48057
+ this.rebaseline(currentState.resources ?? {});
47533
48058
  this.runProducerRegionEvidence = () => this.producerRegionEvidence(currentState);
47534
48059
  refuseMalformedOutputs(currentState, stackName, this.stackRegion, this.options.refusalRecovery);
47535
48060
  refuseMalformedResourcesForDeploy(currentState, stackName, this.stackRegion, this.options.refusalRecovery);
@@ -47608,8 +48133,8 @@ async function doDeployWithPrefetch(stackName, template, createOnlyPrefetch) {
47608
48133
  }]).command}`);
47609
48134
  }
47610
48135
  } catch {}
47611
- this.stampReasonlessParameterRefusals(currentState.resources, template);
47612
- this.kickOffAutoRefreshObservedProperties(currentState.resources, currentState);
48136
+ stampReasonlessParameterRefusals(this.logger, currentState.resources, template);
48137
+ this.observedCapture.kickOffAutoRefreshObservedProperties(currentState.resources, currentState);
47613
48138
  this.logger.debug(safeMsg`Template has ${Object.keys(template.Resources || {}).length} resources`);
47614
48139
  const outputsDigestSource = structuredClone({
47615
48140
  ...template,
@@ -47618,7 +48143,7 @@ async function doDeployWithPrefetch(stackName, template, createOnlyPrefetch) {
47618
48143
  const parameterValues = await this.resolver.resolveParameters(template, this.options.parameters, { ...this.options.inheritedSecrets && hasMaskableValues(this.options.inheritedSecrets) && { inheritedSecrets: this.options.inheritedSecrets } });
47619
48144
  this.logger.debug(safeMsg`Resolved ${Object.keys(parameterValues).length} parameters: ${Object.keys(parameterValues).join(", ")}`);
47620
48145
  poisonRenderedSpellingsCollidingIn(template, parameterValues, this.options.inheritedSecrets);
47621
- this.inheritedNoEchoParameters = /* @__PURE__ */ new Set([...this.freshNoEchoParameters(parameterValues) ?? [], ...this.options.passedNoEchoParameters ?? []]);
48146
+ this.noEchoRun.inheritedNoEchoParameters = /* @__PURE__ */ new Set([...this.freshNoEchoParameters(parameterValues) ?? [], ...this.options.passedNoEchoParameters ?? []]);
47622
48147
  const backfillNoEchoValues = noEchoParameterValueSeed(template.Parameters, parameterValues, this.options.inheritedSecrets, this.options.parameters);
47623
48148
  this.fingerprintNoEchoValues = backfillNoEchoValues;
47624
48149
  this.fingerprintParameters = parameterInputsFor({
@@ -47649,14 +48174,15 @@ async function doDeployWithPrefetch(stackName, template, createOnlyPrefetch) {
47649
48174
  }));
47650
48175
  }
47651
48176
  const effectiveTemplate = this.templateParser.filterResourcesByCondition(template, conditions);
47652
- this.constructPathTemplate = effectiveTemplate;
47653
- this.noEchoConditions = conditions;
47654
- this.seedPersistedNoEchoAttributes(currentState.resources);
48177
+ this.noEchoRun.constructPathTemplate = effectiveTemplate;
48178
+ this.noEchoRun.noEchoConditions = conditions;
48179
+ seedPersistedNoEchoAttributes(this.noEchoRun, currentState.resources);
47655
48180
  const orphanCountBeforeAdoption = (currentState.orphans ?? []).length;
47656
48181
  const orphanPlan = await this.adoptRollbackOrphans(currentState, effectiveTemplate);
47657
- this.preDeploySecretNamedRecords = secretNamedRecordNeedles(currentState.resources, this.fingerprintNoEchoValues);
48182
+ this.captureStoredNoEchoNamingValues(currentState.resources, effectiveTemplate, conditions);
48183
+ this.preDeploySecretNamedRecords = secretNamedRecordNeedles(currentState.resources, this.stateNamingSecrets());
47658
48184
  if (Object.keys(orphanPlan.adopted).length > 0) {
47659
- this.stampReasonlessParameterRefusals(currentState.resources, template);
48185
+ stampReasonlessParameterRefusals(this.logger, currentState.resources, template);
47660
48186
  if (backfillMaskedPropertyFingerprints(currentState.resources, template, backfillNoEchoValues) > 0) maskedFingerprintsBackfilled = true;
47661
48187
  }
47662
48188
  const orphansChanged = Object.keys(orphanPlan.adopted).length > 0 || (currentState.orphans ?? []).length !== orphanCountBeforeAdoption;
@@ -47691,7 +48217,7 @@ async function doDeployWithPrefetch(stackName, template, createOnlyPrefetch) {
47691
48217
  sources: maskedInputSourcesForDiff,
47692
48218
  rebaselined: /* @__PURE__ */ new Map()
47693
48219
  };
47694
- const changes = await this.diffCalculator.calculateDiff(currentState, effectiveTemplate, diffResolveFn, makeCanonicalizePropertiesFn(this.providerRegistry), this.providerRegistry.getAllowedUnsupportedProperties?.(), freshNoEchoParametersWithDeclared(this.inheritedNoEchoParameters, effectiveTemplate), this.diffLogMasker(diffResolverContext.recordedSecretValues, effectiveTemplate, parameterValues, currentState.resources), recreateTargetIdsFor(this.options.recreateTargets, stackName), maskedInputs, this.options.refusalRecovery, this.noEchoDiffComparison(currentState.resources, effectiveTemplate, conditions, parameterValues, stackName), {
48220
+ const changes = await this.diffCalculator.calculateDiff(currentState, effectiveTemplate, diffResolveFn, makeCanonicalizePropertiesFn(this.providerRegistry), this.providerRegistry.getAllowedUnsupportedProperties?.(), freshNoEchoParametersWithDeclared(this.noEchoRun.inheritedNoEchoParameters, effectiveTemplate), this.diffLogMasker(diffResolverContext.recordedSecretValues, effectiveTemplate, parameterValues, currentState.resources), recreateTargetIdsFor(this.options.recreateTargets, stackName), maskedInputs, this.options.refusalRecovery, noEchoDiffComparison(this.noEchoRun, this.noEchoDeps(), currentState.resources, effectiveTemplate, conditions, parameterValues, stackName), {
47695
48221
  ...this.options.inheritedReferenceProvenance && { inherited: this.options.inheritedReferenceProvenance },
47696
48222
  crossStackOutputs: crossStackOutputProvenanceSource(crossStackReads, this.recordedImports, this.stateBackend)
47697
48223
  });
@@ -47734,7 +48260,7 @@ async function doDeployWithPrefetch(stackName, template, createOnlyPrefetch) {
47734
48260
  }
47735
48261
  const startProvenanceCapture = () => {
47736
48262
  if (this.options.dryRun || isKnownTokenFreeState(currentStateData?.state)) return;
47737
- this.kickOffProvenanceCapture({
48263
+ this.provenanceCapture.kickOffProvenanceCapture({
47738
48264
  noChange: this.diffCalculator.filterByType(changes, "NO_CHANGE").map((change) => change.logicalId),
47739
48265
  resources: currentState.resources,
47740
48266
  template: effectiveTemplate,
@@ -47748,8 +48274,8 @@ async function doDeployWithPrefetch(stackName, template, createOnlyPrefetch) {
47748
48274
  startProvenanceCapture();
47749
48275
  let persistedOutputs = currentState.outputs ?? {};
47750
48276
  if (!this.options.dryRun) {
47751
- const resolvedOutputs = this.redactOutputs(await withSharedDrainBudget(() => this.resolveOutputs(effectiveTemplate, currentState.resources, stackName, outputsDigestSource, parameterValues, conditions)));
47752
- const observedRefresh = await this.drainObservedCaptures(currentState.resources) > 0;
48277
+ const resolvedOutputs = this.redactOutputs(await withSharedDrainBudget(() => resolveOutputs(this.outputsRun, this.outputsDeps(), effectiveTemplate, currentState.resources, stackName, outputsDigestSource, parameterValues, conditions)));
48278
+ const observedRefresh = await this.observedCapture.drainObservedCaptures(currentState.resources) > 0;
47753
48279
  const resolutionFailed = Object.values(resolvedOutputs).some((v) => v === void 0);
47754
48280
  const currentEffectiveExports = new Set(importableOutputKeys(currentState));
47755
48281
  let merge = resolutionFailed ? mergeNoChangeOutputs({
@@ -47757,27 +48283,27 @@ async function doDeployWithPrefetch(stackName, template, createOnlyPrefetch) {
47757
48283
  resolved: resolvedOutputs,
47758
48284
  declaredOutputs: effectiveTemplate.Outputs,
47759
48285
  previousExportNames: currentEffectiveExports,
47760
- resolvedExportNames: this.resolvedExportNames,
47761
- refusesCarriedAlias: (outputKey, exportName) => this.carriedExportAliasRefusal === void 0 ? "An export alias was not carried: no export-name verdict is available." : this.carriedExportAliasRefusal(outputKey, exportName)
48286
+ resolvedExportNames: this.outputsRun.resolvedExportNames,
48287
+ refusesCarriedAlias: (outputKey, exportName) => this.outputsRun.carriedExportAliasRefusal === void 0 ? "An export alias was not carried: no export-name verdict is available." : this.outputsRun.carriedExportAliasRefusal(outputKey, exportName)
47762
48288
  }) : void 0;
47763
48289
  if (merge?.kind === "merged") {
47764
- for (const key of merge.carriedKeys) Reflect.deleteProperty(this.outputsTemplateSource, key);
48290
+ for (const key of merge.carriedKeys) Reflect.deleteProperty(this.outputsRun.outputsTemplateSource, key);
47765
48291
  if (merge.carriedKeys.length > 0 && !bagHoldsSecretExpression(persistedOutputs) && bagHoldsSecretExpression(this.redactOutputs(merge.outputs))) merge = {
47766
48292
  kind: "kept",
47767
48293
  reason: "mixed-generation"
47768
48294
  };
47769
48295
  }
47770
- if (merge?.kind === "kept") this.outputsSourceUsable = false;
48296
+ if (merge?.kind === "kept") this.outputsRun.outputsSourceUsable = false;
47771
48297
  if (merge?.kind === "merged") for (const { reason } of merge.refusedAliases) this.logger.warn(reason);
47772
48298
  const outputsToPersist = merge === void 0 ? resolvedOutputs : merge.kind === "merged" ? merge.outputs : persistedOutputs;
47773
- const exportNamesToPersist = merge === void 0 ? this.resolvedExportNames : merge.kind === "merged" ? merge.exportNames : void 0;
48299
+ const exportNamesToPersist = merge === void 0 ? this.outputsRun.resolvedExportNames : merge.kind === "merged" ? merge.exportNames : void 0;
47774
48300
  const outputsChanged = !outputMapsEqual(persistedOutputs, outputsToPersist);
47775
48301
  const persistExportSet = new Set(exportNamesToPersist ?? []);
47776
48302
  const exportSetChanged = exportNamesToPersist !== void 0 && (currentEffectiveExports.size !== persistExportSet.size || [...persistExportSet].some((k) => !currentEffectiveExports.has(k)));
47777
48303
  if (merge?.kind === "kept" && !outputMapsEqual(persistedOutputs, resolvedOutputs)) this.logger.warn(safeMsg`Outputs changed but one or more could not be resolved; keeping the previously persisted outputs. ${keptWholeReasonText(merge.reason)} ` + "A downstream Fn::ImportValue may fail until the next deploy.");
47778
48304
  else if (merge?.kind === "merged" && merge.carriedKeys.length > 0) this.logger.debug(safeMsg`Kept the previously persisted value of ${merge.carriedKeys.length} output key(s), ` + "carried export aliases included, that could not be resolved (no-change path)");
47779
- const skippedOutputsChanged = !skippedOutputsEqual(currentState.skippedOutputs, this.skippedOutputs);
47780
- const healedAttributesPending = this.hasUnpersistedHeals(currentState.resources);
48305
+ const skippedOutputsChanged = !skippedOutputsEqual(currentState.skippedOutputs, this.outputsRun.skippedOutputs);
48306
+ const healedAttributesPending = this.attributeHealer.hasUnpersistedHeals(currentState.resources);
47781
48307
  const conditionVerdictsChanged = !conditionVerdictRecordsEqual(readRecordedConditionVerdicts(currentState), conditionVerdicts);
47782
48308
  if (outputsChanged || exportSetChanged && currentState.exportNames !== void 0) await requireOutputsOnlyApproval({
47783
48309
  options: this.options,
@@ -47793,7 +48319,7 @@ async function doDeployWithPrefetch(stackName, template, createOnlyPrefetch) {
47793
48319
  ...orphansCarriedFrom(currentState),
47794
48320
  outputs: outputsChanged ? outputsToPersist : persistedOutputs,
47795
48321
  ...exportNamesToPersist === void 0 ? exportNamesCarriedFrom(currentState) : { exportNames: [...exportNamesToPersist] },
47796
- ...this.skippedOutputs && { skippedOutputs: { ...this.skippedOutputs } },
48322
+ ...this.outputsRun.skippedOutputs && { skippedOutputs: { ...this.outputsRun.skippedOutputs } },
47797
48323
  ...crossStackReadsForPartialSave(currentState, this.recordedImports, this.recordedOutputReads, this.crossStackReadKeyNormalizer()),
47798
48324
  ...conditionVerdicts && { conditionVerdicts },
47799
48325
  lastModified: Date.now()
@@ -47826,7 +48352,7 @@ async function doDeployWithPrefetch(stackName, template, createOnlyPrefetch) {
47826
48352
  updatePartial: 0,
47827
48353
  unchanged: Object.keys(currentState.resources).length,
47828
48354
  durationMs: Date.now() - startTime,
47829
- outputs: this.buildDisplayOutputs(template, this.redactOutputs(persistedOutputs)),
48355
+ outputs: buildDisplayOutputs(template, this.redactOutputs(persistedOutputs)),
47830
48356
  attributeFallbackCount: this.resolver.getPhysicalIdFallbackCount()
47831
48357
  };
47832
48358
  }
@@ -47907,7 +48433,7 @@ async function doDeployWithPrefetch(stackName, template, createOnlyPrefetch) {
47907
48433
  try {
47908
48434
  this.stateBackend.warmConnections(stackName, this.stackRegion, TAIL_WARM_CONNECTIONS);
47909
48435
  } catch {}
47910
- await this.drainObservedCaptures(newState.resources);
48436
+ await this.observedCapture.drainObservedCaptures(newState.resources);
47911
48437
  const [newEtag] = await Promise.all([this.stateBackend.saveState(stackName, this.stackRegion, this.withParentInfo(conditionVerdicts ? {
47912
48438
  ...newState,
47913
48439
  conditionVerdicts
@@ -47944,7 +48470,7 @@ async function doDeployWithPrefetch(stackName, template, createOnlyPrefetch) {
47944
48470
  ...(actualCounts.crossPrefixKept ?? 0) > 0 && { crossPrefixKept: actualCounts.crossPrefixKept },
47945
48471
  unchanged: unchangedCount,
47946
48472
  durationMs,
47947
- outputs: this.buildDisplayOutputs(template, this.redactOutputs(newState.outputs ?? {})),
48473
+ outputs: buildDisplayOutputs(template, this.redactOutputs(newState.outputs ?? {})),
47948
48474
  attributeFallbackCount: this.resolver.getPhysicalIdFallbackCount()
47949
48475
  };
47950
48476
  } catch (error) {
@@ -47956,7 +48482,7 @@ async function doDeployWithPrefetch(stackName, template, createOnlyPrefetch) {
47956
48482
  renderer.stop();
47957
48483
  } catch {}
47958
48484
  process.removeListener("SIGINT", sigintHandler);
47959
- this.observedCaptureTasks.clear();
48485
+ this.observedCapture.observedCaptureTasks.clear();
47960
48486
  try {
47961
48487
  await flushKeptForReadoption(this);
47962
48488
  await this.generatedNameGuard?.settle();
@@ -47978,175 +48504,6 @@ async function doDeployWithPrefetch(stackName, template, createOnlyPrefetch) {
47978
48504
  }
47979
48505
  }
47980
48506
 
47981
- //#endregion
47982
- //#region src/deployment/label-routing.ts
47983
- function deriveLabelRouting(change, existingState, registry, forceCcApi = false) {
47984
- try {
47985
- if (change.changeType === "DELETE") return existingState?.provisionedBy;
47986
- return registry.getProviderFor({
47987
- resourceType: change.resourceType,
47988
- properties: change.desiredProperties ?? {},
47989
- provisionedBy: existingState?.provisionedBy,
47990
- previousProperties: existingState?.properties,
47991
- forceCcApi
47992
- }).provisionedBy;
47993
- } catch {
47994
- return;
47995
- }
47996
- }
47997
-
47998
- //#endregion
47999
- //#region src/deployment/deploy-engine/routing.ts
48000
- function isPinnedToCcApi(stackName, logicalId) {
48001
- return this.options.pinCcApi?.stackName === stackName && this.options.pinCcApi.logicalIds.has(logicalId);
48002
- }
48003
- function recreateDirectionFor(stackName, logicalId) {
48004
- const targets = this.options.recreateTargets?.stackName === stackName ? this.options.recreateTargets : void 0;
48005
- if (targets === void 0) return void 0;
48006
- if (targets.viaCcApi.has(logicalId)) return "cc-api";
48007
- if (targets.viaSdkProvider.has(logicalId)) return "sdk";
48008
- }
48009
- function peekRoutingForLabel(change, existingState, stackName, logicalId, needsReplacement = false, recreateDirection) {
48010
- if (needsReplacement) {
48011
- const hintRecord = {
48012
- ...recreateDirection !== void 0 && { provisionedBy: recreateDirection },
48013
- ...existingState?.properties !== void 0 && { properties: existingState.properties }
48014
- };
48015
- return deriveLabelRouting(change, hintRecord, this.providerRegistry, recreateDirection === "cc-api");
48016
- }
48017
- return deriveLabelRouting(change, existingState, this.providerRegistry, this.isPinnedToCcApi(stackName, logicalId));
48018
- }
48019
- function preparePropertiesForCcApi(resourceType, resolvedProps, logicalId) {
48020
- const sdkProvider = this.providerRegistry.getRegisteredTypes().includes(resourceType) ? this.providerRegistry.getProvider(resourceType) : void 0;
48021
- if (sdkProvider?.preparePropertiesForFallback) return sdkProvider.preparePropertiesForFallback(logicalId, resourceType, resolvedProps);
48022
- return applyDefaultNameForFallback(logicalId, resourceType, resolvedProps);
48023
- }
48024
-
48025
- //#endregion
48026
- //#region src/analyzer/implicit-delete-deps.ts
48027
- const IMPLICIT_DELETE_DEPENDENCIES = {
48028
- "AWS::EC2::InternetGateway": ["AWS::EC2::VPCGatewayAttachment", "AWS::EC2::NatGateway"],
48029
- "AWS::EC2::VPCGatewayAttachment": ["AWS::EC2::NatGateway"],
48030
- "AWS::Events::EventBus": ["AWS::Events::Rule"],
48031
- "AWS::Athena::WorkGroup": ["AWS::Athena::NamedQuery"],
48032
- "AWS::CloudFront::ResponseHeadersPolicy": ["AWS::CloudFront::Distribution"],
48033
- "AWS::CloudFront::CachePolicy": ["AWS::CloudFront::Distribution"],
48034
- "AWS::CloudFront::OriginAccessControl": ["AWS::CloudFront::Distribution"],
48035
- "AWS::EC2::VPC": [
48036
- "AWS::EC2::Subnet",
48037
- "AWS::EC2::SecurityGroup",
48038
- "AWS::EC2::InternetGateway",
48039
- "AWS::EC2::EgressOnlyInternetGateway",
48040
- "AWS::EC2::VPCGatewayAttachment",
48041
- "AWS::EC2::RouteTable"
48042
- ],
48043
- "AWS::EC2::Subnet": ["AWS::EC2::SubnetRouteTableAssociation", "AWS::Lambda::Function"],
48044
- "AWS::EC2::RouteTable": ["AWS::EC2::Route", "AWS::EC2::SubnetRouteTableAssociation"],
48045
- "AWS::EC2::SecurityGroup": [
48046
- "AWS::EC2::SecurityGroupIngress",
48047
- "AWS::EC2::SecurityGroupEgress",
48048
- "AWS::Lambda::Function"
48049
- ]
48050
- };
48051
- const ALARM_RULE_FUNCTION_REGEX = /\b(?:ALARM|OK|INSUFFICIENT_DATA)\s*\(\s*([^)]*?)\s*\)/gi;
48052
- function extractReferencedAlarmNames(alarmRule) {
48053
- const names = /* @__PURE__ */ new Set();
48054
- for (const match of alarmRule.matchAll(ALARM_RULE_FUNCTION_REGEX)) {
48055
- let arg = (match[1] ?? "").trim();
48056
- if (arg.length === 0) continue;
48057
- if (arg.startsWith("\"") && arg.endsWith("\"") || arg.startsWith("'") && arg.endsWith("'")) arg = arg.slice(1, -1);
48058
- if (arg.length === 0) continue;
48059
- const arnAlarmMatch = /:alarm:(.+)$/.exec(arg);
48060
- if (arnAlarmMatch?.[1]) names.add(arnAlarmMatch[1]);
48061
- else names.add(arg);
48062
- }
48063
- return [...names];
48064
- }
48065
- function computeImplicitDeleteEdges(resources) {
48066
- const edges = [];
48067
- const alarmTypes = /* @__PURE__ */ new Set(["AWS::CloudWatch::Alarm", "AWS::CloudWatch::CompositeAlarm"]);
48068
- const nameToLogicalId = /* @__PURE__ */ new Map();
48069
- for (const [logicalId, resource] of Object.entries(resources)) {
48070
- if (!alarmTypes.has(resource.resourceType)) continue;
48071
- const alarmName = typeof resource.properties?.["AlarmName"] === "string" ? resource.properties["AlarmName"] : resource.physicalId;
48072
- if (alarmName) nameToLogicalId.set(alarmName, logicalId);
48073
- }
48074
- for (const [logicalId, resource] of Object.entries(resources)) {
48075
- if (resource.resourceType !== "AWS::CloudWatch::CompositeAlarm") continue;
48076
- const alarmRule = resource.properties?.["AlarmRule"];
48077
- if (typeof alarmRule !== "string") continue;
48078
- for (const referencedName of extractReferencedAlarmNames(alarmRule)) {
48079
- const referencedLogicalId = nameToLogicalId.get(referencedName);
48080
- if (!referencedLogicalId || referencedLogicalId === logicalId) continue;
48081
- edges.push({
48082
- before: logicalId,
48083
- after: referencedLogicalId
48084
- });
48085
- }
48086
- }
48087
- return edges;
48088
- }
48089
-
48090
- //#endregion
48091
- //#region src/deployment/deploy-engine/dependencies.ts
48092
- function hasPending(executor) {
48093
- for (const node of executor.values()) if (node.state === "pending") return true;
48094
- return false;
48095
- }
48096
- function buildDeletionDependencies(deleteIds, state) {
48097
- const dependedBy = /* @__PURE__ */ new Map();
48098
- for (const id of deleteIds) dependedBy.set(id, /* @__PURE__ */ new Set());
48099
- for (const id of deleteIds) {
48100
- const resource = state.resources[id];
48101
- if (!resource?.dependencies) continue;
48102
- for (const dep of resource.dependencies) {
48103
- if (!deleteIds.has(dep)) continue;
48104
- dependedBy.get(dep).add(id);
48105
- }
48106
- }
48107
- this.addImplicitDeleteDependencies(deleteIds, state, dependedBy);
48108
- return dependedBy;
48109
- }
48110
- function addImplicitDeleteDependencies(deleteIds, state, dependedBy) {
48111
- const typeToIds = /* @__PURE__ */ new Map();
48112
- for (const id of deleteIds) {
48113
- const resource = state.resources[id];
48114
- if (!resource) continue;
48115
- const ids = typeToIds.get(resource.resourceType) ?? [];
48116
- ids.push(id);
48117
- typeToIds.set(resource.resourceType, ids);
48118
- }
48119
- for (const id of deleteIds) {
48120
- const resource = state.resources[id];
48121
- if (!resource) continue;
48122
- const mustDeleteAfter = IMPLICIT_DELETE_DEPENDENCIES[resource.resourceType];
48123
- if (!mustDeleteAfter) continue;
48124
- for (const depType of mustDeleteAfter) {
48125
- const depIds = typeToIds.get(depType);
48126
- if (!depIds) continue;
48127
- for (const depId of depIds) {
48128
- if (!dependedBy.has(id)) dependedBy.set(id, /* @__PURE__ */ new Set());
48129
- if (!dependedBy.get(id).has(depId)) {
48130
- dependedBy.get(id).add(depId);
48131
- this.logger.debug(safeMsg`Implicit delete dependency: ${depId} (${depType}) must be deleted before ${id} (${resource.resourceType})`);
48132
- }
48133
- }
48134
- }
48135
- }
48136
- const scoped = {};
48137
- for (const id of deleteIds) {
48138
- const resource = state.resources[id];
48139
- if (resource) scoped[id] = resource;
48140
- }
48141
- for (const { before, after } of computeImplicitDeleteEdges(scoped)) {
48142
- if (!dependedBy.has(after)) dependedBy.set(after, /* @__PURE__ */ new Set());
48143
- if (!dependedBy.get(after).has(before)) {
48144
- dependedBy.get(after).add(before);
48145
- this.logger.debug(safeMsg`Implicit delete dependency: ${before} (${scoped[before]?.resourceType}) must be deleted before ${after} (${scoped[after]?.resourceType})`);
48146
- }
48147
- }
48148
- }
48149
-
48150
48507
  //#endregion
48151
48508
  //#region src/deployment/deploy-engine.ts
48152
48509
  const EMPTY_SECRETS = /* @__PURE__ */ new Map();
@@ -48183,10 +48540,9 @@ var DeployEngine = class {
48183
48540
  resolver;
48184
48541
  interrupted = false;
48185
48542
  interruptCause = null;
48186
- observedCaptureTasks = /* @__PURE__ */ new Map();
48187
48543
  absentJournalVersionPurge;
48188
48544
  noEchoCeilingReadbackTimeoutMs = 3e4;
48189
- recapturedBaselines = /* @__PURE__ */ new WeakMap();
48545
+ observedCapture;
48190
48546
  stateBackend;
48191
48547
  lockManager;
48192
48548
  dagBuilder;
@@ -48198,33 +48554,19 @@ var DeployEngine = class {
48198
48554
  recordedImports = [];
48199
48555
  recordedOutputReads = [];
48200
48556
  perResourceSecrets = /* @__PURE__ */ new Map();
48201
- noEchoAttributeResources = /* @__PURE__ */ new Map();
48202
- persistedNoEchoAttributes = /* @__PURE__ */ new Map();
48203
- noEchoConditions;
48204
- inheritedNoEchoParameters = /* @__PURE__ */ new Set();
48205
- noEchoPhysicalIdWarned = /* @__PURE__ */ new Set();
48206
- noEchoPositionedValues = /* @__PURE__ */ new Map();
48207
- noEchoExactEchoes = /* @__PURE__ */ new Map();
48208
- noEchoAttributeReads = /* @__PURE__ */ new Map();
48557
+ noEchoRun = new NoEchoRunState();
48209
48558
  replacedDeleteSkips = /* @__PURE__ */ new Map();
48210
48559
  deferredReplacedDeletes = void 0;
48211
48560
  secretNameNeedles = /* @__PURE__ */ new Map();
48212
48561
  perResourceTemplateProps = /* @__PURE__ */ new Map();
48213
48562
  perResourceResolvedType = /* @__PURE__ */ new Map();
48214
- witnessConfirmedLeaves = /* @__PURE__ */ new Map();
48215
48563
  fingerprintNoEchoValues = void 0;
48216
48564
  preDeploySecretNamedRecords = void 0;
48565
+ storedNoEchoNamingValues = /* @__PURE__ */ new Map();
48217
48566
  fingerprintParameters = void 0;
48218
48567
  fingerprintChildTemplates = void 0;
48219
48568
  perResourceInputFingerprints = /* @__PURE__ */ new Map();
48220
- outputSecrets = /* @__PURE__ */ new Map();
48221
- outputsPassSecretMaps = [];
48222
- outputsTemplateSource = Object.create(null);
48223
- resolvedExportNames = [];
48224
- carriedExportAliasRefusal;
48225
- skippedOutputs;
48226
- constructPathTemplate;
48227
- outputsSourceUsable = true;
48569
+ outputsRun = new OutputsRunState();
48228
48570
  attemptedResolvedProps = /* @__PURE__ */ new Map();
48229
48571
  resumedCreates = /* @__PURE__ */ new Map();
48230
48572
  generatedNameGuard;
@@ -48236,20 +48578,18 @@ var DeployEngine = class {
48236
48578
  updatesThatSentNothing = /* @__PURE__ */ new Set();
48237
48579
  updateWasReplaced = /* @__PURE__ */ new Map();
48238
48580
  inPlaceCreateOnlyPaths = /* @__PURE__ */ new Map();
48239
- outputProvenanceSinks = /* @__PURE__ */ new Map();
48240
- outputsResolvedThisRun = /* @__PURE__ */ new WeakSet();
48241
48581
  provenanceBaseline = void 0;
48242
- resolvedOutputsBag = void 0;
48243
- provenanceCaptureTasks = /* @__PURE__ */ new Map();
48582
+ provenanceCapture;
48244
48583
  oldDeletedBeforeCreate = /* @__PURE__ */ new Set();
48245
- healBaseline = {};
48584
+ get healBaseline() {
48585
+ return this.attributeHealer.baseline;
48586
+ }
48246
48587
  runProducerRegionEvidence = void 0;
48247
48588
  deployChanges = /* @__PURE__ */ new Map();
48248
48589
  deployStateResources = {};
48249
48590
  stackRecordsView = void 0;
48250
48591
  inlinePolicyWriters = /* @__PURE__ */ new Map();
48251
- attributeHeals = /* @__PURE__ */ new Map();
48252
- healedAttributes = /* @__PURE__ */ new Map();
48592
+ attributeHealer;
48253
48593
  stackRegion;
48254
48594
  constructor(stateBackend, lockManager, dagBuilder, diffCalculator, providerRegistry, options = {}, stackRegion, exportIndexStore) {
48255
48595
  this.stateBackend = stateBackend;
@@ -48273,28 +48613,74 @@ var DeployEngine = class {
48273
48613
  this.options.resourceWarnAfterMs = options.resourceWarnAfterMs ?? 3e5;
48274
48614
  this.options.resourceTimeoutMs = options.resourceTimeoutMs ?? 18e5;
48275
48615
  this.options.captureObservedState = options.captureObservedState ?? true;
48616
+ this.attributeHealer = this.rebaseline({});
48617
+ this.provenanceCapture = this.freshProvenanceCapture();
48618
+ this.observedCapture = this.freshObservedCapture();
48619
+ }
48620
+ freshObservedCapture() {
48621
+ return new ObservedCapture({
48622
+ logger: this.logger,
48623
+ options: this.options,
48624
+ resolver: this.resolver,
48625
+ providerRegistry: this.providerRegistry,
48626
+ printingSecretsFor: (logicalId) => this.printingSecretsFor(logicalId),
48627
+ fingerprintNoEchoValues: () => this.fingerprintNoEchoValues,
48628
+ provenanceCapture: () => this.provenanceCapture
48629
+ });
48630
+ }
48631
+ rebaseline(resources) {
48632
+ this.attributeHealer = new AttributeHealer({
48633
+ providerRegistry: this.providerRegistry,
48634
+ stackRegion: this.stackRegion,
48635
+ logger: this.logger,
48636
+ baseline: resources,
48637
+ resolvedSecretsOf: (logicalId) => this.perResourceSecrets.get(logicalId),
48638
+ namingSecrets: () => this.stateNamingSecrets()
48639
+ });
48640
+ return this.attributeHealer;
48641
+ }
48642
+ freshProvenanceCapture() {
48643
+ return new ProvenanceCapture({
48644
+ buildResolverContext: (...args) => this.buildResolverContext(...args),
48645
+ resolver: this.resolver,
48646
+ logger: this.logger
48647
+ });
48648
+ }
48649
+ outputsDeps() {
48650
+ return {
48651
+ options: this.options,
48652
+ logger: this.logger,
48653
+ resolver: this.resolver,
48654
+ buildResolverContext: (...args) => this.buildResolverContext(...args),
48655
+ noEchoPositionSources: (...args) => noEchoPositionSources(this.noEchoRun, ...args)
48656
+ };
48657
+ }
48658
+ noEchoDeps() {
48659
+ return {
48660
+ stackRegion: this.stackRegion,
48661
+ logger: this.logger,
48662
+ providerRegistry: this.providerRegistry,
48663
+ perResourceSecrets: () => this.perResourceSecrets,
48664
+ perResourceTemplateProps: () => this.perResourceTemplateProps,
48665
+ perResourceResolvedType: () => this.perResourceResolvedType,
48666
+ outputsRun: () => this.outputsRun,
48667
+ readReaderForFreshNoEchoCeiling: (...args) => this.readReaderForFreshNoEchoCeiling(...args),
48668
+ maskForResource: (...args) => this.maskForResource(...args)
48669
+ };
48276
48670
  }
48277
48671
  async deploy(stackName, template) {
48278
48672
  this.recordedImports = [];
48279
48673
  this.recordedOutputReads = [];
48280
48674
  this.perResourceSecrets = /* @__PURE__ */ new Map();
48281
- this.noEchoAttributeResources = /* @__PURE__ */ new Map();
48282
- this.persistedNoEchoAttributes = /* @__PURE__ */ new Map();
48283
- this.noEchoConditions = void 0;
48284
- this.inheritedNoEchoParameters = /* @__PURE__ */ new Set();
48285
- this.noEchoPhysicalIdWarned = /* @__PURE__ */ new Set();
48286
- this.noEchoPositionedValues = /* @__PURE__ */ new Map();
48287
- this.noEchoExactEchoes = /* @__PURE__ */ new Map();
48288
- this.noEchoAttributeReads = /* @__PURE__ */ new Map();
48675
+ this.noEchoRun = new NoEchoRunState();
48289
48676
  this.replacedDeleteSkips = /* @__PURE__ */ new Map();
48290
48677
  this.deferredReplacedDeletes = void 0;
48291
48678
  this.secretNameNeedles = /* @__PURE__ */ new Map();
48292
48679
  this.perResourceTemplateProps = /* @__PURE__ */ new Map();
48293
- this.constructPathTemplate = void 0;
48294
48680
  this.perResourceResolvedType = /* @__PURE__ */ new Map();
48295
- this.witnessConfirmedLeaves = /* @__PURE__ */ new Map();
48296
48681
  this.fingerprintNoEchoValues = void 0;
48297
48682
  this.preDeploySecretNamedRecords = void 0;
48683
+ this.storedNoEchoNamingValues = /* @__PURE__ */ new Map();
48298
48684
  this.fingerprintParameters = void 0;
48299
48685
  this.fingerprintChildTemplates = void 0;
48300
48686
  this.perResourceInputFingerprints = /* @__PURE__ */ new Map();
@@ -48302,11 +48688,7 @@ var DeployEngine = class {
48302
48688
  this.resumedCreates = /* @__PURE__ */ new Map();
48303
48689
  this.generatedNameGuard = void 0;
48304
48690
  this.liveTaskLabels = /* @__PURE__ */ new Map();
48305
- this.outputSecrets = /* @__PURE__ */ new Map();
48306
- this.outputsPassSecretMaps = [];
48307
- this.outputsTemplateSource = Object.create(null);
48308
- this.outputsSourceUsable = true;
48309
- this.skippedOutputs = void 0;
48691
+ this.outputsRun = new OutputsRunState();
48310
48692
  this.retainedOldOnReplacement = /* @__PURE__ */ new Set();
48311
48693
  this.replacedOldMaySurvive = /* @__PURE__ */ new Map();
48312
48694
  this.recreatedUnderSameId = /* @__PURE__ */ new Set();
@@ -48314,19 +48696,15 @@ var DeployEngine = class {
48314
48696
  this.updatesThatSentNothing = /* @__PURE__ */ new Set();
48315
48697
  this.updateWasReplaced = /* @__PURE__ */ new Map();
48316
48698
  this.inPlaceCreateOnlyPaths = /* @__PURE__ */ new Map();
48317
- this.outputProvenanceSinks = /* @__PURE__ */ new Map();
48318
- this.outputsResolvedThisRun = /* @__PURE__ */ new WeakSet();
48319
48699
  this.provenanceBaseline = void 0;
48320
- this.resolvedOutputsBag = void 0;
48321
- this.provenanceCaptureTasks = /* @__PURE__ */ new Map();
48700
+ this.provenanceCapture = this.freshProvenanceCapture();
48701
+ this.observedCapture = this.freshObservedCapture();
48322
48702
  this.oldDeletedBeforeCreate = /* @__PURE__ */ new Set();
48323
- this.healBaseline = {};
48703
+ this.rebaseline({});
48324
48704
  this.runProducerRegionEvidence = void 0;
48325
48705
  this.deployChanges = /* @__PURE__ */ new Map();
48326
48706
  this.deployStateResources = {};
48327
48707
  this.inlinePolicyWriters = /* @__PURE__ */ new Map();
48328
- this.attributeHeals = /* @__PURE__ */ new Map();
48329
- this.healedAttributes = /* @__PURE__ */ new Map();
48330
48708
  this.resolver.resetPhysicalIdFallbackCount();
48331
48709
  const ledger = ledgerForStack(this.stateBackend, stackName, this.stackRegion);
48332
48710
  return withStackName(stackName, () => this.options.dryRun ? this.doDeploy(stackName, template) : withCreateTokenLedger(ledger, () => this.doDeploy(stackName, template)));
@@ -48337,16 +48715,16 @@ var DeployEngine = class {
48337
48715
  for (const [logicalId, record] of Object.entries(state.resources)) {
48338
48716
  const secrets = this.perResourceSecrets.get(logicalId);
48339
48717
  const templateProps = this.perResourceTemplateProps.get(logicalId);
48340
- const scrubbed = scrubResourceRecord(this.withHealedAttributes(logicalId, record), secrets ?? /* @__PURE__ */ new Map(), templateProps);
48341
- const noEchoScrubbed = this.applyNoEchoPersist(logicalId, record, this.withNoEchoExactEchoes(logicalId, scrubbed), templateProps, state.resources, secrets);
48342
- resources[logicalId] = withReferenceProvenance(withConstructPath(withMaskedPropertyFingerprints(noEchoScrubbed, record.properties, templateProps, secrets, this.fingerprintNoEchoValues, this.perResourceInputFingerprints.get(logicalId)), constructPathOf(this.constructPathTemplate, logicalId)), this.referenceProvenanceToPersist(logicalId, record, noEchoScrubbed, secrets));
48718
+ const scrubbed = scrubResourceRecord(this.attributeHealer.withHealedAttributes(logicalId, record), secrets ?? /* @__PURE__ */ new Map(), templateProps);
48719
+ const noEchoScrubbed = applyNoEchoPersist(this.noEchoRun, this.noEchoDeps(), logicalId, record, withNoEchoExactEchoes(this.noEchoRun, logicalId, scrubbed), templateProps, state.resources, secrets);
48720
+ resources[logicalId] = withReferenceProvenance(withConstructPath(withMaskedPropertyFingerprints(noEchoScrubbed, record.properties, templateProps, secrets, this.fingerprintNoEchoValues, this.perResourceInputFingerprints.get(logicalId)), constructPathOf(this.noEchoRun.constructPathTemplate, logicalId)), this.referenceProvenanceToPersist(logicalId, record, noEchoScrubbed, secrets));
48343
48721
  }
48344
48722
  const orphans = state.orphans?.map((entry) => {
48345
48723
  const sameResource = this.perResourceResolvedType.get(entry.logicalId) === entry.state.resourceType;
48346
48724
  const orphanTemplateProps = sameResource ? this.perResourceTemplateProps.get(entry.logicalId) : void 0;
48347
48725
  return {
48348
48726
  ...entry,
48349
- state: withMaskedPropertyFingerprints(this.applyNoEchoPersist(entry.logicalId, entry.state, scrubResourceRecord(entry.state, (sameResource ? this.perResourceSecrets.get(entry.logicalId) : void 0) ?? /* @__PURE__ */ new Map(), orphanTemplateProps), orphanTemplateProps, state.resources), entry.state.properties, orphanTemplateProps, sameResource ? this.perResourceSecrets.get(entry.logicalId) : void 0, sameResource ? this.fingerprintNoEchoValues : void 0, sameResource ? this.perResourceInputFingerprints.get(entry.logicalId) : void 0)
48727
+ state: withMaskedPropertyFingerprints(applyNoEchoPersist(this.noEchoRun, this.noEchoDeps(), entry.logicalId, entry.state, scrubResourceRecord(entry.state, (sameResource ? this.perResourceSecrets.get(entry.logicalId) : void 0) ?? /* @__PURE__ */ new Map(), orphanTemplateProps), orphanTemplateProps, state.resources), entry.state.properties, orphanTemplateProps, sameResource ? this.perResourceSecrets.get(entry.logicalId) : void 0, sameResource ? this.fingerprintNoEchoValues : void 0, sameResource ? this.perResourceInputFingerprints.get(entry.logicalId) : void 0)
48350
48728
  };
48351
48729
  });
48352
48730
  const outputs = this.redactOutputs(state.outputs);
@@ -48363,9 +48741,9 @@ var DeployEngine = class {
48363
48741
  };
48364
48742
  }
48365
48743
  outputReferenceProvenanceFor(outputs, redacted) {
48366
- const sinkOf = (outputKey) => this.outputProvenanceSinks.get(outputKey);
48744
+ const sinkOf = (outputKey) => this.outputsRun.outputProvenanceSinks.get(outputKey);
48367
48745
  const baseline = this.provenanceBaseline;
48368
- if (!this.outputsResolvedThisRun.has(outputs) && baseline !== void 0 && outputs === baseline.outputs && baseline.outputReferenceProvenance === void 0 && !baseline.tokenFree && this.resolvedOutputsBag !== void 0 && outputMapsEqual(this.redactOutputs(this.resolvedOutputsBag), redacted)) return outputProvenanceForPersist({
48746
+ if (!this.outputsRun.outputsResolvedThisRun.has(outputs) && baseline !== void 0 && outputs === baseline.outputs && baseline.outputReferenceProvenance === void 0 && !baseline.tokenFree && this.outputsRun.resolvedOutputsBag !== void 0 && outputMapsEqual(this.redactOutputs(this.outputsRun.resolvedOutputsBag), redacted)) return outputProvenanceForPersist({
48369
48747
  outputs: redacted,
48370
48748
  resolvedThisRun: true,
48371
48749
  carriedFrom: void 0,
@@ -48373,7 +48751,7 @@ var DeployEngine = class {
48373
48751
  });
48374
48752
  return outputProvenanceForPersist({
48375
48753
  outputs: redacted,
48376
- resolvedThisRun: this.outputsResolvedThisRun.has(outputs),
48754
+ resolvedThisRun: this.outputsRun.outputsResolvedThisRun.has(outputs),
48377
48755
  carriedFrom: baseline !== void 0 && outputs === baseline.outputs ? baseline : void 0,
48378
48756
  sinkOf
48379
48757
  });
@@ -48491,17 +48869,6 @@ var DeployEngine = class {
48491
48869
  return maskingRetryLogger(this.logger, secrets);
48492
48870
  }
48493
48871
  };
48494
- DeployEngine.prototype.hasPending = hasPending;
48495
- DeployEngine.prototype.buildDeletionDependencies = buildDeletionDependencies;
48496
- DeployEngine.prototype.addImplicitDeleteDependencies = addImplicitDeleteDependencies;
48497
- DeployEngine.prototype.auditResolvedAssetReferences = auditResolvedAssetReferences;
48498
- DeployEngine.prototype.extractAllDependencies = extractAllDependencies;
48499
- DeployEngine.prototype.propertiesToRecord = propertiesToRecord;
48500
- DeployEngine.prototype.extractTemplateAttributes = extractTemplateAttributes;
48501
- DeployEngine.prototype.isPinnedToCcApi = isPinnedToCcApi;
48502
- DeployEngine.prototype.recreateDirectionFor = recreateDirectionFor;
48503
- DeployEngine.prototype.peekRoutingForLabel = peekRoutingForLabel;
48504
- DeployEngine.prototype.preparePropertiesForCcApi = preparePropertiesForCcApi;
48505
48872
  DeployEngine.prototype.buildResolverContext = buildResolverContext;
48506
48873
  DeployEngine.prototype.maskedInputSources = maskedInputSources;
48507
48874
  DeployEngine.prototype.doDeployWithPrefetch = doDeployWithPrefetch;
@@ -48514,11 +48881,6 @@ DeployEngine.prototype.provisionUpdate = provisionUpdate;
48514
48881
  DeployEngine.prototype.updateByReplacement = updateByReplacement;
48515
48882
  DeployEngine.prototype.updateInPlace = updateInPlace;
48516
48883
  DeployEngine.prototype.provisionCreate = provisionCreate;
48517
- DeployEngine.prototype.healStaleAttributes = healStaleAttributes;
48518
- DeployEngine.prototype.isHealEligible = isHealEligible;
48519
- DeployEngine.prototype.readStaleAttributes = readStaleAttributes;
48520
- DeployEngine.prototype.withHealedAttributes = withHealedAttributes;
48521
- DeployEngine.prototype.hasUnpersistedHeals = hasUnpersistedHeals;
48522
48884
  DeployEngine.prototype.replacementDeleteContext = replacementDeleteContext;
48523
48885
  DeployEngine.prototype.prepareFinalSnapshotForDelete = prepareFinalSnapshotForDelete;
48524
48886
  DeployEngine.prototype.replaceDeleteFirstAndRecreate = replaceDeleteFirstAndRecreate;
@@ -48543,15 +48905,9 @@ DeployEngine.prototype.secretNameBagFor = secretNameBagFor;
48543
48905
  DeployEngine.prototype.noteSecretNamedRecord = noteSecretNamedRecord;
48544
48906
  DeployEngine.prototype.printingSecretsFor = printingSecretsFor;
48545
48907
  DeployEngine.prototype.namingSecretsFor = namingSecretsFor;
48908
+ DeployEngine.prototype.stateNamingSecrets = stateNamingSecrets;
48909
+ DeployEngine.prototype.captureStoredNoEchoNamingValues = captureStoredNoEchoNamingValues;
48546
48910
  DeployEngine.prototype.noteSecretNamedReads = noteSecretNamedReads;
48547
- DeployEngine.prototype.kickOffObservedCapture = kickOffObservedCapture;
48548
- DeployEngine.prototype.drainObservedCaptures = drainObservedCaptures;
48549
- DeployEngine.prototype.kickOffProvenanceCapture = kickOffProvenanceCapture;
48550
- DeployEngine.prototype.drainProvenanceCaptures = drainProvenanceCaptures;
48551
- DeployEngine.prototype.buildObservedCaptureSiblings = buildObservedCaptureSiblings;
48552
- DeployEngine.prototype.stampReasonlessParameterRefusals = stampReasonlessParameterRefusals;
48553
- DeployEngine.prototype.kickOffAutoRefreshObservedProperties = kickOffAutoRefreshObservedProperties;
48554
- DeployEngine.prototype.kickOffMaskedBaselineRecapture = kickOffMaskedBaselineRecapture;
48555
48911
  DeployEngine.prototype.adoptRollbackOrphans = adoptRollbackOrphans;
48556
48912
  DeployEngine.prototype.performRollback = performRollback;
48557
48913
  DeployEngine.prototype.settleJournalAfterSuccess = settleJournalAfterSuccess;
@@ -48563,23 +48919,7 @@ DeployEngine.prototype.rollbackExecutorContext = rollbackExecutorContext;
48563
48919
  DeployEngine.prototype.producerRegionEvidence = producerRegionEvidence;
48564
48920
  DeployEngine.prototype.writeRollbackJournalSegment = writeRollbackJournalSegment;
48565
48921
  DeployEngine.prototype.redactOperationsForJournal = redactOperationsForJournal;
48566
- DeployEngine.prototype.noEchoPositionSources = noEchoPositionSources;
48567
- DeployEngine.prototype.noEchoLeavesFor = noEchoLeavesFor;
48568
- DeployEngine.prototype.applyNoEchoPersist = applyNoEchoPersist;
48569
- DeployEngine.prototype.maskOutputsByPosition = maskOutputsByPosition;
48570
- DeployEngine.prototype.warnNoEchoPhysicalId = warnNoEchoPhysicalId;
48571
- DeployEngine.prototype.seedPersistedNoEchoAttributes = seedPersistedNoEchoAttributes;
48572
- DeployEngine.prototype.noEchoAttributeOverridesFor = noEchoAttributeOverridesFor;
48573
- DeployEngine.prototype.noEchoDiffComparison = noEchoDiffComparison;
48574
- DeployEngine.prototype.noteNoEchoExactEchoes = noteNoEchoExactEchoes;
48575
- DeployEngine.prototype.establishNoEchoEchoFidelity = establishNoEchoEchoFidelity;
48576
- DeployEngine.prototype.withNoEchoExactEchoes = withNoEchoExactEchoes;
48577
- DeployEngine.prototype.handleOutputResolutionFailure = handleOutputResolutionFailure;
48578
- DeployEngine.prototype.resolveOutputs = resolveOutputs;
48579
- DeployEngine.prototype.buildDisplayOutputs = buildDisplayOutputs;
48580
- DeployEngine.prototype.replacementNameOrigin = replacementNameOrigin;
48581
- DeployEngine.prototype.orphanedNameCollisionAdvice = orphanedNameCollisionAdvice;
48582
-
48583
- //#endregion
48584
- export { S3_AUTO_DELETE_OBJECTS_TAG as $, unpreviewableOrphanRecords as $a, stripControlChars as $c, hasReadableOutputs as $i, unsupportedFinalSnapshotError as $n, carryLogOnlyValues as $o, poisonRenderedSpellingsCollidingIn as $r, crossPrefixDeniedWarning as $s, isJournaledOrphan as $t, diffSecurity as A, refuseMalformedOutputs as Aa, readBootstrapMarkerBody as Ac, isImpossibleEmptyStoredAttribute as Ai, StageLoadError as Al, collectPublishedOutputNames as An, prefetchCreateOnlyPropertyPaths as Ao, CUSTOM_RESOURCE_RESPONSE_LIFECYCLE_RULE_ID as Ar, recordPhysicalNameCopy as As, NESTED_PENDING_PARENT_REASON as At, readProtection as B, refuseMalformedResourcePropertiesForDrift as Ba, finchSecretArgvRefusal as Bc, withSharedDrainBudget as Bi, renderAssemblyPathEscape as Bl, secretNamePrintingBags as Bn, isMarkedCoordinate as Bo, deleteSkipReason as Br, STATE_SOURCED_BASELINE_RULES as Bs, collectNestedChildUnaddressed as Bt, withApiLimit as C, refuseDivergentRecordRegionForDestroy as Ca, AssetModeResolver as Cc, classifyReplaySecretRegion as Ci, CUSTOM_RESOURCE_RESPONSE_OBJECT_DESCRIPTION as Cl, secretSafeKeyDisplay as Cn, configIntegerRefusal as Co, isCustomResource as Cr, pathCrossesDottedKey as Cs, dropFailedCommands as Ct, findServiceTokenRefusals as D, refuseMalformedOrphans as Da, getBootstrapMarkerKey as Dc, isUnboundTemplateParameter as Di, canonicalizeRegion as Dl, isWholeDynamicReferenceValue as Dn, requireConfigArray as Do, isCustomResourceType as Dr, recoverMaskedOutput as Ds, loadJournaledOrphans as Dt, deferredServiceTokenWarning as E, refuseMalformedOrphanRecordsForDestroy as Ea, ensureAssetStorage as Ec, coerceParameterTypedValue as Ei, PARTITION_TABLE as El, exportNameSecretExposure as En, replayWarn as Eo, readsNoEchoDeleteValues as Er, recordNestedStackParameterExpressions as Es, journaledOrphanLines as Et, recordedProtectionEvidence as F, refuseMalformedResourceEntriesForDestroy as Fa, resolveDockerContextDirectory as Fc, AWS_NO_VALUE as Fi, nullPrototypeRecord as Fl, completedReplayEntries as Fn, lambdaFunctionNameForMask as Fo, unchangedBehindSecretReference as Fr, recordMaskOnlyValuesIn as Fs, nestedChildStackName as Ft, deleteBudgetKey as G, refuseMalformedResourcesForExport as Ga, partitionSensitiveEnv as Gc, STATE_REGION_DIVERGED as Gi, resolveBucketRegion as Gl, ATOMIC_FINAL_SNAPSHOT_TYPES as Gn, noEchoCoordinatesOf as Go, ec2InstanceProtectionSite as Gr, isSingleDynamicReferenceToken as Gs, awaitInFlightSibling as Gt, DYNAMODB_DELETE_MIN_RESOURCE_TIMEOUT_MS as H, refuseMalformedResourcePropertiesForOrphan as Ha, getDockerCmd as Hc, passedParameterClassesOf as Hi, injectAwsRegion as Hl, stateSecretNameNeedles as Hn, maskReadbackAtCoordinates as Ho, isWaitAbandonedError as Hr, STATE_SOURCED_READBACK_RULES as Hs, withNestedStackContext as Ht, recordedProtectionNote as I, refuseMalformedResourceEntriesForImport as Ia, describeDockerCapturedOutput as Ic, cfnRefValueFromPhysicalId as Ii, ownValue as Il, journaledOrphanPrintingBag as In, sameLambdaFunctionAddress as Io, RollbackInlinePolicyWriters as Ir, recordNoEchoAttributeValues as Is, recordDisplacedSkips as It, DELETE_INDEX_WAIT_PROCEED_NOTE as J, repairMalformedOrphansForReadOnly as Ja, redactedDockerCause as Jc, UNREADABLE_RESOURCES_MAP_ROW as Ji, ccRoutedFinalSnapshotError as Jn, passedNoEchoParametersOf as Jo, reDisableInstanceApiTermination as Jr, S3StateBackend as Js, withStackRecords as Jt, resolveDynamoDbDeleteBudgetClock as K, refuseMalformedState as Ka, redactDockerArgvValues as Kc, STATE_RESOURCES_MALFORMED as Ki, PRE_DELETE_SNAPSHOT_TYPES as Kn, noEchoLeavesOf as Ko, isTerminationProtectionPropagationError as Kr, LockManager as Ks, destroyStackRecordsView as Kt, PROTECTION_PROPERTY_BY_TYPE as L, refuseMalformedResourceEntriesForImportSave as La, describeDockerExecFailure as Lc, isStalePlaceholderArnAttribute as Li, absoluteAssemblyPathEscape as Ll, maskEventTextWithBoundBags as Ln, DagBuilder as Lo, UNSPECIFIED_SKIP_REASON as Lr, recordNoEchoParameterFreshValue as Ls, revertNestedChildFromJournal as Lt, noEchoComparisonForTemplate as M, refuseMalformedResourceAttributesForOrphan as Ma, validateContainerRepoName as Mc, carriesFetchableDynamicReference as Mi, defineOwnKey as Ml, bindingSkippedOutputs as Mn, describeTypeWithThrottleRetry as Mo, customResourceResponseExpirationWarning as Mr, carriesSecretMask as Ms, displacedPhysicalIdShown as Mt, noEchoExactEchoLeavesOf as N, refuseMalformedResourceEntries as Na, buildDenyExternalAccessPolicy as Nc, isNamelessDynamicReferenceError as Ni, hasOwnKey as Nl, DEFAULT_RESOURCE_TIMEOUT_MS as Nn, withRetry as No, CloudControlProvider as Nr, provenPublicValue as Ns, dropSettledNestedJournals as Nt, serviceTokenBlockingReason as O, refuseMalformedOrphansForDestroy as Oa, isCrossRegionRedirect as Oc, parameterTypeMayLoseSecretIdentity as Oi, derivePartitionAndUrlSuffix as Ol, noEchoParameterValueSeed as On, requireConfigObject as Oo, getCurrentResourceSecrets as Or, physicalNameCopiesOf as Os, makeForeignHolderScan as Ot, noEchoParameterNamesOf as P, refuseMalformedResourceEntriesForDeploy as Pa, buildDockerImage as Pc, keepsSecretReferenceToken as Pi, hasPlainPrototype$1 as Pl, DEFAULT_RESOURCE_WARN_AFTER_MS as Pn, canonicalLambdaFunctionName as Po, slowCcOperationTimeoutMs as Pr, recordMaskOnlyValue as Ps, getNestedRevertRun as Pt, ECR_AUTO_DELETE_IMAGES_TAG as Q, repairMalformedResourcesForReadOnly as Qa, escapeRegExp$3 as Qc, hasReadableOrphans as Qi, refusesFinalSnapshot as Qn, liveMatchesUnresolvedTokenFrame as Qo, IntrinsicFunctionResolver as Qr, applyCrossPrefixScan as Qs, demoteSupersededOrphans as Qt, isProtectionValueActive as R, refuseMalformedResourceEntriesForOrphan as Ra, describeDockerFailure as Rc, refStateLookupFromResource as Ri, describeFileReadFailure as Rl, orphanRecordsPrintingBag as Rn, TemplateParser as Ro, deleteIndeterminateGuards as Rr, recordProvenPublicExpression as Rs, revertedNestedRowIds as Rt, lookupEachName as S, previewableOrphanRecords as Sa, rewriteTemplateAssetReferences as Sc, classifyRecordedSecretRegion as Si, uploadCfnTemplate as Sl, secretBearingStateKeyWarning as Sn, configBooleanRefusal as So, ccBrokenReason as Sr, isUncertifiedBaselineMaskPosition as Ss, deleteJournaledOrphans as St, recordRetainedForReadoption as T, refuseMalformedOrphanRecords as Ta, assertAssetBucketRegion as Tc, regionLessSecretName as Ti, expectedOwnerParam as Tl, exportNameNoEchoParameters as Tn, readConfigString as To, TemplateNoEchoReresolver as Tr, inheritNestedStackParameterAssociations as Ts, isHandledOrphan as Tt, beginDeleteWait as U, refuseMalformedResourcesForDeploy as Ua, isDockerClientEnvKey as Uc, declaresNoEcho as Ui, injectedAwsRegionValue as Ul, storedSecretNameNeedles as Un, maskWholeValue as Uo, markWaitAbandoned as Ur, TEMPLATE_SOURCED_RULES as Us, replayFailedOperations as Ut, DynamoDBGlobalTableProvider as V, refuseMalformedResourcePropertiesForExport as Va, formatDockerLoginError as Vc, parameterInputsFor as Vi, resolveAssemblyPath as Vl, secretNamedRecordNeedles as Vn, maskAtCoordinates as Vo, withIndeterminateGuard as Vr, STATE_SOURCED_CROSS_GENERATION_RULES as Vs, getCurrentNestedStackContext as Vt, compensateRemovedDeletionProtection as W, refuseMalformedResourcesForDestroy as Wa, isMalformedEnvKey as Wc, JSON_LISTING_HOLE_VALUE as Wi, clearBucketRegionCache as Wl, extractDeploymentEventError as Wn, maskedLeafCoordinatesOf as Wo, disableInstanceApiTermination as Wr, WHOLE_DYNAMIC_REFERENCE_PATTERN as Ws, replayRollback as Wt, deleteTableWithIndexBusyRetry as X, repairMalformedResourceEntriesForReadOnly as Xa, runDockerStreaming as Xc, deployRefusesOrphanRowsReason as Xi, effectiveDeletionPolicy as Xn, readsNoEchoSource as Xo, DiffCalculator as Xr, CrossPrefixReadError as Xs, replacedDeleteFailureVerdict as Xt, INDEX_SETTLE_POLL_INTERVAL_MS as Y, repairMalformedOutputsForReadOnly as Ya, runDockerForeground as Yc, accountArgs as Yi, createPreDeleteFinalSnapshot as Yn, readbackPathFor as Yo, reEnableInstanceApiTermination as Yr, rebuildClientForBucketRegion as Ys, removeProtectionTypeList as Yt, waitForIndexesSettled as Z, repairMalformedResourcePropertiesForReadOnly as Za, warnFinchArgvExposure as Zc, displayLogicalId as Zi, isFinalSnapshotError as Zn, valueAtCoordinate as Zo, INTRINSIC_KEYS as Zr, CrossPrefixScanCache as Zs, recordAfterRollbackUpdate as Zt, keptWholeReasonText as _, malformedResourceEntriesWarning as _a, stringifyValue as _c, s3BucketArn as _i, ssmResolvedValueType as _l, orphanNeedsIdentity as _n, isWarmThroughputDecrease as _o, tagPlanWarning as _r, scrubResourceRecord as _s, planOrphanAdoption as _t, inheritedProvenanceForChildDiff as a, malformedExportSourceWarning as aa, exportNamesCarriedFrom as ac, explicitRoleArnOrThrow as ai, getDefaultStateBucketName as al, replacementNeverSwapped as an, unwrittenCreateOnlyReplacement as ao, ledgerForStack as ar, recordLogOnlyParameterValue as as, createReadOnlyAttributeHealerFactory as at, chunks as b, malformedScrubResourceEntriesRefusalMessage as ba, createAssetRedirectResolver as bc, s3BucketRegionalDomainName as bi, MIGRATE_TMP_PREFIX as bl, exportAliasCollisionScrubWarning as bn, coerceCfnBoolean as bo, CC_BROKEN_REASON as br, DYNAMIC_REFERENCE_TOKEN_SCAN as bs, pendingRequestCount as bt, isAbsoluteAssetPath as c, malformedLocalResourcesWarning as ca, hasUnverifiableParameterRefusal as cc, AWS_CREDENTIAL_ENV_KEYS as ci, resolveApp as cl, findNestedStackTypeChanges as cn, hasNoCloudControlHandlers as co, acquireIdempotencyToken as cr, unionOfSecretBags as cs, gray as ct, templateIdentity as d, malformedOrphanRowsKeptWarning as da, isReadableBag as dc, envCredentialsAreAssumedRole as di, resolveSkipPrefix as dl, REDACTED_DELETE_ADDRESS_SKIP_REASON as dn, MULTI_REGION_RECREATE_BLOCKED_TYPES as do, DBPROXY_TAGS_WHAT as dr, maskSecretsInError as ds, yellow as dt, hasReadableResources as ea, isAccessDenied$1 as ec, producerLookupOver as ei, stripForDisplay as el, isReplacementOrphan as en, unreadableOrphanRecords as eo, maskingRetryLogger as er, createUnionSecretMasker as es, hasCdkAutoDeleteTag as et, conditionFingerprint as f, malformedOrphansRefusalMessage as fa, orphansAfterRollback as fc, isSettledInstanceState as fi, resolveStateBucketWithDefault as fl, isRedactedRecordedValue as fn, isStatefulRecreateTargetForReplace as fo, DBPROXY_TAG_OPTIONS as fr, maskSecretsInText as fs, computeParameterTaint as ft, isSecretBearingReferenceString as g, malformedRenderedContainersWarning as ga, isSensitiveAttributeName as gc, recordedReferenceRegions as gi, warnDeprecatedNoPrefixCliFlag as gl, updatePartialReason as gn, coerceWarmThroughput as go, tagMapAsList as gr, redactSecretsForState as gs, makeSiblingClaimReader as gt, readRecordedConditionVerdicts as h, malformedOutputsWarning as ha, AssetPublisher as hc, recordedOutputReferenceRegions as hi, stateBucketExistenceConfirmed as hl, updatePartialMessage as hn, WARM_THROUGHPUT_MEMBERS as ho, refuseMalformedDesiredTags as hr, snapshotPassProvenance as hs, resourcesNamingDeclaredParameter as ht, crossStackOutputProvenanceSource as i, malformedExportNamesWarning as ia, describeRegionValueKind as ic, assertSendableRoleArn as ii, synthesisStatusMessage as il, recordUnderIdIsNotOwn as in, findSilentDropProperties as io, earliestDefined as ir, printingCorpusOf as is, formatResourceLine as it, noEchoAttributeNamesOf as j, refuseMalformedOutputsForDestroy as ja, validateAssetBucketName as jc, carriesDynamicReference as ji, processStackMessages as jl, isExportAliasCollision as jn, templateResourceTypes as jo, applyCustomResourceResponseExpiration as jr, splitGetAttStringForm as js, displacedOpClause as jt, withResourceDeadline as k, refuseMalformedOrphansForOrphan as ka, parseBootstrapMarker as kc, getAccountInfo as ki, AssemblyReader as kl, collectDeclaredOutputNames as kn, requireConfigString as ko, withPrintingSecrets as kr, recordAttributeIdCopy as ks, sameJournaledOrphans as kt, listNestedTemplateRows as l, malformedOrphanRecordsRefusalMessage as la, importableOutputKeys as lc, applyCallerIdentityCredentials as li, resolveAutoAssetStorage as ll, getCurrentProducerRegions as ln, findReplacedReadersOfRecreateTargets as lo, isRefusedByName as lr, createSecretMasker as ls, green as lt, parentSuppliedValues as m, malformedOutputsRefusalMessage as ma, shouldRetainResource as mc, outputReferenceProvenanceOf as mi, resolveUseCdkBootstrapAssets as ml, redactedDeleteAddressSkip as mn, renderStatefulReason as mo, readTagList as mr, recordReferenceProvenanceEntry as ms, reachableDivergentParameters as mt, IMPLICIT_DELETE_DEPENDENCIES as n, isReadableResourceEntry as na, splitImportedOps as nc, applyRoleArnIfSet as ni, getDockerImageBySourceHash as nl, planRollback as nn, withheldAccountClause as no, findDestructiveChanges as nr, literalSplitDelimitersOf as ns, getPriorAttempts as nt, childTemplateLoader as o, malformedLocalOutputsWarning as oa, hasReadableExportSet as oc, isIamRoleArn as oi, getLegacyStateBucketName as ol, resolveReplacementOldType as on, withoutSilentDropProperties as oo, reserveStackCreateToken as or, recordLogOnlyValue as os, bold as ot, conditionInputsFrom as p, malformedOrphansWarning as pa, orphansCarriedFrom as pc, keepHeldTokenProvenance as pi, resolveStateBucketWithDefaultAndSource as pl, redactedDeleteAddressFields as pn, isStatefulRecreateTargetSync as po, planTagDiff as pr, markSameGenerationBag as ps, namesAnyDeclaredParameter as pt, resolveDynamoDbDeleteBudgetMs as q, repairMalformedOrphanRecordsForReadOnly as qa, redactedCause as qc, UNREADABLE_ORPHANS_CONTAINER_ROW as qi, buildFinalSnapshotIdentifier as qn, noEchoOutputsComparison as qo, observeThenDisableInstanceApiTermination as qr, isLockInfoExpired as qs, getStackRecords as qt, computeImplicitDeleteEdges as r, malformedDriftResourcePropertiesWarning as ra, acceptedCreateOnlyDropsOf as rc, assertFlagRoleArn as ri, Synthesizer as rl, recheckFailedPlan as rn, findActionableSilentDrops as ro, formatDestructiveChange as rr, logOnlyValueCount as rs, markRefusedBeforeApplying as rt, findNestedTemplateTreeDefect as s, malformedLocalResourceEntriesWarning as sa, hasReasonlessBaselineRefusal as sc, sendableAssumeRoleCommand as si, loadCdkJson as sl, seedsDeleteFirstGuard as sn, NO_CC_HANDLERS_REASON as so, withCreateTokenLedger as sr, shareLogOnlyValues as ss, cyan as st, DeployEngine as t, isReadableOrphanRecord as ta, isNotImplemented as tc, refuseUnreadableCdkCrossAccountRefs as ti, AssetManifestLoader as tl, planFailedOps as tn, unreadableResourceEntries as to, constructPathOf as tr, hasMaskableValues as ts, isTruthyCfnBoolean as tt, renderNestedTemplateTreeDefect as u, malformedOrphanRecordsWarning as ua, importableOutputs as uc, callerEnvCredentials as ui, resolveCaptureObservedState as ul, inheritProducerRegions as un, shownType as uo, markDeleteStarted as ur, errorCauseChain as us, red as ut, mergeNoChangeOutputs as v, malformedResourcePropertiesWarning as va, WorkGraph as vc, s3BucketDomainName as vi, CFN_TEMPLATE_BODY_LIMIT as vl, WITHHELD_NAME_DISPLAY as vn, toCfnInteger as vo, definedAttributes as vr, withPhysicalNameCopies as vs, DeploymentEventsReader as vt, keptForReadoption as w, refuseMalformedNestedChildOutputs as wa, BOOTSTRAP_MARKER_PREFIX as wc, producerRegionsFromState as wi, decodeListingKey as wl, carriedExportAliasExposure as wn, configStringRefusal as wo, wouldReturnToSdkProvider as wr, identityKeyFor as ws, dropFailedHint as wt, isAccessDeniedError as x, malformedStateRefusalMessage as xa, loadPublishableAssetManifest as xc, s3BucketWebsiteUrl as xi, findLargeInlineResources as xl, secretBearing as xn, coerceCfnInteger as xo, ProviderRegistry as xr, dynamicReferenceTokens as xs, resolvePendingCloudControlRequests as xt, makeCanonicalizePropertiesFn as y, malformedResourcesWarning as ya, buildAssetRedirectMap as yc, s3BucketDualStackDomainName as yi, CFN_TEMPLATE_URL_LIMIT as yl, displayTextOrWithheld as yn, toFiniteNumber as yo, stringifyIfAssigned as yr, withoutPhysicalNameCopies as ys, DeploymentEventsStore as yt, perType as z, refuseMalformedResourcePropertiesForDestroy as za, dockerSpawnEnvWithSensitive as zc, parseWebACLArn as zi, displayAssemblyPath as zl, secretNamePrintingBag as zn, canonicalCoordinates as zo, deleteLeftInPlace as zr, wholeStringLeavesOf as zs, withNestedRevertRun as zt };
48585
- //# sourceMappingURL=deploy-engine--5XWdjW3.js.map
48922
+
48923
+ //#endregion
48924
+ export { markRefusedBeforeApplying as $, repairMalformedResourceEntriesForReadOnly as $a, runDockerForeground as $c, deployRefusesOrphanRowsReason as $i, isFinalSnapshotError as $n, readsNoEchoSource as $o, DiffCalculator as $r, rebuildClientForBucketRegion as $s, isJournaledOrphan as $t, diffSecurity as A, refuseMalformedOrphans as Aa, ensureAssetStorage as Ac, isUnboundTemplateParameter as Ai, PARTITION_TABLE as Al, collectPublishedOutputNames as An, requireConfigArray as Ao, isCustomResourceType as Ar, recordNestedStackParameterExpressions as As, NESTED_PENDING_PARENT_REASON as At, compensateRemovedDeletionProtection as B, refuseMalformedResourceEntriesForImportSave as Ba, describeDockerCapturedOutput as Bc, isStalePlaceholderArnAttribute as Bi, ownValue as Bl, secretNamePrintingBag as Bn, DagBuilder as Bo, UNSPECIFIED_SKIP_REASON as Br, recordNoEchoAttributeValues as Bs, collectNestedChildUnaddressed as Bt, computeImplicitDeleteEdges as C, malformedScrubResourceEntriesRefusalMessage as Ca, buildAssetRedirectMap as Cc, s3BucketRegionalDomainName as Ci, CFN_TEMPLATE_URL_LIMIT as Cl, secretSafeKeyDisplay as Cn, coerceCfnBoolean as Co, ProviderRegistry as Cr, withoutPhysicalNameCopies as Cs, dropFailedCommands as Ct, findServiceTokenRefusals as D, refuseMalformedNestedChildOutputs as Da, AssetModeResolver as Dc, producerRegionsFromState as Di, CUSTOM_RESOURCE_RESPONSE_OBJECT_DESCRIPTION as Dl, isWholeDynamicReferenceValue as Dn, configStringRefusal as Do, waitForLambdaFunctionActive as Dr, pathCrossesDottedKey as Ds, loadJournaledOrphans as Dt, deferredServiceTokenWarning as E, refuseDivergentRecordRegionForDestroy as Ea, rewriteTemplateAssetReferences as Ec, classifyReplaySecretRegion as Ei, uploadCfnTemplate as El, exportNameSecretExposure as En, configIntegerRefusal as Eo, wouldReturnToSdkProvider as Er, isUncertifiedBaselineMaskPosition as Es, journaledOrphanLines as Et, perType as F, refuseMalformedResourceAttributesForOrphan as Fa, validateAssetBucketName as Fc, carriesFetchableDynamicReference as Fi, processStackMessages as Fl, completedReplayEntries as Fn, describeTypeWithThrottleRetry as Fo, customResourceResponseExpirationWarning as Fr, splitGetAttStringForm as Fs, nestedChildStackName as Ft, INDEX_SETTLE_POLL_INTERVAL_MS as G, refuseMalformedResourcePropertiesForOrphan as Ga, formatDockerLoginError as Gc, passedParameterClassesOf as Gi, resolveAssemblyPath as Gl, storedSecretNameNeedles as Gn, maskReadbackAtCoordinates as Go, isWaitAbandonedError as Gr, STATE_SOURCED_CROSS_GENERATION_RULES as Gs, awaitInFlightSibling as Gt, resolveDynamoDbDeleteBudgetClock as H, refuseMalformedResourcePropertiesForDestroy as Ha, describeDockerFailure as Hc, parseWebACLArn as Hi, describeFileReadFailure as Hl, secretNamedAttributeNamesOf as Hn, canonicalCoordinates as Ho, deleteLeftInPlace as Hr, recordProvenPublicExpression as Hs, withNestedStackContext as Ht, readProtection as I, refuseMalformedResourceEntries as Ia, validateContainerRepoName as Ic, isNamelessDynamicReferenceError as Ii, defineOwnKey as Il, journaledOrphanPrintingBag as In, withRetry as Io, CloudControlProvider as Ir, carriesSecretMask as Is, recordDisplacedSkips as It, ECR_AUTO_DELETE_IMAGES_TAG as J, refuseMalformedResourcesForExport as Ja, isMalformedEnvKey as Jc, STATE_REGION_DIVERGED as Ji, clearBucketRegionCache as Jl, PRE_DELETE_SNAPSHOT_TYPES as Jn, noEchoCoordinatesOf as Jo, ec2InstanceProtectionSite as Jr, WHOLE_DYNAMIC_REFERENCE_PATTERN as Js, withStackRecords as Jt, deleteTableWithIndexBusyRetry as K, refuseMalformedResourcesForDeploy as Ka, getDockerCmd as Kc, declaresNoEcho as Ki, injectAwsRegion as Kl, extractDeploymentEventError as Kn, maskWholeValue as Ko, markWaitAbandoned as Kr, STATE_SOURCED_READBACK_RULES as Ks, destroyStackRecordsView as Kt, DynamoDBGlobalTableProvider as L, refuseMalformedResourceEntriesForDeploy as La, buildDenyExternalAccessPolicy as Lc, keepsSecretReferenceToken as Li, hasOwnKey as Ll, maskEventTextWithBoundBags as Ln, canonicalLambdaFunctionName as Lo, slowCcOperationTimeoutMs as Lr, provenPublicValue as Ls, revertNestedChildFromJournal as Lt, recordedProtectionNote as M, refuseMalformedOrphansForOrphan as Ma, isCrossRegionRedirect as Mc, getAccountInfo as Mi, derivePartitionAndUrlSuffix as Ml, bindingSkippedOutputs as Mn, requireConfigString as Mo, withPrintingSecrets as Mr, physicalNameCopiesOf as Ms, displacedPhysicalIdShown as Mt, PROTECTION_PROPERTY_BY_TYPE as N, refuseMalformedOutputs as Na, parseBootstrapMarker as Nc, isImpossibleEmptyStoredAttribute as Ni, AssemblyReader as Nl, DEFAULT_RESOURCE_TIMEOUT_MS as Nn, prefetchCreateOnlyPropertyPaths as No, CUSTOM_RESOURCE_RESPONSE_LIFECYCLE_RULE_ID as Nr, recordAttributeIdCopy as Ns, dropSettledNestedJournals as Nt, serviceTokenBlockingReason as O, refuseMalformedOrphanRecords as Oa, BOOTSTRAP_MARKER_PREFIX as Oc, regionLessSecretName as Oi, decodeListingKey as Ol, noEchoParameterValueSeed as On, readConfigString as Oo, TemplateNoEchoReresolver as Or, identityKeyFor as Os, makeForeignHolderScan as Ot, isProtectionValueActive as P, refuseMalformedOutputsForDestroy as Pa, readBootstrapMarkerBody as Pc, carriesDynamicReference as Pi, StageLoadError as Pl, DEFAULT_RESOURCE_WARN_AFTER_MS as Pn, templateResourceTypes as Po, applyCustomResourceResponseExpiration as Pr, recordPhysicalNameCopy as Ps, getNestedRevertRun as Pt, getPriorAttempts as Q, repairMalformedOutputsForReadOnly as Qa, redactedDockerCause as Qc, accountArgs as Qi, effectiveDeletionPolicy as Qn, readbackPathFor as Qo, reEnableInstanceApiTermination as Qr, S3StateBackend as Qs, demoteSupersededOrphans as Qt, DYNAMODB_DELETE_MIN_RESOURCE_TIMEOUT_MS as R, refuseMalformedResourceEntriesForDestroy as Ra, buildDockerImage as Rc, AWS_NO_VALUE as Ri, hasPlainPrototype$1 as Rl, namingSecretsWithRecordedNoEcho as Rn, lambdaFunctionNameForMask as Ro, unchangedBehindSecretReference as Rr, recordMaskOnlyValue as Rs, revertedNestedRowIds as Rt, IMPLICIT_DELETE_DEPENDENCIES as S, malformedResourcesWarning as Sa, WorkGraph as Sc, s3BucketDualStackDomainName as Si, CFN_TEMPLATE_BODY_LIMIT as Sl, secretBearingStateKeyWarning as Sn, toFiniteNumber as So, CC_BROKEN_REASON as Sr, withPhysicalNameCopies as Ss, deleteJournaledOrphans as St, recordRetainedForReadoption as T, previewableOrphanRecords as Ta, loadPublishableAssetManifest as Tc, classifyRecordedSecretRegion as Ti, findLargeInlineResources as Tl, exportNameNoEchoParameters as Tn, configBooleanRefusal as To, isCustomResource as Tr, dynamicReferenceTokens as Ts, isHandledOrphan as Tt, resolveDynamoDbDeleteBudgetMs as U, refuseMalformedResourcePropertiesForDrift as Ua, dockerSpawnEnvWithSensitive as Uc, withSharedDrainBudget as Ui, displayAssemblyPath as Ul, secretNamedRecordNeedles as Un, isMarkedCoordinate as Uo, deleteSkipReason as Ur, wholeStringLeavesOf as Us, replayFailedOperations as Ut, deleteBudgetKey as V, refuseMalformedResourceEntriesForOrphan as Va, describeDockerExecFailure as Vc, refStateLookupFromResource as Vi, absoluteAssemblyPathEscape as Vl, secretNamePrintingBags as Vn, TemplateParser as Vo, deleteIndeterminateGuards as Vr, recordNoEchoParameterFreshValue as Vs, getCurrentNestedStackContext as Vt, DELETE_INDEX_WAIT_PROCEED_NOTE as W, refuseMalformedResourcePropertiesForExport as Wa, finchSecretArgvRefusal as Wc, parameterInputsFor as Wi, renderAssemblyPathEscape as Wl, stateSecretNameNeedles as Wn, maskAtCoordinates as Wo, withIndeterminateGuard as Wr, STATE_SOURCED_BASELINE_RULES as Ws, replayRollback as Wt, hasCdkAutoDeleteTag as X, repairMalformedOrphanRecordsForReadOnly as Xa, redactDockerArgvValues as Xc, UNREADABLE_ORPHANS_CONTAINER_ROW as Xi, ccRoutedFinalSnapshotError as Xn, noEchoOutputsComparison as Xo, observeThenDisableInstanceApiTermination as Xr, LockManager as Xs, replacedDeleteFailureVerdict as Xt, S3_AUTO_DELETE_OBJECTS_TAG as Y, refuseMalformedState as Ya, partitionSensitiveEnv as Yc, STATE_RESOURCES_MALFORMED as Yi, resolveBucketRegion as Yl, buildFinalSnapshotIdentifier as Yn, noEchoLeavesOf as Yo, isTerminationProtectionPropagationError as Yr, isSingleDynamicReferenceToken as Ys, removeProtectionTypeList as Yt, isTruthyCfnBoolean as Z, repairMalformedOrphansForReadOnly as Za, redactedCause as Zc, UNREADABLE_RESOURCES_MAP_ROW as Zi, createPreDeleteFinalSnapshot as Zn, passedNoEchoParametersOf as Zo, reDisableInstanceApiTermination as Zr, isLockInfoExpired as Zs, recordAfterRollbackUpdate as Zt, makeCanonicalizePropertiesFn as _, malformedOutputsRefusalMessage as _a, orphansCarriedFrom as _c, outputReferenceProvenanceOf as _i, resolveStateBucketWithDefaultAndSource as _l, orphanNeedsIdentity as _n, renderStatefulReason as _o, refuseMalformedDesiredTags as _r, markSameGenerationBag as _s, planOrphanAdoption as _t, findNestedTemplateTreeDefect as a, isReadableResourceEntry as aa, isNotImplemented as ac, applyRoleArnIfSet as ai, AssetManifestLoader as al, replacementNeverSwapped as an, withheldAccountClause as ao, formatDestructiveChange as ar, hasMaskableValues as as, red as at, lookupEachName as b, malformedResourceEntriesWarning as ba, isSensitiveAttributeName as bc, s3BucketArn as bi, warnDeprecatedNoPrefixCliFlag as bl, exportAliasCollisionScrubWarning as bn, isWarmThroughputDecrease as bo, definedAttributes as br, redactSecretsForState as bs, pendingRequestCount as bt, renderNestedTemplateTreeDefect as c, malformedExportSourceWarning as ca, describeRegionValueKind as cc, explicitRoleArnOrThrow as ci, synthesisStatusMessage as cl, findNestedStackTypeChanges as cn, unwrittenCreateOnlyReplacement as co, reserveStackCreateToken as cr, printingCorpusOf as cs, namesAnyDeclaredParameter as ct, conditionInputsFrom as d, malformedLocalResourcesWarning as da, hasReasonlessBaselineRefusal as dc, AWS_CREDENTIAL_ENV_KEYS as di, loadCdkJson as dl, REDACTED_DELETE_ADDRESS_SKIP_REASON as dn, hasNoCloudControlHandlers as do, isRefusedByName as dr, shareLogOnlyValues as ds, noEchoAttributeNamesOf as dt, displayLogicalId as ea, CrossPrefixReadError as ec, INTRINSIC_KEYS as ei, runDockerStreaming as el, isReplacementOrphan as en, repairMalformedResourcePropertiesForReadOnly as eo, refusesFinalSnapshot as er, recordedNoEchoValuesOf as es, formatResourceLine as et, parentSuppliedValues as f, malformedOrphanRecordsRefusalMessage as fa, hasUnverifiableParameterRefusal as fc, applyCallerIdentityCredentials as fi, resolveApp as fl, isRedactedRecordedValue as fn, findReplacedReadersOfRecreateTargets as fo, markDeleteStarted as fr, unionOfSecretBags as fs, noEchoComparisonForTemplate as ft, mergeNoChangeOutputs as g, malformedOrphansWarning as ga, orphansAfterRollback as gc, keepHeldTokenProvenance as gi, resolveStateBucketWithDefault as gl, updatePartialReason as gn, isStatefulRecreateTargetSync as go, readTagList as gr, maskSecretsInText as gs, makeSiblingClaimReader as gt, keptWholeReasonText as h, malformedOrphansRefusalMessage as ha, isReadableBag as hc, isSettledInstanceState as hi, resolveSkipPrefix as hl, updatePartialMessage as hn, isStatefulRecreateTargetForReplace as ho, planTagDiff as hr, maskSecretsInError as hs, createReadOnlyAttributeHealerFactory as ht, childTemplateLoader as i, isReadableOrphanRecord as ia, isAccessDenied$1 as ic, refuseUnreadableCdkCrossAccountRefs as ii, stripForDisplay as il, recordUnderIdIsNotOwn as in, unreadableResourceEntries as io, findDestructiveChanges as ir, createUnionSecretMasker as is, green as it, recordedProtectionEvidence as j, refuseMalformedOrphansForDestroy as ja, getBootstrapMarkerKey as jc, parameterTypeMayLoseSecretIdentity as ji, canonicalizeRegion as jl, isExportAliasCollision as jn, requireConfigObject as jo, getCurrentResourceSecrets as jr, recoverMaskedOutput as js, displacedOpClause as jt, withResourceDeadline as k, refuseMalformedOrphanRecordsForDestroy as ka, assertAssetBucketRegion as kc, coerceParameterTypedValue as ki, expectedOwnerParam as kl, collectDeclaredOutputNames as kn, replayWarn as ko, readsNoEchoDeleteValues as kr, inheritNestedStackParameterAssociations as ks, sameJournaledOrphans as kt, templateIdentity as l, malformedLocalOutputsWarning as la, exportNamesCarriedFrom as lc, isIamRoleArn as li, getDefaultStateBucketName as ll, getCurrentProducerRegions as ln, withoutSilentDropProperties as lo, withCreateTokenLedger as lr, recordLogOnlyParameterValue as ls, reachableDivergentParameters as lt, isSecretBearingReferenceString as m, malformedOrphanRowsKeptWarning as ma, importableOutputs as mc, envCredentialsAreAssumedRole as mi, resolveCaptureObservedState as ml, redactedDeleteAddressSkip as mn, MULTI_REGION_RECREATE_BLOCKED_TYPES as mo, DBPROXY_TAG_OPTIONS as mr, errorCauseChain as ms, noEchoParameterNamesOf as mt, crossStackOutputProvenanceSource as n, hasReadableOutputs as na, applyCrossPrefixScan as nc, poisonRenderedSpellingsCollidingIn as ni, escapeRegExp$3 as nl, planRollback as nn, unpreviewableOrphanRecords as no, maskingRetryLogger as nr, liveMatchesUnresolvedTokenFrame as ns, cyan as nt, isAbsoluteAssetPath as o, malformedDriftResourcePropertiesWarning as oa, splitImportedOps as oc, assertFlagRoleArn as oi, getDockerImageBySourceHash as ol, resolveReplacementOldType as on, findActionableSilentDrops as oo, earliestDefined as or, literalSplitDelimitersOf as os, yellow as ot, readRecordedConditionVerdicts as p, malformedOrphanRecordsWarning as pa, importableOutputKeys as pc, callerEnvCredentials as pi, resolveAutoAssetStorage as pl, redactedDeleteAddressFields as pn, shownType as po, DBPROXY_TAGS_WHAT as pr, createSecretMasker as ps, noEchoExactEchoLeavesOf as pt, waitForIndexesSettled as q, refuseMalformedResourcesForDestroy as qa, isDockerClientEnvKey as qc, JSON_LISTING_HOLE_VALUE as qi, injectedAwsRegionValue as ql, ATOMIC_FINAL_SNAPSHOT_TYPES as qn, maskedLeafCoordinatesOf as qo, disableInstanceApiTermination as qr, TEMPLATE_SOURCED_RULES as qs, getStackRecords as qt, inheritedProvenanceForChildDiff as r, hasReadableResources as ra, crossPrefixDeniedWarning as rc, producerLookupOver as ri, stripControlChars as rl, recheckFailedPlan as rn, unreadableOrphanRecords as ro, constructPathOf as rr, carryLogOnlyValues as rs, gray as rt, listNestedTemplateRows as s, malformedExportNamesWarning as sa, acceptedCreateOnlyDropsOf as sc, assertSendableRoleArn as si, Synthesizer as sl, seedsDeleteFirstGuard as sn, findSilentDropProperties as so, ledgerForStack as sr, logOnlyValueCount as ss, computeParameterTaint as st, DeployEngine as t, hasReadableOrphans as ta, CrossPrefixScanCache as tc, IntrinsicFunctionResolver as ti, warnFinchArgvExposure as tl, planFailedOps as tn, repairMalformedResourcesForReadOnly as to, unsupportedFinalSnapshotError as tr, valueAtCoordinate as ts, bold as tt, conditionFingerprint as u, malformedLocalResourceEntriesWarning as ua, hasReadableExportSet as uc, sendableAssumeRoleCommand as ui, getLegacyStateBucketName as ul, inheritProducerRegions as un, NO_CC_HANDLERS_REASON as uo, acquireIdempotencyToken as ur, recordLogOnlyValue as us, resourcesNamingDeclaredParameter as ut, chunks as v, malformedOutputsWarning as va, shouldRetainResource as vc, recordedOutputReferenceRegions as vi, resolveUseCdkBootstrapAssets as vl, WITHHELD_NAME_DISPLAY as vn, WARM_THROUGHPUT_MEMBERS as vo, tagMapAsList as vr, recordReferenceProvenanceEntry as vs, DeploymentEventsReader as vt, keptForReadoption as w, malformedStateRefusalMessage as wa, createAssetRedirectResolver as wc, s3BucketWebsiteUrl as wi, MIGRATE_TMP_PREFIX as wl, carriedExportAliasExposure as wn, coerceCfnInteger as wo, ccBrokenReason as wr, DYNAMIC_REFERENCE_TOKEN_SCAN as ws, dropFailedHint as wt, withApiLimit as x, malformedResourcePropertiesWarning as xa, stringifyValue as xc, s3BucketDomainName as xi, ssmResolvedValueType as xl, secretBearing as xn, toCfnInteger as xo, stringifyIfAssigned as xr, scrubResourceRecord as xs, resolvePendingCloudControlRequests as xt, isAccessDeniedError as y, malformedRenderedContainersWarning as ya, AssetPublisher as yc, recordedReferenceRegions as yi, stateBucketExistenceConfirmed as yl, displayTextOrWithheld as yn, coerceWarmThroughput as yo, tagPlanWarning as yr, snapshotPassProvenance as ys, DeploymentEventsStore as yt, beginDeleteWait as z, refuseMalformedResourceEntriesForImport as za, resolveDockerContextDirectory as zc, cfnRefValueFromPhysicalId as zi, nullPrototypeRecord as zl, orphanRecordsPrintingBag as zn, sameLambdaFunctionAddress as zo, RollbackInlinePolicyWriters as zr, recordMaskOnlyValuesIn as zs, withNestedRevertRun as zt };
48925
+ //# sourceMappingURL=deploy-engine-BIPU9Xdh.js.map