@go-to-k/cdkd 0.242.0 → 0.243.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.
package/dist/cli.js
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
import { a as getLiveRenderer, c as PATTERN_B_RESOURCE_TYPES, d as generateResourceNameWithFallback, f as withSkipPrefix, i as runStackBuffered, n as getLogger, o as PATTERN_B_NAME_OPTIONS, p as withStackName, s as PATTERN_B_NAME_PROPERTIES, u as generateResourceName } from "./logger-BzO-joNR.js";
|
|
3
3
|
import { A as withErrorHandling, C as StackHasActiveImportsError, S as ResourceUpdateNotSupportedError, _ as MissingCdkCliError, a as normalizeAwsTagsToCfn, b as ProvisioningError, f as LocalInvokeBuildError$1, i as matchesCdkPath, k as normalizeAwsError, l as CdkdError, m as LocalStartServiceError, n as isTerminationProtectionPropagationError, o as resolveExplicitPhysicalId, p as LocalMigrateError, r as CDK_PATH_TAG, s as assertRegionMatch, t as disableInstanceApiTermination, v as NestedStackChildDirectDestroyError, w as StackTerminationProtectionError, x as ResourceTimeoutError, y as PartialFailureError } from "./ec2-termination-protection-q-WGWgxa.js";
|
|
4
4
|
import { a as setAwsClients, i as resetAwsClients, r as getAwsClients, t as AwsClients } from "./aws-clients-B15NAPbL.js";
|
|
5
|
-
import { $ as getDockerCmd, A as DiffCalculator, B as buildAssetRedirectMap, C as findActionableSilentDrops, Ct as resolveBucketRegion, D as refStateLookupFromResource, E as cfnRefValueFromPhysicalId, F as rebuildClientForBucketRegion, G as BOOTSTRAP_MARKER_PREFIX, H as loadPublishableAssetManifest, I as shouldRetainResource, J as parseBootstrapMarker, K as ensureAssetStorage, L as AssetPublisher, M as TemplateParser, N as LockManager, O as WAFv2WebACLProvider, P as S3StateBackend, Q as formatDockerLoginError, R as stringifyValue, S as ProviderRegistry, T as IntrinsicFunctionResolver, U as rewriteTemplateAssetReferences, V as createAssetRedirectResolver, W as AssetModeResolver, X as validateContainerRepoName, Y as validateAssetBucketName, Z as buildDockerImage, _ as green, _t as CFN_TEMPLATE_URL_LIMIT, a as withRetry, at as synthesisStatusMessage, b as IAMRoleProvider, bt as uploadCfnTemplate, c as computeImplicitDeleteEdges, ct as resolveApp, d as isStatefulRecreateTargetSync, dt as resolveSkipPrefix, et as runDockerForeground, f as renderStatefulReason, ft as resolveStateBucketWithDefault, g as gray, gt as CFN_TEMPLATE_BODY_LIMIT, h as cyan, ht as warnDeprecatedNoPrefixCliFlag, i as withResourceDeadline, it as Synthesizer, j as DagBuilder, k as applyRoleArnIfSet, l as extractDeploymentEventError, lt as resolveAutoAssetStorage, m as bold, mt as resolveUseCdkBootstrapAssets, n as DEFAULT_RESOURCE_WARN_AFTER_MS, nt as AssetManifestLoader, o as isRetryableTransientError, ot as getDefaultStateBucketName, p as formatResourceLine, pt as resolveStateBucketWithDefaultAndSource, q as getBootstrapMarkerKey, r as DeployEngine, rt as getDockerImageBySourceHash, s as IMPLICIT_DELETE_DEPENDENCIES, st as getLegacyStateBucketName, t as DEFAULT_RESOURCE_TIMEOUT_MS, tt as runDockerStreaming, u as MULTI_REGION_RECREATE_BLOCKED_TYPES, ut as resolveCaptureObservedState, v as red, vt as MIGRATE_TMP_PREFIX, w as CloudControlProvider, x as collectInlinePolicyNamesManagedBySiblings, xt as AssemblyReader, y as yellow, yt as findLargeInlineResources, z as WorkGraph } from "./deploy-engine-
|
|
5
|
+
import { $ as getDockerCmd, A as DiffCalculator, B as buildAssetRedirectMap, C as findActionableSilentDrops, Ct as resolveBucketRegion, D as refStateLookupFromResource, E as cfnRefValueFromPhysicalId, F as rebuildClientForBucketRegion, G as BOOTSTRAP_MARKER_PREFIX, H as loadPublishableAssetManifest, I as shouldRetainResource, J as parseBootstrapMarker, K as ensureAssetStorage, L as AssetPublisher, M as TemplateParser, N as LockManager, O as WAFv2WebACLProvider, P as S3StateBackend, Q as formatDockerLoginError, R as stringifyValue, S as ProviderRegistry, T as IntrinsicFunctionResolver, U as rewriteTemplateAssetReferences, V as createAssetRedirectResolver, W as AssetModeResolver, X as validateContainerRepoName, Y as validateAssetBucketName, Z as buildDockerImage, _ as green, _t as CFN_TEMPLATE_URL_LIMIT, a as withRetry, at as synthesisStatusMessage, b as IAMRoleProvider, bt as uploadCfnTemplate, c as computeImplicitDeleteEdges, ct as resolveApp, d as isStatefulRecreateTargetSync, dt as resolveSkipPrefix, et as runDockerForeground, f as renderStatefulReason, ft as resolveStateBucketWithDefault, g as gray, gt as CFN_TEMPLATE_BODY_LIMIT, h as cyan, ht as warnDeprecatedNoPrefixCliFlag, i as withResourceDeadline, it as Synthesizer, j as DagBuilder, k as applyRoleArnIfSet, l as extractDeploymentEventError, lt as resolveAutoAssetStorage, m as bold, mt as resolveUseCdkBootstrapAssets, n as DEFAULT_RESOURCE_WARN_AFTER_MS, nt as AssetManifestLoader, o as isRetryableTransientError, ot as getDefaultStateBucketName, p as formatResourceLine, pt as resolveStateBucketWithDefaultAndSource, q as getBootstrapMarkerKey, r as DeployEngine, rt as getDockerImageBySourceHash, s as IMPLICIT_DELETE_DEPENDENCIES, st as getLegacyStateBucketName, t as DEFAULT_RESOURCE_TIMEOUT_MS, tt as runDockerStreaming, u as MULTI_REGION_RECREATE_BLOCKED_TYPES, ut as resolveCaptureObservedState, v as red, vt as MIGRATE_TMP_PREFIX, w as CloudControlProvider, x as collectInlinePolicyNamesManagedBySiblings, xt as AssemblyReader, y as yellow, yt as findLargeInlineResources, z as WorkGraph } from "./deploy-engine-DNqZHDA5.js";
|
|
6
6
|
import { t as expectedOwnerParam } from "./expected-bucket-owner-BjEfUnkA.js";
|
|
7
7
|
import { t as ASGProvider } from "./asg-provider-Dbl1_mwT.js";
|
|
8
8
|
import { AsyncLocalStorage } from "node:async_hooks";
|
|
@@ -23,7 +23,7 @@ import { AddTagsToResourceCommand, DeleteParameterCommand, DescribeParametersCom
|
|
|
23
23
|
import { CloudFrontClient, CreateCloudFrontOriginAccessIdentityCommand, CreateDistributionCommand, CreateDistributionWithTagsCommand, DeleteCloudFrontOriginAccessIdentityCommand, DeleteDistributionCommand, GetCloudFrontOriginAccessIdentityCommand, GetDistributionCommand, GetDistributionConfigCommand, ListDistributionsCommand, ListTagsForResourceCommand as ListTagsForResourceCommand$3, NoSuchCloudFrontOriginAccessIdentity, NoSuchDistribution, TagResourceCommand as TagResourceCommand$6, UntagResourceCommand as UntagResourceCommand$6, UpdateCloudFrontOriginAccessIdentityCommand, UpdateDistributionCommand } from "@aws-sdk/client-cloudfront";
|
|
24
24
|
import { CloudWatchClient, DeleteAlarmsCommand, DescribeAlarmsCommand, ListTagsForResourceCommand as ListTagsForResourceCommand$4, PutMetricAlarmCommand, TagResourceCommand as TagResourceCommand$7, UntagResourceCommand as UntagResourceCommand$7 } from "@aws-sdk/client-cloudwatch";
|
|
25
25
|
import { AssociateKmsKeyCommand, CloudWatchLogsClient, CreateLogGroupCommand, DeleteDataProtectionPolicyCommand, DeleteIndexPolicyCommand, DeleteLogGroupCommand, DeleteRetentionPolicyCommand, DescribeIndexPoliciesCommand, DescribeLogGroupsCommand, DisassociateKmsKeyCommand, GetDataProtectionPolicyCommand, ListTagsForResourceCommand as ListTagsForResourceCommand$5, PutBearerTokenAuthenticationCommand, PutDataProtectionPolicyCommand, PutIndexPolicyCommand, PutLogGroupDeletionProtectionCommand, PutRetentionPolicyCommand, ResourceAlreadyExistsException, ResourceNotFoundException as ResourceNotFoundException$4, TagResourceCommand as TagResourceCommand$8, UntagResourceCommand as UntagResourceCommand$8 } from "@aws-sdk/client-cloudwatch-logs";
|
|
26
|
-
import { BedrockAgentCoreControlClient, CreateAgentRuntimeCommand, DeleteAgentRuntimeCommand, GetAgentRuntimeCommand, ResourceNotFoundException as ResourceNotFoundException$5, UpdateAgentRuntimeCommand } from "@aws-sdk/client-bedrock-agentcore-control";
|
|
26
|
+
import { BedrockAgentCoreControlClient, CreateAgentRuntimeCommand, CreateEvaluatorCommand, DeleteAgentRuntimeCommand, DeleteEvaluatorCommand, GetAgentRuntimeCommand, GetBrowserCommand, GetCodeInterpreterCommand, GetEvaluatorCommand, ListTagsForResourceCommand as ListTagsForResourceCommand$6, ResourceNotFoundException as ResourceNotFoundException$5, TagResourceCommand as TagResourceCommand$9, UntagResourceCommand as UntagResourceCommand$9, UpdateAgentRuntimeCommand, UpdateEvaluatorCommand } from "@aws-sdk/client-bedrock-agentcore-control";
|
|
27
27
|
import { ACMClient, AddTagsToCertificateCommand, DeleteCertificateCommand, DescribeCertificateCommand, ListCertificatesCommand, ListTagsForCertificateCommand, RemoveTagsFromCertificateCommand, RequestCertificateCommand, ResourceNotFoundException as ResourceNotFoundException$6, UpdateCertificateOptionsCommand } from "@aws-sdk/client-acm";
|
|
28
28
|
import * as fs from "node:fs";
|
|
29
29
|
import { cpSync, existsSync, mkdirSync, mkdtempSync, readFileSync, readdirSync, rmSync, statSync, writeFileSync } from "node:fs";
|
|
@@ -31,14 +31,14 @@ import * as path from "node:path";
|
|
|
31
31
|
import { basename, dirname, isAbsolute, join, resolve } from "node:path";
|
|
32
32
|
import { execFile, spawn } from "node:child_process";
|
|
33
33
|
import { tmpdir } from "node:os";
|
|
34
|
-
import { AssociateVPCWithHostedZoneCommand, ChangeResourceRecordSetsCommand, ChangeTagsForResourceCommand, CreateHostedZoneCommand, CreateQueryLoggingConfigCommand, DeleteHostedZoneCommand, DeleteQueryLoggingConfigCommand, DisassociateVPCFromHostedZoneCommand, GetHostedZoneCommand, ListHostedZonesByNameCommand, ListHostedZonesCommand, ListQueryLoggingConfigsCommand, ListResourceRecordSetsCommand, ListTagsForResourceCommand as ListTagsForResourceCommand$
|
|
34
|
+
import { AssociateVPCWithHostedZoneCommand, ChangeResourceRecordSetsCommand, ChangeTagsForResourceCommand, CreateHostedZoneCommand, CreateQueryLoggingConfigCommand, DeleteHostedZoneCommand, DeleteQueryLoggingConfigCommand, DisassociateVPCFromHostedZoneCommand, GetHostedZoneCommand, ListHostedZonesByNameCommand, ListHostedZonesCommand, ListQueryLoggingConfigsCommand, ListResourceRecordSetsCommand, ListTagsForResourceCommand as ListTagsForResourceCommand$7, Route53Client, UpdateHostedZoneCommentCommand, UpdateHostedZoneFeaturesCommand } from "@aws-sdk/client-route-53";
|
|
35
35
|
import { AddTagsCommand, CreateListenerCommand, CreateLoadBalancerCommand, CreateTargetGroupCommand, DeleteListenerCommand, DeleteLoadBalancerCommand, DeleteTargetGroupCommand, DescribeListenerAttributesCommand, DescribeListenersCommand, DescribeLoadBalancerAttributesCommand, DescribeLoadBalancersCommand, DescribeTagsCommand, DescribeTargetGroupsCommand, ElasticLoadBalancingV2Client, ModifyListenerAttributesCommand, ModifyListenerCommand, ModifyLoadBalancerAttributesCommand, ModifyTargetGroupCommand, RemoveTagsCommand, SetIpAddressTypeCommand, SetSecurityGroupsCommand, SetSubnetsCommand } from "@aws-sdk/client-elastic-load-balancing-v2";
|
|
36
|
-
import { CreateAliasCommand, CreateKeyCommand, DeleteAliasCommand, DescribeKeyCommand, DisableKeyCommand, DisableKeyRotationCommand, EnableKeyCommand, EnableKeyRotationCommand, GetKeyPolicyCommand, GetKeyRotationStatusCommand, KMSClient, ListAliasesCommand, ListKeysCommand, ListResourceTagsCommand, NotFoundException as NotFoundException$2, PutKeyPolicyCommand, ScheduleKeyDeletionCommand, TagResourceCommand as TagResourceCommand$
|
|
36
|
+
import { CreateAliasCommand, CreateKeyCommand, DeleteAliasCommand, DescribeKeyCommand, DisableKeyCommand, DisableKeyRotationCommand, EnableKeyCommand, EnableKeyRotationCommand, GetKeyPolicyCommand, GetKeyRotationStatusCommand, KMSClient, ListAliasesCommand, ListKeysCommand, ListResourceTagsCommand, NotFoundException as NotFoundException$2, PutKeyPolicyCommand, ScheduleKeyDeletionCommand, TagResourceCommand as TagResourceCommand$10, UntagResourceCommand as UntagResourceCommand$10, UpdateAliasCommand, UpdateKeyDescriptionCommand } from "@aws-sdk/client-kms";
|
|
37
37
|
import { join as join$1 } from "path";
|
|
38
|
-
import { BatchDeleteImageCommand, CreateRepositoryCommand, DeleteLifecyclePolicyCommand, DeleteRepositoryCommand, DeleteRepositoryPolicyCommand, DescribeImagesCommand as DescribeImagesCommand$1, DescribeRepositoriesCommand, ECRClient, GetAuthorizationTokenCommand, GetLifecyclePolicyCommand, LifecyclePolicyNotFoundException, ListTagsForResourceCommand as ListTagsForResourceCommand$
|
|
38
|
+
import { BatchDeleteImageCommand, CreateRepositoryCommand, DeleteLifecyclePolicyCommand, DeleteRepositoryCommand, DeleteRepositoryPolicyCommand, DescribeImagesCommand as DescribeImagesCommand$1, DescribeRepositoriesCommand, ECRClient, GetAuthorizationTokenCommand, GetLifecyclePolicyCommand, LifecyclePolicyNotFoundException, ListTagsForResourceCommand as ListTagsForResourceCommand$8, PutImageScanningConfigurationCommand, PutImageTagMutabilityCommand, PutLifecyclePolicyCommand, RepositoryNotFoundException, SetRepositoryPolicyCommand, TagResourceCommand as TagResourceCommand$11, UntagResourceCommand as UntagResourceCommand$11 } from "@aws-sdk/client-ecr";
|
|
39
39
|
import graphlib from "graphlib";
|
|
40
|
-
import { AddTagsToResourceCommand as AddTagsToResourceCommand$1, CreateDBClusterCommand, CreateDBInstanceCommand, CreateDBProxyCommand, CreateDBProxyEndpointCommand, CreateDBSubnetGroupCommand, DBProxyEndpointNotFoundFault, DBProxyNotFoundFault, DBProxyTargetGroupNotFoundFault, DBProxyTargetNotFoundFault, DeleteDBClusterCommand, DeleteDBInstanceCommand, DeleteDBProxyCommand, DeleteDBProxyEndpointCommand, DeleteDBSubnetGroupCommand, DeregisterDBProxyTargetsCommand, DescribeDBClustersCommand, DescribeDBInstancesCommand, DescribeDBProxiesCommand, DescribeDBProxyEndpointsCommand, DescribeDBProxyTargetGroupsCommand, DescribeDBProxyTargetsCommand, DescribeDBSubnetGroupsCommand, ListTagsForResourceCommand as ListTagsForResourceCommand$
|
|
41
|
-
import { AddTagsToResourceCommand as AddTagsToResourceCommand$2, CreateCacheClusterCommand, CreateCacheSubnetGroupCommand, DeleteCacheClusterCommand, DeleteCacheSubnetGroupCommand, DescribeCacheClustersCommand, DescribeCacheSubnetGroupsCommand, ElastiCacheClient, ListTagsForResourceCommand as ListTagsForResourceCommand$
|
|
40
|
+
import { AddTagsToResourceCommand as AddTagsToResourceCommand$1, CreateDBClusterCommand, CreateDBInstanceCommand, CreateDBProxyCommand, CreateDBProxyEndpointCommand, CreateDBSubnetGroupCommand, DBProxyEndpointNotFoundFault, DBProxyNotFoundFault, DBProxyTargetGroupNotFoundFault, DBProxyTargetNotFoundFault, DeleteDBClusterCommand, DeleteDBInstanceCommand, DeleteDBProxyCommand, DeleteDBProxyEndpointCommand, DeleteDBSubnetGroupCommand, DeregisterDBProxyTargetsCommand, DescribeDBClustersCommand, DescribeDBInstancesCommand, DescribeDBProxiesCommand, DescribeDBProxyEndpointsCommand, DescribeDBProxyTargetGroupsCommand, DescribeDBProxyTargetsCommand, DescribeDBSubnetGroupsCommand, ListTagsForResourceCommand as ListTagsForResourceCommand$9, ModifyDBClusterCommand, ModifyDBInstanceCommand, ModifyDBProxyCommand, ModifyDBProxyEndpointCommand, ModifyDBProxyTargetGroupCommand, ModifyDBSubnetGroupCommand, RDSClient, RegisterDBProxyTargetsCommand, RemoveTagsFromResourceCommand as RemoveTagsFromResourceCommand$1 } from "@aws-sdk/client-rds";
|
|
41
|
+
import { AddTagsToResourceCommand as AddTagsToResourceCommand$2, CreateCacheClusterCommand, CreateCacheSubnetGroupCommand, DeleteCacheClusterCommand, DeleteCacheSubnetGroupCommand, DescribeCacheClustersCommand, DescribeCacheSubnetGroupsCommand, ElastiCacheClient, ListTagsForResourceCommand as ListTagsForResourceCommand$10, ModifyCacheClusterCommand, ModifyCacheSubnetGroupCommand, RemoveTagsFromResourceCommand as RemoveTagsFromResourceCommand$2 } from "@aws-sdk/client-elasticache";
|
|
42
42
|
import { Command, Option } from "commander";
|
|
43
43
|
import * as readline$1 from "node:readline/promises";
|
|
44
44
|
import readline from "node:readline/promises";
|
|
@@ -46,26 +46,26 @@ import { writeFileSync as writeFileSync$1 } from "fs";
|
|
|
46
46
|
import * as zlib from "node:zlib";
|
|
47
47
|
import { ApplicationAutoScalingClient, DeleteScalingPolicyCommand, DeregisterScalableTargetCommand, DescribeScalableTargetsCommand, DescribeScalingPoliciesCommand, PutScalingPolicyCommand, RegisterScalableTargetCommand } from "@aws-sdk/client-application-auto-scaling";
|
|
48
48
|
import { ApiGatewayV2Client, CreateApiCommand, CreateAuthorizerCommand as CreateAuthorizerCommand$1, CreateIntegrationCommand, CreateRouteCommand as CreateRouteCommand$1, CreateStageCommand as CreateStageCommand$1, DeleteApiCommand, DeleteAuthorizerCommand as DeleteAuthorizerCommand$1, DeleteIntegrationCommand, DeleteRouteCommand as DeleteRouteCommand$1, DeleteStageCommand as DeleteStageCommand$1, GetApiCommand, GetApisCommand, GetAuthorizerCommand as GetAuthorizerCommand$1, GetIntegrationCommand, GetRouteCommand, GetStageCommand as GetStageCommand$1, NotFoundException as NotFoundException$3, UpdateApiCommand, UpdateAuthorizerCommand as UpdateAuthorizerCommand$1, UpdateIntegrationCommand, UpdateRouteCommand, UpdateStageCommand as UpdateStageCommand$1 } from "@aws-sdk/client-apigatewayv2";
|
|
49
|
-
import { CreateStateMachineCommand, DeleteStateMachineCommand, DescribeStateMachineCommand, ListStateMachinesCommand, ListTagsForResourceCommand as ListTagsForResourceCommand$
|
|
50
|
-
import { CreateClusterCommand, CreateServiceCommand, DeleteClusterCommand, DeleteServiceCommand, DeregisterTaskDefinitionCommand, DescribeClustersCommand, DescribeServicesCommand, DescribeTaskDefinitionCommand, ECSClient, ListClustersCommand, ListServicesCommand, ListTagsForResourceCommand as ListTagsForResourceCommand$
|
|
51
|
-
import { AddTagsToResourceCommand as AddTagsToResourceCommand$3, CreateDBClusterCommand as CreateDBClusterCommand$1, CreateDBInstanceCommand as CreateDBInstanceCommand$1, CreateDBSubnetGroupCommand as CreateDBSubnetGroupCommand$1, DeleteDBClusterCommand as DeleteDBClusterCommand$1, DeleteDBInstanceCommand as DeleteDBInstanceCommand$1, DeleteDBSubnetGroupCommand as DeleteDBSubnetGroupCommand$1, DescribeDBClustersCommand as DescribeDBClustersCommand$1, DescribeDBInstancesCommand as DescribeDBInstancesCommand$1, DescribeDBSubnetGroupsCommand as DescribeDBSubnetGroupsCommand$1, DocDBClient, ListTagsForResourceCommand as ListTagsForResourceCommand$
|
|
52
|
-
import { AddTagsToResourceCommand as AddTagsToResourceCommand$4, CreateDBClusterCommand as CreateDBClusterCommand$2, CreateDBInstanceCommand as CreateDBInstanceCommand$2, CreateDBSubnetGroupCommand as CreateDBSubnetGroupCommand$2, DeleteDBClusterCommand as DeleteDBClusterCommand$2, DeleteDBInstanceCommand as DeleteDBInstanceCommand$2, DeleteDBSubnetGroupCommand as DeleteDBSubnetGroupCommand$2, DescribeDBClustersCommand as DescribeDBClustersCommand$2, DescribeDBInstancesCommand as DescribeDBInstancesCommand$2, DescribeDBSubnetGroupsCommand as DescribeDBSubnetGroupsCommand$2, ListTagsForResourceCommand as ListTagsForResourceCommand$
|
|
53
|
-
import { AddCustomAttributesCommand, CognitoIdentityProviderClient, CreateUserPoolCommand, DeleteUserPoolCommand, DescribeUserPoolCommand, GetUserPoolMfaConfigCommand, ListTagsForResourceCommand as ListTagsForResourceCommand$
|
|
54
|
-
import { CreateHttpNamespaceCommand, CreatePrivateDnsNamespaceCommand, CreatePublicDnsNamespaceCommand, CreateServiceCommand as CreateServiceCommand$1, DeleteNamespaceCommand, DeleteServiceAttributesCommand, DeleteServiceCommand as DeleteServiceCommand$1, GetNamespaceCommand, GetOperationCommand, GetServiceAttributesCommand, GetServiceCommand, ListNamespacesCommand, ListServicesCommand as ListServicesCommand$1, ListTagsForResourceCommand as ListTagsForResourceCommand$
|
|
55
|
-
import { AppSyncClient, CreateApiKeyCommand, CreateDataSourceCommand, CreateGraphqlApiCommand, CreateResolverCommand, DeleteApiKeyCommand, DeleteDataSourceCommand, DeleteGraphqlApiCommand, DeleteResolverCommand, GetDataSourceCommand, GetGraphqlApiCommand, GetIntrospectionSchemaCommand, GetResolverCommand, ListApiKeysCommand, ListGraphqlApisCommand, NotFoundException as NotFoundException$4, StartSchemaCreationCommand, TagResourceCommand as TagResourceCommand$
|
|
49
|
+
import { CreateStateMachineCommand, DeleteStateMachineCommand, DescribeStateMachineCommand, ListStateMachinesCommand, ListTagsForResourceCommand as ListTagsForResourceCommand$11, SFNClient, StateMachineDoesNotExist, TagResourceCommand as TagResourceCommand$12, UntagResourceCommand as UntagResourceCommand$12, UpdateStateMachineCommand } from "@aws-sdk/client-sfn";
|
|
50
|
+
import { CreateClusterCommand, CreateServiceCommand, DeleteClusterCommand, DeleteServiceCommand, DeregisterTaskDefinitionCommand, DescribeClustersCommand, DescribeServicesCommand, DescribeTaskDefinitionCommand, ECSClient, ListClustersCommand, ListServicesCommand, ListTagsForResourceCommand as ListTagsForResourceCommand$12, PutClusterCapacityProvidersCommand, RegisterTaskDefinitionCommand, TagResourceCommand as TagResourceCommand$13, UntagResourceCommand as UntagResourceCommand$13, UpdateClusterCommand, UpdateServiceCommand } from "@aws-sdk/client-ecs";
|
|
51
|
+
import { AddTagsToResourceCommand as AddTagsToResourceCommand$3, CreateDBClusterCommand as CreateDBClusterCommand$1, CreateDBInstanceCommand as CreateDBInstanceCommand$1, CreateDBSubnetGroupCommand as CreateDBSubnetGroupCommand$1, DeleteDBClusterCommand as DeleteDBClusterCommand$1, DeleteDBInstanceCommand as DeleteDBInstanceCommand$1, DeleteDBSubnetGroupCommand as DeleteDBSubnetGroupCommand$1, DescribeDBClustersCommand as DescribeDBClustersCommand$1, DescribeDBInstancesCommand as DescribeDBInstancesCommand$1, DescribeDBSubnetGroupsCommand as DescribeDBSubnetGroupsCommand$1, DocDBClient, ListTagsForResourceCommand as ListTagsForResourceCommand$13, ModifyDBClusterCommand as ModifyDBClusterCommand$1, ModifyDBInstanceCommand as ModifyDBInstanceCommand$1, ModifyDBSubnetGroupCommand as ModifyDBSubnetGroupCommand$1, RemoveTagsFromResourceCommand as RemoveTagsFromResourceCommand$3 } from "@aws-sdk/client-docdb";
|
|
52
|
+
import { AddTagsToResourceCommand as AddTagsToResourceCommand$4, CreateDBClusterCommand as CreateDBClusterCommand$2, CreateDBInstanceCommand as CreateDBInstanceCommand$2, CreateDBSubnetGroupCommand as CreateDBSubnetGroupCommand$2, DeleteDBClusterCommand as DeleteDBClusterCommand$2, DeleteDBInstanceCommand as DeleteDBInstanceCommand$2, DeleteDBSubnetGroupCommand as DeleteDBSubnetGroupCommand$2, DescribeDBClustersCommand as DescribeDBClustersCommand$2, DescribeDBInstancesCommand as DescribeDBInstancesCommand$2, DescribeDBSubnetGroupsCommand as DescribeDBSubnetGroupsCommand$2, ListTagsForResourceCommand as ListTagsForResourceCommand$14, ModifyDBClusterCommand as ModifyDBClusterCommand$2, ModifyDBInstanceCommand as ModifyDBInstanceCommand$2, ModifyDBSubnetGroupCommand as ModifyDBSubnetGroupCommand$2, NeptuneClient, RemoveTagsFromResourceCommand as RemoveTagsFromResourceCommand$4 } from "@aws-sdk/client-neptune";
|
|
53
|
+
import { AddCustomAttributesCommand, CognitoIdentityProviderClient, CreateUserPoolCommand, DeleteUserPoolCommand, DescribeUserPoolCommand, GetUserPoolMfaConfigCommand, ListTagsForResourceCommand as ListTagsForResourceCommand$15, ListUserPoolsCommand, ResourceNotFoundException as ResourceNotFoundException$7, SetUserPoolMfaConfigCommand, UpdateUserPoolCommand } from "@aws-sdk/client-cognito-identity-provider";
|
|
54
|
+
import { CreateHttpNamespaceCommand, CreatePrivateDnsNamespaceCommand, CreatePublicDnsNamespaceCommand, CreateServiceCommand as CreateServiceCommand$1, DeleteNamespaceCommand, DeleteServiceAttributesCommand, DeleteServiceCommand as DeleteServiceCommand$1, GetNamespaceCommand, GetOperationCommand, GetServiceAttributesCommand, GetServiceCommand, ListNamespacesCommand, ListServicesCommand as ListServicesCommand$1, ListTagsForResourceCommand as ListTagsForResourceCommand$16, NamespaceNotFound, ServiceDiscoveryClient, ServiceNotFound, TagResourceCommand as TagResourceCommand$14, UntagResourceCommand as UntagResourceCommand$14, UpdateHttpNamespaceCommand, UpdatePrivateDnsNamespaceCommand, UpdatePublicDnsNamespaceCommand, UpdateServiceAttributesCommand, UpdateServiceCommand as UpdateServiceCommand$1 } from "@aws-sdk/client-servicediscovery";
|
|
55
|
+
import { AppSyncClient, CreateApiKeyCommand, CreateDataSourceCommand, CreateGraphqlApiCommand, CreateResolverCommand, DeleteApiKeyCommand, DeleteDataSourceCommand, DeleteGraphqlApiCommand, DeleteResolverCommand, GetDataSourceCommand, GetGraphqlApiCommand, GetIntrospectionSchemaCommand, GetResolverCommand, ListApiKeysCommand, ListGraphqlApisCommand, NotFoundException as NotFoundException$4, StartSchemaCreationCommand, TagResourceCommand as TagResourceCommand$15, UntagResourceCommand as UntagResourceCommand$15, UpdateApiKeyCommand, UpdateDataSourceCommand, UpdateGraphqlApiCommand, UpdateResolverCommand } from "@aws-sdk/client-appsync";
|
|
56
56
|
import { parse, print } from "graphql";
|
|
57
57
|
import { CrawlerRunningException, CreateConnectionCommand, CreateCrawlerCommand, CreateDatabaseCommand, CreateJobCommand, CreateSecurityConfigurationCommand, CreateTableCommand as CreateTableCommand$1, CreateTriggerCommand, CreateWorkflowCommand, DeleteConnectionCommand, DeleteCrawlerCommand, DeleteDatabaseCommand, DeleteJobCommand, DeleteSecurityConfigurationCommand, DeleteTableCommand as DeleteTableCommand$1, DeleteTriggerCommand, DeleteWorkflowCommand, EntityNotFoundException, GetConnectionCommand, GetCrawlerCommand, GetDatabaseCommand, GetDatabasesCommand, GetJobCommand, GetSecurityConfigurationCommand, GetSecurityConfigurationsCommand, GetTableCommand, GetTablesCommand, GetTagsCommand, GetTriggerCommand, GetWorkflowCommand, GlueClient, ListWorkflowsCommand, StartCrawlerScheduleCommand, StartTriggerCommand, StopCrawlerCommand, StopCrawlerScheduleCommand, StopTriggerCommand, UpdateConnectionCommand, UpdateCrawlerCommand, UpdateDatabaseCommand, UpdateJobCommand, UpdateTableCommand as UpdateTableCommand$1, UpdateTriggerCommand, UpdateWorkflowCommand } from "@aws-sdk/client-glue";
|
|
58
|
-
import { BudgetsClient, CreateBudgetCommand, CreateNotificationCommand, CreateSubscriberCommand, DeleteBudgetCommand, DeleteNotificationCommand, DeleteSubscriberCommand, DescribeBudgetCommand, DescribeBudgetsCommand, DuplicateRecordException, ListTagsForResourceCommand as ListTagsForResourceCommand$
|
|
59
|
-
import { AddTagsToStreamCommand, CreateStreamCommand, DecreaseStreamRetentionPeriodCommand, DeleteStreamCommand, DeregisterStreamConsumerCommand, DescribeStreamCommand, DescribeStreamConsumerCommand, DescribeStreamSummaryCommand, IncreaseStreamRetentionPeriodCommand, KinesisClient, ListStreamsCommand, ListTagsForResourceCommand as ListTagsForResourceCommand$
|
|
58
|
+
import { BudgetsClient, CreateBudgetCommand, CreateNotificationCommand, CreateSubscriberCommand, DeleteBudgetCommand, DeleteNotificationCommand, DeleteSubscriberCommand, DescribeBudgetCommand, DescribeBudgetsCommand, DuplicateRecordException, ListTagsForResourceCommand as ListTagsForResourceCommand$17, NotFoundException as NotFoundException$5, TagResourceCommand as TagResourceCommand$16, UntagResourceCommand as UntagResourceCommand$16, UpdateBudgetCommand } from "@aws-sdk/client-budgets";
|
|
59
|
+
import { AddTagsToStreamCommand, CreateStreamCommand, DecreaseStreamRetentionPeriodCommand, DeleteStreamCommand, DeregisterStreamConsumerCommand, DescribeStreamCommand, DescribeStreamConsumerCommand, DescribeStreamSummaryCommand, IncreaseStreamRetentionPeriodCommand, KinesisClient, ListStreamsCommand, ListTagsForResourceCommand as ListTagsForResourceCommand$18, ListTagsForStreamCommand, RegisterStreamConsumerCommand, RemoveTagsFromStreamCommand, ResourceNotFoundException as ResourceNotFoundException$8, StartStreamEncryptionCommand, StopStreamEncryptionCommand, TagResourceCommand as TagResourceCommand$17, UntagResourceCommand as UntagResourceCommand$17, UpdateShardCountCommand, UpdateStreamModeCommand } from "@aws-sdk/client-kinesis";
|
|
60
60
|
import { CreateScheduleCommand, DeleteScheduleCommand, GetScheduleCommand, ResourceNotFoundException as ResourceNotFoundException$9, SchedulerClient, UpdateScheduleCommand } from "@aws-sdk/client-scheduler";
|
|
61
61
|
import { AccessPointNotFound, CreateAccessPointCommand, CreateFileSystemCommand, CreateMountTargetCommand, DeleteAccessPointCommand, DeleteFileSystemCommand, DeleteMountTargetCommand, DescribeAccessPointsCommand, DescribeBackupPolicyCommand, DescribeFileSystemPolicyCommand, DescribeFileSystemsCommand, DescribeLifecycleConfigurationCommand, DescribeMountTargetSecurityGroupsCommand, DescribeMountTargetsCommand, EFSClient, FileSystemNotFound, ModifyMountTargetSecurityGroupsCommand, MountTargetNotFound, PutBackupPolicyCommand, PutFileSystemPolicyCommand, PutLifecycleConfigurationCommand, UpdateFileSystemCommand, UpdateFileSystemProtectionCommand } from "@aws-sdk/client-efs";
|
|
62
62
|
import { CreateDeliveryStreamCommand, DeleteDeliveryStreamCommand, DescribeDeliveryStreamCommand, FirehoseClient, ListDeliveryStreamsCommand, ListTagsForDeliveryStreamCommand, ResourceNotFoundException as ResourceNotFoundException$10, TagDeliveryStreamCommand, UntagDeliveryStreamCommand, UpdateDestinationCommand } from "@aws-sdk/client-firehose";
|
|
63
63
|
import { AddTagsCommand as AddTagsCommand$1, CloudTrailClient, CreateTrailCommand, DeleteTrailCommand, GetEventSelectorsCommand, GetInsightSelectorsCommand, GetTrailCommand, GetTrailStatusCommand, ListTagsCommand as ListTagsCommand$1, ListTrailsCommand, PutEventSelectorsCommand, PutInsightSelectorsCommand, RemoveTagsCommand as RemoveTagsCommand$1, StartLoggingCommand, StopLoggingCommand, TrailNotFoundException, UpdateTrailCommand } from "@aws-sdk/client-cloudtrail";
|
|
64
64
|
import { BatchGetProjectsCommand, CodeBuildClient, CreateProjectCommand, DeleteProjectCommand, ListProjectsCommand, ResourceNotFoundException as ResourceNotFoundException$11, UpdateProjectCommand } from "@aws-sdk/client-codebuild";
|
|
65
|
-
import { CodeCommitClient, CreateRepositoryCommand as CreateRepositoryCommand$1, DeleteRepositoryCommand as DeleteRepositoryCommand$1, GetRepositoryCommand, ListRepositoriesCommand, ListTagsForResourceCommand as ListTagsForResourceCommand$
|
|
66
|
-
import { CreateLifecyclePolicyCommand, DLMClient, DeleteLifecyclePolicyCommand as DeleteLifecyclePolicyCommand$1, GetLifecyclePoliciesCommand, GetLifecyclePolicyCommand as GetLifecyclePolicyCommand$1, ResourceNotFoundException as ResourceNotFoundException$12, TagResourceCommand as TagResourceCommand$
|
|
67
|
-
import { CreateVectorBucketCommand, DeleteIndexCommand, DeleteVectorBucketCommand, GetVectorBucketCommand, ListIndexesCommand, ListTagsForResourceCommand as ListTagsForResourceCommand$
|
|
68
|
-
import { CreateNamespaceCommand, CreateTableBucketCommand, CreateTableCommand as CreateTableCommand$2, DeleteNamespaceCommand as DeleteNamespaceCommand$1, DeleteTableBucketCommand, DeleteTableCommand as DeleteTableCommand$2, GetTableBucketCommand, GetTableCommand as GetTableCommand$1, ListNamespacesCommand as ListNamespacesCommand$1, ListTableBucketsCommand, ListTablesCommand as ListTablesCommand$1, ListTagsForResourceCommand as ListTagsForResourceCommand$
|
|
65
|
+
import { CodeCommitClient, CreateRepositoryCommand as CreateRepositoryCommand$1, DeleteRepositoryCommand as DeleteRepositoryCommand$1, GetRepositoryCommand, ListRepositoriesCommand, ListTagsForResourceCommand as ListTagsForResourceCommand$19, RepositoryDoesNotExistException, TagResourceCommand as TagResourceCommand$18, UntagResourceCommand as UntagResourceCommand$18, UpdateRepositoryDescriptionCommand, UpdateRepositoryEncryptionKeyCommand, UpdateRepositoryNameCommand } from "@aws-sdk/client-codecommit";
|
|
66
|
+
import { CreateLifecyclePolicyCommand, DLMClient, DeleteLifecyclePolicyCommand as DeleteLifecyclePolicyCommand$1, GetLifecyclePoliciesCommand, GetLifecyclePolicyCommand as GetLifecyclePolicyCommand$1, ResourceNotFoundException as ResourceNotFoundException$12, TagResourceCommand as TagResourceCommand$19, UntagResourceCommand as UntagResourceCommand$19, UpdateLifecyclePolicyCommand } from "@aws-sdk/client-dlm";
|
|
67
|
+
import { CreateVectorBucketCommand, DeleteIndexCommand, DeleteVectorBucketCommand, GetVectorBucketCommand, ListIndexesCommand, ListTagsForResourceCommand as ListTagsForResourceCommand$20, ListVectorBucketsCommand, S3VectorsClient, TagResourceCommand as TagResourceCommand$20, UntagResourceCommand as UntagResourceCommand$20 } from "@aws-sdk/client-s3vectors";
|
|
68
|
+
import { CreateNamespaceCommand, CreateTableBucketCommand, CreateTableCommand as CreateTableCommand$2, DeleteNamespaceCommand as DeleteNamespaceCommand$1, DeleteTableBucketCommand, DeleteTableCommand as DeleteTableCommand$2, GetTableBucketCommand, GetTableCommand as GetTableCommand$1, ListNamespacesCommand as ListNamespacesCommand$1, ListTableBucketsCommand, ListTablesCommand as ListTablesCommand$1, ListTagsForResourceCommand as ListTagsForResourceCommand$21, NotFoundException as NotFoundException$6, S3TablesClient, TagResourceCommand as TagResourceCommand$21, UntagResourceCommand as UntagResourceCommand$21 } from "@aws-sdk/client-s3tables";
|
|
69
69
|
import { Document, Pair, Scalar, YAMLMap, YAMLSeq, parse as parse$1, stringify } from "yaml";
|
|
70
70
|
import { createLocalStartAgentCoreCommand, createLocalStartCloudFrontCommand, createLocalStateProvider, getEmbedConfig, isCfnFlagPresent, listTargets, rejectExplicitCfnStackWithMultipleStacks, resolveCfnFallbackRegion, setEmbedConfig, substituteAgainstState, substituteAgainstStateAsync, substituteEnvVarsFromState, substituteEnvVarsFromStateAsync } from "cdk-local";
|
|
71
71
|
import { A2A_CONTAINER_PORT, A2A_PATH, AGENTCORE_A2A_PROTOCOL, AGENTCORE_AGUI_PROTOCOL, AGENTCORE_MCP_PROTOCOL, ConnectionRegistry, EcsTaskResolutionError, HOST_GATEWAY_MIN_VERSION, LocalInvokeBuildError, MCP_CONTAINER_PORT, MCP_PATH, a2aInvokeOnce, addAlbSpecificOptions, addCommonEcsServiceOptions, addStartServiceSpecificOptions, albStrategy, architectureToPlatform, attachAuthorizers, attachStageContext, availableApiIdentifiers, bufferToBody, buildAgentCoreCodeImage, buildCognitoJwksUrl, buildConnectEvent, buildContainerImage, buildCorsConfigByApiId, buildCorsConfigFromCloudFrontChain, buildDisconnectEvent, buildJwksUrlFromIssuer, buildMessageEvent, buildMgmtEndpointEnvUrl, buildStageMap, classifySourceChange, createAuthorizerCache, createFileWatcher, createFileWatcher as createFileWatcher$1, createJwksCache, createWatchPredicates, defaultCredentialsLoader, derivePseudoParametersFromRegion, discoverRoutes, discoverWebSocketApis, downloadAndExtractS3Bundle, filterRoutesByApiIdentifier, groupRoutesByServer, handleConnectionsRequest, invokeAgentCore, invokeAgentCoreWs, materializeLayerFromArn, mcpInvokeOnce, parseConnectionsPath, parseSelectionExpressionPath, pickAgentCoreCandidateStack, pickAgentCoreCandidateStack as pickAgentCoreCandidateStack$1, probeHostGatewaySupport, readMtlsMaterialsFromDisk, resolveAgentCoreTarget, resolveEnvVars, resolveHostGatewayExtraHosts, resolveRuntimeCodeMountPath, resolveRuntimeFileExtension, resolveRuntimeImage, resolveSingleTarget, resolveWatchConfig, runEcsServiceEmulator, signAgentCoreInvocation, startApiServer, substituteImagePlaceholders, tryResolveImageFnJoin, verifyJwtViaDiscovery, waitForAgentCorePing } from "cdk-local/internal";
|
|
@@ -1888,7 +1888,7 @@ const FLUSH_INTERVAL_MS = 2e3;
|
|
|
1888
1888
|
const FLUSH_EVENT_THRESHOLD = 50;
|
|
1889
1889
|
/** Build-time cdkd version, with a dev fallback for non-built contexts. */
|
|
1890
1890
|
function getCdkdVersion() {
|
|
1891
|
-
return "0.
|
|
1891
|
+
return "0.243.0";
|
|
1892
1892
|
}
|
|
1893
1893
|
/**
|
|
1894
1894
|
* Generate a time-sortable unique run id, e.g.
|
|
@@ -20364,37 +20364,43 @@ var CloudFrontDistributionProvider = class {
|
|
|
20364
20364
|
};
|
|
20365
20365
|
|
|
20366
20366
|
//#endregion
|
|
20367
|
-
//#region src/provisioning/providers/agentcore-
|
|
20367
|
+
//#region src/provisioning/providers/agentcore-case-convert.ts
|
|
20368
20368
|
/**
|
|
20369
|
-
*
|
|
20369
|
+
* PascalCase <-> camelCase key conversion helpers shared by the
|
|
20370
|
+
* BedrockAgentCore SDK Providers (`agentcore-runtime-provider.ts`,
|
|
20371
|
+
* `agentcore-browser-provider.ts`, `agentcore-code-interpreter-provider.ts`,
|
|
20372
|
+
* `agentcore-evaluator-provider.ts`).
|
|
20370
20373
|
*
|
|
20371
|
-
*
|
|
20372
|
-
*
|
|
20373
|
-
*
|
|
20374
|
-
*
|
|
20375
|
-
*
|
|
20376
|
-
*
|
|
20377
|
-
* 6. CC API ClientToken caches the failure result, making it worse
|
|
20374
|
+
* CloudFormation templates carry PascalCase property keys while the
|
|
20375
|
+
* `bedrock-agentcore-control` SDK expects camelCase input shapes (and
|
|
20376
|
+
* returns camelCase output shapes). The BedrockAgentCore CFn schemas mirror
|
|
20377
|
+
* the SDK shapes 1:1 modulo casing, so a mechanical first-letter case flip
|
|
20378
|
+
* round-trips cleanly — including union members (`LlmAsAJudge` <->
|
|
20379
|
+
* `llmAsAJudge`, `CodeBased` <-> `codeBased`).
|
|
20378
20380
|
*
|
|
20379
|
-
*
|
|
20380
|
-
* -
|
|
20381
|
-
* -
|
|
20382
|
-
*
|
|
20383
|
-
* -
|
|
20381
|
+
* `preserveKeys` opts specific keys out of DEEP conversion: the key itself
|
|
20382
|
+
* is still case-flipped, but its VALUE subtree is copied verbatim. Needed
|
|
20383
|
+
* for free-form JSON document properties whose inner keys are user-defined
|
|
20384
|
+
* model/request fields, NOT CFn property names — e.g. the Evaluator's
|
|
20385
|
+
* `AdditionalModelRequestFields` (model-specific request fields like
|
|
20386
|
+
* `top_k` that must reach the service byte-identical).
|
|
20384
20387
|
*/
|
|
20385
20388
|
/**
|
|
20386
20389
|
* Recursively convert PascalCase object keys to camelCase.
|
|
20387
20390
|
* Only converts keys of plain objects; string values, arrays of strings,
|
|
20388
20391
|
* and other primitives are left untouched.
|
|
20392
|
+
*
|
|
20393
|
+
* @param preserveKeys - PascalCase key names whose value subtree is copied
|
|
20394
|
+
* verbatim (the key itself is still converted to camelCase).
|
|
20389
20395
|
*/
|
|
20390
|
-
function pascalToCamelCaseKeys(value) {
|
|
20396
|
+
function pascalToCamelCaseKeys(value, preserveKeys) {
|
|
20391
20397
|
if (value === null || value === void 0) return value;
|
|
20392
|
-
if (Array.isArray(value)) return value.map(pascalToCamelCaseKeys);
|
|
20398
|
+
if (Array.isArray(value)) return value.map((item) => pascalToCamelCaseKeys(item, preserveKeys));
|
|
20393
20399
|
if (typeof value === "object") {
|
|
20394
20400
|
const result = {};
|
|
20395
20401
|
for (const [key, val] of Object.entries(value)) {
|
|
20396
20402
|
const camelKey = key.charAt(0).toLowerCase() + key.slice(1);
|
|
20397
|
-
result[camelKey] = pascalToCamelCaseKeys(val);
|
|
20403
|
+
result[camelKey] = preserveKeys?.has(key) ? val : pascalToCamelCaseKeys(val, preserveKeys);
|
|
20398
20404
|
}
|
|
20399
20405
|
return result;
|
|
20400
20406
|
}
|
|
@@ -20402,22 +20408,46 @@ function pascalToCamelCaseKeys(value) {
|
|
|
20402
20408
|
}
|
|
20403
20409
|
/**
|
|
20404
20410
|
* Recursively convert camelCase object keys to PascalCase. Inverse of
|
|
20405
|
-
* `pascalToCamelCaseKeys`. Used by `readCurrentState` to
|
|
20406
|
-
* SDK responses back into the CFn property names cdkd state
|
|
20411
|
+
* `pascalToCamelCaseKeys`. Used by `readCurrentState` implementations to
|
|
20412
|
+
* re-shape AWS SDK responses back into the CFn property names cdkd state
|
|
20413
|
+
* stores.
|
|
20414
|
+
*
|
|
20415
|
+
* @param preserveKeys - camelCase key names whose value subtree is copied
|
|
20416
|
+
* verbatim (the key itself is still converted to PascalCase).
|
|
20407
20417
|
*/
|
|
20408
|
-
function camelToPascalCaseKeys(value) {
|
|
20418
|
+
function camelToPascalCaseKeys(value, preserveKeys) {
|
|
20409
20419
|
if (value === null || value === void 0) return value;
|
|
20410
|
-
if (Array.isArray(value)) return value.map(camelToPascalCaseKeys);
|
|
20420
|
+
if (Array.isArray(value)) return value.map((item) => camelToPascalCaseKeys(item, preserveKeys));
|
|
20411
20421
|
if (typeof value === "object") {
|
|
20412
20422
|
const result = {};
|
|
20413
20423
|
for (const [key, val] of Object.entries(value)) {
|
|
20414
20424
|
const pascalKey = key.charAt(0).toUpperCase() + key.slice(1);
|
|
20415
|
-
result[pascalKey] = camelToPascalCaseKeys(val);
|
|
20425
|
+
result[pascalKey] = preserveKeys?.has(key) ? val : camelToPascalCaseKeys(val, preserveKeys);
|
|
20416
20426
|
}
|
|
20417
20427
|
return result;
|
|
20418
20428
|
}
|
|
20419
20429
|
return value;
|
|
20420
20430
|
}
|
|
20431
|
+
|
|
20432
|
+
//#endregion
|
|
20433
|
+
//#region src/provisioning/providers/agentcore-runtime-provider.ts
|
|
20434
|
+
/**
|
|
20435
|
+
* SDK Provider for AWS::BedrockAgentCore::Runtime
|
|
20436
|
+
*
|
|
20437
|
+
* Uses direct SDK calls instead of Cloud Control API because:
|
|
20438
|
+
* 1. CC API CREATE is async - it returns IN_PROGRESS, then polls for completion
|
|
20439
|
+
* 2. IAM role propagation to BedrockAgentCore is very slow (30-60+ seconds)
|
|
20440
|
+
* 3. When CC API polling returns FAILED (role validation), cdkd retries CREATE
|
|
20441
|
+
* 4. But the first CREATE actually succeeded asynchronously in the background
|
|
20442
|
+
* 5. The retry then fails with "already exists"
|
|
20443
|
+
* 6. CC API ClientToken caches the failure result, making it worse
|
|
20444
|
+
*
|
|
20445
|
+
* With direct SDK calls, we can:
|
|
20446
|
+
* - Call CreateAgentRuntime synchronously
|
|
20447
|
+
* - Get immediate error responses for IAM propagation issues
|
|
20448
|
+
* - Retry with proper exponential backoff
|
|
20449
|
+
* - Avoid the async CREATE + polling + retry conflict
|
|
20450
|
+
*/
|
|
20421
20451
|
/**
|
|
20422
20452
|
* AWS BedrockAgentCore Runtime Provider
|
|
20423
20453
|
*
|
|
@@ -20627,6 +20657,502 @@ var AgentCoreRuntimeProvider = class {
|
|
|
20627
20657
|
}
|
|
20628
20658
|
};
|
|
20629
20659
|
|
|
20660
|
+
//#endregion
|
|
20661
|
+
//#region src/provisioning/providers/agentcore-browser-provider.ts
|
|
20662
|
+
/**
|
|
20663
|
+
* SDK Provider for AWS::BedrockAgentCore::Browser (adopt-only singleton).
|
|
20664
|
+
*
|
|
20665
|
+
* The CloudFormation registry schema declares this type as a READ-ONLY
|
|
20666
|
+
* resource "representing the default service-managed browser"
|
|
20667
|
+
* (`aws.browser.v1`): every schema property (`BrowserArn` / `BrowserId` /
|
|
20668
|
+
* `Name` / `Status`) is read-only, the only handlers are read/list, and the
|
|
20669
|
+
* `BrowserId` pattern is hard-locked to `^aws\.browser\.v1$`. The registry
|
|
20670
|
+
* marks it `NON_PROVISIONABLE`, so Cloud Control cannot deploy it and cdkd's
|
|
20671
|
+
* pre-flight used to reject it (issue #1038).
|
|
20672
|
+
*
|
|
20673
|
+
* cdkd therefore provisions it as an ADOPT operation, not a create:
|
|
20674
|
+
* - `create` verifies the AWS-managed default browser exists in the deploy
|
|
20675
|
+
* region via `GetBrowser` and records its ARN as the physical id (the
|
|
20676
|
+
* type's primaryIdentifier, matching CFn `Ref` semantics).
|
|
20677
|
+
* - `update` is a no-op (no writable properties exist).
|
|
20678
|
+
* - `delete` is a no-op — the default browser is AWS-owned and must never
|
|
20679
|
+
* be deleted when a stack is destroyed.
|
|
20680
|
+
* - `getAttribute` serves the read-only attributes live from `GetBrowser`.
|
|
20681
|
+
*
|
|
20682
|
+
* Custom, user-created browsers are a DIFFERENT CFn type
|
|
20683
|
+
* (`AWS::BedrockAgentCore::BrowserCustom`, FULLY_MUTABLE) which Cloud
|
|
20684
|
+
* Control handles; the `CreateBrowser` / `DeleteBrowser` control-plane ops
|
|
20685
|
+
* belong to that type's lifecycle, not this one's.
|
|
20686
|
+
*/
|
|
20687
|
+
/** The only valid browser id for this type per the CFn schema pattern. */
|
|
20688
|
+
const DEFAULT_BROWSER_ID = "aws.browser.v1";
|
|
20689
|
+
/**
|
|
20690
|
+
* AWS BedrockAgentCore default-Browser Provider (adopt-only).
|
|
20691
|
+
*/
|
|
20692
|
+
var AgentCoreBrowserProvider = class {
|
|
20693
|
+
client;
|
|
20694
|
+
logger = getLogger().child("AgentCoreBrowserProvider");
|
|
20695
|
+
handledProperties = new Map([["AWS::BedrockAgentCore::Browser", /* @__PURE__ */ new Set([])]]);
|
|
20696
|
+
constructor() {
|
|
20697
|
+
const awsClients = getAwsClients();
|
|
20698
|
+
this.client = awsClients.bedrockAgentCoreControl;
|
|
20699
|
+
}
|
|
20700
|
+
/**
|
|
20701
|
+
* "Create" = adopt the AWS-managed default browser: verify it exists in
|
|
20702
|
+
* the deploy region and record its ARN (the CFn primaryIdentifier) as the
|
|
20703
|
+
* physical id. Nothing is created in AWS.
|
|
20704
|
+
*/
|
|
20705
|
+
async create(logicalId, resourceType, _properties) {
|
|
20706
|
+
this.logger.debug(`Adopting AWS-managed default browser for ${logicalId}`);
|
|
20707
|
+
try {
|
|
20708
|
+
const response = await this.client.send(new GetBrowserCommand({ browserId: DEFAULT_BROWSER_ID }));
|
|
20709
|
+
const browserArn = response.browserArn;
|
|
20710
|
+
this.logger.debug(`Adopted default browser ${DEFAULT_BROWSER_ID} (${browserArn})`);
|
|
20711
|
+
return {
|
|
20712
|
+
physicalId: browserArn,
|
|
20713
|
+
attributes: {
|
|
20714
|
+
BrowserArn: browserArn,
|
|
20715
|
+
BrowserId: response.browserId ?? "aws.browser.v1",
|
|
20716
|
+
Name: response.name ?? "",
|
|
20717
|
+
Status: response.status ?? ""
|
|
20718
|
+
}
|
|
20719
|
+
};
|
|
20720
|
+
} catch (error) {
|
|
20721
|
+
const cause = error instanceof Error ? error : void 0;
|
|
20722
|
+
throw new ProvisioningError(`Failed to adopt the AWS-managed default browser for ${logicalId}: ${error instanceof Error ? error.message : String(error)}. Bedrock AgentCore may not be available in this region.`, resourceType, logicalId, void 0, cause);
|
|
20723
|
+
}
|
|
20724
|
+
}
|
|
20725
|
+
/**
|
|
20726
|
+
* Every property on this type is read-only, so there is nothing to
|
|
20727
|
+
* update — keep the existing physical id.
|
|
20728
|
+
*/
|
|
20729
|
+
async update(logicalId, physicalId, _resourceType, _properties, _previousProperties) {
|
|
20730
|
+
this.logger.debug(`No-op update for default browser ${logicalId}`);
|
|
20731
|
+
return {
|
|
20732
|
+
physicalId,
|
|
20733
|
+
wasReplaced: false,
|
|
20734
|
+
attributes: {}
|
|
20735
|
+
};
|
|
20736
|
+
}
|
|
20737
|
+
/**
|
|
20738
|
+
* The default browser is AWS-owned; destroying a stack must never delete
|
|
20739
|
+
* it. Pure no-op.
|
|
20740
|
+
*/
|
|
20741
|
+
async delete(logicalId, _physicalId, _resourceType) {
|
|
20742
|
+
this.logger.debug(`No-op delete for AWS-managed default browser ${logicalId}`);
|
|
20743
|
+
}
|
|
20744
|
+
/**
|
|
20745
|
+
* Get resource attribute (for Fn::GetAtt resolution). The CFn read-only
|
|
20746
|
+
* attribute set is BrowserArn / BrowserId / Name / Status.
|
|
20747
|
+
*/
|
|
20748
|
+
async getAttribute(physicalId, _resourceType, attributeName) {
|
|
20749
|
+
if (attributeName === "BrowserArn") return physicalId;
|
|
20750
|
+
if (attributeName === "BrowserId") return DEFAULT_BROWSER_ID;
|
|
20751
|
+
if (attributeName === "Name" || attributeName === "Status") {
|
|
20752
|
+
const response = await this.client.send(new GetBrowserCommand({ browserId: DEFAULT_BROWSER_ID }));
|
|
20753
|
+
return attributeName === "Name" ? response.name : response.status;
|
|
20754
|
+
}
|
|
20755
|
+
throw new Error(`Unsupported attribute: ${attributeName} for AWS::BedrockAgentCore::Browser`);
|
|
20756
|
+
}
|
|
20757
|
+
/** No managed properties → nothing can drift. */
|
|
20758
|
+
async readCurrentState() {
|
|
20759
|
+
return {};
|
|
20760
|
+
}
|
|
20761
|
+
/**
|
|
20762
|
+
* Import: the type is a singleton pointing at the AWS-managed default
|
|
20763
|
+
* browser, so auto-lookup is trivial — resolve it live via `GetBrowser`
|
|
20764
|
+
* (no `--resource` override needed; a supplied override is ignored in
|
|
20765
|
+
* favor of the live ARN, which is the only valid physical id).
|
|
20766
|
+
*/
|
|
20767
|
+
async import(_input) {
|
|
20768
|
+
const response = await this.client.send(new GetBrowserCommand({ browserId: DEFAULT_BROWSER_ID }));
|
|
20769
|
+
return {
|
|
20770
|
+
physicalId: response.browserArn,
|
|
20771
|
+
attributes: {
|
|
20772
|
+
BrowserArn: response.browserArn,
|
|
20773
|
+
BrowserId: response.browserId ?? "aws.browser.v1",
|
|
20774
|
+
Name: response.name ?? "",
|
|
20775
|
+
Status: response.status ?? ""
|
|
20776
|
+
}
|
|
20777
|
+
};
|
|
20778
|
+
}
|
|
20779
|
+
};
|
|
20780
|
+
|
|
20781
|
+
//#endregion
|
|
20782
|
+
//#region src/provisioning/providers/agentcore-code-interpreter-provider.ts
|
|
20783
|
+
/**
|
|
20784
|
+
* SDK Provider for AWS::BedrockAgentCore::CodeInterpreter (adopt-only
|
|
20785
|
+
* singleton).
|
|
20786
|
+
*
|
|
20787
|
+
* The CloudFormation registry schema declares this type as a READ-ONLY
|
|
20788
|
+
* resource "representing the AWS-managed default code interpreter
|
|
20789
|
+
* (aws.codeinterpreter.v1)": every schema property (`CodeInterpreterArn` /
|
|
20790
|
+
* `CodeInterpreterId` / `Status`) is read-only, the only handlers are
|
|
20791
|
+
* read/list, and the `CodeInterpreterId` pattern is hard-locked to
|
|
20792
|
+
* `^aws\.codeinterpreter\.v1$`. The registry marks it `NON_PROVISIONABLE`,
|
|
20793
|
+
* so Cloud Control cannot deploy it and cdkd's pre-flight used to reject it
|
|
20794
|
+
* (issue #1039).
|
|
20795
|
+
*
|
|
20796
|
+
* cdkd therefore provisions it as an ADOPT operation, not a create — see
|
|
20797
|
+
* `agentcore-browser-provider.ts` (the exactly-parallel sibling) for the
|
|
20798
|
+
* full rationale. Custom, user-created code interpreters are a DIFFERENT
|
|
20799
|
+
* CFn type (`AWS::BedrockAgentCore::CodeInterpreterCustom`, FULLY_MUTABLE)
|
|
20800
|
+
* which Cloud Control handles.
|
|
20801
|
+
*/
|
|
20802
|
+
/** The only valid code interpreter id for this type per the CFn schema pattern. */
|
|
20803
|
+
const DEFAULT_CODE_INTERPRETER_ID = "aws.codeinterpreter.v1";
|
|
20804
|
+
/**
|
|
20805
|
+
* AWS BedrockAgentCore default-CodeInterpreter Provider (adopt-only).
|
|
20806
|
+
*/
|
|
20807
|
+
var AgentCoreCodeInterpreterProvider = class {
|
|
20808
|
+
client;
|
|
20809
|
+
logger = getLogger().child("AgentCoreCodeInterpreterProvider");
|
|
20810
|
+
handledProperties = new Map([["AWS::BedrockAgentCore::CodeInterpreter", /* @__PURE__ */ new Set([])]]);
|
|
20811
|
+
constructor() {
|
|
20812
|
+
const awsClients = getAwsClients();
|
|
20813
|
+
this.client = awsClients.bedrockAgentCoreControl;
|
|
20814
|
+
}
|
|
20815
|
+
/**
|
|
20816
|
+
* "Create" = adopt the AWS-managed default code interpreter: verify it
|
|
20817
|
+
* exists in the deploy region and record its ARN (the CFn
|
|
20818
|
+
* primaryIdentifier) as the physical id. Nothing is created in AWS.
|
|
20819
|
+
*/
|
|
20820
|
+
async create(logicalId, resourceType, _properties) {
|
|
20821
|
+
this.logger.debug(`Adopting AWS-managed default code interpreter for ${logicalId}`);
|
|
20822
|
+
try {
|
|
20823
|
+
const response = await this.client.send(new GetCodeInterpreterCommand({ codeInterpreterId: DEFAULT_CODE_INTERPRETER_ID }));
|
|
20824
|
+
const codeInterpreterArn = response.codeInterpreterArn;
|
|
20825
|
+
this.logger.debug(`Adopted default code interpreter ${DEFAULT_CODE_INTERPRETER_ID} (${codeInterpreterArn})`);
|
|
20826
|
+
return {
|
|
20827
|
+
physicalId: codeInterpreterArn,
|
|
20828
|
+
attributes: {
|
|
20829
|
+
CodeInterpreterArn: codeInterpreterArn,
|
|
20830
|
+
CodeInterpreterId: response.codeInterpreterId ?? "aws.codeinterpreter.v1",
|
|
20831
|
+
Status: response.status ?? ""
|
|
20832
|
+
}
|
|
20833
|
+
};
|
|
20834
|
+
} catch (error) {
|
|
20835
|
+
const cause = error instanceof Error ? error : void 0;
|
|
20836
|
+
throw new ProvisioningError(`Failed to adopt the AWS-managed default code interpreter for ${logicalId}: ${error instanceof Error ? error.message : String(error)}. Bedrock AgentCore may not be available in this region.`, resourceType, logicalId, void 0, cause);
|
|
20837
|
+
}
|
|
20838
|
+
}
|
|
20839
|
+
/**
|
|
20840
|
+
* Every property on this type is read-only, so there is nothing to
|
|
20841
|
+
* update — keep the existing physical id.
|
|
20842
|
+
*/
|
|
20843
|
+
async update(logicalId, physicalId, _resourceType, _properties, _previousProperties) {
|
|
20844
|
+
this.logger.debug(`No-op update for default code interpreter ${logicalId}`);
|
|
20845
|
+
return {
|
|
20846
|
+
physicalId,
|
|
20847
|
+
wasReplaced: false,
|
|
20848
|
+
attributes: {}
|
|
20849
|
+
};
|
|
20850
|
+
}
|
|
20851
|
+
/**
|
|
20852
|
+
* The default code interpreter is AWS-owned; destroying a stack must
|
|
20853
|
+
* never delete it. Pure no-op.
|
|
20854
|
+
*/
|
|
20855
|
+
async delete(logicalId, _physicalId, _resourceType) {
|
|
20856
|
+
this.logger.debug(`No-op delete for AWS-managed default code interpreter ${logicalId}`);
|
|
20857
|
+
}
|
|
20858
|
+
/**
|
|
20859
|
+
* Get resource attribute (for Fn::GetAtt resolution). The CFn read-only
|
|
20860
|
+
* attribute set is CodeInterpreterArn / CodeInterpreterId / Status.
|
|
20861
|
+
*/
|
|
20862
|
+
async getAttribute(physicalId, _resourceType, attributeName) {
|
|
20863
|
+
if (attributeName === "CodeInterpreterArn") return physicalId;
|
|
20864
|
+
if (attributeName === "CodeInterpreterId") return DEFAULT_CODE_INTERPRETER_ID;
|
|
20865
|
+
if (attributeName === "Status") return (await this.client.send(new GetCodeInterpreterCommand({ codeInterpreterId: DEFAULT_CODE_INTERPRETER_ID }))).status;
|
|
20866
|
+
throw new Error(`Unsupported attribute: ${attributeName} for AWS::BedrockAgentCore::CodeInterpreter`);
|
|
20867
|
+
}
|
|
20868
|
+
/** No managed properties → nothing can drift. */
|
|
20869
|
+
async readCurrentState() {
|
|
20870
|
+
return {};
|
|
20871
|
+
}
|
|
20872
|
+
/**
|
|
20873
|
+
* Import: the type is a singleton pointing at the AWS-managed default
|
|
20874
|
+
* code interpreter, so auto-lookup is trivial — resolve it live via
|
|
20875
|
+
* `GetCodeInterpreter` (no `--resource` override needed; a supplied
|
|
20876
|
+
* override is ignored in favor of the live ARN, which is the only valid
|
|
20877
|
+
* physical id).
|
|
20878
|
+
*/
|
|
20879
|
+
async import(_input) {
|
|
20880
|
+
const response = await this.client.send(new GetCodeInterpreterCommand({ codeInterpreterId: DEFAULT_CODE_INTERPRETER_ID }));
|
|
20881
|
+
return {
|
|
20882
|
+
physicalId: response.codeInterpreterArn,
|
|
20883
|
+
attributes: {
|
|
20884
|
+
CodeInterpreterArn: response.codeInterpreterArn,
|
|
20885
|
+
CodeInterpreterId: response.codeInterpreterId ?? "aws.codeinterpreter.v1",
|
|
20886
|
+
Status: response.status ?? ""
|
|
20887
|
+
}
|
|
20888
|
+
};
|
|
20889
|
+
}
|
|
20890
|
+
};
|
|
20891
|
+
|
|
20892
|
+
//#endregion
|
|
20893
|
+
//#region src/provisioning/providers/agentcore-evaluator-provider.ts
|
|
20894
|
+
/**
|
|
20895
|
+
* SDK Provider for AWS::BedrockAgentCore::Evaluator
|
|
20896
|
+
*
|
|
20897
|
+
* Provisions custom evaluators (LLM-as-a-Judge or code-based Lambda
|
|
20898
|
+
* configs) for AgentCore quality evaluations via the
|
|
20899
|
+
* `bedrock-agentcore-control` control plane (issue #1058).
|
|
20900
|
+
*
|
|
20901
|
+
* Uses direct SDK calls (`CreateEvaluator` / `UpdateEvaluator` /
|
|
20902
|
+
* `DeleteEvaluator` / `GetEvaluator`) instead of Cloud Control for the same
|
|
20903
|
+
* reasons as the sibling `agentcore-runtime-provider.ts`: synchronous
|
|
20904
|
+
* responses, immediate error surfaces, and no CC-API polling overhead.
|
|
20905
|
+
*
|
|
20906
|
+
* CFn <-> SDK mapping notes (verified against the registry schema and
|
|
20907
|
+
* `@aws-sdk/client-bedrock-agentcore-control` typings):
|
|
20908
|
+
* - The physical id is the Evaluator ARN (the type's primaryIdentifier, so
|
|
20909
|
+
* `Ref` matches CloudFormation); the SDK ops take the evaluator ID, which
|
|
20910
|
+
* is the ARN's final `evaluator/<id>` path segment.
|
|
20911
|
+
* - `EvaluatorConfig` is a union (`LlmAsAJudge` | `CodeBased`) whose member
|
|
20912
|
+
* and field names map 1:1 to the SDK's camelCase shapes — EXCEPT the
|
|
20913
|
+
* free-form `AdditionalModelRequestFields` document, whose inner keys are
|
|
20914
|
+
* model-specific request fields (e.g. `top_k`) and must be passed
|
|
20915
|
+
* verbatim (see `agentcore-case-convert.ts`).
|
|
20916
|
+
* - CFn `Tags` is a `[{Key, Value}]` list; the SDK's create/tag ops take a
|
|
20917
|
+
* `Record<string, string>` map. `UpdateEvaluator` does not accept tags,
|
|
20918
|
+
* so tag changes go through `TagResource` / `UntagResource`.
|
|
20919
|
+
* - `EvaluatorName` is the type's only createOnly property; a name change
|
|
20920
|
+
* is classified as replacement by the deploy engine's registry-schema
|
|
20921
|
+
* createOnly fallback (`create-only-properties.ts`) — no per-provider
|
|
20922
|
+
* replacement logic needed.
|
|
20923
|
+
*/
|
|
20924
|
+
/**
|
|
20925
|
+
* The `EvaluatorConfig` subtree keys whose values are free-form JSON
|
|
20926
|
+
* documents (user/model-defined keys) that must NOT be case-converted.
|
|
20927
|
+
*/
|
|
20928
|
+
const CFN_PRESERVE_KEYS = new Set(["AdditionalModelRequestFields"]);
|
|
20929
|
+
const SDK_PRESERVE_KEYS = new Set(["additionalModelRequestFields"]);
|
|
20930
|
+
/**
|
|
20931
|
+
* Extract the evaluator ID from an evaluator ARN
|
|
20932
|
+
* (`arn:...:evaluator/<id>` → `<id>`). Falls back to the input verbatim
|
|
20933
|
+
* when it does not look like an ARN (already an ID).
|
|
20934
|
+
*/
|
|
20935
|
+
function evaluatorIdFromArn(arnOrId) {
|
|
20936
|
+
const idx = arnOrId.indexOf(":evaluator/");
|
|
20937
|
+
return idx >= 0 ? arnOrId.slice(idx + 11) : arnOrId;
|
|
20938
|
+
}
|
|
20939
|
+
/** CFn `[{Key, Value}]` tag list → SDK `Record<string, string>` map. */
|
|
20940
|
+
function cfnTagListToMap(tags) {
|
|
20941
|
+
const map = {};
|
|
20942
|
+
if (Array.isArray(tags)) {
|
|
20943
|
+
for (const tag of tags) if (tag !== null && typeof tag === "object" && typeof tag["Key"] === "string") map[tag["Key"]] = String(tag["Value"] ?? "");
|
|
20944
|
+
}
|
|
20945
|
+
return map;
|
|
20946
|
+
}
|
|
20947
|
+
/** SDK `Record<string, string>` tag map → CFn `[{Key, Value}]` list. */
|
|
20948
|
+
function tagMapToCfnList(tags) {
|
|
20949
|
+
return Object.entries(tags).map(([Key, Value]) => ({
|
|
20950
|
+
Key,
|
|
20951
|
+
Value
|
|
20952
|
+
}));
|
|
20953
|
+
}
|
|
20954
|
+
/**
|
|
20955
|
+
* AWS BedrockAgentCore Evaluator Provider
|
|
20956
|
+
*/
|
|
20957
|
+
var AgentCoreEvaluatorProvider = class {
|
|
20958
|
+
client;
|
|
20959
|
+
logger = getLogger().child("AgentCoreEvaluatorProvider");
|
|
20960
|
+
handledProperties = new Map([["AWS::BedrockAgentCore::Evaluator", new Set([
|
|
20961
|
+
"EvaluatorName",
|
|
20962
|
+
"Description",
|
|
20963
|
+
"EvaluatorConfig",
|
|
20964
|
+
"Level",
|
|
20965
|
+
"KmsKeyArn",
|
|
20966
|
+
"Tags"
|
|
20967
|
+
])]]);
|
|
20968
|
+
constructor() {
|
|
20969
|
+
const awsClients = getAwsClients();
|
|
20970
|
+
this.client = awsClients.bedrockAgentCoreControl;
|
|
20971
|
+
}
|
|
20972
|
+
/**
|
|
20973
|
+
* Create a BedrockAgentCore Evaluator
|
|
20974
|
+
*/
|
|
20975
|
+
async create(logicalId, resourceType, properties) {
|
|
20976
|
+
this.logger.debug(`Creating BedrockAgentCore Evaluator ${logicalId}`);
|
|
20977
|
+
const evaluatorName = properties["EvaluatorName"];
|
|
20978
|
+
if (!evaluatorName) throw new ProvisioningError(`EvaluatorName is required for ${logicalId}`, resourceType, logicalId);
|
|
20979
|
+
if (properties["EvaluatorConfig"] === void 0) throw new ProvisioningError(`EvaluatorConfig is required for ${logicalId}`, resourceType, logicalId);
|
|
20980
|
+
if (properties["Level"] === void 0) throw new ProvisioningError(`Level is required for ${logicalId}`, resourceType, logicalId);
|
|
20981
|
+
try {
|
|
20982
|
+
const input = {
|
|
20983
|
+
evaluatorName,
|
|
20984
|
+
evaluatorConfig: pascalToCamelCaseKeys(properties["EvaluatorConfig"], CFN_PRESERVE_KEYS),
|
|
20985
|
+
level: properties["Level"]
|
|
20986
|
+
};
|
|
20987
|
+
if (properties["Description"] !== void 0) input["description"] = properties["Description"];
|
|
20988
|
+
if (properties["KmsKeyArn"] !== void 0) input["kmsKeyArn"] = properties["KmsKeyArn"];
|
|
20989
|
+
if (properties["Tags"] !== void 0) {
|
|
20990
|
+
const tags = cfnTagListToMap(properties["Tags"]);
|
|
20991
|
+
if (Object.keys(tags).length > 0) input["tags"] = tags;
|
|
20992
|
+
}
|
|
20993
|
+
const response = await this.client.send(new CreateEvaluatorCommand(input));
|
|
20994
|
+
const evaluatorArn = response.evaluatorArn;
|
|
20995
|
+
const evaluatorId = response.evaluatorId;
|
|
20996
|
+
this.logger.debug(`Created BedrockAgentCore Evaluator: ${evaluatorId} (${evaluatorArn})`);
|
|
20997
|
+
return {
|
|
20998
|
+
physicalId: evaluatorArn,
|
|
20999
|
+
attributes: {
|
|
21000
|
+
EvaluatorArn: evaluatorArn,
|
|
21001
|
+
EvaluatorId: evaluatorId,
|
|
21002
|
+
Status: response.status ?? "",
|
|
21003
|
+
CreatedAt: response.createdAt?.toISOString() ?? ""
|
|
21004
|
+
}
|
|
21005
|
+
};
|
|
21006
|
+
} catch (error) {
|
|
21007
|
+
const cause = error instanceof Error ? error : void 0;
|
|
21008
|
+
throw new ProvisioningError(`Failed to create BedrockAgentCore Evaluator ${logicalId}: ${error instanceof Error ? error.message : String(error)}`, resourceType, logicalId, void 0, cause);
|
|
21009
|
+
}
|
|
21010
|
+
}
|
|
21011
|
+
/**
|
|
21012
|
+
* Update a BedrockAgentCore Evaluator.
|
|
21013
|
+
*
|
|
21014
|
+
* `UpdateEvaluator` covers Description / EvaluatorConfig / Level /
|
|
21015
|
+
* KmsKeyArn; tag changes are applied via TagResource / UntagResource
|
|
21016
|
+
* (the update op does not accept tags). `EvaluatorName` is createOnly —
|
|
21017
|
+
* the deploy engine replaces the resource instead of calling this.
|
|
21018
|
+
*/
|
|
21019
|
+
async update(logicalId, physicalId, resourceType, properties, previousProperties) {
|
|
21020
|
+
this.logger.debug(`Updating BedrockAgentCore Evaluator ${logicalId}: ${physicalId}`);
|
|
21021
|
+
try {
|
|
21022
|
+
const input = { evaluatorId: evaluatorIdFromArn(physicalId) };
|
|
21023
|
+
if (properties["Description"] !== void 0) input["description"] = properties["Description"];
|
|
21024
|
+
if (properties["EvaluatorConfig"] !== void 0) input["evaluatorConfig"] = pascalToCamelCaseKeys(properties["EvaluatorConfig"], CFN_PRESERVE_KEYS);
|
|
21025
|
+
if (properties["Level"] !== void 0) input["level"] = properties["Level"];
|
|
21026
|
+
if (properties["KmsKeyArn"] !== void 0) input["kmsKeyArn"] = properties["KmsKeyArn"];
|
|
21027
|
+
const response = await this.client.send(new UpdateEvaluatorCommand(input));
|
|
21028
|
+
await this.syncTags(physicalId, properties["Tags"], previousProperties["Tags"]);
|
|
21029
|
+
const evaluatorArn = response.evaluatorArn ?? physicalId;
|
|
21030
|
+
this.logger.debug(`Successfully updated BedrockAgentCore Evaluator ${logicalId}`);
|
|
21031
|
+
return {
|
|
21032
|
+
physicalId: evaluatorArn,
|
|
21033
|
+
wasReplaced: false,
|
|
21034
|
+
attributes: {
|
|
21035
|
+
EvaluatorArn: evaluatorArn,
|
|
21036
|
+
EvaluatorId: response.evaluatorId ?? evaluatorIdFromArn(evaluatorArn),
|
|
21037
|
+
Status: response.status ?? "",
|
|
21038
|
+
UpdatedAt: response.updatedAt?.toISOString() ?? ""
|
|
21039
|
+
}
|
|
21040
|
+
};
|
|
21041
|
+
} catch (error) {
|
|
21042
|
+
const cause = error instanceof Error ? error : void 0;
|
|
21043
|
+
throw new ProvisioningError(`Failed to update BedrockAgentCore Evaluator ${logicalId}: ${error instanceof Error ? error.message : String(error)}`, resourceType, logicalId, physicalId, cause);
|
|
21044
|
+
}
|
|
21045
|
+
}
|
|
21046
|
+
/**
|
|
21047
|
+
* Apply CFn tag-list changes via TagResource / UntagResource.
|
|
21048
|
+
*/
|
|
21049
|
+
async syncTags(evaluatorArn, nextTagsRaw, previousTagsRaw) {
|
|
21050
|
+
const nextTags = cfnTagListToMap(nextTagsRaw);
|
|
21051
|
+
const previousTags = cfnTagListToMap(previousTagsRaw);
|
|
21052
|
+
const removedKeys = Object.keys(previousTags).filter((key) => !(key in nextTags));
|
|
21053
|
+
const upserts = {};
|
|
21054
|
+
for (const [key, value] of Object.entries(nextTags)) if (previousTags[key] !== value) upserts[key] = value;
|
|
21055
|
+
if (removedKeys.length > 0) await this.client.send(new UntagResourceCommand$9({
|
|
21056
|
+
resourceArn: evaluatorArn,
|
|
21057
|
+
tagKeys: removedKeys
|
|
21058
|
+
}));
|
|
21059
|
+
if (Object.keys(upserts).length > 0) await this.client.send(new TagResourceCommand$9({
|
|
21060
|
+
resourceArn: evaluatorArn,
|
|
21061
|
+
tags: upserts
|
|
21062
|
+
}));
|
|
21063
|
+
}
|
|
21064
|
+
/**
|
|
21065
|
+
* Delete a BedrockAgentCore Evaluator
|
|
21066
|
+
*/
|
|
21067
|
+
async delete(logicalId, physicalId, resourceType, _properties, context) {
|
|
21068
|
+
this.logger.debug(`Deleting BedrockAgentCore Evaluator ${logicalId}: ${physicalId}`);
|
|
21069
|
+
try {
|
|
21070
|
+
await this.client.send(new DeleteEvaluatorCommand({ evaluatorId: evaluatorIdFromArn(physicalId) }));
|
|
21071
|
+
this.logger.debug(`Successfully deleted BedrockAgentCore Evaluator ${logicalId}`);
|
|
21072
|
+
} catch (error) {
|
|
21073
|
+
if (error instanceof ResourceNotFoundException$5) {
|
|
21074
|
+
assertRegionMatch(await this.client.config.region(), context?.expectedRegion, resourceType, logicalId, physicalId);
|
|
21075
|
+
this.logger.debug(`Evaluator ${physicalId} does not exist, skipping deletion`);
|
|
21076
|
+
return;
|
|
21077
|
+
}
|
|
21078
|
+
const cause = error instanceof Error ? error : void 0;
|
|
21079
|
+
throw new ProvisioningError(`Failed to delete BedrockAgentCore Evaluator ${logicalId}: ${error instanceof Error ? error.message : String(error)}`, resourceType, logicalId, physicalId, cause);
|
|
21080
|
+
}
|
|
21081
|
+
}
|
|
21082
|
+
/**
|
|
21083
|
+
* Get resource attribute (for Fn::GetAtt resolution). The CFn read-only
|
|
21084
|
+
* attribute set is EvaluatorArn / EvaluatorId / Status / CreatedAt /
|
|
21085
|
+
* UpdatedAt.
|
|
21086
|
+
*/
|
|
21087
|
+
async getAttribute(physicalId, _resourceType, attributeName) {
|
|
21088
|
+
if (attributeName === "EvaluatorArn") return physicalId;
|
|
21089
|
+
if (attributeName === "EvaluatorId") return evaluatorIdFromArn(physicalId);
|
|
21090
|
+
if (attributeName === "Status" || attributeName === "CreatedAt" || attributeName === "UpdatedAt") {
|
|
21091
|
+
const response = await this.client.send(new GetEvaluatorCommand({ evaluatorId: evaluatorIdFromArn(physicalId) }));
|
|
21092
|
+
if (attributeName === "Status") return response.status;
|
|
21093
|
+
if (attributeName === "CreatedAt") return response.createdAt?.toISOString();
|
|
21094
|
+
return response.updatedAt?.toISOString();
|
|
21095
|
+
}
|
|
21096
|
+
throw new Error(`Unsupported attribute: ${attributeName} for AWS::BedrockAgentCore::Evaluator`);
|
|
21097
|
+
}
|
|
21098
|
+
/**
|
|
21099
|
+
* Read the AWS-current Evaluator configuration in CFn-property shape.
|
|
21100
|
+
*
|
|
21101
|
+
* Issues `GetEvaluator` + `ListTagsForResource` and surfaces the keys
|
|
21102
|
+
* `create()` accepts, re-shaped to PascalCase (the free-form
|
|
21103
|
+
* `additionalModelRequestFields` document is passed through verbatim).
|
|
21104
|
+
* Returns `undefined` when the evaluator is gone
|
|
21105
|
+
* (`ResourceNotFoundException`).
|
|
21106
|
+
*/
|
|
21107
|
+
async readCurrentState(physicalId, _logicalId, _resourceType) {
|
|
21108
|
+
let resp;
|
|
21109
|
+
try {
|
|
21110
|
+
resp = await this.client.send(new GetEvaluatorCommand({ evaluatorId: evaluatorIdFromArn(physicalId) }));
|
|
21111
|
+
} catch (err) {
|
|
21112
|
+
if (err instanceof ResourceNotFoundException$5) return void 0;
|
|
21113
|
+
throw err;
|
|
21114
|
+
}
|
|
21115
|
+
const result = {};
|
|
21116
|
+
if (resp.evaluatorName !== void 0) result["EvaluatorName"] = resp.evaluatorName;
|
|
21117
|
+
result["Description"] = resp.description ?? "";
|
|
21118
|
+
if (resp.evaluatorConfig !== void 0) result["EvaluatorConfig"] = camelToPascalCaseKeys(resp.evaluatorConfig, SDK_PRESERVE_KEYS);
|
|
21119
|
+
if (resp.level !== void 0) result["Level"] = resp.level;
|
|
21120
|
+
if (resp.kmsKeyArn !== void 0) result["KmsKeyArn"] = resp.kmsKeyArn;
|
|
21121
|
+
try {
|
|
21122
|
+
result["Tags"] = tagMapToCfnList((await this.client.send(new ListTagsForResourceCommand$6({ resourceArn: physicalId }))).tags ?? {});
|
|
21123
|
+
} catch (err) {
|
|
21124
|
+
this.logger.debug(`Failed to read tags for evaluator ${physicalId}: ${err instanceof Error ? err.message : String(err)}`);
|
|
21125
|
+
}
|
|
21126
|
+
return result;
|
|
21127
|
+
}
|
|
21128
|
+
/**
|
|
21129
|
+
* Adopt an existing BedrockAgentCore Evaluator into cdkd state.
|
|
21130
|
+
*
|
|
21131
|
+
* **Explicit override only.** Pass `--resource <logicalId>=<value>` where
|
|
21132
|
+
* `<value>` is the evaluator ARN or the bare evaluator ID; an ID is
|
|
21133
|
+
* resolved to the canonical ARN (the physical id shape `create()`
|
|
21134
|
+
* records) via `GetEvaluator`.
|
|
21135
|
+
*/
|
|
21136
|
+
async import(input) {
|
|
21137
|
+
if (!input.knownPhysicalId) return null;
|
|
21138
|
+
if (input.knownPhysicalId.includes(":evaluator/")) return {
|
|
21139
|
+
physicalId: input.knownPhysicalId,
|
|
21140
|
+
attributes: {
|
|
21141
|
+
EvaluatorArn: input.knownPhysicalId,
|
|
21142
|
+
EvaluatorId: evaluatorIdFromArn(input.knownPhysicalId)
|
|
21143
|
+
}
|
|
21144
|
+
};
|
|
21145
|
+
const response = await this.client.send(new GetEvaluatorCommand({ evaluatorId: input.knownPhysicalId }));
|
|
21146
|
+
return {
|
|
21147
|
+
physicalId: response.evaluatorArn,
|
|
21148
|
+
attributes: {
|
|
21149
|
+
EvaluatorArn: response.evaluatorArn,
|
|
21150
|
+
EvaluatorId: response.evaluatorId ?? input.knownPhysicalId
|
|
21151
|
+
}
|
|
21152
|
+
};
|
|
21153
|
+
}
|
|
21154
|
+
};
|
|
21155
|
+
|
|
20630
21156
|
//#endregion
|
|
20631
21157
|
//#region src/provisioning/providers/stepfunctions-provider.ts
|
|
20632
21158
|
/**
|
|
@@ -20823,7 +21349,7 @@ var StepFunctionsProvider = class {
|
|
|
20823
21349
|
result["EncryptionConfiguration"] = ec;
|
|
20824
21350
|
}
|
|
20825
21351
|
try {
|
|
20826
|
-
result["Tags"] = normalizeAwsTagsToCfn((await this.getClient().send(new ListTagsForResourceCommand$
|
|
21352
|
+
result["Tags"] = normalizeAwsTagsToCfn((await this.getClient().send(new ListTagsForResourceCommand$11({ resourceArn: physicalId }))).tags);
|
|
20827
21353
|
} catch (err) {
|
|
20828
21354
|
if (!(err instanceof StateMachineDoesNotExist)) throw err;
|
|
20829
21355
|
}
|
|
@@ -20861,7 +21387,7 @@ var StepFunctionsProvider = class {
|
|
|
20861
21387
|
const list = await this.getClient().send(new ListStateMachinesCommand({ ...nextToken && { nextToken } }));
|
|
20862
21388
|
for (const sm of list.stateMachines ?? []) {
|
|
20863
21389
|
if (!sm.stateMachineArn) continue;
|
|
20864
|
-
const tagsResp = await this.getClient().send(new ListTagsForResourceCommand$
|
|
21390
|
+
const tagsResp = await this.getClient().send(new ListTagsForResourceCommand$11({ resourceArn: sm.stateMachineArn }));
|
|
20865
21391
|
if (this.tagsMatchCdkPath(tagsResp.tags, input.cdkPath)) return {
|
|
20866
21392
|
physicalId: sm.stateMachineArn,
|
|
20867
21393
|
attributes: {}
|
|
@@ -20892,14 +21418,14 @@ var StepFunctionsProvider = class {
|
|
|
20892
21418
|
const tagsToRemove = [];
|
|
20893
21419
|
for (const k of oldMap.keys()) if (!newMap.has(k)) tagsToRemove.push(k);
|
|
20894
21420
|
if (tagsToRemove.length > 0) {
|
|
20895
|
-
await this.getClient().send(new UntagResourceCommand$
|
|
21421
|
+
await this.getClient().send(new UntagResourceCommand$12({
|
|
20896
21422
|
resourceArn: stateMachineArn,
|
|
20897
21423
|
tagKeys: tagsToRemove
|
|
20898
21424
|
}));
|
|
20899
21425
|
this.logger.debug(`Removed ${tagsToRemove.length} tag(s) from SFN state machine ${stateMachineArn}`);
|
|
20900
21426
|
}
|
|
20901
21427
|
if (tagsToAdd.length > 0) {
|
|
20902
|
-
await this.getClient().send(new TagResourceCommand$
|
|
21428
|
+
await this.getClient().send(new TagResourceCommand$12({
|
|
20903
21429
|
resourceArn: stateMachineArn,
|
|
20904
21430
|
tags: tagsToAdd
|
|
20905
21431
|
}));
|
|
@@ -21519,14 +22045,14 @@ var ECSProvider = class {
|
|
|
21519
22045
|
const tagsToRemove = [];
|
|
21520
22046
|
for (const k of oldMap.keys()) if (!newMap.has(k)) tagsToRemove.push(k);
|
|
21521
22047
|
if (tagsToRemove.length > 0) {
|
|
21522
|
-
await this.getClient().send(new UntagResourceCommand$
|
|
22048
|
+
await this.getClient().send(new UntagResourceCommand$13({
|
|
21523
22049
|
resourceArn,
|
|
21524
22050
|
tagKeys: tagsToRemove
|
|
21525
22051
|
}));
|
|
21526
22052
|
this.logger.debug(`Removed ${tagsToRemove.length} tag(s) from ECS resource ${resourceArn}`);
|
|
21527
22053
|
}
|
|
21528
22054
|
if (tagsToAdd.length > 0) {
|
|
21529
|
-
await this.getClient().send(new TagResourceCommand$
|
|
22055
|
+
await this.getClient().send(new TagResourceCommand$13({
|
|
21530
22056
|
resourceArn,
|
|
21531
22057
|
tags: tagsToAdd
|
|
21532
22058
|
}));
|
|
@@ -22097,7 +22623,7 @@ var ECSProvider = class {
|
|
|
22097
22623
|
do {
|
|
22098
22624
|
const list = await this.getClient().send(new ListClustersCommand({ ...nextToken && { nextToken } }));
|
|
22099
22625
|
for (const arn of list.clusterArns ?? []) {
|
|
22100
|
-
const tagsResp = await this.getClient().send(new ListTagsForResourceCommand$
|
|
22626
|
+
const tagsResp = await this.getClient().send(new ListTagsForResourceCommand$12({ resourceArn: arn }));
|
|
22101
22627
|
if (this.tagsMatchCdkPath(tagsResp.tags, input.cdkPath)) return {
|
|
22102
22628
|
physicalId: arn.substring(arn.lastIndexOf("/") + 1),
|
|
22103
22629
|
attributes: {}
|
|
@@ -22124,7 +22650,7 @@ var ECSProvider = class {
|
|
|
22124
22650
|
...svcToken && { nextToken: svcToken }
|
|
22125
22651
|
}));
|
|
22126
22652
|
for (const svcArn of svcList.serviceArns ?? []) {
|
|
22127
|
-
const tagsResp = await this.getClient().send(new ListTagsForResourceCommand$
|
|
22653
|
+
const tagsResp = await this.getClient().send(new ListTagsForResourceCommand$12({ resourceArn: svcArn }));
|
|
22128
22654
|
if (this.tagsMatchCdkPath(tagsResp.tags, input.cdkPath)) return {
|
|
22129
22655
|
physicalId: `${clusterArn}|${svcArn.substring(svcArn.lastIndexOf("/") + 1)}`,
|
|
22130
22656
|
attributes: {}
|
|
@@ -23622,7 +24148,7 @@ var RDSProvider = class {
|
|
|
23622
24148
|
*/
|
|
23623
24149
|
async attachTags(result, arn) {
|
|
23624
24150
|
try {
|
|
23625
|
-
result["Tags"] = normalizeAwsTagsToCfn((await this.getClient().send(new ListTagsForResourceCommand$
|
|
24151
|
+
result["Tags"] = normalizeAwsTagsToCfn((await this.getClient().send(new ListTagsForResourceCommand$9({ ResourceName: arn }))).TagList);
|
|
23626
24152
|
} catch (err) {
|
|
23627
24153
|
this.logger.debug(`RDS ListTagsForResource(${arn}) failed: ${err instanceof Error ? err.message : String(err)}`);
|
|
23628
24154
|
}
|
|
@@ -23645,7 +24171,7 @@ var RDSProvider = class {
|
|
|
23645
24171
|
const list = await this.getClient().send(new DescribeDBInstancesCommand({ ...marker && { Marker: marker } }));
|
|
23646
24172
|
for (const inst of list.DBInstances ?? []) {
|
|
23647
24173
|
if (!inst.DBInstanceIdentifier || !inst.DBInstanceArn) continue;
|
|
23648
|
-
if (matchesCdkPath((await this.getClient().send(new ListTagsForResourceCommand$
|
|
24174
|
+
if (matchesCdkPath((await this.getClient().send(new ListTagsForResourceCommand$9({ ResourceName: inst.DBInstanceArn }))).TagList, input.cdkPath)) return {
|
|
23649
24175
|
physicalId: inst.DBInstanceIdentifier,
|
|
23650
24176
|
attributes: {}
|
|
23651
24177
|
};
|
|
@@ -23672,7 +24198,7 @@ var RDSProvider = class {
|
|
|
23672
24198
|
const list = await this.getClient().send(new DescribeDBClustersCommand({ ...marker && { Marker: marker } }));
|
|
23673
24199
|
for (const c of list.DBClusters ?? []) {
|
|
23674
24200
|
if (!c.DBClusterIdentifier || !c.DBClusterArn) continue;
|
|
23675
|
-
if (matchesCdkPath((await this.getClient().send(new ListTagsForResourceCommand$
|
|
24201
|
+
if (matchesCdkPath((await this.getClient().send(new ListTagsForResourceCommand$9({ ResourceName: c.DBClusterArn }))).TagList, input.cdkPath)) return {
|
|
23676
24202
|
physicalId: c.DBClusterIdentifier,
|
|
23677
24203
|
attributes: {}
|
|
23678
24204
|
};
|
|
@@ -23699,7 +24225,7 @@ var RDSProvider = class {
|
|
|
23699
24225
|
const list = await this.getClient().send(new DescribeDBSubnetGroupsCommand({ ...marker && { Marker: marker } }));
|
|
23700
24226
|
for (const sg of list.DBSubnetGroups ?? []) {
|
|
23701
24227
|
if (!sg.DBSubnetGroupName || !sg.DBSubnetGroupArn) continue;
|
|
23702
|
-
if (matchesCdkPath((await this.getClient().send(new ListTagsForResourceCommand$
|
|
24228
|
+
if (matchesCdkPath((await this.getClient().send(new ListTagsForResourceCommand$9({ ResourceName: sg.DBSubnetGroupArn }))).TagList, input.cdkPath)) return {
|
|
23703
24229
|
physicalId: sg.DBSubnetGroupName,
|
|
23704
24230
|
attributes: {}
|
|
23705
24231
|
};
|
|
@@ -23929,7 +24455,7 @@ var RDSDBProxyProvider = class {
|
|
|
23929
24455
|
for (const proxy of describe.DBProxies ?? []) {
|
|
23930
24456
|
if (!proxy.DBProxyArn) continue;
|
|
23931
24457
|
try {
|
|
23932
|
-
if (matchesCdkPath((await client.send(new ListTagsForResourceCommand$
|
|
24458
|
+
if (matchesCdkPath((await client.send(new ListTagsForResourceCommand$9({ ResourceName: proxy.DBProxyArn }))).TagList ?? [], input.cdkPath)) return this.buildImportResult(proxy.DBProxyName ?? "");
|
|
23933
24459
|
} catch (error) {
|
|
23934
24460
|
this.logger.debug(`ListTagsForResource failed for ${proxy.DBProxyName}: ${error instanceof Error ? error.message : String(error)}`);
|
|
23935
24461
|
}
|
|
@@ -23972,7 +24498,7 @@ var RDSDBProxyProvider = class {
|
|
|
23972
24498
|
}))
|
|
23973
24499
|
};
|
|
23974
24500
|
if (p.DBProxyArn) try {
|
|
23975
|
-
result["Tags"] = normalizeAwsTagsToCfn((await client.send(new ListTagsForResourceCommand$
|
|
24501
|
+
result["Tags"] = normalizeAwsTagsToCfn((await client.send(new ListTagsForResourceCommand$9({ ResourceName: p.DBProxyArn }))).TagList ?? []);
|
|
23976
24502
|
} catch (error) {
|
|
23977
24503
|
this.logger.debug(`ListTagsForResource failed for ${physicalId}: ${error instanceof Error ? error.message : String(error)}`);
|
|
23978
24504
|
result["Tags"] = [];
|
|
@@ -24271,7 +24797,7 @@ var RDSDBProxyEndpointProvider = class {
|
|
|
24271
24797
|
for (const ep of describe.DBProxyEndpoints ?? []) {
|
|
24272
24798
|
if (!ep.DBProxyEndpointArn) continue;
|
|
24273
24799
|
try {
|
|
24274
|
-
if (matchesCdkPath((await client.send(new ListTagsForResourceCommand$
|
|
24800
|
+
if (matchesCdkPath((await client.send(new ListTagsForResourceCommand$9({ ResourceName: ep.DBProxyEndpointArn }))).TagList ?? [], input.cdkPath)) return this.buildImportResult(ep.DBProxyEndpointName ?? "");
|
|
24275
24801
|
} catch (error) {
|
|
24276
24802
|
this.logger.debug(`ListTagsForResource failed for ${ep.DBProxyEndpointName}: ${error instanceof Error ? error.message : String(error)}`);
|
|
24277
24803
|
}
|
|
@@ -24299,7 +24825,7 @@ var RDSDBProxyEndpointProvider = class {
|
|
|
24299
24825
|
TargetRole: e.TargetRole ?? "READ_WRITE"
|
|
24300
24826
|
};
|
|
24301
24827
|
if (e.DBProxyEndpointArn) try {
|
|
24302
|
-
result["Tags"] = normalizeAwsTagsToCfn((await client.send(new ListTagsForResourceCommand$
|
|
24828
|
+
result["Tags"] = normalizeAwsTagsToCfn((await client.send(new ListTagsForResourceCommand$9({ ResourceName: e.DBProxyEndpointArn }))).TagList ?? []);
|
|
24303
24829
|
} catch (error) {
|
|
24304
24830
|
this.logger.debug(`ListTagsForResource failed for ${physicalId}: ${error instanceof Error ? error.message : String(error)}`);
|
|
24305
24831
|
result["Tags"] = [];
|
|
@@ -25268,7 +25794,7 @@ var DocDBProvider = class {
|
|
|
25268
25794
|
*/
|
|
25269
25795
|
async attachTags(result, arn) {
|
|
25270
25796
|
try {
|
|
25271
|
-
result["Tags"] = normalizeAwsTagsToCfn((await this.getClient().send(new ListTagsForResourceCommand$
|
|
25797
|
+
result["Tags"] = normalizeAwsTagsToCfn((await this.getClient().send(new ListTagsForResourceCommand$13({ ResourceName: arn }))).TagList);
|
|
25272
25798
|
} catch (err) {
|
|
25273
25799
|
this.logger.debug(`DocDB ListTagsForResource(${arn}) failed: ${err instanceof Error ? err.message : String(err)}`);
|
|
25274
25800
|
}
|
|
@@ -25291,7 +25817,7 @@ var DocDBProvider = class {
|
|
|
25291
25817
|
const list = await this.getClient().send(new DescribeDBInstancesCommand$1({ ...marker && { Marker: marker } }));
|
|
25292
25818
|
for (const inst of list.DBInstances ?? []) {
|
|
25293
25819
|
if (!inst.DBInstanceIdentifier || !inst.DBInstanceArn) continue;
|
|
25294
|
-
if (matchesCdkPath((await this.getClient().send(new ListTagsForResourceCommand$
|
|
25820
|
+
if (matchesCdkPath((await this.getClient().send(new ListTagsForResourceCommand$13({ ResourceName: inst.DBInstanceArn }))).TagList, input.cdkPath)) return {
|
|
25295
25821
|
physicalId: inst.DBInstanceIdentifier,
|
|
25296
25822
|
attributes: {}
|
|
25297
25823
|
};
|
|
@@ -25318,7 +25844,7 @@ var DocDBProvider = class {
|
|
|
25318
25844
|
const list = await this.getClient().send(new DescribeDBClustersCommand$1({ ...marker && { Marker: marker } }));
|
|
25319
25845
|
for (const c of list.DBClusters ?? []) {
|
|
25320
25846
|
if (!c.DBClusterIdentifier || !c.DBClusterArn) continue;
|
|
25321
|
-
if (matchesCdkPath((await this.getClient().send(new ListTagsForResourceCommand$
|
|
25847
|
+
if (matchesCdkPath((await this.getClient().send(new ListTagsForResourceCommand$13({ ResourceName: c.DBClusterArn }))).TagList, input.cdkPath)) return {
|
|
25322
25848
|
physicalId: c.DBClusterIdentifier,
|
|
25323
25849
|
attributes: {}
|
|
25324
25850
|
};
|
|
@@ -25345,7 +25871,7 @@ var DocDBProvider = class {
|
|
|
25345
25871
|
const list = await this.getClient().send(new DescribeDBSubnetGroupsCommand$1({ ...marker && { Marker: marker } }));
|
|
25346
25872
|
for (const sg of list.DBSubnetGroups ?? []) {
|
|
25347
25873
|
if (!sg.DBSubnetGroupName || !sg.DBSubnetGroupArn) continue;
|
|
25348
|
-
if (matchesCdkPath((await this.getClient().send(new ListTagsForResourceCommand$
|
|
25874
|
+
if (matchesCdkPath((await this.getClient().send(new ListTagsForResourceCommand$13({ ResourceName: sg.DBSubnetGroupArn }))).TagList, input.cdkPath)) return {
|
|
25349
25875
|
physicalId: sg.DBSubnetGroupName,
|
|
25350
25876
|
attributes: {}
|
|
25351
25877
|
};
|
|
@@ -25938,7 +26464,7 @@ var NeptuneProvider = class {
|
|
|
25938
26464
|
*/
|
|
25939
26465
|
async attachTags(result, arn) {
|
|
25940
26466
|
try {
|
|
25941
|
-
result["Tags"] = normalizeAwsTagsToCfn((await this.getClient().send(new ListTagsForResourceCommand$
|
|
26467
|
+
result["Tags"] = normalizeAwsTagsToCfn((await this.getClient().send(new ListTagsForResourceCommand$14({ ResourceName: arn }))).TagList);
|
|
25942
26468
|
} catch (err) {
|
|
25943
26469
|
this.logger.debug(`Neptune ListTagsForResource(${arn}) failed: ${err instanceof Error ? err.message : String(err)}`);
|
|
25944
26470
|
}
|
|
@@ -25961,7 +26487,7 @@ var NeptuneProvider = class {
|
|
|
25961
26487
|
const list = await this.getClient().send(new DescribeDBInstancesCommand$2({ ...marker && { Marker: marker } }));
|
|
25962
26488
|
for (const inst of list.DBInstances ?? []) {
|
|
25963
26489
|
if (!inst.DBInstanceIdentifier || !inst.DBInstanceArn) continue;
|
|
25964
|
-
if (matchesCdkPath((await this.getClient().send(new ListTagsForResourceCommand$
|
|
26490
|
+
if (matchesCdkPath((await this.getClient().send(new ListTagsForResourceCommand$14({ ResourceName: inst.DBInstanceArn }))).TagList, input.cdkPath)) return {
|
|
25965
26491
|
physicalId: inst.DBInstanceIdentifier,
|
|
25966
26492
|
attributes: {}
|
|
25967
26493
|
};
|
|
@@ -25988,7 +26514,7 @@ var NeptuneProvider = class {
|
|
|
25988
26514
|
const list = await this.getClient().send(new DescribeDBClustersCommand$2({ ...marker && { Marker: marker } }));
|
|
25989
26515
|
for (const c of list.DBClusters ?? []) {
|
|
25990
26516
|
if (!c.DBClusterIdentifier || !c.DBClusterArn) continue;
|
|
25991
|
-
if (matchesCdkPath((await this.getClient().send(new ListTagsForResourceCommand$
|
|
26517
|
+
if (matchesCdkPath((await this.getClient().send(new ListTagsForResourceCommand$14({ ResourceName: c.DBClusterArn }))).TagList, input.cdkPath)) return {
|
|
25992
26518
|
physicalId: c.DBClusterIdentifier,
|
|
25993
26519
|
attributes: {}
|
|
25994
26520
|
};
|
|
@@ -26015,7 +26541,7 @@ var NeptuneProvider = class {
|
|
|
26015
26541
|
const list = await this.getClient().send(new DescribeDBSubnetGroupsCommand$2({ ...marker && { Marker: marker } }));
|
|
26016
26542
|
for (const sg of list.DBSubnetGroups ?? []) {
|
|
26017
26543
|
if (!sg.DBSubnetGroupName || !sg.DBSubnetGroupArn) continue;
|
|
26018
|
-
if (matchesCdkPath((await this.getClient().send(new ListTagsForResourceCommand$
|
|
26544
|
+
if (matchesCdkPath((await this.getClient().send(new ListTagsForResourceCommand$14({ ResourceName: sg.DBSubnetGroupArn }))).TagList, input.cdkPath)) return {
|
|
26019
26545
|
physicalId: sg.DBSubnetGroupName,
|
|
26020
26546
|
attributes: {}
|
|
26021
26547
|
};
|
|
@@ -26641,7 +27167,7 @@ var Route53Provider = class {
|
|
|
26641
27167
|
});
|
|
26642
27168
|
const idTail = physicalId.replace(/^\/hostedzone\//, "");
|
|
26643
27169
|
try {
|
|
26644
|
-
result["HostedZoneTags"] = normalizeAwsTagsToCfn((await this.getClient().send(new ListTagsForResourceCommand$
|
|
27170
|
+
result["HostedZoneTags"] = normalizeAwsTagsToCfn((await this.getClient().send(new ListTagsForResourceCommand$7({
|
|
26645
27171
|
ResourceType: "hostedzone",
|
|
26646
27172
|
ResourceId: idTail
|
|
26647
27173
|
}))).ResourceTagSet?.Tags);
|
|
@@ -26766,7 +27292,7 @@ var Route53Provider = class {
|
|
|
26766
27292
|
if (!zone.Id) continue;
|
|
26767
27293
|
const zoneId = zone.Id.replace("/hostedzone/", "");
|
|
26768
27294
|
try {
|
|
26769
|
-
if (matchesCdkPath((await this.getClient().send(new ListTagsForResourceCommand$
|
|
27295
|
+
if (matchesCdkPath((await this.getClient().send(new ListTagsForResourceCommand$7({
|
|
26770
27296
|
ResourceType: "hostedzone",
|
|
26771
27297
|
ResourceId: zoneId
|
|
26772
27298
|
}))).ResourceTagSet?.Tags, input.cdkPath)) return {
|
|
@@ -27338,7 +27864,7 @@ var CognitoUserPoolProvider = class {
|
|
|
27338
27864
|
if (input.cdkPath) try {
|
|
27339
27865
|
const arn = (await this.getClient().send(new DescribeUserPoolCommand({ UserPoolId: pool.Id }))).UserPool?.Arn;
|
|
27340
27866
|
if (!arn) continue;
|
|
27341
|
-
if ((await this.getClient().send(new ListTagsForResourceCommand$
|
|
27867
|
+
if ((await this.getClient().send(new ListTagsForResourceCommand$15({ ResourceArn: arn }))).Tags?.["aws:cdk:path"] === input.cdkPath) return {
|
|
27342
27868
|
physicalId: pool.Id,
|
|
27343
27869
|
attributes: {}
|
|
27344
27870
|
};
|
|
@@ -27776,7 +28302,7 @@ var ElastiCacheProvider = class {
|
|
|
27776
28302
|
/** Best-effort tag fetch — failures omit the key without breaking the read. */
|
|
27777
28303
|
async attachTags(result, arn) {
|
|
27778
28304
|
try {
|
|
27779
|
-
result["Tags"] = normalizeAwsTagsToCfn((await this.getClient().send(new ListTagsForResourceCommand$
|
|
28305
|
+
result["Tags"] = normalizeAwsTagsToCfn((await this.getClient().send(new ListTagsForResourceCommand$10({ ResourceName: arn }))).TagList);
|
|
27780
28306
|
} catch (err) {
|
|
27781
28307
|
this.logger.debug(`ElastiCache ListTagsForResource(${arn}) failed: ${err instanceof Error ? err.message : String(err)}`);
|
|
27782
28308
|
}
|
|
@@ -27822,7 +28348,7 @@ var ElastiCacheProvider = class {
|
|
|
27822
28348
|
for (const c of list.CacheClusters ?? []) {
|
|
27823
28349
|
if (!c.CacheClusterId) continue;
|
|
27824
28350
|
const arn = c.ARN ?? await this.buildClusterArn(c.CacheClusterId);
|
|
27825
|
-
if (matchesCdkPath((await this.getClient().send(new ListTagsForResourceCommand$
|
|
28351
|
+
if (matchesCdkPath((await this.getClient().send(new ListTagsForResourceCommand$10({ ResourceName: arn }))).TagList, input.cdkPath)) return {
|
|
27826
28352
|
physicalId: c.CacheClusterId,
|
|
27827
28353
|
attributes: {}
|
|
27828
28354
|
};
|
|
@@ -27850,7 +28376,7 @@ var ElastiCacheProvider = class {
|
|
|
27850
28376
|
for (const g of list.CacheSubnetGroups ?? []) {
|
|
27851
28377
|
if (!g.CacheSubnetGroupName) continue;
|
|
27852
28378
|
const arn = g.ARN ?? await this.buildSubnetGroupArn(g.CacheSubnetGroupName);
|
|
27853
|
-
if (matchesCdkPath((await this.getClient().send(new ListTagsForResourceCommand$
|
|
28379
|
+
if (matchesCdkPath((await this.getClient().send(new ListTagsForResourceCommand$10({ ResourceName: arn }))).TagList, input.cdkPath)) return {
|
|
27854
28380
|
physicalId: g.CacheSubnetGroupName,
|
|
27855
28381
|
attributes: {}
|
|
27856
28382
|
};
|
|
@@ -28403,11 +28929,11 @@ var ServiceDiscoveryProvider = class ServiceDiscoveryProvider {
|
|
|
28403
28929
|
const hasAdds = !!newTags && newTags.length > 0;
|
|
28404
28930
|
if (removedKeys.length === 0 && !hasAdds) return;
|
|
28405
28931
|
const arn = await this.resolveNamespaceArn(physicalId);
|
|
28406
|
-
if (removedKeys.length > 0) await this.getClient().send(new UntagResourceCommand$
|
|
28932
|
+
if (removedKeys.length > 0) await this.getClient().send(new UntagResourceCommand$14({
|
|
28407
28933
|
ResourceARN: arn,
|
|
28408
28934
|
TagKeys: removedKeys
|
|
28409
28935
|
}));
|
|
28410
|
-
if (hasAdds) await this.getClient().send(new TagResourceCommand$
|
|
28936
|
+
if (hasAdds) await this.getClient().send(new TagResourceCommand$14({
|
|
28411
28937
|
ResourceARN: arn,
|
|
28412
28938
|
Tags: newTags
|
|
28413
28939
|
}));
|
|
@@ -28595,7 +29121,7 @@ var ServiceDiscoveryProvider = class ServiceDiscoveryProvider {
|
|
|
28595
29121
|
/** Best-effort tag fetch via `ListTagsForResource(ResourceARN)`. */
|
|
28596
29122
|
async attachTags(result, arn) {
|
|
28597
29123
|
try {
|
|
28598
|
-
result["Tags"] = normalizeAwsTagsToCfn((await this.getClient().send(new ListTagsForResourceCommand$
|
|
29124
|
+
result["Tags"] = normalizeAwsTagsToCfn((await this.getClient().send(new ListTagsForResourceCommand$16({ ResourceARN: arn }))).Tags);
|
|
28599
29125
|
} catch (err) {
|
|
28600
29126
|
this.logger.debug(`ServiceDiscovery ListTagsForResource(${arn}) failed: ${err instanceof Error ? err.message : String(err)}`);
|
|
28601
29127
|
}
|
|
@@ -28648,7 +29174,7 @@ var ServiceDiscoveryProvider = class ServiceDiscoveryProvider {
|
|
|
28648
29174
|
attributes: {}
|
|
28649
29175
|
};
|
|
28650
29176
|
if (input.cdkPath) try {
|
|
28651
|
-
if (matchesCdkPath((await this.getClient().send(new ListTagsForResourceCommand$
|
|
29177
|
+
if (matchesCdkPath((await this.getClient().send(new ListTagsForResourceCommand$16({ ResourceARN: ns.Arn }))).Tags, input.cdkPath)) return {
|
|
28652
29178
|
physicalId: ns.Id,
|
|
28653
29179
|
attributes: {}
|
|
28654
29180
|
};
|
|
@@ -28679,7 +29205,7 @@ var ServiceDiscoveryProvider = class ServiceDiscoveryProvider {
|
|
|
28679
29205
|
for (const svc of list.Services ?? []) {
|
|
28680
29206
|
if (!svc.Id || !svc.Arn) continue;
|
|
28681
29207
|
try {
|
|
28682
|
-
if (matchesCdkPath((await this.getClient().send(new ListTagsForResourceCommand$
|
|
29208
|
+
if (matchesCdkPath((await this.getClient().send(new ListTagsForResourceCommand$16({ ResourceARN: svc.Arn }))).Tags, input.cdkPath)) return {
|
|
28683
29209
|
physicalId: svc.Id,
|
|
28684
29210
|
attributes: {}
|
|
28685
29211
|
};
|
|
@@ -29069,7 +29595,7 @@ var AppSyncProvider = class {
|
|
|
29069
29595
|
const tagsToAdd = {};
|
|
29070
29596
|
for (const [k, v] of Object.entries(newMap)) if (oldMap[k] !== v) tagsToAdd[k] = v;
|
|
29071
29597
|
if (tagKeysToRemove.length > 0) try {
|
|
29072
|
-
await this.getClient().send(new UntagResourceCommand$
|
|
29598
|
+
await this.getClient().send(new UntagResourceCommand$15({
|
|
29073
29599
|
resourceArn: arn,
|
|
29074
29600
|
tagKeys: tagKeysToRemove
|
|
29075
29601
|
}));
|
|
@@ -29077,7 +29603,7 @@ var AppSyncProvider = class {
|
|
|
29077
29603
|
throw this.wrapUpdateError(error, resourceType, logicalId, apiId, "GraphqlApi (untag)");
|
|
29078
29604
|
}
|
|
29079
29605
|
if (Object.keys(tagsToAdd).length > 0) try {
|
|
29080
|
-
await this.getClient().send(new TagResourceCommand$
|
|
29606
|
+
await this.getClient().send(new TagResourceCommand$15({
|
|
29081
29607
|
resourceArn: arn,
|
|
29082
29608
|
tags: tagsToAdd
|
|
29083
29609
|
}));
|
|
@@ -31630,14 +32156,14 @@ var KMSProvider = class {
|
|
|
31630
32156
|
const tagsToRemove = [];
|
|
31631
32157
|
for (const k of oldMap.keys()) if (!newMap.has(k)) tagsToRemove.push(k);
|
|
31632
32158
|
if (tagsToRemove.length > 0) {
|
|
31633
|
-
await this.getClient().send(new UntagResourceCommand$
|
|
32159
|
+
await this.getClient().send(new UntagResourceCommand$10({
|
|
31634
32160
|
KeyId: keyId,
|
|
31635
32161
|
TagKeys: tagsToRemove
|
|
31636
32162
|
}));
|
|
31637
32163
|
this.logger.debug(`Removed ${tagsToRemove.length} tag(s) from KMS Key ${keyId}`);
|
|
31638
32164
|
}
|
|
31639
32165
|
if (tagsToAdd.length > 0) {
|
|
31640
|
-
await this.getClient().send(new TagResourceCommand$
|
|
32166
|
+
await this.getClient().send(new TagResourceCommand$10({
|
|
31641
32167
|
KeyId: keyId,
|
|
31642
32168
|
Tags: tagsToAdd
|
|
31643
32169
|
}));
|
|
@@ -32252,11 +32778,11 @@ var BudgetsBudgetProvider = class {
|
|
|
32252
32778
|
const removedKeys = oldTags.map((t) => t.Key).filter((k) => {
|
|
32253
32779
|
return typeof k === "string" && !newKeys.has(k);
|
|
32254
32780
|
});
|
|
32255
|
-
if (removedKeys.length > 0) await this.getClient().send(new UntagResourceCommand$
|
|
32781
|
+
if (removedKeys.length > 0) await this.getClient().send(new UntagResourceCommand$16({
|
|
32256
32782
|
ResourceARN: arn,
|
|
32257
32783
|
ResourceTagKeys: removedKeys
|
|
32258
32784
|
}));
|
|
32259
|
-
if (newTags.length > 0) await this.getClient().send(new TagResourceCommand$
|
|
32785
|
+
if (newTags.length > 0) await this.getClient().send(new TagResourceCommand$16({
|
|
32260
32786
|
ResourceARN: arn,
|
|
32261
32787
|
ResourceTags: newTags
|
|
32262
32788
|
}));
|
|
@@ -32344,7 +32870,7 @@ var BudgetsBudgetProvider = class {
|
|
|
32344
32870
|
}));
|
|
32345
32871
|
for (const budget of list.Budgets ?? []) {
|
|
32346
32872
|
if (!budget.BudgetName) continue;
|
|
32347
|
-
if (matchesCdkPath((await client.send(new ListTagsForResourceCommand$
|
|
32873
|
+
if (matchesCdkPath((await client.send(new ListTagsForResourceCommand$17({ ResourceARN: this.budgetArn(accountId, budget.BudgetName) }))).ResourceTags, input.cdkPath)) return {
|
|
32348
32874
|
physicalId: budget.BudgetName,
|
|
32349
32875
|
attributes: { Arn: this.budgetArn(accountId, budget.BudgetName) }
|
|
32350
32876
|
};
|
|
@@ -32915,7 +33441,7 @@ var KinesisStreamConsumerProvider = class {
|
|
|
32915
33441
|
if (desc.ConsumerName !== void 0) result["ConsumerName"] = desc.ConsumerName;
|
|
32916
33442
|
if (desc.StreamARN !== void 0) result["StreamARN"] = desc.StreamARN;
|
|
32917
33443
|
try {
|
|
32918
|
-
result["Tags"] = normalizeAwsTagsToCfn((await this.getClient().send(new ListTagsForResourceCommand$
|
|
33444
|
+
result["Tags"] = normalizeAwsTagsToCfn((await this.getClient().send(new ListTagsForResourceCommand$18({ ResourceARN: physicalId }))).Tags);
|
|
32919
33445
|
} catch (err) {
|
|
32920
33446
|
if (err instanceof ResourceNotFoundException$8) return void 0;
|
|
32921
33447
|
this.logger.debug(`ListTagsForResource(${physicalId}) failed: ${err instanceof Error ? err.message : String(err)}`);
|
|
@@ -32939,14 +33465,14 @@ var KinesisStreamConsumerProvider = class {
|
|
|
32939
33465
|
const tagsToRemove = [];
|
|
32940
33466
|
for (const k of Object.keys(oldMap)) if (!(k in newMap)) tagsToRemove.push(k);
|
|
32941
33467
|
if (tagsToRemove.length > 0) {
|
|
32942
|
-
await this.getClient().send(new UntagResourceCommand$
|
|
33468
|
+
await this.getClient().send(new UntagResourceCommand$17({
|
|
32943
33469
|
ResourceARN: consumerArn,
|
|
32944
33470
|
TagKeys: tagsToRemove
|
|
32945
33471
|
}));
|
|
32946
33472
|
this.logger.debug(`Removed ${tagsToRemove.length} tag(s) from Kinesis stream consumer ${consumerArn}`);
|
|
32947
33473
|
}
|
|
32948
33474
|
if (Object.keys(tagsToAdd).length > 0) {
|
|
32949
|
-
await this.getClient().send(new TagResourceCommand$
|
|
33475
|
+
await this.getClient().send(new TagResourceCommand$17({
|
|
32950
33476
|
ResourceARN: consumerArn,
|
|
32951
33477
|
Tags: tagsToAdd
|
|
32952
33478
|
}));
|
|
@@ -36097,11 +36623,11 @@ var CodeCommitRepositoryProvider = class {
|
|
|
36097
36623
|
const repoArn = metadata?.Arn;
|
|
36098
36624
|
if (repoArn) {
|
|
36099
36625
|
const removedKeys = Object.keys(oldTagMap).filter((k) => !(k in newTagMap));
|
|
36100
|
-
if (removedKeys.length > 0) await this.getClient().send(new UntagResourceCommand$
|
|
36626
|
+
if (removedKeys.length > 0) await this.getClient().send(new UntagResourceCommand$18({
|
|
36101
36627
|
resourceArn: repoArn,
|
|
36102
36628
|
tagKeys: removedKeys
|
|
36103
36629
|
}));
|
|
36104
|
-
if (Object.keys(newTagMap).length > 0) await this.getClient().send(new TagResourceCommand$
|
|
36630
|
+
if (Object.keys(newTagMap).length > 0) await this.getClient().send(new TagResourceCommand$18({
|
|
36105
36631
|
resourceArn: repoArn,
|
|
36106
36632
|
tags: newTagMap
|
|
36107
36633
|
}));
|
|
@@ -36208,7 +36734,7 @@ var CodeCommitRepositoryProvider = class {
|
|
|
36208
36734
|
throw err;
|
|
36209
36735
|
}
|
|
36210
36736
|
if (!metadata?.Arn) continue;
|
|
36211
|
-
if ((await this.getClient().send(new ListTagsForResourceCommand$
|
|
36737
|
+
if ((await this.getClient().send(new ListTagsForResourceCommand$19({ resourceArn: metadata.Arn }))).tags?.["aws:cdk:path"] === input.cdkPath) return {
|
|
36212
36738
|
physicalId: repo.repositoryName,
|
|
36213
36739
|
attributes: this.toAttributes(metadata)
|
|
36214
36740
|
};
|
|
@@ -36358,7 +36884,7 @@ var DLMLifecyclePolicyProvider = class {
|
|
|
36358
36884
|
if (tagsChanged && arn) {
|
|
36359
36885
|
const removedKeys = Object.keys(oldTags).filter((k) => !(k in newTags));
|
|
36360
36886
|
if (removedKeys.length > 0) {
|
|
36361
|
-
await this.getClient().send(new UntagResourceCommand$
|
|
36887
|
+
await this.getClient().send(new UntagResourceCommand$19({
|
|
36362
36888
|
ResourceArn: arn,
|
|
36363
36889
|
TagKeys: removedKeys
|
|
36364
36890
|
}));
|
|
@@ -36367,7 +36893,7 @@ var DLMLifecyclePolicyProvider = class {
|
|
|
36367
36893
|
const tagsToAdd = {};
|
|
36368
36894
|
for (const [k, v] of Object.entries(newTags)) if (oldTags[k] !== v) tagsToAdd[k] = v;
|
|
36369
36895
|
if (Object.keys(tagsToAdd).length > 0) {
|
|
36370
|
-
await this.getClient().send(new TagResourceCommand$
|
|
36896
|
+
await this.getClient().send(new TagResourceCommand$19({
|
|
36371
36897
|
ResourceArn: arn,
|
|
36372
36898
|
Tags: tagsToAdd
|
|
36373
36899
|
}));
|
|
@@ -36570,11 +37096,11 @@ var S3VectorsProvider = class {
|
|
|
36570
37096
|
}
|
|
36571
37097
|
if (!resourceArn) throw new ProvisioningError(`Could not resolve ARN for S3 VectorBucket ${logicalId} (${physicalId}); cannot apply tag update.`, resourceType, logicalId, physicalId);
|
|
36572
37098
|
try {
|
|
36573
|
-
if (Object.keys(toSet).length > 0) await this.getClient().send(new TagResourceCommand$
|
|
37099
|
+
if (Object.keys(toSet).length > 0) await this.getClient().send(new TagResourceCommand$20({
|
|
36574
37100
|
resourceArn,
|
|
36575
37101
|
tags: toSet
|
|
36576
37102
|
}));
|
|
36577
|
-
if (toRemove.length > 0) await this.getClient().send(new UntagResourceCommand$
|
|
37103
|
+
if (toRemove.length > 0) await this.getClient().send(new UntagResourceCommand$20({
|
|
36578
37104
|
resourceArn,
|
|
36579
37105
|
tagKeys: toRemove
|
|
36580
37106
|
}));
|
|
@@ -36702,7 +37228,7 @@ var S3VectorsProvider = class {
|
|
|
36702
37228
|
if (Object.keys(enc).length > 0) result["EncryptionConfiguration"] = enc;
|
|
36703
37229
|
}
|
|
36704
37230
|
if (bucket?.vectorBucketArn) try {
|
|
36705
|
-
result["Tags"] = normalizeAwsTagsToCfn((await this.getClient().send(new ListTagsForResourceCommand$
|
|
37231
|
+
result["Tags"] = normalizeAwsTagsToCfn((await this.getClient().send(new ListTagsForResourceCommand$20({ resourceArn: bucket.vectorBucketArn }))).tags);
|
|
36706
37232
|
} catch (err) {
|
|
36707
37233
|
this.logger.debug(`S3Vectors ListTagsForResource(${bucket.vectorBucketArn}) failed: ${err instanceof Error ? err.message : String(err)}`);
|
|
36708
37234
|
result["Tags"] = [];
|
|
@@ -36738,7 +37264,7 @@ var S3VectorsProvider = class {
|
|
|
36738
37264
|
for (const bucket of list.vectorBuckets ?? []) {
|
|
36739
37265
|
if (!bucket.vectorBucketName || !bucket.vectorBucketArn) continue;
|
|
36740
37266
|
try {
|
|
36741
|
-
if ((await this.getClient().send(new ListTagsForResourceCommand$
|
|
37267
|
+
if ((await this.getClient().send(new ListTagsForResourceCommand$20({ resourceArn: bucket.vectorBucketArn }))).tags?.["aws:cdk:path"] === input.cdkPath) return {
|
|
36742
37268
|
physicalId: bucket.vectorBucketName,
|
|
36743
37269
|
attributes: {}
|
|
36744
37270
|
};
|
|
@@ -37348,7 +37874,7 @@ var S3TablesProvider = class {
|
|
|
37348
37874
|
attributes: {}
|
|
37349
37875
|
};
|
|
37350
37876
|
if (input.cdkPath) try {
|
|
37351
|
-
if ((await this.getClient().send(new ListTagsForResourceCommand$
|
|
37877
|
+
if ((await this.getClient().send(new ListTagsForResourceCommand$21({ resourceArn: bucket.arn }))).tags?.["aws:cdk:path"] === input.cdkPath) return {
|
|
37352
37878
|
physicalId: bucket.arn,
|
|
37353
37879
|
attributes: {}
|
|
37354
37880
|
};
|
|
@@ -37415,7 +37941,7 @@ var S3TablesProvider = class {
|
|
|
37415
37941
|
for (const table of tables.tables ?? []) {
|
|
37416
37942
|
if (!table.name || !table.tableARN) continue;
|
|
37417
37943
|
try {
|
|
37418
|
-
if ((await this.getClient().send(new ListTagsForResourceCommand$
|
|
37944
|
+
if ((await this.getClient().send(new ListTagsForResourceCommand$21({ resourceArn: table.tableARN }))).tags?.["aws:cdk:path"] === input.cdkPath) return {
|
|
37419
37945
|
physicalId: `${bucket.arn}|${namespaceName}|${table.name}`,
|
|
37420
37946
|
attributes: {}
|
|
37421
37947
|
};
|
|
@@ -37511,7 +38037,7 @@ var S3TablesProvider = class {
|
|
|
37511
38037
|
*/
|
|
37512
38038
|
async readTagsBestEffort(resourceArn) {
|
|
37513
38039
|
try {
|
|
37514
|
-
const tags = (await this.getClient().send(new ListTagsForResourceCommand$
|
|
38040
|
+
const tags = (await this.getClient().send(new ListTagsForResourceCommand$21({ resourceArn }))).tags ?? {};
|
|
37515
38041
|
const out = [];
|
|
37516
38042
|
for (const [Key, Value] of Object.entries(tags)) out.push({
|
|
37517
38043
|
Key,
|
|
@@ -37565,7 +38091,7 @@ var S3TablesProvider = class {
|
|
|
37565
38091
|
const resourceArn = await this.lookupTableArn(tableBucketARN, namespace, name);
|
|
37566
38092
|
if (!resourceArn) throw new ProvisioningError(`applyTableTagsDiff: GetTable returned no tableARN for ${physicalId} — table is gone or state is out-of-sync. Refusing to silently drop the tag update (run 'cdkd state orphan ${logicalId}' to clean up if the table was deleted out-of-band).`, resourceType, logicalId, physicalId);
|
|
37567
38093
|
if (removedKeys.length > 0) try {
|
|
37568
|
-
await this.getClient().send(new UntagResourceCommand$
|
|
38094
|
+
await this.getClient().send(new UntagResourceCommand$21({
|
|
37569
38095
|
resourceArn,
|
|
37570
38096
|
tagKeys: removedKeys
|
|
37571
38097
|
}));
|
|
@@ -37574,7 +38100,7 @@ var S3TablesProvider = class {
|
|
|
37574
38100
|
throw new ProvisioningError(`applyTableTagsDiff: UntagResource failed for ${resourceArn} (keys: ${removedKeys.join(", ")}): ${err instanceof Error ? err.message : String(err)}. State has NOT been updated so the next deploy will retry the tag-diff.`, resourceType, logicalId, physicalId, cause);
|
|
37575
38101
|
}
|
|
37576
38102
|
if (Object.keys(upserts).length > 0) try {
|
|
37577
|
-
await this.getClient().send(new TagResourceCommand$
|
|
38103
|
+
await this.getClient().send(new TagResourceCommand$21({
|
|
37578
38104
|
resourceArn,
|
|
37579
38105
|
tags: upserts
|
|
37580
38106
|
}));
|
|
@@ -37606,7 +38132,7 @@ var S3TablesProvider = class {
|
|
|
37606
38132
|
if (removedKeys.length === 0 && Object.keys(upserts).length === 0) return;
|
|
37607
38133
|
const resourceArn = physicalId;
|
|
37608
38134
|
if (removedKeys.length > 0) try {
|
|
37609
|
-
await this.getClient().send(new UntagResourceCommand$
|
|
38135
|
+
await this.getClient().send(new UntagResourceCommand$21({
|
|
37610
38136
|
resourceArn,
|
|
37611
38137
|
tagKeys: removedKeys
|
|
37612
38138
|
}));
|
|
@@ -37615,7 +38141,7 @@ var S3TablesProvider = class {
|
|
|
37615
38141
|
throw new ProvisioningError(`applyTableBucketTagsDiff: UntagResource failed for ${resourceArn} (keys: ${removedKeys.join(", ")}): ${err instanceof Error ? err.message : String(err)}. State has NOT been updated so the next deploy will retry the tag-diff.`, resourceType, logicalId, physicalId, cause);
|
|
37616
38142
|
}
|
|
37617
38143
|
if (Object.keys(upserts).length > 0) try {
|
|
37618
|
-
await this.getClient().send(new TagResourceCommand$
|
|
38144
|
+
await this.getClient().send(new TagResourceCommand$21({
|
|
37619
38145
|
resourceArn,
|
|
37620
38146
|
tags: upserts
|
|
37621
38147
|
}));
|
|
@@ -37798,11 +38324,11 @@ var ECRProvider = class {
|
|
|
37798
38324
|
if (repoArn) {
|
|
37799
38325
|
const newKeys = new Set((newTags ?? []).map((t) => t.Key).filter((k) => !!k));
|
|
37800
38326
|
const removedKeys = (oldTags ?? []).map((t) => t.Key).filter((k) => !!k && !newKeys.has(k));
|
|
37801
|
-
if (removedKeys.length > 0) await this.getClient().send(new UntagResourceCommand$
|
|
38327
|
+
if (removedKeys.length > 0) await this.getClient().send(new UntagResourceCommand$11({
|
|
37802
38328
|
resourceArn: repoArn,
|
|
37803
38329
|
tagKeys: removedKeys
|
|
37804
38330
|
}));
|
|
37805
|
-
if (newTags && newTags.length > 0) await this.getClient().send(new TagResourceCommand$
|
|
38331
|
+
if (newTags && newTags.length > 0) await this.getClient().send(new TagResourceCommand$11({
|
|
37806
38332
|
resourceArn: repoArn,
|
|
37807
38333
|
tags: newTags
|
|
37808
38334
|
}));
|
|
@@ -37901,7 +38427,7 @@ var ECRProvider = class {
|
|
|
37901
38427
|
if (!(err instanceof LifecyclePolicyNotFoundException)) throw err;
|
|
37902
38428
|
}
|
|
37903
38429
|
if (r.repositoryArn) try {
|
|
37904
|
-
result["Tags"] = normalizeAwsTagsToCfn((await this.getClient().send(new ListTagsForResourceCommand$
|
|
38430
|
+
result["Tags"] = normalizeAwsTagsToCfn((await this.getClient().send(new ListTagsForResourceCommand$8({ resourceArn: r.repositoryArn }))).tags);
|
|
37905
38431
|
} catch (err) {
|
|
37906
38432
|
if (!(err instanceof RepositoryNotFoundException)) throw err;
|
|
37907
38433
|
}
|
|
@@ -37934,7 +38460,7 @@ var ECRProvider = class {
|
|
|
37934
38460
|
for (const repo of list.repositories ?? []) {
|
|
37935
38461
|
if (!repo.repositoryArn || !repo.repositoryName) continue;
|
|
37936
38462
|
try {
|
|
37937
|
-
if (matchesCdkPath((await this.getClient().send(new ListTagsForResourceCommand$
|
|
38463
|
+
if (matchesCdkPath((await this.getClient().send(new ListTagsForResourceCommand$8({ resourceArn: repo.repositoryArn }))).tags, input.cdkPath)) return {
|
|
37938
38464
|
physicalId: repo.repositoryName,
|
|
37939
38465
|
attributes: {}
|
|
37940
38466
|
};
|
|
@@ -39236,6 +39762,9 @@ function registerAllProviders(registry) {
|
|
|
39236
39762
|
registry.register("AWS::ServiceDiscovery::PublicDnsNamespace", serviceDiscoveryProvider);
|
|
39237
39763
|
registry.register("AWS::ServiceDiscovery::Service", serviceDiscoveryProvider);
|
|
39238
39764
|
registry.register("AWS::BedrockAgentCore::Runtime", new AgentCoreRuntimeProvider());
|
|
39765
|
+
registry.register("AWS::BedrockAgentCore::Browser", new AgentCoreBrowserProvider());
|
|
39766
|
+
registry.register("AWS::BedrockAgentCore::CodeInterpreter", new AgentCoreCodeInterpreterProvider());
|
|
39767
|
+
registry.register("AWS::BedrockAgentCore::Evaluator", new AgentCoreEvaluatorProvider());
|
|
39239
39768
|
const appSyncProvider = new AppSyncProvider();
|
|
39240
39769
|
registry.register("AWS::AppSync::GraphQLApi", appSyncProvider);
|
|
39241
39770
|
registry.register("AWS::AppSync::GraphQLSchema", appSyncProvider);
|
|
@@ -58539,7 +59068,7 @@ function reorderArgs(argv) {
|
|
|
58539
59068
|
async function main() {
|
|
58540
59069
|
installPipeCloseHandler();
|
|
58541
59070
|
const program = new Command();
|
|
58542
|
-
program.name("cdkd").description("CDK Direct - Deploy AWS CDK apps directly via SDK/Cloud Control API").version("0.
|
|
59071
|
+
program.name("cdkd").description("CDK Direct - Deploy AWS CDK apps directly via SDK/Cloud Control API").version("0.243.0");
|
|
58543
59072
|
program.addCommand(createBootstrapCommand());
|
|
58544
59073
|
program.addCommand(createSynthCommand());
|
|
58545
59074
|
program.addCommand(createListCommand());
|