@aws-cdk/integ-runner 2.197.14 → 2.197.16
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/THIRD_PARTY_LICENSES +1 -1
- package/lib/workers/extract/index.js +413 -324
- package/package.json +6 -6
package/THIRD_PARTY_LICENSES
CHANGED
|
@@ -21278,7 +21278,7 @@ THE SOFTWARE.
|
|
|
21278
21278
|
|
|
21279
21279
|
----------------
|
|
21280
21280
|
|
|
21281
|
-
** basic-ftp@5.
|
|
21281
|
+
** basic-ftp@5.3.0 - https://www.npmjs.com/package/basic-ftp/v/5.3.0 | MIT
|
|
21282
21282
|
Copyright (c) 2019 Patrick Juchli
|
|
21283
21283
|
|
|
21284
21284
|
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
@@ -1287,6 +1287,8 @@ var init_metadata_schema = __esm({
|
|
|
1287
1287
|
ArtifactMetadataEntryType8["LOGICAL_ID"] = "aws:cdk:logicalId";
|
|
1288
1288
|
ArtifactMetadataEntryType8["STACK_TAGS"] = "aws:cdk:stack-tags";
|
|
1289
1289
|
ArtifactMetadataEntryType8["DO_NOT_REFACTOR"] = "aws:cdk:do-not-refactor";
|
|
1290
|
+
ArtifactMetadataEntryType8["CREATION_STACK"] = "aws:cdk:creationStack";
|
|
1291
|
+
ArtifactMetadataEntryType8["PROPERTY_ASSIGNMENT"] = "aws:cdk:propertyAssignment";
|
|
1290
1292
|
return ArtifactMetadataEntryType8;
|
|
1291
1293
|
})(ArtifactMetadataEntryType || {});
|
|
1292
1294
|
}
|
|
@@ -4670,7 +4672,7 @@ var require_semver2 = __commonJS({
|
|
|
4670
4672
|
// ../cloud-assembly-schema/cli-version.json
|
|
4671
4673
|
var require_cli_version = __commonJS({
|
|
4672
4674
|
"../cloud-assembly-schema/cli-version.json"(exports2, module2) {
|
|
4673
|
-
module2.exports = { version: "2.1118.
|
|
4675
|
+
module2.exports = { version: "2.1118.3" };
|
|
4674
4676
|
}
|
|
4675
4677
|
});
|
|
4676
4678
|
|
|
@@ -5095,12 +5097,22 @@ have a unique display name. (Default - no display name)`,
|
|
|
5095
5097
|
{
|
|
5096
5098
|
$ref: "#/definitions/ContainerImageAssetMetadataEntry"
|
|
5097
5099
|
},
|
|
5100
|
+
{
|
|
5101
|
+
$ref: "#/definitions/PropertyMutationMetadataEntry"
|
|
5102
|
+
},
|
|
5098
5103
|
{
|
|
5099
5104
|
type: "array",
|
|
5100
5105
|
items: {
|
|
5101
5106
|
$ref: "#/definitions/Tag"
|
|
5102
5107
|
}
|
|
5103
5108
|
},
|
|
5109
|
+
{
|
|
5110
|
+
description: "Type of creation stack data",
|
|
5111
|
+
type: "array",
|
|
5112
|
+
items: {
|
|
5113
|
+
type: "string"
|
|
5114
|
+
}
|
|
5115
|
+
},
|
|
5104
5116
|
{
|
|
5105
5117
|
type: [
|
|
5106
5118
|
"string",
|
|
@@ -5296,6 +5308,27 @@ have a unique display name. (Default - no display name)`,
|
|
|
5296
5308
|
"type"
|
|
5297
5309
|
]
|
|
5298
5310
|
},
|
|
5311
|
+
PropertyMutationMetadataEntry: {
|
|
5312
|
+
description: "Metadata type of a PropertyMutation",
|
|
5313
|
+
type: "object",
|
|
5314
|
+
properties: {
|
|
5315
|
+
propertyName: {
|
|
5316
|
+
description: "Name of the property",
|
|
5317
|
+
type: "string"
|
|
5318
|
+
},
|
|
5319
|
+
stackTrace: {
|
|
5320
|
+
description: "Stack trace of the mutation",
|
|
5321
|
+
type: "array",
|
|
5322
|
+
items: {
|
|
5323
|
+
type: "string"
|
|
5324
|
+
}
|
|
5325
|
+
}
|
|
5326
|
+
},
|
|
5327
|
+
required: [
|
|
5328
|
+
"propertyName",
|
|
5329
|
+
"stackTrace"
|
|
5330
|
+
]
|
|
5331
|
+
},
|
|
5299
5332
|
Tag: {
|
|
5300
5333
|
description: "Metadata Entry spec for stack tag.",
|
|
5301
5334
|
type: "object",
|
|
@@ -6676,7 +6709,7 @@ var require_integ_schema = __commonJS({
|
|
|
6676
6709
|
var require_version = __commonJS({
|
|
6677
6710
|
"../cloud-assembly-schema/schema/version.json"(exports2, module2) {
|
|
6678
6711
|
module2.exports = {
|
|
6679
|
-
schemaHash: "
|
|
6712
|
+
schemaHash: "794dc834654646b4a60c6d8ea46ed0245a71de33e598289f6922082951768d04",
|
|
6680
6713
|
$comment: "Do not hold back the version on additions: jsonschema validation of the manifest by the consumer will trigger errors on unexpected fields.",
|
|
6681
6714
|
revision: 53
|
|
6682
6715
|
};
|
|
@@ -112855,7 +112888,7 @@ var require_dist_cjs56 = __commonJS({
|
|
|
112855
112888
|
__name(this, "ListResourcesCommand");
|
|
112856
112889
|
}
|
|
112857
112890
|
};
|
|
112858
|
-
var
|
|
112891
|
+
var UpdateResourceCommand2 = class extends smithyClient.Command.classBuilder().ep(commonParams6).m(function(Command, cs, config, o6) {
|
|
112859
112892
|
return [middlewareEndpoint.getEndpointPlugin(config, Command.getEndpointParameterInstructions())];
|
|
112860
112893
|
}).s("CloudApiService", "UpdateResource", {}).n("CloudControlClient", "UpdateResourceCommand").sc(schemas_0.UpdateResource$).build() {
|
|
112861
112894
|
static {
|
|
@@ -112918,7 +112951,7 @@ var require_dist_cjs56 = __commonJS({
|
|
|
112918
112951
|
GetResourceRequestStatusCommand,
|
|
112919
112952
|
ListResourceRequestsCommand,
|
|
112920
112953
|
ListResourcesCommand: ListResourcesCommand2,
|
|
112921
|
-
UpdateResourceCommand
|
|
112954
|
+
UpdateResourceCommand: UpdateResourceCommand2
|
|
112922
112955
|
};
|
|
112923
112956
|
var paginators = {
|
|
112924
112957
|
paginateListResourceRequests,
|
|
@@ -112979,7 +113012,7 @@ var require_dist_cjs56 = __commonJS({
|
|
|
112979
113012
|
exports2.ListResourcesCommand = ListResourcesCommand2;
|
|
112980
113013
|
exports2.Operation = Operation;
|
|
112981
113014
|
exports2.OperationStatus = OperationStatus;
|
|
112982
|
-
exports2.UpdateResourceCommand =
|
|
113015
|
+
exports2.UpdateResourceCommand = UpdateResourceCommand2;
|
|
112983
113016
|
exports2.paginateListResourceRequests = paginateListResourceRequests;
|
|
112984
113017
|
exports2.paginateListResources = paginateListResources;
|
|
112985
113018
|
exports2.waitForResourceRequestSuccess = waitForResourceRequestSuccess;
|
|
@@ -118643,7 +118676,7 @@ var require_dist_cjs57 = __commonJS({
|
|
|
118643
118676
|
__name(this, "DescribeStackSetOperationCommand");
|
|
118644
118677
|
}
|
|
118645
118678
|
};
|
|
118646
|
-
var
|
|
118679
|
+
var DescribeTypeCommand2 = class extends smithyClient.Command.classBuilder().ep(commonParams6).m(function(Command, cs, config, o6) {
|
|
118647
118680
|
return [middlewareEndpoint.getEndpointPlugin(config, Command.getEndpointParameterInstructions())];
|
|
118648
118681
|
}).s("CloudFormation", "DescribeType", {}).n("CloudFormationClient", "DescribeTypeCommand").sc(schemas_0.DescribeType$).build() {
|
|
118649
118682
|
static {
|
|
@@ -119941,7 +119974,7 @@ var require_dist_cjs57 = __commonJS({
|
|
|
119941
119974
|
DescribeStacksCommand: DescribeStacksCommand2,
|
|
119942
119975
|
DescribeStackSetCommand,
|
|
119943
119976
|
DescribeStackSetOperationCommand,
|
|
119944
|
-
DescribeTypeCommand,
|
|
119977
|
+
DescribeTypeCommand: DescribeTypeCommand2,
|
|
119945
119978
|
DescribeTypeRegistrationCommand,
|
|
119946
119979
|
DetectStackDriftCommand: DetectStackDriftCommand2,
|
|
119947
119980
|
DetectStackResourceDriftCommand: DetectStackResourceDriftCommand2,
|
|
@@ -120622,7 +120655,7 @@ var require_dist_cjs57 = __commonJS({
|
|
|
120622
120655
|
exports2.DescribeStackSetCommand = DescribeStackSetCommand;
|
|
120623
120656
|
exports2.DescribeStackSetOperationCommand = DescribeStackSetOperationCommand;
|
|
120624
120657
|
exports2.DescribeStacksCommand = DescribeStacksCommand2;
|
|
120625
|
-
exports2.DescribeTypeCommand =
|
|
120658
|
+
exports2.DescribeTypeCommand = DescribeTypeCommand2;
|
|
120626
120659
|
exports2.DescribeTypeRegistrationCommand = DescribeTypeRegistrationCommand;
|
|
120627
120660
|
exports2.DetailedStatus = DetailedStatus;
|
|
120628
120661
|
exports2.DetectStackDriftCommand = DetectStackDriftCommand2;
|
|
@@ -285216,7 +285249,8 @@ var init_sdk = __esm({
|
|
|
285216
285249
|
const client = new import_client_cloudcontrol.CloudControlClient(this.config);
|
|
285217
285250
|
return {
|
|
285218
285251
|
listResources: /* @__PURE__ */ __name((input) => client.send(new import_client_cloudcontrol.ListResourcesCommand(input)), "listResources"),
|
|
285219
|
-
getResource: /* @__PURE__ */ __name((input) => client.send(new import_client_cloudcontrol.GetResourceCommand(input)), "getResource")
|
|
285252
|
+
getResource: /* @__PURE__ */ __name((input) => client.send(new import_client_cloudcontrol.GetResourceCommand(input)), "getResource"),
|
|
285253
|
+
updateResource: /* @__PURE__ */ __name((input) => client.send(new import_client_cloudcontrol.UpdateResourceCommand(input)), "updateResource")
|
|
285220
285254
|
};
|
|
285221
285255
|
}
|
|
285222
285256
|
cloudFormation() {
|
|
@@ -285242,6 +285276,7 @@ var init_sdk = __esm({
|
|
|
285242
285276
|
describeStackResourceDrifts: /* @__PURE__ */ __name((input) => client.send(new import_client_cloudformation.DescribeStackResourceDriftsCommand(input)), "describeStackResourceDrifts"),
|
|
285243
285277
|
describeStacks: /* @__PURE__ */ __name((input) => client.send(new import_client_cloudformation.DescribeStacksCommand(input)), "describeStacks"),
|
|
285244
285278
|
describeStackResources: /* @__PURE__ */ __name((input) => client.send(new import_client_cloudformation.DescribeStackResourcesCommand(input)), "describeStackResources"),
|
|
285279
|
+
describeType: /* @__PURE__ */ __name((input) => client.send(new import_client_cloudformation.DescribeTypeCommand(input)), "describeType"),
|
|
285245
285280
|
executeChangeSet: /* @__PURE__ */ __name((input) => client.send(new import_client_cloudformation.ExecuteChangeSetCommand(input)), "executeChangeSet"),
|
|
285246
285281
|
getGeneratedTemplate: /* @__PURE__ */ __name((input) => client.send(new import_client_cloudformation.GetGeneratedTemplateCommand(input)), "getGeneratedTemplate"),
|
|
285247
285282
|
getTemplate: /* @__PURE__ */ __name((input) => client.send(new import_client_cloudformation.GetTemplateCommand(input)), "getTemplate"),
|
|
@@ -285423,13 +285458,13 @@ var init_sdk = __esm({
|
|
|
285423
285458
|
updateFunctionCode: /* @__PURE__ */ __name((input) => client.send(new import_client_lambda.UpdateFunctionCodeCommand(input)), "updateFunctionCode"),
|
|
285424
285459
|
updateFunctionConfiguration: /* @__PURE__ */ __name((input) => client.send(new import_client_lambda.UpdateFunctionConfigurationCommand(input)), "updateFunctionConfiguration"),
|
|
285425
285460
|
// Waiters
|
|
285426
|
-
waitUntilFunctionUpdated: /* @__PURE__ */ __name((
|
|
285461
|
+
waitUntilFunctionUpdated: /* @__PURE__ */ __name((minDelaySeconds, maxDelaySeconds, input) => {
|
|
285427
285462
|
return (0, import_client_lambda.waitUntilFunctionUpdatedV2)(
|
|
285428
285463
|
{
|
|
285429
285464
|
client,
|
|
285430
|
-
maxDelay:
|
|
285431
|
-
minDelay:
|
|
285432
|
-
maxWaitTime:
|
|
285465
|
+
maxDelay: maxDelaySeconds,
|
|
285466
|
+
minDelay: minDelaySeconds,
|
|
285467
|
+
maxWaitTime: maxDelaySeconds * 60
|
|
285433
285468
|
},
|
|
285434
285469
|
input
|
|
285435
285470
|
);
|
|
@@ -292013,7 +292048,7 @@ async function asyncGlobalReplace(str, regex, cb) {
|
|
|
292013
292048
|
ret.push(str.slice(start));
|
|
292014
292049
|
return ret.join("");
|
|
292015
292050
|
}
|
|
292016
|
-
var LazyListStackResources, LazyLookupExport, CfnEvaluationException, EvaluateCloudFormationTemplate, RESOURCE_TYPE_SPECIAL_NAMES, RESOURCE_TYPE_ATTRIBUTES_FORMATS;
|
|
292051
|
+
var LazyListStackResources, LazyLookupExport, CfnEvaluationException, EvaluateCloudFormationTemplate, RESOURCE_TYPE_PRIMARY_IDENTIFIERS, RESOURCE_TYPE_SPECIAL_NAMES, RESOURCE_TYPE_ATTRIBUTES_FORMATS;
|
|
292017
292052
|
var init_evaluate_cloudformation_template = __esm({
|
|
292018
292053
|
"../toolkit-lib/lib/api/cloudformation/evaluate-cloudformation-template.ts"() {
|
|
292019
292054
|
"use strict";
|
|
@@ -292099,6 +292134,7 @@ var init_evaluate_cloudformation_template = __esm({
|
|
|
292099
292134
|
stackResources;
|
|
292100
292135
|
lookupExport;
|
|
292101
292136
|
cachedUrlSuffix;
|
|
292137
|
+
_cloudControl;
|
|
292102
292138
|
constructor(props) {
|
|
292103
292139
|
this.stackArtifact = props.stackArtifact;
|
|
292104
292140
|
this.stackName = props.stackName ?? props.stackArtifact.stackName;
|
|
@@ -292117,6 +292153,12 @@ var init_evaluate_cloudformation_template = __esm({
|
|
|
292117
292153
|
this.stackResources = new LazyListStackResources(this.sdk, this.stackName);
|
|
292118
292154
|
this.lookupExport = new LazyLookupExport(this.sdk);
|
|
292119
292155
|
}
|
|
292156
|
+
get cloudControl() {
|
|
292157
|
+
if (!this._cloudControl) {
|
|
292158
|
+
this._cloudControl = this.sdk.cloudControl();
|
|
292159
|
+
}
|
|
292160
|
+
return this._cloudControl;
|
|
292161
|
+
}
|
|
292120
292162
|
// clones current EvaluateCloudFormationTemplate object, but updates the stack name
|
|
292121
292163
|
async createNestedEvaluateCloudFormationTemplate(stackName, nestedTemplate, nestedStackParameters) {
|
|
292122
292164
|
const evaluatedParams = await this.evaluateCfnExpression(nestedStackParameters);
|
|
@@ -292250,6 +292292,41 @@ var init_evaluate_cloudformation_template = __esm({
|
|
|
292250
292292
|
}
|
|
292251
292293
|
return cfnExpression;
|
|
292252
292294
|
}
|
|
292295
|
+
/**
|
|
292296
|
+
* Best-effort attempt to construct the Cloud Control API primary identifier for a resource.
|
|
292297
|
+
*
|
|
292298
|
+
* Cloud Control compound identifiers are pipe-delimited, ordered by the `primaryIdentifier`
|
|
292299
|
+
* array in the resource type schema (e.g. `DatabaseName|TableName` for `AWS::Glue::Table`).
|
|
292300
|
+
*
|
|
292301
|
+
* CloudFormation's `PhysicalResourceId` (the `physicalId` parameter here) is the `Ref` return
|
|
292302
|
+
* value for the resource, which is resource-type-specific and may not correspond to the Cloud
|
|
292303
|
+
* Control Primary Identifier.
|
|
292304
|
+
*
|
|
292305
|
+
* For properties present in the template, we resolve them directly. For properties NOT in the
|
|
292306
|
+
* template (e.g. service-generated read-only values), we fall back to `physicalId`. This is
|
|
292307
|
+
* only correct when:
|
|
292308
|
+
*
|
|
292309
|
+
* - Exactly one property in the identifier is missing from the template, AND
|
|
292310
|
+
* - That property happens to be the one that `Ref` returns for this resource type.
|
|
292311
|
+
*
|
|
292312
|
+
* If multiple properties are missing, `physicalId` is reused for all of them.
|
|
292313
|
+
*/
|
|
292314
|
+
async evaluateCloudControlIdentifier(logicalId, resourceType, physicalId) {
|
|
292315
|
+
if (resourceType in RESOURCE_TYPE_PRIMARY_IDENTIFIERS) {
|
|
292316
|
+
const primaryProps = RESOURCE_TYPE_PRIMARY_IDENTIFIERS[resourceType];
|
|
292317
|
+
const parts = [];
|
|
292318
|
+
for (const propName of primaryProps) {
|
|
292319
|
+
const templateVal = this.getResourceProperty(logicalId, propName);
|
|
292320
|
+
if (templateVal) {
|
|
292321
|
+
parts.push(await this.evaluateCfnExpression(templateVal));
|
|
292322
|
+
} else {
|
|
292323
|
+
parts.push(physicalId);
|
|
292324
|
+
}
|
|
292325
|
+
}
|
|
292326
|
+
return parts.join("|");
|
|
292327
|
+
}
|
|
292328
|
+
return physicalId;
|
|
292329
|
+
}
|
|
292253
292330
|
getResourceProperty(logicalId, propertyName) {
|
|
292254
292331
|
return this.template.Resources?.[logicalId]?.Properties?.[propertyName];
|
|
292255
292332
|
}
|
|
@@ -292336,33 +292413,43 @@ var init_evaluate_cloudformation_template = __esm({
|
|
|
292336
292413
|
}
|
|
292337
292414
|
return void 0;
|
|
292338
292415
|
}
|
|
292339
|
-
formatResourceAttribute(resource, attribute) {
|
|
292416
|
+
async formatResourceAttribute(resource, attribute) {
|
|
292340
292417
|
const physicalId = resource.PhysicalResourceId;
|
|
292341
292418
|
if (!attribute) {
|
|
292342
292419
|
return physicalId;
|
|
292343
292420
|
}
|
|
292344
292421
|
const resourceTypeFormats = RESOURCE_TYPE_ATTRIBUTES_FORMATS[resource.ResourceType];
|
|
292345
|
-
if (
|
|
292346
|
-
|
|
292347
|
-
|
|
292348
|
-
|
|
292422
|
+
if (resourceTypeFormats) {
|
|
292423
|
+
const attributeFormatFunc = resourceTypeFormats[attribute];
|
|
292424
|
+
if (attributeFormatFunc) {
|
|
292425
|
+
const service = this.getServiceOfResource(resource);
|
|
292426
|
+
const resourceTypeArnPart = this.getResourceTypeArnPartOfResource(resource);
|
|
292427
|
+
return attributeFormatFunc({
|
|
292428
|
+
partition: this.partition,
|
|
292429
|
+
service,
|
|
292430
|
+
region: this.region,
|
|
292431
|
+
account: this.account,
|
|
292432
|
+
resourceType: resourceTypeArnPart,
|
|
292433
|
+
resourceName: physicalId
|
|
292434
|
+
});
|
|
292435
|
+
}
|
|
292349
292436
|
}
|
|
292350
|
-
|
|
292351
|
-
|
|
292352
|
-
|
|
292353
|
-
|
|
292354
|
-
|
|
292437
|
+
try {
|
|
292438
|
+
const identifier = await this.evaluateCloudControlIdentifier(resource.LogicalResourceId, resource.ResourceType, physicalId);
|
|
292439
|
+
const response = await this.cloudControl.getResource({
|
|
292440
|
+
TypeName: resource.ResourceType,
|
|
292441
|
+
Identifier: identifier
|
|
292442
|
+
});
|
|
292443
|
+
const props = JSON.parse(response.ResourceDescription?.Properties ?? "{}");
|
|
292444
|
+
if (attribute in props) {
|
|
292445
|
+
return props[attribute];
|
|
292446
|
+
}
|
|
292447
|
+
} catch (error4) {
|
|
292448
|
+
throw new CfnEvaluationException(`Could not find '${attribute}' attribute of the '${resource.ResourceType}' resource becausean error occured while attempting to retrieve the information: '${error4.name}:${error4.message}'`);
|
|
292355
292449
|
}
|
|
292356
|
-
|
|
292357
|
-
|
|
292358
|
-
|
|
292359
|
-
partition: this.partition,
|
|
292360
|
-
service,
|
|
292361
|
-
region: this.region,
|
|
292362
|
-
account: this.account,
|
|
292363
|
-
resourceType: resourceTypeArnPart,
|
|
292364
|
-
resourceName: physicalId
|
|
292365
|
-
});
|
|
292450
|
+
throw new CfnEvaluationException(
|
|
292451
|
+
`We don't support the '${attribute}' attribute of the '${resource.ResourceType}' resource. This is a CDK limitation. Please report it at https://github.com/aws/aws-cdk/issues/new/choose`
|
|
292452
|
+
);
|
|
292366
292453
|
}
|
|
292367
292454
|
getServiceOfResource(resource) {
|
|
292368
292455
|
return resource.ResourceType.split("::")[1].toLowerCase();
|
|
@@ -292376,6 +292463,75 @@ var init_evaluate_cloudformation_template = __esm({
|
|
|
292376
292463
|
);
|
|
292377
292464
|
}
|
|
292378
292465
|
};
|
|
292466
|
+
RESOURCE_TYPE_PRIMARY_IDENTIFIERS = {
|
|
292467
|
+
"AWS::ApiGateway::Authorizer": ["RestApiId", "AuthorizerId"],
|
|
292468
|
+
"AWS::ApiGateway::Deployment": ["DeploymentId", "RestApiId"],
|
|
292469
|
+
"AWS::ApiGateway::Model": ["RestApiId", "Name"],
|
|
292470
|
+
"AWS::ApiGateway::RequestValidator": ["RestApiId", "RequestValidatorId"],
|
|
292471
|
+
"AWS::ApiGateway::DocumentationPart": ["DocumentationPartId", "RestApiId"],
|
|
292472
|
+
"AWS::ApiGateway::Resource": ["RestApiId", "ResourceId"],
|
|
292473
|
+
"AWS::ApiGateway::Stage": ["RestApiId", "StageName"],
|
|
292474
|
+
"AWS::ApiGatewayV2::ApiMapping": ["ApiMappingId", "DomainName"],
|
|
292475
|
+
"AWS::ApiGatewayV2::Authorizer": ["AuthorizerId", "ApiId"],
|
|
292476
|
+
"AWS::ApiGatewayV2::Deployment": ["ApiId", "DeploymentId"],
|
|
292477
|
+
"AWS::ApiGatewayV2::Integration": ["ApiId", "IntegrationId"],
|
|
292478
|
+
"AWS::ApiGatewayV2::IntegrationResponse": ["ApiId", "IntegrationId", "IntegrationResponseId"],
|
|
292479
|
+
"AWS::ApiGatewayV2::Model": ["ApiId", "ModelId"],
|
|
292480
|
+
"AWS::ApiGatewayV2::Route": ["ApiId", "RouteId"],
|
|
292481
|
+
"AWS::ApiGatewayV2::RouteResponse": ["ApiId", "RouteId", "RouteResponseId"],
|
|
292482
|
+
"AWS::ApiGatewayV2::Stage": ["Id"],
|
|
292483
|
+
"AWS::AppConfig::ConfigurationProfile": ["ApplicationId", "ConfigurationProfileId"],
|
|
292484
|
+
"AWS::AppConfig::Environment": ["ApplicationId", "EnvironmentId"],
|
|
292485
|
+
"AWS::AppConfig::HostedConfigurationVersion": ["ApplicationId", "ConfigurationProfileId", "VersionNumber"],
|
|
292486
|
+
"AWS::AppMesh::GatewayRoute": ["Id"],
|
|
292487
|
+
"AWS::AppMesh::Mesh": ["Id"],
|
|
292488
|
+
"AWS::AppMesh::Route": ["Id"],
|
|
292489
|
+
"AWS::AppMesh::VirtualGateway": ["Id"],
|
|
292490
|
+
"AWS::AppMesh::VirtualNode": ["Id"],
|
|
292491
|
+
"AWS::AppMesh::VirtualRouter": ["Id"],
|
|
292492
|
+
"AWS::AppMesh::VirtualService": ["Id"],
|
|
292493
|
+
"AWS::AppSync::ApiKey": ["ApiKeyId"],
|
|
292494
|
+
"AWS::AppSync::GraphQLApi": ["ApiId"],
|
|
292495
|
+
"AWS::Batch::JobDefinition": ["JobDefinitionName"],
|
|
292496
|
+
"AWS::CloudWatch::InsightRule": ["Id"],
|
|
292497
|
+
"AWS::CodeBuild::Project": ["Id"],
|
|
292498
|
+
"AWS::CodeBuild::ReportGroup": ["Id"],
|
|
292499
|
+
"AWS::CodeDeploy::DeploymentGroup": ["ApplicationName", "DeploymentGroupName"],
|
|
292500
|
+
"AWS::CodePipeline::Webhook": ["Id"],
|
|
292501
|
+
"AWS::Cognito::UserPoolClient": ["UserPoolId", "ClientId"],
|
|
292502
|
+
"AWS::Cognito::UserPoolDomain": ["UserPoolId", "Domain"],
|
|
292503
|
+
"AWS::Cognito::UserPoolGroup": ["UserPoolId", "GroupName"],
|
|
292504
|
+
"AWS::Cognito::UserPoolIdentityProvider": ["UserPoolId", "ProviderName"],
|
|
292505
|
+
"AWS::Cognito::UserPoolResourceServer": ["UserPoolId", "Identifier"],
|
|
292506
|
+
"AWS::Cognito::UserPoolUser": ["UserPoolId", "Username"],
|
|
292507
|
+
"AWS::DAX::Cluster": ["Id"],
|
|
292508
|
+
"AWS::DAX::ParameterGroup": ["Id"],
|
|
292509
|
+
"AWS::DAX::SubnetGroup": ["Id"],
|
|
292510
|
+
"AWS::DMS::EventSubscription": ["Id"],
|
|
292511
|
+
"AWS::EC2::EIP": ["PublicIp", "AllocationId"],
|
|
292512
|
+
"AWS::ECS::Service": ["ServiceArn", "Cluster"],
|
|
292513
|
+
"AWS::ElastiCache::CacheCluster": ["Id"],
|
|
292514
|
+
"AWS::ElasticLoadBalancing::LoadBalancer": ["Id"],
|
|
292515
|
+
"AWS::ElastiCache::User": ["UserId"],
|
|
292516
|
+
"AWS::Elasticsearch::Domain": ["Id"],
|
|
292517
|
+
"AWS::Events::Rule": ["Arn"],
|
|
292518
|
+
"AWS::EventSchemas::RegistryPolicy": ["Id"],
|
|
292519
|
+
"AWS::Glue::DevEndpoint": ["Id"],
|
|
292520
|
+
"AWS::Glue::Workflow": ["Id"],
|
|
292521
|
+
"AWS::IoT::Policy": ["Id"],
|
|
292522
|
+
"AWS::Logs::LogStream": ["LogGroupName", "LogStreamName"],
|
|
292523
|
+
"AWS::Logs::SubscriptionFilter": ["FilterName", "LogGroupName"],
|
|
292524
|
+
"AWS::MediaConvert::JobTemplate": ["Id"],
|
|
292525
|
+
"AWS::MediaConvert::Preset": ["Id"],
|
|
292526
|
+
"AWS::MediaConvert::Queue": ["Id"],
|
|
292527
|
+
"AWS::Route53::RecordSet": ["Id"],
|
|
292528
|
+
"AWS::SageMaker::Device": ["Device/DeviceName"],
|
|
292529
|
+
"AWS::SecretsManager::ResourcePolicy": ["Id"],
|
|
292530
|
+
"AWS::SecretsManager::SecretTargetAttachment": ["Id"],
|
|
292531
|
+
"AWS::SES::ReceiptRuleSet": ["Id"],
|
|
292532
|
+
"AWS::SSM::MaintenanceWindowTarget": ["WindowId", "WindowTargetId"],
|
|
292533
|
+
"AWS::SSM::MaintenanceWindowTask": ["WindowId", "WindowTaskId"]
|
|
292534
|
+
};
|
|
292379
292535
|
RESOURCE_TYPE_SPECIAL_NAMES = {
|
|
292380
292536
|
"AWS::Events::EventBus": {
|
|
292381
292537
|
resourceType: "event-bus"
|
|
@@ -310555,156 +310711,6 @@ var init_appsync_mapping_templates = __esm({
|
|
|
310555
310711
|
}
|
|
310556
310712
|
});
|
|
310557
310713
|
|
|
310558
|
-
// ../toolkit-lib/lib/api/hotswap/bedrock-agentcore-runtimes.ts
|
|
310559
|
-
async function isHotswappableBedrockAgentCoreRuntimeChange(logicalId, change, evaluateCfnTemplate) {
|
|
310560
|
-
if (change.newValue.Type !== "AWS::BedrockAgentCore::Runtime") {
|
|
310561
|
-
return [];
|
|
310562
|
-
}
|
|
310563
|
-
const ret = [];
|
|
310564
|
-
const classifiedChanges = classifyChanges(change, [
|
|
310565
|
-
"AgentRuntimeArtifact",
|
|
310566
|
-
"EnvironmentVariables",
|
|
310567
|
-
"Description"
|
|
310568
|
-
]);
|
|
310569
|
-
classifiedChanges.reportNonHotswappablePropertyChanges(ret);
|
|
310570
|
-
const namesOfHotswappableChanges = Object.keys(classifiedChanges.hotswappableProps);
|
|
310571
|
-
if (namesOfHotswappableChanges.length === 0) {
|
|
310572
|
-
return ret;
|
|
310573
|
-
}
|
|
310574
|
-
const agentRuntimeId = await evaluateCfnTemplate.findPhysicalNameFor(logicalId);
|
|
310575
|
-
if (!agentRuntimeId) {
|
|
310576
|
-
return ret;
|
|
310577
|
-
}
|
|
310578
|
-
const runtimeChange = await evaluateBedrockAgentCoreRuntimeProps(
|
|
310579
|
-
classifiedChanges.hotswappableProps,
|
|
310580
|
-
evaluateCfnTemplate
|
|
310581
|
-
);
|
|
310582
|
-
ret.push({
|
|
310583
|
-
change: {
|
|
310584
|
-
cause: change,
|
|
310585
|
-
resources: [{
|
|
310586
|
-
logicalId,
|
|
310587
|
-
resourceType: change.newValue.Type,
|
|
310588
|
-
physicalName: agentRuntimeId,
|
|
310589
|
-
metadata: evaluateCfnTemplate.metadataFor(logicalId)
|
|
310590
|
-
}]
|
|
310591
|
-
},
|
|
310592
|
-
hotswappable: true,
|
|
310593
|
-
service: "bedrock-agentcore",
|
|
310594
|
-
apply: /* @__PURE__ */ __name(async (sdk) => {
|
|
310595
|
-
const bedrockAgentCore = sdk.bedrockAgentCoreControl();
|
|
310596
|
-
const currentRuntime = await bedrockAgentCore.getAgentRuntime({
|
|
310597
|
-
agentRuntimeId
|
|
310598
|
-
});
|
|
310599
|
-
if (!currentRuntime.agentRuntimeArtifact) {
|
|
310600
|
-
throw new ToolkitError("RuntimeMissingArtifact", "Current runtime does not have an artifact");
|
|
310601
|
-
}
|
|
310602
|
-
if (!currentRuntime.roleArn) {
|
|
310603
|
-
throw new ToolkitError("RuntimeMissingRoleArn", "Current runtime does not have a roleArn");
|
|
310604
|
-
}
|
|
310605
|
-
if (!currentRuntime.networkConfiguration) {
|
|
310606
|
-
throw new ToolkitError("RuntimeMissingNetworkConfig", "Current runtime does not have a networkConfiguration");
|
|
310607
|
-
}
|
|
310608
|
-
await bedrockAgentCore.updateAgentRuntime({
|
|
310609
|
-
agentRuntimeId,
|
|
310610
|
-
agentRuntimeArtifact: runtimeChange.artifact ? toSdkAgentRuntimeArtifact(runtimeChange.artifact) : currentRuntime.agentRuntimeArtifact,
|
|
310611
|
-
roleArn: currentRuntime.roleArn,
|
|
310612
|
-
networkConfiguration: currentRuntime.networkConfiguration,
|
|
310613
|
-
description: runtimeChange.description ?? currentRuntime.description,
|
|
310614
|
-
authorizerConfiguration: currentRuntime.authorizerConfiguration,
|
|
310615
|
-
requestHeaderConfiguration: currentRuntime.requestHeaderConfiguration,
|
|
310616
|
-
protocolConfiguration: currentRuntime.protocolConfiguration,
|
|
310617
|
-
lifecycleConfiguration: currentRuntime.lifecycleConfiguration,
|
|
310618
|
-
environmentVariables: runtimeChange.environmentVariables ?? currentRuntime.environmentVariables
|
|
310619
|
-
});
|
|
310620
|
-
}, "apply")
|
|
310621
|
-
});
|
|
310622
|
-
return ret;
|
|
310623
|
-
}
|
|
310624
|
-
async function evaluateBedrockAgentCoreRuntimeProps(hotswappablePropChanges, evaluateCfnTemplate) {
|
|
310625
|
-
const runtimeChange = {};
|
|
310626
|
-
for (const updatedPropName in hotswappablePropChanges) {
|
|
310627
|
-
const updatedProp = hotswappablePropChanges[updatedPropName];
|
|
310628
|
-
switch (updatedPropName) {
|
|
310629
|
-
case "AgentRuntimeArtifact":
|
|
310630
|
-
runtimeChange.artifact = await evaluateAgentRuntimeArtifact(
|
|
310631
|
-
updatedProp.newValue,
|
|
310632
|
-
evaluateCfnTemplate
|
|
310633
|
-
);
|
|
310634
|
-
break;
|
|
310635
|
-
case "Description":
|
|
310636
|
-
runtimeChange.description = await evaluateCfnTemplate.evaluateCfnExpression(updatedProp.newValue);
|
|
310637
|
-
break;
|
|
310638
|
-
case "EnvironmentVariables":
|
|
310639
|
-
runtimeChange.environmentVariables = await evaluateCfnTemplate.evaluateCfnExpression(updatedProp.newValue);
|
|
310640
|
-
break;
|
|
310641
|
-
default:
|
|
310642
|
-
throw new ToolkitError(
|
|
310643
|
-
"UnexpectedHotswapProperty",
|
|
310644
|
-
"Unexpected hotswappable property for BedrockAgentCore Runtime. Please report this at github.com/aws/aws-cdk/issues/new/choose"
|
|
310645
|
-
);
|
|
310646
|
-
}
|
|
310647
|
-
}
|
|
310648
|
-
return runtimeChange;
|
|
310649
|
-
}
|
|
310650
|
-
async function evaluateAgentRuntimeArtifact(artifactValue, evaluateCfnTemplate) {
|
|
310651
|
-
if (artifactValue.CodeConfiguration) {
|
|
310652
|
-
const codeConfig = artifactValue.CodeConfiguration;
|
|
310653
|
-
const code = codeConfig.Code;
|
|
310654
|
-
const s3Location = code.S3 ? {
|
|
310655
|
-
bucket: await evaluateCfnTemplate.evaluateCfnExpression(code.S3.Bucket),
|
|
310656
|
-
prefix: await evaluateCfnTemplate.evaluateCfnExpression(code.S3.Prefix),
|
|
310657
|
-
versionId: code.S3.VersionId ? await evaluateCfnTemplate.evaluateCfnExpression(code.S3.VersionId) : void 0
|
|
310658
|
-
} : void 0;
|
|
310659
|
-
return {
|
|
310660
|
-
codeConfiguration: {
|
|
310661
|
-
code: s3Location ? { s3: s3Location } : {},
|
|
310662
|
-
runtime: await evaluateCfnTemplate.evaluateCfnExpression(codeConfig.Runtime),
|
|
310663
|
-
entryPoint: await evaluateCfnTemplate.evaluateCfnExpression(codeConfig.EntryPoint)
|
|
310664
|
-
}
|
|
310665
|
-
};
|
|
310666
|
-
}
|
|
310667
|
-
if (artifactValue.ContainerConfiguration) {
|
|
310668
|
-
return {
|
|
310669
|
-
containerConfiguration: {
|
|
310670
|
-
containerUri: await evaluateCfnTemplate.evaluateCfnExpression(
|
|
310671
|
-
artifactValue.ContainerConfiguration.ContainerUri
|
|
310672
|
-
)
|
|
310673
|
-
}
|
|
310674
|
-
};
|
|
310675
|
-
}
|
|
310676
|
-
return void 0;
|
|
310677
|
-
}
|
|
310678
|
-
function toSdkAgentRuntimeArtifact(artifact) {
|
|
310679
|
-
if (artifact.codeConfiguration) {
|
|
310680
|
-
const code = artifact.codeConfiguration.code.s3 ? { s3: artifact.codeConfiguration.code.s3 } : void 0;
|
|
310681
|
-
return {
|
|
310682
|
-
codeConfiguration: {
|
|
310683
|
-
code,
|
|
310684
|
-
runtime: artifact.codeConfiguration.runtime,
|
|
310685
|
-
entryPoint: artifact.codeConfiguration.entryPoint
|
|
310686
|
-
}
|
|
310687
|
-
};
|
|
310688
|
-
}
|
|
310689
|
-
if (artifact.containerConfiguration) {
|
|
310690
|
-
return {
|
|
310691
|
-
containerConfiguration: artifact.containerConfiguration
|
|
310692
|
-
};
|
|
310693
|
-
}
|
|
310694
|
-
throw new ToolkitError("RuntimeArtifactMissingConfig", "AgentRuntimeArtifact must have either codeConfiguration or containerConfiguration");
|
|
310695
|
-
}
|
|
310696
|
-
var init_bedrock_agentcore_runtimes = __esm({
|
|
310697
|
-
"../toolkit-lib/lib/api/hotswap/bedrock-agentcore-runtimes.ts"() {
|
|
310698
|
-
"use strict";
|
|
310699
|
-
init_common3();
|
|
310700
|
-
init_toolkit_error();
|
|
310701
|
-
__name(isHotswappableBedrockAgentCoreRuntimeChange, "isHotswappableBedrockAgentCoreRuntimeChange");
|
|
310702
|
-
__name(evaluateBedrockAgentCoreRuntimeProps, "evaluateBedrockAgentCoreRuntimeProps");
|
|
310703
|
-
__name(evaluateAgentRuntimeArtifact, "evaluateAgentRuntimeArtifact");
|
|
310704
|
-
__name(toSdkAgentRuntimeArtifact, "toSdkAgentRuntimeArtifact");
|
|
310705
|
-
}
|
|
310706
|
-
});
|
|
310707
|
-
|
|
310708
310714
|
// ../toolkit-lib/lib/api/hotswap/code-build-projects.ts
|
|
310709
310715
|
async function isHotswappableCodeBuildProjectChange(logicalId, change, evaluateCfnTemplate) {
|
|
310710
310716
|
if (change.newValue.Type !== "AWS::CodeBuild::Project") {
|
|
@@ -310993,7 +310999,7 @@ async function isHotswappableLambdaFunctionChange(logicalId, change, evaluateCfn
|
|
|
310993
310999
|
const operations = [];
|
|
310994
311000
|
if (lambdaCodeChange.code !== void 0 || lambdaCodeChange.configurations !== void 0) {
|
|
310995
311001
|
if (lambdaCodeChange.code !== void 0) {
|
|
310996
|
-
|
|
311002
|
+
await lambda.updateFunctionCode({
|
|
310997
311003
|
FunctionName: functionName,
|
|
310998
311004
|
S3Bucket: lambdaCodeChange.code.s3Bucket,
|
|
310999
311005
|
S3Key: lambdaCodeChange.code.s3Key,
|
|
@@ -311001,7 +311007,7 @@ async function isHotswappableLambdaFunctionChange(logicalId, change, evaluateCfn
|
|
|
311001
311007
|
ZipFile: lambdaCodeChange.code.functionCodeZip,
|
|
311002
311008
|
S3ObjectVersion: lambdaCodeChange.code.s3ObjectVersion
|
|
311003
311009
|
});
|
|
311004
|
-
await waitForLambdasPropertiesUpdateToFinish(
|
|
311010
|
+
await waitForLambdasPropertiesUpdateToFinish(lambda, functionName);
|
|
311005
311011
|
}
|
|
311006
311012
|
if (lambdaCodeChange.configurations !== void 0) {
|
|
311007
311013
|
const updateRequest = {
|
|
@@ -311013,8 +311019,8 @@ async function isHotswappableLambdaFunctionChange(logicalId, change, evaluateCfn
|
|
|
311013
311019
|
if (lambdaCodeChange.configurations.environment !== void 0) {
|
|
311014
311020
|
updateRequest.Environment = lambdaCodeChange.configurations.environment;
|
|
311015
311021
|
}
|
|
311016
|
-
|
|
311017
|
-
await waitForLambdasPropertiesUpdateToFinish(
|
|
311022
|
+
await lambda.updateFunctionConfiguration(updateRequest);
|
|
311023
|
+
await waitForLambdasPropertiesUpdateToFinish(lambda, functionName);
|
|
311018
311024
|
}
|
|
311019
311025
|
const versions = dependencies.filter((d6) => d6.resourceType === "AWS::Lambda::Version");
|
|
311020
311026
|
if (versions.length) {
|
|
@@ -311132,10 +311138,10 @@ function zipString(fileName, rawString) {
|
|
|
311132
311138
|
void archive.finalize();
|
|
311133
311139
|
});
|
|
311134
311140
|
}
|
|
311135
|
-
async function waitForLambdasPropertiesUpdateToFinish(
|
|
311136
|
-
const
|
|
311137
|
-
const
|
|
311138
|
-
await lambda.waitUntilFunctionUpdated(
|
|
311141
|
+
async function waitForLambdasPropertiesUpdateToFinish(lambda, functionName) {
|
|
311142
|
+
const minDelaySeconds = 1;
|
|
311143
|
+
const maxDelaySeconds = 10;
|
|
311144
|
+
await lambda.waitUntilFunctionUpdated(minDelaySeconds, maxDelaySeconds, {
|
|
311139
311145
|
FunctionName: functionName
|
|
311140
311146
|
});
|
|
311141
311147
|
}
|
|
@@ -311301,50 +311307,99 @@ var init_s3_bucket_deployments = __esm({
|
|
|
311301
311307
|
}
|
|
311302
311308
|
});
|
|
311303
311309
|
|
|
311304
|
-
// ../toolkit-lib/lib/api/hotswap/
|
|
311305
|
-
async function
|
|
311306
|
-
if (change.newValue.Type !== "AWS::StepFunctions::StateMachine") {
|
|
311307
|
-
return [];
|
|
311308
|
-
}
|
|
311310
|
+
// ../toolkit-lib/lib/api/hotswap/cloud-control-resource.ts
|
|
311311
|
+
async function isHotswappableCloudControlChange(logicalId, change, evaluateCfnTemplate, _hotswapPropertyOverrides) {
|
|
311309
311312
|
const ret = [];
|
|
311310
|
-
const
|
|
311313
|
+
const changedPropNames = Object.keys(change.propertyUpdates);
|
|
311314
|
+
if (changedPropNames.length === 0) {
|
|
311315
|
+
return ret;
|
|
311316
|
+
}
|
|
311317
|
+
const classifiedChanges = classifyChanges(change, changedPropNames);
|
|
311311
311318
|
classifiedChanges.reportNonHotswappablePropertyChanges(ret);
|
|
311312
|
-
|
|
311313
|
-
|
|
311314
|
-
|
|
311315
|
-
|
|
311316
|
-
|
|
311317
|
-
|
|
311318
|
-
|
|
311319
|
-
|
|
311319
|
+
if (classifiedChanges.namesOfHotswappableProps.length === 0) {
|
|
311320
|
+
return ret;
|
|
311321
|
+
}
|
|
311322
|
+
const resourceType = change.newValue.Type;
|
|
311323
|
+
const identifier = await resolveCloudControlIdentifier(logicalId, resourceType, evaluateCfnTemplate);
|
|
311324
|
+
if (!identifier) {
|
|
311325
|
+
ret.push(nonHotswappableChange(
|
|
311326
|
+
change,
|
|
311327
|
+
"resource-unsupported" /* RESOURCE_UNSUPPORTED */,
|
|
311328
|
+
"Could not determine the physical name or primary identifier of the resource, so Cloud Control API cannot hotswap it."
|
|
311329
|
+
));
|
|
311330
|
+
return ret;
|
|
311331
|
+
}
|
|
311332
|
+
const evaluatedProps = {};
|
|
311333
|
+
for (const propName of classifiedChanges.namesOfHotswappableProps) {
|
|
311334
|
+
try {
|
|
311335
|
+
evaluatedProps[propName] = await evaluateCfnTemplate.evaluateCfnExpression(
|
|
311336
|
+
change.propertyUpdates[propName].newValue
|
|
311337
|
+
);
|
|
311338
|
+
} catch (e6) {
|
|
311339
|
+
if (e6 instanceof CfnEvaluationException) {
|
|
311340
|
+
ret.push(nonHotswappableChange(
|
|
311341
|
+
change,
|
|
311342
|
+
"resource-unsupported" /* RESOURCE_UNSUPPORTED */,
|
|
311343
|
+
`Property '${propName}' of resource '${logicalId}' has been replaced and could not be resolved: ${e6.message}`
|
|
311344
|
+
));
|
|
311345
|
+
return ret;
|
|
311346
|
+
}
|
|
311347
|
+
throw e6;
|
|
311320
311348
|
}
|
|
311321
|
-
ret.push({
|
|
311322
|
-
change: {
|
|
311323
|
-
cause: change,
|
|
311324
|
-
resources: [{
|
|
311325
|
-
logicalId,
|
|
311326
|
-
resourceType: change.newValue.Type,
|
|
311327
|
-
physicalName: stateMachineArn?.split(":")[6],
|
|
311328
|
-
metadata: evaluateCfnTemplate.metadataFor(logicalId)
|
|
311329
|
-
}]
|
|
311330
|
-
},
|
|
311331
|
-
hotswappable: true,
|
|
311332
|
-
service: "stepfunctions-service",
|
|
311333
|
-
apply: /* @__PURE__ */ __name(async (sdk) => {
|
|
311334
|
-
await sdk.stepFunctions().updateStateMachine({
|
|
311335
|
-
stateMachineArn,
|
|
311336
|
-
definition: await evaluateCfnTemplate.evaluateCfnExpression(change.propertyUpdates.DefinitionString.newValue)
|
|
311337
|
-
});
|
|
311338
|
-
}, "apply")
|
|
311339
|
-
});
|
|
311340
311349
|
}
|
|
311350
|
+
ret.push({
|
|
311351
|
+
change: {
|
|
311352
|
+
cause: change,
|
|
311353
|
+
resources: [{
|
|
311354
|
+
logicalId,
|
|
311355
|
+
resourceType,
|
|
311356
|
+
physicalName: identifier,
|
|
311357
|
+
metadata: evaluateCfnTemplate.metadataFor(logicalId)
|
|
311358
|
+
}]
|
|
311359
|
+
},
|
|
311360
|
+
hotswappable: true,
|
|
311361
|
+
service: "cloudcontrol",
|
|
311362
|
+
apply: /* @__PURE__ */ __name(async (sdk) => {
|
|
311363
|
+
const cloudControl = sdk.cloudControl();
|
|
311364
|
+
const patchOps = [];
|
|
311365
|
+
for (const propName of classifiedChanges.namesOfHotswappableProps) {
|
|
311366
|
+
const diff = change.propertyUpdates[propName];
|
|
311367
|
+
const newValue = evaluatedProps[propName];
|
|
311368
|
+
if (diff.isRemoval) {
|
|
311369
|
+
patchOps.push({ op: "remove", path: `/${propName}` });
|
|
311370
|
+
} else if (diff.isAddition) {
|
|
311371
|
+
patchOps.push({ op: "add", path: `/${propName}`, value: newValue });
|
|
311372
|
+
} else {
|
|
311373
|
+
patchOps.push({ op: "replace", path: `/${propName}`, value: newValue });
|
|
311374
|
+
}
|
|
311375
|
+
}
|
|
311376
|
+
if (patchOps.length === 0) {
|
|
311377
|
+
return;
|
|
311378
|
+
}
|
|
311379
|
+
await cloudControl.updateResource({
|
|
311380
|
+
TypeName: resourceType,
|
|
311381
|
+
Identifier: identifier,
|
|
311382
|
+
PatchDocument: JSON.stringify(patchOps)
|
|
311383
|
+
});
|
|
311384
|
+
}, "apply")
|
|
311385
|
+
});
|
|
311341
311386
|
return ret;
|
|
311342
311387
|
}
|
|
311343
|
-
|
|
311344
|
-
|
|
311388
|
+
async function resolveCloudControlIdentifier(logicalId, resourceType, evaluateCfnTemplate) {
|
|
311389
|
+
const cfnPhysicalId = await evaluateCfnTemplate.findPhysicalNameFor(logicalId);
|
|
311390
|
+
if (!cfnPhysicalId) {
|
|
311391
|
+
return void 0;
|
|
311392
|
+
}
|
|
311393
|
+
return evaluateCfnTemplate.evaluateCloudControlIdentifier(logicalId, resourceType, cfnPhysicalId);
|
|
311394
|
+
}
|
|
311395
|
+
var init_cloud_control_resource = __esm({
|
|
311396
|
+
"../toolkit-lib/lib/api/hotswap/cloud-control-resource.ts"() {
|
|
311345
311397
|
"use strict";
|
|
311346
311398
|
init_common3();
|
|
311347
|
-
|
|
311399
|
+
init_payloads();
|
|
311400
|
+
init_cloudformation2();
|
|
311401
|
+
__name(isHotswappableCloudControlChange, "isHotswappableCloudControlChange");
|
|
311402
|
+
__name(resolveCloudControlIdentifier, "resolveCloudControlIdentifier");
|
|
311348
311403
|
}
|
|
311349
311404
|
});
|
|
311350
311405
|
|
|
@@ -311560,6 +311615,8 @@ async function classifyResourceChanges(stackChanges, evaluateCfnTemplate, sdk, n
|
|
|
311560
311615
|
const promises3 = [];
|
|
311561
311616
|
const hotswappableResources = new Array();
|
|
311562
311617
|
const nonHotswappableResources = new Array();
|
|
311618
|
+
const nestedStackTasks = [];
|
|
311619
|
+
const limit = pLimit2(10);
|
|
311563
311620
|
for (const logicalId of Object.keys(stackChanges.outputs.changes)) {
|
|
311564
311621
|
nonHotswappableResources.push({
|
|
311565
311622
|
hotswappable: false,
|
|
@@ -311576,16 +311633,14 @@ async function classifyResourceChanges(stackChanges, evaluateCfnTemplate, sdk, n
|
|
|
311576
311633
|
}
|
|
311577
311634
|
for (const [logicalId, change] of Object.entries(resourceDifferences)) {
|
|
311578
311635
|
if (change.newValue?.Type === "AWS::CloudFormation::Stack" && change.oldValue?.Type === "AWS::CloudFormation::Stack") {
|
|
311579
|
-
|
|
311636
|
+
nestedStackTasks.push(limit(() => findNestedHotswappableChanges(
|
|
311580
311637
|
logicalId,
|
|
311581
311638
|
change,
|
|
311582
311639
|
nestedStackNames,
|
|
311583
311640
|
evaluateCfnTemplate,
|
|
311584
311641
|
sdk,
|
|
311585
311642
|
hotswapPropertyOverrides
|
|
311586
|
-
);
|
|
311587
|
-
hotswappableResources.push(...nestedHotswappableResources.hotswappable);
|
|
311588
|
-
nonHotswappableResources.push(...nestedHotswappableResources.nonHotswappable);
|
|
311643
|
+
)));
|
|
311589
311644
|
continue;
|
|
311590
311645
|
}
|
|
311591
311646
|
const hotswappableChangeCandidate = isCandidateForHotswapping(logicalId, change, evaluateCfnTemplate);
|
|
@@ -311604,9 +311659,14 @@ async function classifyResourceChanges(stackChanges, evaluateCfnTemplate, sdk, n
|
|
|
311604
311659
|
nonHotswappableResources.push(nonHotswappableResource(hotswappableChangeCandidate));
|
|
311605
311660
|
}
|
|
311606
311661
|
}
|
|
311662
|
+
const nestedResults = await Promise.all(nestedStackTasks);
|
|
311663
|
+
for (const nested of nestedResults) {
|
|
311664
|
+
hotswappableResources.push(...nested.hotswappable);
|
|
311665
|
+
nonHotswappableResources.push(...nested.nonHotswappable);
|
|
311666
|
+
}
|
|
311607
311667
|
const changesDetectionResults = [];
|
|
311608
|
-
|
|
311609
|
-
|
|
311668
|
+
const detectorResults = await Promise.all(promises3.map((fn) => limit(fn)));
|
|
311669
|
+
for (const hotswapDetectionResults of detectorResults) {
|
|
311610
311670
|
changesDetectionResults.push(hotswapDetectionResults);
|
|
311611
311671
|
}
|
|
311612
311672
|
for (const resourceDetectionResults of changesDetectionResults) {
|
|
@@ -311876,16 +311936,15 @@ var init_hotswap_deployments = __esm({
|
|
|
311876
311936
|
init_util();
|
|
311877
311937
|
init_cloudformation2();
|
|
311878
311938
|
init_appsync_mapping_templates();
|
|
311879
|
-
init_bedrock_agentcore_runtimes();
|
|
311880
311939
|
init_code_build_projects();
|
|
311881
311940
|
init_common3();
|
|
311882
311941
|
init_ecs_services();
|
|
311883
311942
|
init_lambda_functions();
|
|
311884
311943
|
init_s3_bucket_deployments();
|
|
311885
|
-
init_stepfunctions_state_machines();
|
|
311886
311944
|
init_toolkit_error();
|
|
311887
311945
|
init_private();
|
|
311888
311946
|
init_plugin2();
|
|
311947
|
+
init_cloud_control_resource();
|
|
311889
311948
|
pLimit2 = require_p_limit();
|
|
311890
311949
|
RESOURCE_DETECTORS = {
|
|
311891
311950
|
// Lambda
|
|
@@ -311897,10 +311956,8 @@ var init_hotswap_deployments = __esm({
|
|
|
311897
311956
|
"AWS::AppSync::FunctionConfiguration": isHotswappableAppSyncChange,
|
|
311898
311957
|
"AWS::AppSync::GraphQLSchema": isHotswappableAppSyncChange,
|
|
311899
311958
|
"AWS::AppSync::ApiKey": isHotswappableAppSyncChange,
|
|
311900
|
-
"AWS::BedrockAgentCore::Runtime": isHotswappableBedrockAgentCoreRuntimeChange,
|
|
311901
311959
|
"AWS::ECS::TaskDefinition": isHotswappableEcsServiceChange,
|
|
311902
311960
|
"AWS::CodeBuild::Project": isHotswappableCodeBuildProjectChange,
|
|
311903
|
-
"AWS::StepFunctions::StateMachine": isHotswappableStateMachineChange,
|
|
311904
311961
|
"Custom::CDKBucketDeployment": isHotswappableS3BucketDeploymentChange,
|
|
311905
311962
|
"AWS::IAM::Policy": /* @__PURE__ */ __name(async (logicalId, change, evaluateCfnTemplate) => {
|
|
311906
311963
|
if (await skipChangeForS3DeployCustomResourcePolicy(logicalId, change, evaluateCfnTemplate)) {
|
|
@@ -311908,7 +311965,23 @@ var init_hotswap_deployments = __esm({
|
|
|
311908
311965
|
}
|
|
311909
311966
|
return [nonHotswappableResource(change)];
|
|
311910
311967
|
}, "AWS::IAM::Policy"),
|
|
311911
|
-
"AWS::CDK::Metadata": /* @__PURE__ */ __name(async () => [], "AWS::CDK::Metadata")
|
|
311968
|
+
"AWS::CDK::Metadata": /* @__PURE__ */ __name(async () => [], "AWS::CDK::Metadata"),
|
|
311969
|
+
// Resources that use CCAPIS
|
|
311970
|
+
"AWS::ApiGateway::RestApi": isHotswappableCloudControlChange,
|
|
311971
|
+
"AWS::ApiGateway::Deployment": isHotswappableCloudControlChange,
|
|
311972
|
+
"AWS::ApiGateway::Method": isHotswappableCloudControlChange,
|
|
311973
|
+
"AWS::ApiGatewayV2::Api": isHotswappableCloudControlChange,
|
|
311974
|
+
"AWS::ApiGatewayV2::Integration": isHotswappableCloudControlChange,
|
|
311975
|
+
"AWS::Bedrock::Agent": isHotswappableCloudControlChange,
|
|
311976
|
+
"AWS::Events::Rule": isHotswappableCloudControlChange,
|
|
311977
|
+
"AWS::DynamoDB::Table": isHotswappableCloudControlChange,
|
|
311978
|
+
"AWS::DynamoDB::GlobalTable": isHotswappableCloudControlChange,
|
|
311979
|
+
"AWS::SQS::Queue": isHotswappableCloudControlChange,
|
|
311980
|
+
"AWS::CloudWatch::Alarm": isHotswappableCloudControlChange,
|
|
311981
|
+
"AWS::CloudWatch::CompositeAlarm": isHotswappableCloudControlChange,
|
|
311982
|
+
"AWS::CloudWatch::Dashboard": isHotswappableCloudControlChange,
|
|
311983
|
+
"AWS::StepFunctions::StateMachine": isHotswappableCloudControlChange,
|
|
311984
|
+
"AWS::BedrockAgentCore::Runtime": isHotswappableCloudControlChange
|
|
311912
311985
|
};
|
|
311913
311986
|
__name(tryHotswapDeployment, "tryHotswapDeployment");
|
|
311914
311987
|
__name(hotswapDeployment, "hotswapDeployment");
|
|
@@ -313745,12 +313818,19 @@ function resourceMoves(before, after, direction = "direct", ignoreModifications
|
|
|
313745
313818
|
const digestsAfter = resourceDigests(after, direction);
|
|
313746
313819
|
if (!(ignoreModifications || isomorphic(digestsBefore, digestsAfter))) {
|
|
313747
313820
|
const message2 = ["A refactor operation cannot add, remove or update resources. Only resource moves and renames are allowed."];
|
|
313748
|
-
const
|
|
313749
|
-
return Array.from(setDiff(new Set(Object.keys(a6)), new Set(Object.keys(b6)))).flatMap((k6) => a6[k6])
|
|
313750
|
-
}, "
|
|
313821
|
+
const locationsForDigests = /* @__PURE__ */ __name((a6, b6) => {
|
|
313822
|
+
return Array.from(setDiff(new Set(Object.keys(a6)), new Set(Object.keys(b6)))).flatMap((k6) => a6[k6]);
|
|
313823
|
+
}, "locationsForDigests");
|
|
313824
|
+
const formatList = /* @__PURE__ */ __name((locs, icon) => locs.map((x6) => ` [${icon}] ${x6.toPath()}`).sort().join("\n"), "formatList");
|
|
313751
313825
|
const stackNames = /* @__PURE__ */ __name((stacks) => stacks.length === 0 ? "NONE" : stacks.map((s6) => s6.stackName).sort().join(", "), "stackNames");
|
|
313752
|
-
const
|
|
313753
|
-
const
|
|
313826
|
+
const onlyDeployedLocs = locationsForDigests(digestsBefore, digestsAfter);
|
|
313827
|
+
const onlyLocalLocs = locationsForDigests(digestsAfter, digestsBefore);
|
|
313828
|
+
const onlyDeployedPaths = new Set(onlyDeployedLocs.map((l6) => l6.toPath()));
|
|
313829
|
+
const onlyLocalPaths = new Set(onlyLocalLocs.map((l6) => l6.toPath()));
|
|
313830
|
+
const differentPaths = new Set(Array.from(onlyDeployedPaths).filter((p6) => onlyLocalPaths.has(p6)));
|
|
313831
|
+
const onlyDeployed = formatList(onlyDeployedLocs.filter((l6) => !differentPaths.has(l6.toPath())), "-");
|
|
313832
|
+
const onlyLocal = formatList(onlyLocalLocs.filter((l6) => !differentPaths.has(l6.toPath())), "+");
|
|
313833
|
+
const different = formatList([...onlyDeployedLocs, ...onlyLocalLocs].filter((l6) => differentPaths.has(l6.toPath())), "~");
|
|
313754
313834
|
if (onlyDeployed.length > 0) {
|
|
313755
313835
|
message2.push(`The following resources are present only in the AWS environment:
|
|
313756
313836
|
${onlyDeployed}`);
|
|
@@ -313759,6 +313839,11 @@ ${onlyDeployed}`);
|
|
|
313759
313839
|
message2.push(`
|
|
313760
313840
|
The following resources are present only in your CDK application:
|
|
313761
313841
|
${onlyLocal}`);
|
|
313842
|
+
}
|
|
313843
|
+
if (different.length > 0) {
|
|
313844
|
+
message2.push(`
|
|
313845
|
+
The following resources are different in your CDK application and the AWS environment:
|
|
313846
|
+
${different}`);
|
|
313762
313847
|
}
|
|
313763
313848
|
message2.push("");
|
|
313764
313849
|
message2.push("The following stacks were used in the comparison:");
|
|
@@ -317106,11 +317191,6 @@ var init_toolkit = __esm({
|
|
|
317106
317191
|
deploymentMethod: options.deploymentMethod,
|
|
317107
317192
|
cleanupOnNoOp: isExecutingChangeSetDeployment(options.deploymentMethod)
|
|
317108
317193
|
}) : void 0;
|
|
317109
|
-
if (prepareResult?.noOp === true) {
|
|
317110
|
-
await ioHelper.notify(IO.CDK_TOOLKIT_I5900.msg(chalk23.green(`
|
|
317111
|
-
\u2705 ${stack.displayName} (no changes)`), prepareResult));
|
|
317112
|
-
return;
|
|
317113
|
-
}
|
|
317114
317194
|
const formatter = new DiffFormatter({
|
|
317115
317195
|
templateInfo: {
|
|
317116
317196
|
oldTemplate: currentTemplate,
|
|
@@ -317148,7 +317228,7 @@ Do you wish to deploy these changes`;
|
|
|
317148
317228
|
deploySpan.incCounter("resources", resourceCount);
|
|
317149
317229
|
let deployDuration;
|
|
317150
317230
|
try {
|
|
317151
|
-
const prepareIsFinal = isNonExecutingChangeSetDeployment(options.deploymentMethod);
|
|
317231
|
+
const prepareIsFinal = prepareResult && (prepareResult.noOp || isNonExecutingChangeSetDeployment(options.deploymentMethod));
|
|
317152
317232
|
let deployResult = prepareIsFinal ? prepareResult : void 0;
|
|
317153
317233
|
let rollback = options.rollback;
|
|
317154
317234
|
let iteration = 0;
|
|
@@ -317229,10 +317309,9 @@ ${deployResult.stackArn}`));
|
|
|
317229
317309
|
hierarchicalId: stack.hierarchicalId
|
|
317230
317310
|
});
|
|
317231
317311
|
} catch (e6) {
|
|
317232
|
-
|
|
317233
|
-
|
|
317234
|
-
|
|
317235
|
-
);
|
|
317312
|
+
const code = ToolkitError.isToolkitError(e6) ? e6.name : "DeployStackFailed";
|
|
317313
|
+
const newMessage = [`\u274C ${chalk23.bold(stack.stackName)} failed:`, ...e6.name ? [`${e6.name}:`] : [], e6.message].join(" ");
|
|
317314
|
+
throw new ToolkitError(code, newMessage);
|
|
317236
317315
|
} finally {
|
|
317237
317316
|
if (options.traceLogs) {
|
|
317238
317317
|
const cloudWatchLogMonitor = options.cloudWatchLogMonitor ?? new CloudWatchLogEventMonitor({ ioHelper });
|
|
@@ -325023,6 +325102,61 @@ Closing reason: ${this._closingError.stack}`;
|
|
|
325023
325102
|
}
|
|
325024
325103
|
});
|
|
325025
325104
|
|
|
325105
|
+
// ../../../node_modules/basic-ftp/dist/netUtils.js
|
|
325106
|
+
var require_netUtils = __commonJS({
|
|
325107
|
+
"../../../node_modules/basic-ftp/dist/netUtils.js"(exports2) {
|
|
325108
|
+
"use strict";
|
|
325109
|
+
Object.defineProperty(exports2, "__esModule", { value: true });
|
|
325110
|
+
exports2.describeTLS = describeTLS;
|
|
325111
|
+
exports2.describeAddress = describeAddress;
|
|
325112
|
+
exports2.upgradeSocket = upgradeSocket;
|
|
325113
|
+
exports2.ipIsPrivateV4Address = ipIsPrivateV4Address;
|
|
325114
|
+
var tls_1 = require("tls");
|
|
325115
|
+
function describeTLS(socket) {
|
|
325116
|
+
if (socket instanceof tls_1.TLSSocket) {
|
|
325117
|
+
const protocol = socket.getProtocol();
|
|
325118
|
+
return protocol ? protocol : "Server socket or disconnected client socket";
|
|
325119
|
+
}
|
|
325120
|
+
return "No encryption";
|
|
325121
|
+
}
|
|
325122
|
+
__name(describeTLS, "describeTLS");
|
|
325123
|
+
function describeAddress(socket) {
|
|
325124
|
+
if (socket.remoteFamily === "IPv6") {
|
|
325125
|
+
return `[${socket.remoteAddress}]:${socket.remotePort}`;
|
|
325126
|
+
}
|
|
325127
|
+
return `${socket.remoteAddress}:${socket.remotePort}`;
|
|
325128
|
+
}
|
|
325129
|
+
__name(describeAddress, "describeAddress");
|
|
325130
|
+
function upgradeSocket(socket, options) {
|
|
325131
|
+
return new Promise((resolve13, reject) => {
|
|
325132
|
+
const tlsOptions = Object.assign({}, options, {
|
|
325133
|
+
socket
|
|
325134
|
+
});
|
|
325135
|
+
const tlsSocket = (0, tls_1.connect)(tlsOptions, () => {
|
|
325136
|
+
const expectCertificate = tlsOptions.rejectUnauthorized !== false;
|
|
325137
|
+
if (expectCertificate && !tlsSocket.authorized) {
|
|
325138
|
+
reject(tlsSocket.authorizationError);
|
|
325139
|
+
} else {
|
|
325140
|
+
tlsSocket.removeAllListeners("error");
|
|
325141
|
+
resolve13(tlsSocket);
|
|
325142
|
+
}
|
|
325143
|
+
}).once("error", (error4) => {
|
|
325144
|
+
reject(error4);
|
|
325145
|
+
});
|
|
325146
|
+
});
|
|
325147
|
+
}
|
|
325148
|
+
__name(upgradeSocket, "upgradeSocket");
|
|
325149
|
+
function ipIsPrivateV4Address(ip = "") {
|
|
325150
|
+
if (ip.startsWith("::ffff:")) {
|
|
325151
|
+
ip = ip.substr(7);
|
|
325152
|
+
}
|
|
325153
|
+
const octets = ip.split(".").map((o6) => parseInt(o6, 10));
|
|
325154
|
+
return octets[0] === 10 || octets[0] === 172 && octets[1] >= 16 && octets[1] <= 31 || octets[0] === 192 && octets[1] === 168 || ip === "127.0.0.1";
|
|
325155
|
+
}
|
|
325156
|
+
__name(ipIsPrivateV4Address, "ipIsPrivateV4Address");
|
|
325157
|
+
}
|
|
325158
|
+
});
|
|
325159
|
+
|
|
325026
325160
|
// ../../../node_modules/basic-ftp/dist/FileInfo.js
|
|
325027
325161
|
var require_FileInfo = __commonJS({
|
|
325028
325162
|
"../../../node_modules/basic-ftp/dist/FileInfo.js"(exports2) {
|
|
@@ -325559,81 +325693,33 @@ var require_StringWriter = __commonJS({
|
|
|
325559
325693
|
static {
|
|
325560
325694
|
__name(this, "StringWriter");
|
|
325561
325695
|
}
|
|
325562
|
-
constructor() {
|
|
325563
|
-
super(
|
|
325564
|
-
this.
|
|
325696
|
+
constructor(maxByteLength = 1 * 1024 * 1024) {
|
|
325697
|
+
super();
|
|
325698
|
+
this.maxByteLength = maxByteLength;
|
|
325699
|
+
this.byteLength = 0;
|
|
325700
|
+
this.bufs = [];
|
|
325565
325701
|
}
|
|
325566
325702
|
_write(chunk, _2, callback) {
|
|
325567
|
-
if (chunk instanceof Buffer) {
|
|
325568
|
-
|
|
325569
|
-
|
|
325570
|
-
}
|
|
325571
|
-
|
|
325703
|
+
if (!(chunk instanceof Buffer)) {
|
|
325704
|
+
callback(new Error("StringWriter: expects chunks of type 'Buffer'."));
|
|
325705
|
+
return;
|
|
325706
|
+
}
|
|
325707
|
+
if (this.byteLength + chunk.byteLength > this.maxByteLength) {
|
|
325708
|
+
callback(new Error(`StringWriter: Maximum bytes exceeded, maxByteLength=${this.maxByteLength}.`));
|
|
325709
|
+
return;
|
|
325572
325710
|
}
|
|
325711
|
+
this.byteLength += chunk.byteLength;
|
|
325712
|
+
this.bufs.push(chunk);
|
|
325713
|
+
callback(null);
|
|
325573
325714
|
}
|
|
325574
325715
|
getText(encoding) {
|
|
325575
|
-
return this.
|
|
325716
|
+
return Buffer.concat(this.bufs).toString(encoding);
|
|
325576
325717
|
}
|
|
325577
325718
|
};
|
|
325578
325719
|
exports2.StringWriter = StringWriter;
|
|
325579
325720
|
}
|
|
325580
325721
|
});
|
|
325581
325722
|
|
|
325582
|
-
// ../../../node_modules/basic-ftp/dist/netUtils.js
|
|
325583
|
-
var require_netUtils = __commonJS({
|
|
325584
|
-
"../../../node_modules/basic-ftp/dist/netUtils.js"(exports2) {
|
|
325585
|
-
"use strict";
|
|
325586
|
-
Object.defineProperty(exports2, "__esModule", { value: true });
|
|
325587
|
-
exports2.describeTLS = describeTLS;
|
|
325588
|
-
exports2.describeAddress = describeAddress;
|
|
325589
|
-
exports2.upgradeSocket = upgradeSocket;
|
|
325590
|
-
exports2.ipIsPrivateV4Address = ipIsPrivateV4Address;
|
|
325591
|
-
var tls_1 = require("tls");
|
|
325592
|
-
function describeTLS(socket) {
|
|
325593
|
-
if (socket instanceof tls_1.TLSSocket) {
|
|
325594
|
-
const protocol = socket.getProtocol();
|
|
325595
|
-
return protocol ? protocol : "Server socket or disconnected client socket";
|
|
325596
|
-
}
|
|
325597
|
-
return "No encryption";
|
|
325598
|
-
}
|
|
325599
|
-
__name(describeTLS, "describeTLS");
|
|
325600
|
-
function describeAddress(socket) {
|
|
325601
|
-
if (socket.remoteFamily === "IPv6") {
|
|
325602
|
-
return `[${socket.remoteAddress}]:${socket.remotePort}`;
|
|
325603
|
-
}
|
|
325604
|
-
return `${socket.remoteAddress}:${socket.remotePort}`;
|
|
325605
|
-
}
|
|
325606
|
-
__name(describeAddress, "describeAddress");
|
|
325607
|
-
function upgradeSocket(socket, options) {
|
|
325608
|
-
return new Promise((resolve13, reject) => {
|
|
325609
|
-
const tlsOptions = Object.assign({}, options, {
|
|
325610
|
-
socket
|
|
325611
|
-
});
|
|
325612
|
-
const tlsSocket = (0, tls_1.connect)(tlsOptions, () => {
|
|
325613
|
-
const expectCertificate = tlsOptions.rejectUnauthorized !== false;
|
|
325614
|
-
if (expectCertificate && !tlsSocket.authorized) {
|
|
325615
|
-
reject(tlsSocket.authorizationError);
|
|
325616
|
-
} else {
|
|
325617
|
-
tlsSocket.removeAllListeners("error");
|
|
325618
|
-
resolve13(tlsSocket);
|
|
325619
|
-
}
|
|
325620
|
-
}).once("error", (error4) => {
|
|
325621
|
-
reject(error4);
|
|
325622
|
-
});
|
|
325623
|
-
});
|
|
325624
|
-
}
|
|
325625
|
-
__name(upgradeSocket, "upgradeSocket");
|
|
325626
|
-
function ipIsPrivateV4Address(ip = "") {
|
|
325627
|
-
if (ip.startsWith("::ffff:")) {
|
|
325628
|
-
ip = ip.substr(7);
|
|
325629
|
-
}
|
|
325630
|
-
const octets = ip.split(".").map((o6) => parseInt(o6, 10));
|
|
325631
|
-
return octets[0] === 10 || octets[0] === 172 && octets[1] >= 16 && octets[1] <= 31 || octets[0] === 192 && octets[1] === 168 || ip === "127.0.0.1";
|
|
325632
|
-
}
|
|
325633
|
-
__name(ipIsPrivateV4Address, "ipIsPrivateV4Address");
|
|
325634
|
-
}
|
|
325635
|
-
});
|
|
325636
|
-
|
|
325637
325723
|
// ../../../node_modules/basic-ftp/dist/transfer.js
|
|
325638
325724
|
var require_transfer2 = __commonJS({
|
|
325639
325725
|
"../../../node_modules/basic-ftp/dist/transfer.js"(exports2) {
|
|
@@ -325909,13 +325995,13 @@ var require_Client = __commonJS({
|
|
|
325909
325995
|
var tls_1 = require("tls");
|
|
325910
325996
|
var util_1 = require("util");
|
|
325911
325997
|
var FtpContext_1 = require_FtpContext();
|
|
325998
|
+
var netUtils_1 = require_netUtils();
|
|
325999
|
+
var parseControlResponse_1 = require_parseControlResponse();
|
|
325912
326000
|
var parseList_1 = require_parseList();
|
|
326001
|
+
var parseListMLSD_1 = require_parseListMLSD();
|
|
325913
326002
|
var ProgressTracker_1 = require_ProgressTracker();
|
|
325914
326003
|
var StringWriter_1 = require_StringWriter();
|
|
325915
|
-
var parseListMLSD_1 = require_parseListMLSD();
|
|
325916
|
-
var netUtils_1 = require_netUtils();
|
|
325917
326004
|
var transfer_1 = require_transfer2();
|
|
325918
|
-
var parseControlResponse_1 = require_parseControlResponse();
|
|
325919
326005
|
var fsReadDir = (0, util_1.promisify)(fs_1.readdir);
|
|
325920
326006
|
var fsMkDir = (0, util_1.promisify)(fs_1.mkdir);
|
|
325921
326007
|
var fsStat = (0, util_1.promisify)(fs_1.stat);
|
|
@@ -325923,7 +326009,8 @@ var require_Client = __commonJS({
|
|
|
325923
326009
|
var fsClose = (0, util_1.promisify)(fs_1.close);
|
|
325924
326010
|
var fsUnlink = (0, util_1.promisify)(fs_1.unlink);
|
|
325925
326011
|
var defaultClientOptions = {
|
|
325926
|
-
allowSeparateTransferHost: true
|
|
326012
|
+
allowSeparateTransferHost: true,
|
|
326013
|
+
maxListingBytes: 40 * 1024 * 1024
|
|
325927
326014
|
};
|
|
325928
326015
|
var LIST_COMMANDS_DEFAULT = /* @__PURE__ */ __name(() => ["LIST -a", "LIST"], "LIST_COMMANDS_DEFAULT");
|
|
325929
326016
|
var LIST_COMMANDS_MLSD = /* @__PURE__ */ __name(() => ["MLSD", "LIST -a", "LIST"], "LIST_COMMANDS_MLSD");
|
|
@@ -325936,13 +326023,15 @@ var require_Client = __commonJS({
|
|
|
325936
326023
|
*
|
|
325937
326024
|
* @param timeout Timeout in milliseconds, use 0 for no timeout. Optional, default is 30 seconds.
|
|
325938
326025
|
*/
|
|
325939
|
-
constructor(timeout = 3e4,
|
|
326026
|
+
constructor(timeout = 3e4, userOptions = defaultClientOptions) {
|
|
325940
326027
|
this.availableListCommands = LIST_COMMANDS_DEFAULT();
|
|
326028
|
+
const options = { ...defaultClientOptions, ...userOptions };
|
|
325941
326029
|
this.ftp = new FtpContext_1.FTPContext(timeout);
|
|
325942
326030
|
this.prepareTransfer = this._enterFirstCompatibleMode([
|
|
325943
326031
|
transfer_1.enterPassiveModeIPv6,
|
|
325944
326032
|
options.allowSeparateTransferHost ? transfer_1.enterPassiveModeIPv4 : transfer_1.enterPassiveModeIPv4_forceControlHostIP
|
|
325945
326033
|
]);
|
|
326034
|
+
this.options = options;
|
|
325946
326035
|
this.parseList = parseList_1.parseList;
|
|
325947
326036
|
this._progressTracker = new ProgressTracker_1.ProgressTracker();
|
|
325948
326037
|
}
|
|
@@ -326379,7 +326468,7 @@ var require_Client = __commonJS({
|
|
|
326379
326468
|
* @protected
|
|
326380
326469
|
*/
|
|
326381
326470
|
async _requestListWithCommand(command) {
|
|
326382
|
-
const buffer = new StringWriter_1.StringWriter();
|
|
326471
|
+
const buffer = new StringWriter_1.StringWriter(this.options.maxListingBytes);
|
|
326383
326472
|
await (0, transfer_1.downloadTo)(buffer, {
|
|
326384
326473
|
ftp: this.ftp,
|
|
326385
326474
|
tracker: this._progressTracker,
|
package/package.json
CHANGED
|
@@ -64,13 +64,13 @@
|
|
|
64
64
|
"ts-jest": "^29.4.9",
|
|
65
65
|
"typescript": "5.9",
|
|
66
66
|
"@aws-cdk/aws-service-spec": "^0.1.171",
|
|
67
|
-
"@aws-cdk/cdk-assets-lib": "1.4.
|
|
67
|
+
"@aws-cdk/cdk-assets-lib": "1.4.4",
|
|
68
68
|
"@aws-cdk/cloud-assembly-api": "2.2.2",
|
|
69
|
-
"@aws-cdk/cloud-assembly-schema": ">=53.
|
|
69
|
+
"@aws-cdk/cloud-assembly-schema": ">=53.17.0",
|
|
70
70
|
"@aws-cdk/cloudformation-diff": "2.187.1",
|
|
71
|
-
"@aws-cdk/toolkit-lib": "1.
|
|
71
|
+
"@aws-cdk/toolkit-lib": "1.22.1",
|
|
72
72
|
"@aws-sdk/client-cloudformation": "^3",
|
|
73
|
-
"aws-cdk": "2.1118.
|
|
73
|
+
"aws-cdk": "2.1118.3",
|
|
74
74
|
"chalk": "^4",
|
|
75
75
|
"chokidar": "^4",
|
|
76
76
|
"fs-extra": "^11",
|
|
@@ -80,7 +80,7 @@
|
|
|
80
80
|
},
|
|
81
81
|
"dependencies": {
|
|
82
82
|
"@aws-cdk/aws-service-spec": "0.1.171",
|
|
83
|
-
"aws-cdk": "2.1118.
|
|
83
|
+
"aws-cdk": "2.1118.3"
|
|
84
84
|
},
|
|
85
85
|
"keywords": [
|
|
86
86
|
"aws",
|
|
@@ -102,7 +102,7 @@
|
|
|
102
102
|
"publishConfig": {
|
|
103
103
|
"access": "public"
|
|
104
104
|
},
|
|
105
|
-
"version": "2.197.
|
|
105
|
+
"version": "2.197.16",
|
|
106
106
|
"packageManager": "yarn@4.13.0",
|
|
107
107
|
"types": "lib/index.d.ts",
|
|
108
108
|
"//": "~~ Generated by projen. To modify, edit .projenrc.js and run \"yarn projen\"."
|