@go-to-k/cdkd 0.250.0 → 0.252.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -10873,7 +10873,7 @@ var CloudControlProvider = class {
10873
10873
  this.logger.debug(`Deleting resource ${logicalId} (${resourceType}), physical ID: ${physicalId}`);
10874
10874
  if (context?.removeProtection === true && resourceType === "AWS::AutoScaling::AutoScalingGroup") {
10875
10875
  this.logger.debug(`Delegating protected AutoScalingGroup ${logicalId} delete to the SDK ASGProvider (Cloud Control cannot force-delete a protected ASG)`);
10876
- const { ASGProvider } = await import("./asg-provider-er3xGYRo.js").then((n) => n.n);
10876
+ const { ASGProvider } = await import("./asg-provider-BzBdoSYp.js").then((n) => n.n);
10877
10877
  await new ASGProvider().delete(logicalId, physicalId, resourceType, _properties, context);
10878
10878
  return;
10879
10879
  }
@@ -15733,17 +15733,29 @@ const THROTTLING_ERROR_NAMES = /* @__PURE__ */ new Set([
15733
15733
  "TransactionInProgressException"
15734
15734
  ]);
15735
15735
  /**
15736
- * Walk the error + its `.cause` chain (bounded) looking for an AWS SDK v3
15737
- * throttling error `name`. cdkd wraps the original AWS error in a
15738
- * `ProvisioningError`, so the throttling signal is typically one cause-link
15739
- * deep; the bounded walk also tolerates SDK errors that nest a `$response`/
15740
- * cause without exploding on a cyclic chain.
15736
+ * Walk the error + its `.cause` chain (bounded) looking for a rate-limit
15737
+ * signal either an AWS SDK v3 throttling error `name`
15738
+ * ({@link THROTTLING_ERROR_NAMES}) or a retryable HTTP status
15739
+ * ({@link RETRYABLE_HTTP_STATUS_CODES}) on `$metadata`.
15740
+ *
15741
+ * cdkd wraps the original AWS error in a `ProvisioningError`, so the signal is
15742
+ * typically one cause-link deep; the bounded walk also tolerates SDK errors
15743
+ * that nest a `$response`/cause without exploding on a cyclic chain.
15744
+ *
15745
+ * BOTH signals are checked at EVERY depth. An earlier version checked the name
15746
+ * to depth 5 but the HTTP status only at depths 0 and 1, so a 429 nested two
15747
+ * links deep was missed. This is the single shared cause-walk: the read-only
15748
+ * import tag walk (`src/provisioning/import-tag-walk.ts`) composes its own
15749
+ * classifier on top of this function rather than re-implementing the traversal,
15750
+ * so the two cannot drift apart again.
15741
15751
  */
15742
15752
  function isThrottlingError(error) {
15743
15753
  let current = error;
15744
15754
  for (let depth = 0; depth < 5 && current != null; depth++) {
15745
15755
  const name = current.name;
15746
15756
  if (typeof name === "string" && THROTTLING_ERROR_NAMES.has(name)) return true;
15757
+ const status = current.$metadata?.httpStatusCode;
15758
+ if (status !== void 0 && RETRYABLE_HTTP_STATUS_CODES.has(status)) return true;
15747
15759
  current = current.cause;
15748
15760
  }
15749
15761
  return false;
@@ -15752,17 +15764,13 @@ function isThrottlingError(error) {
15752
15764
  * Determine whether an AWS error should be retried.
15753
15765
  *
15754
15766
  * Checks (in order):
15755
- * 1. HTTP status code on the error itself (`$metadata.httpStatusCode`)
15756
- * 2. HTTP status code on a wrapped cause (`cause.$metadata.httpStatusCode`)
15757
- * 3. Throttling error `name` on the error or any wrapped cause (most AWS
15758
- * throttles are HTTP 400, not 429 — see {@link THROTTLING_ERROR_NAMES})
15759
- * 4. Substring match against {@link RETRYABLE_ERROR_MESSAGE_PATTERNS}
15767
+ * 1. Rate-limit signal on the error or any wrapped cause — throttling error
15768
+ * `name` or retryable HTTP status (most AWS throttles are HTTP 400, not
15769
+ * 429, so the name check carries most of the weight). See
15770
+ * {@link isThrottlingError}.
15771
+ * 2. Substring match against {@link RETRYABLE_ERROR_MESSAGE_PATTERNS}
15760
15772
  */
15761
15773
  function isRetryableTransientError(error, message) {
15762
- const statusCode = error.$metadata?.httpStatusCode;
15763
- if (statusCode !== void 0 && RETRYABLE_HTTP_STATUS_CODES.has(statusCode)) return true;
15764
- const causeStatus = error.cause?.$metadata?.httpStatusCode;
15765
- if (causeStatus !== void 0 && RETRYABLE_HTTP_STATUS_CODES.has(causeStatus)) return true;
15766
15774
  if (isThrottlingError(error)) return true;
15767
15775
  return RETRYABLE_ERROR_MESSAGE_PATTERNS.some((p) => message.includes(p));
15768
15776
  }
@@ -17393,5 +17401,5 @@ var DeployEngine = class {
17393
17401
  };
17394
17402
 
17395
17403
  //#endregion
17396
- export { ensureAssetStorage as $, SynthesisError as $t, WAFv2WebACLProvider as A, clearBucketRegionCache as At, LockManager as B, LocalInvokeBuildError as Bt, findActionableSilentDrops as C, CFN_TEMPLATE_BODY_LIMIT as Ct, IntrinsicFunctionResolver as D, uploadCfnTemplate as Dt, isTerminationProtectionPropagationError as E, findLargeInlineResources as Et, assertRegionMatch as F, setAwsClients as Ft, stringifyValue as G, NestedStackChildDirectDestroyError as Gt, rebuildClientForBucketRegion as H, LocalStartServiceError as Ht, applyRoleArnIfSet as I, AssetError as It, createAssetRedirectResolver as J, ResourceTimeoutError as Jt, WorkGraph as K, PartialFailureError as Kt, DiffCalculator as L, CdkdError as Lt, matchesCdkPath as M, AwsClients as Mt, normalizeAwsTagsToCfn as N, getAwsClients as Nt, cfnRefValueFromPhysicalId as O, expectedOwnerParam as Ot, resolveExplicitPhysicalId as P, resetAwsClients as Pt, BOOTSTRAP_MARKER_PREFIX as Q, StateError as Qt, DagBuilder as R, ConfigError as Rt, ProviderRegistry as S, warnDeprecatedNoPrefixCliFlag as St, disableInstanceApiTermination as T, MIGRATE_TMP_PREFIX as Tt, shouldRetainResource as U, LockError as Ut, S3StateBackend as V, LocalMigrateError as Vt, AssetPublisher as W, MissingCdkCliError as Wt, rewriteTemplateAssetReferences as X, StackHasActiveImportsError as Xt, loadPublishableAssetManifest as Y, ResourceUpdateNotSupportedError as Yt, AssetModeResolver as Z, StackTerminationProtectionError as Zt, green as _, resolveCaptureObservedState as _t, withRetry as a, formatDockerLoginError as at, IAMRoleProvider as b, resolveStateBucketWithDefaultAndSource as bt, computeImplicitDeleteEdges as c, runDockerStreaming as ct, isStatefulRecreateTargetSync as d, Synthesizer as dt, formatError as en, getBootstrapMarkerKey as et, renderStatefulReason as f, synthesisStatusMessage as ft, gray as g, resolveAutoAssetStorage as gt, cyan as h, resolveApp as ht, withResourceDeadline as i, __exportAll as in, buildDockerImage as it, CDK_PATH_TAG as j, resolveBucketRegion as jt, refStateLookupFromResource as k, AssemblyReader as kt, extractDeploymentEventError as l, AssetManifestLoader as lt, bold as m, getLegacyStateBucketName as mt, DEFAULT_RESOURCE_WARN_AFTER_MS as n, normalizeAwsError as nn, validateAssetBucketName as nt, isRetryableTransientError as o, getDockerCmd as ot, formatResourceLine as p, getDefaultStateBucketName as pt, buildAssetRedirectMap as q, ProvisioningError as qt, DeployEngine as r, withErrorHandling as rn, validateContainerRepoName as rt, IMPLICIT_DELETE_DEPENDENCIES as s, runDockerForeground as st, DEFAULT_RESOURCE_TIMEOUT_MS as t, isCdkdError as tn, parseBootstrapMarker as tt, MULTI_REGION_RECREATE_BLOCKED_TYPES as u, getDockerImageBySourceHash as ut, red as v, resolveSkipPrefix as vt, CloudControlProvider as w, CFN_TEMPLATE_URL_LIMIT as wt, collectInlinePolicyNamesManagedBySiblings as x, resolveUseCdkBootstrapAssets as xt, yellow as y, resolveStateBucketWithDefault as yt, TemplateParser as z, DependencyError as zt };
17397
- //# sourceMappingURL=deploy-engine-D-gBbMiZ.js.map
17404
+ export { BOOTSTRAP_MARKER_PREFIX as $, StateError as $t, refStateLookupFromResource as A, AssemblyReader as At, TemplateParser as B, DependencyError as Bt, ProviderRegistry as C, warnDeprecatedNoPrefixCliFlag as Ct, isTerminationProtectionPropagationError as D, findLargeInlineResources as Dt, disableInstanceApiTermination as E, MIGRATE_TMP_PREFIX as Et, resolveExplicitPhysicalId as F, resetAwsClients as Ft, AssetPublisher as G, MissingCdkCliError as Gt, S3StateBackend as H, LocalMigrateError as Ht, assertRegionMatch as I, setAwsClients as It, buildAssetRedirectMap as J, ProvisioningError as Jt, stringifyValue as K, NestedStackChildDirectDestroyError as Kt, applyRoleArnIfSet as L, AssetError as Lt, CDK_PATH_TAG as M, resolveBucketRegion as Mt, matchesCdkPath as N, AwsClients as Nt, IntrinsicFunctionResolver as O, uploadCfnTemplate as Ot, normalizeAwsTagsToCfn as P, getAwsClients as Pt, AssetModeResolver as Q, StackTerminationProtectionError as Qt, DiffCalculator as R, CdkdError as Rt, collectInlinePolicyNamesManagedBySiblings as S, resolveUseCdkBootstrapAssets as St, CloudControlProvider as T, CFN_TEMPLATE_URL_LIMIT as Tt, rebuildClientForBucketRegion as U, LocalStartServiceError as Ut, LockManager as V, LocalInvokeBuildError as Vt, shouldRetainResource as W, LockError as Wt, loadPublishableAssetManifest as X, ResourceUpdateNotSupportedError as Xt, createAssetRedirectResolver as Y, ResourceTimeoutError as Yt, rewriteTemplateAssetReferences as Z, StackHasActiveImportsError as Zt, gray as _, resolveAutoAssetStorage as _t, withRetry as a, __exportAll as an, buildDockerImage as at, yellow as b, resolveStateBucketWithDefault as bt, IMPLICIT_DELETE_DEPENDENCIES as c, runDockerForeground as ct, MULTI_REGION_RECREATE_BLOCKED_TYPES as d, getDockerImageBySourceHash as dt, SynthesisError as en, ensureAssetStorage as et, isStatefulRecreateTargetSync as f, Synthesizer as ft, cyan as g, resolveApp as gt, bold as h, getLegacyStateBucketName as ht, withResourceDeadline as i, withErrorHandling as in, validateContainerRepoName as it, WAFv2WebACLProvider as j, clearBucketRegionCache as jt, cfnRefValueFromPhysicalId as k, expectedOwnerParam as kt, computeImplicitDeleteEdges as l, runDockerStreaming as lt, formatResourceLine as m, getDefaultStateBucketName as mt, DEFAULT_RESOURCE_WARN_AFTER_MS as n, isCdkdError as nn, parseBootstrapMarker as nt, isRetryableTransientError as o, formatDockerLoginError as ot, renderStatefulReason as p, synthesisStatusMessage as pt, WorkGraph as q, PartialFailureError as qt, DeployEngine as r, normalizeAwsError as rn, validateAssetBucketName as rt, isThrottlingError as s, getDockerCmd as st, DEFAULT_RESOURCE_TIMEOUT_MS as t, formatError as tn, getBootstrapMarkerKey as tt, extractDeploymentEventError as u, AssetManifestLoader as ut, green as v, resolveCaptureObservedState as vt, findActionableSilentDrops as w, CFN_TEMPLATE_BODY_LIMIT as wt, IAMRoleProvider as x, resolveStateBucketWithDefaultAndSource as xt, red as y, resolveSkipPrefix as yt, DagBuilder as z, ConfigError as zt };
17405
+ //# sourceMappingURL=deploy-engine-IkhnJXWR.js.map