(stepfunctions-tasks): checking for task token in EcsRunTask containerOverrides causes memory explosion
See original GitHub issueAfter the release of 1.108.0, I’m no longer able to successfully cdk synth
my Step Function. The exact same implementation works in 1.107.0 and before (initially written on version 1.95.1).
Reproduction Steps
I’ll try to provide a more concise example, but here’s what I have (I recognize it’s not complete because there are some dependencies where aren’t included)
Expand for sample
internal EosDataLoadStateMachineStack(Construct scope, string id, EosDataLoadStateMachineStackProps props) : base(scope, id, props)
{
AwsEnv = props.Env;
DataLoadStateMachineName = $"{props.AppEnvironment}EosDataLoadStateMachine";
var vpc = Vpc.FromLookup(this, "Vpc", new VpcLookupOptions { VpcId = props.VpcId, });
var privateSubnets = vpc.PrivateSubnets
.Where(subnet => ContextHelper
.GetPrivateSubnetIds(props.Env, props.AppEnvironment)
.Contains(subnet.SubnetId))
.ToArray();
var ecsTaskSubnets = new SubnetSelection { Subnets = privateSubnets, };
var ecsTaskSecurityGroups = new[] { props.MainRegionComputeStack.DataLoadSecurityGroup, };
props.InfrastructureStack.StartDataLoadStateMachineTopic.AddSubscription(new LambdaSubscription(props.MainRegionComputeStack.StartDatabaseLoader));
#region Actions
var checkDataLoadStatus = new LambdaInvoke(this, "CheckDataLoadStatus", new EosLambdaInvokeProps
{
LambdaFunction = props.MainRegionComputeStack.GetIsDataLoadRunning,
ResultPath = "$.IsRunning",
});
var setDataLoadIsRunning = new LambdaInvoke(this, "SetDataLoadIsRunning", new EosLambdaInvokeProps
{
LambdaFunction = props.MainRegionComputeStack.SetDataLoadIsRunning,
ResultPath = JsonPath.DISCARD,
});
var calculateZipHash = new LambdaInvoke(this, "CalculateZipHash", new EosLambdaInvokeProps
{
InputPath = "$.Zip",
LambdaFunction = props.MainRegionComputeStack.CalculateZipHash,
ResultPath = "$.CurrentHash",
});
var getPreviousZipHash = new LambdaInvoke(this, "GetPreviousZipHash", new EosLambdaInvokeProps
{
InputPath = "$.Zip",
LambdaFunction = props.MainRegionComputeStack.GetPreviousZipHash,
ResultPath = "$.PreviousHash",
});
var determineIfZipValid = new EcsRunTask(this, "DetermineIfZipValid", new EcsRunTaskProps
{
Cluster = props.MainRegionComputeStack.Cluster,
ContainerOverrides = new[]
{
new ContainerOverride
{
ContainerDefinition = props.MainRegionComputeStack.DetermineIfZipValid.DefaultContainer,
Environment = new[]
{
new TaskEnvironmentVariable { Name = "BUCKET_NAME", Value = JsonPath.StringAt("$.Zip.BucketName"), },
new TaskEnvironmentVariable { Name = "OBJECT_KEY", Value = JsonPath.StringAt("$.Zip.ObjectKey"), },
new TaskEnvironmentVariable { Name = "TASK_TOKEN", Value = JsonPath.TaskToken, },
}
}
},
IntegrationPattern = IntegrationPattern.WAIT_FOR_TASK_TOKEN,
LaunchTarget = new EcsFargateLaunchTarget(),
ResultPath = "$.Zip.IsValid",
SecurityGroups = ecsTaskSecurityGroups,
Subnets = ecsTaskSubnets,
TaskDefinition = props.MainRegionComputeStack.DetermineIfZipValid,
Timeout = Duration.Minutes(5),
});
GrantSendTaskStatusPermissionsForStateMachine(props.MainRegionComputeStack.DetermineIfZipValid);
var moveZipFile = new LambdaInvoke(this, "MoveZipFile", new EosLambdaInvokeProps
{
InputPath = "$.Zip",
LambdaFunction = props.MainRegionComputeStack.MoveZipFile,
ResultPath = JsonPath.DISCARD,
});
var deleteStagedZipFile = new LambdaInvoke(this, "DeleteStagedZipFile", new EosLambdaInvokeProps
{
InputPath = "$.Zip",
LambdaFunction = props.MainRegionComputeStack.DeleteStagedZipFile,
ResultPath = JsonPath.DISCARD,
});
var determineInactiveSchema = new LambdaInvoke(this, "DetermineInactiveSchema", new EosLambdaInvokeProps
{
LambdaFunction = props.MainRegionComputeStack.DetermineInactiveSchema,
ResultPath = "$.InactiveSchema"
});
var loadDatabase = new EcsRunTask(this, "LoadDatabase", new EcsRunTaskProps
{
Cluster = props.MainRegionComputeStack.Cluster,
LaunchTarget = new EcsFargateLaunchTarget(),
ResultPath = JsonPath.DISCARD,
SecurityGroups = new[] { props.MainRegionComputeStack.DataLoadSecurityGroup, },
TaskDefinition = props.MainRegionComputeStack.LoadCache, // TODO
});
var checkIfReplicationComplete = new LambdaInvoke(this, "CheckIfReplicationComplete", new EosLambdaInvokeProps
{
LambdaFunction = props.MainRegionComputeStack.CheckIfReplicationComplete,
ResultPath = "$.Database.Replication",
});
var incrementElapsedReplicationWaitTime = new LambdaInvoke(this, "IncrementElapsedReplicationWaitTime", new EosLambdaInvokeProps
{
InputPath = "$.Database.Replication",
LambdaFunction = props.MainRegionComputeStack.IncrementElapsedReplicationWaitTime,
ResultPath = "$.Database.Replication",
});
var cacheLoadMain = new EcsRunTask(this, $"CacheLoad-{RegionHelper.GetShortRegion(props.MainRegionComputeStack.Region)}", new EcsRunTaskProps
{
Cluster = props.MainRegionComputeStack.Cluster,
ContainerOverrides = new[]
{
new ContainerOverride
{
ContainerDefinition = props.MainRegionComputeStack.LoadCache.DefaultContainer,
Environment = new[]
{
new TaskEnvironmentVariable { Name = "ORIGIN_REGION", Value = Aws.REGION, },
new TaskEnvironmentVariable { Name = "TASK_TOKEN", Value = JsonPath.TaskToken, },
},
},
},
IntegrationPattern = IntegrationPattern.WAIT_FOR_TASK_TOKEN,
LaunchTarget = new EcsFargateLaunchTarget(),
ResultPath = JsonPath.DISCARD,
SecurityGroups = ecsTaskSecurityGroups,
Subnets = ecsTaskSubnets,
TaskDefinition = props.MainRegionComputeStack.LoadCache,
Timeout = Duration.Minutes(5),
});
GrantSendTaskStatusPermissionsForStateMachine(props.MainRegionComputeStack.LoadCache);
var cacheLoadTasks = new List<IChainable> { cacheLoadMain, };
foreach (var secondaryRegionCompute in props.SecondaryRegionComputeStacks)
{
Topic.FromTopicArn(this, "StartCacheLoadUsWest2Topic", props.InfrastructureStack.StartCacheLoadUsWest2Topic.TopicArn)
.AddSubscription(new LambdaSubscription(secondaryRegionCompute.StartCacheLoader));
GrantSendTaskStatusPermissionsForStateMachine(secondaryRegionCompute.LoadCache);
cacheLoadTasks.Add(new SnsPublish(this, $"CacheLoad-{RegionHelper.GetShortRegion(secondaryRegionCompute.Region)}", new SnsPublishProps
{
IntegrationPattern = IntegrationPattern.WAIT_FOR_TASK_TOKEN,
Message = TaskInput.FromObject(new Dictionary<string, object>
{
{ "Env", props.AppEnvironment.ToString().ToLower() },
{ "OriginRegion", Aws.REGION },
{ "TaskToken", JsonPath.TaskToken },
}),
ResultPath = JsonPath.DISCARD,
Timeout = Duration.Minutes(5),
Topic = props.InfrastructureStack.StartCacheLoadUsWest2Topic,
}));
}
var putCurrentZipHash = new LambdaInvoke(this, "PutCurrentZipHash", new LambdaInvokeProps
{
InputPath = JsonPath.StringAt("$.Zip"),
LambdaFunction = props.MainRegionComputeStack.PutCurrentZipHash,
ResultPath = JsonPath.DISCARD,
});
var updateActiveSchemaParameter = new LambdaInvoke(this, "UpdateActiveSchema", new EosLambdaInvokeProps
{
LambdaFunction = props.MainRegionComputeStack.UpdateActiveSchema,
ResultPath = JsonPath.DISCARD,
});
var resetIsRunningParameter = new LambdaInvoke(this, "ResetIsRunningParameter", new EosLambdaInvokeProps
{
LambdaFunction = props.MainRegionComputeStack.ResetIsRunningParameter,
OutputPath = JsonPath.EntirePayload,
ResultPath = JsonPath.DISCARD,
});
var notifyFailure = new SnsPublish(this, "NotifyFailure", new SnsPublishProps
{
Message = TaskInput.FromObject(new Dictionary<string, object>
{
{
"Error",
new Dictionary<string, object>
{
{ "Cause", JsonPath.StringAt("$.Cause") },
{ "Error", JsonPath.StringAt("$.Error") },
}
},
}),
ResultPath = JsonPath.DISCARD,
Topic = props.InfrastructureStack.StartCacheLoadUsWest2Topic,
});
#endregion
#region State Flow
var start = Chain.Start(checkDataLoadStatus);
checkDataLoadStatus
.AddCatch(notifyFailure)
.Next(new Choice(this, "IsDataLoadRunning")
.When(
Condition.BooleanEquals(JsonPath.StringAt("$.IsRunning"), false),
new Pass(this, "DataLoadIsNotRunning", new PassEntirePayloadProps())
.Next(setDataLoadIsRunning))
.When(
Condition.BooleanEquals(JsonPath.StringAt("$.IsRunning"), true),
new Pass(this, "DataLoadIsRunning", new PassProps
{
Result = Result.FromObject(new Dictionary<string, object>
{
{ "Cause", "DataLoad is already running" },
{ "Error", "null" },
}),
})
.Next(notifyFailure)));
setDataLoadIsRunning
.AddCatch(notifyFailure)
.Next(new Parallel(this, "GetZipHashes", new ParallelProps
{
OutputPath = "$.MergedParallelStateOutput",
ResultPath = "$.MergedParallelStateOutput.Zip",
ResultSelector = new Dictionary<string, object>
{
{ "BucketName.$", JsonPath.StringAt("$.[0].Zip.BucketName" ) },
{ "ObjectKey.$", JsonPath.StringAt("$.[0].Zip.ObjectKey") },
{ "CurrentHash.$", JsonPath.StringAt("$.[0].CurrentHash") },
{ "PreviousHash.$", JsonPath.StringAt("$.[1].PreviousHash") },
},
})
.AddCatch(notifyFailure)
.Branch(new IChainable[] { calculateZipHash, getPreviousZipHash, })
.Next(
new Choice(this, "AreHashesEqual")
.When(
Condition.Not(Condition.StringEqualsJsonPath(JsonPath.StringAt("$.Zip.CurrentHash"), JsonPath.StringAt("$.Zip.PreviousHash"))),
new Pass(this, "HashesAreNotEqual", new PassEntirePayloadProps())
.Next(determineIfZipValid))
.When(
Condition.StringEqualsJsonPath(JsonPath.StringAt("$.Zip.CurrentHash"), JsonPath.StringAt("$.Zip.PreviousHash")),
new Pass(this, "HashesAreEqual", new PassProps
{
Result = Result.FromObject(new Dictionary<string, object>
{
{ "Cause", "Zip hashes are equal" },
{ "Error", "null" },
}),
})
.Next(notifyFailure))));
determineIfZipValid
.AddCatch(notifyFailure)
.Next(new Choice(this, "IsZipValid")
.When(
Condition.BooleanEquals(JsonPath.StringAt("$.Zip.IsValid"), true),
new Pass(this, "ZipIsValid", new PassEntirePayloadProps())
.Next(determineInactiveSchema))
.When(
Condition.BooleanEquals(JsonPath.StringAt("$.Zip.IsValid"), false),
new Pass(this, "ZipIsNotValid", new PassProps
{
Result = Result.FromObject(new Dictionary<string, object>
{
{ "Cause", "Zip is not valid" },
{ "Error", "null" },
}),
})
.Next(notifyFailure)));
determineInactiveSchema
.AddCatch(notifyFailure)
.Next(loadDatabase);
loadDatabase
.AddCatch(notifyFailure)
.Next(checkIfReplicationComplete);
checkIfReplicationComplete
.AddCatch(notifyFailure)
.Next(new Choice(this, "IsReplicationComplete")
.When(
Condition.BooleanEquals("$.Database.Replication.IsComplete", true),
new Pass(this, "ReplicationIsComplete", new PassEntirePayloadProps())
.Next(
new Parallel(this, "LoadCache", new ParallelProps
{
OutputPath = "$.MergedParallelStateOutput",
ResultPath = "$.MergedParallelStateOutput",
ResultSelector = new Dictionary<string, object>
{
{ "Zip.$", JsonPath.StringAt("$.[0].Zip" ) },
{ "InactiveSchema.$", JsonPath.StringAt("$.[0].InactiveSchema") },
{ "Database.$", JsonPath.StringAt("$.[0].Database") },
},
})
.Branch(cacheLoadTasks.ToArray())
.AddCatch(notifyFailure)
.Next(putCurrentZipHash)))
.When(
Condition.NumberGreaterThan(JsonPath.StringAt("$.Database.Replication.ElapsedTimeInMinutes"), 5),
notifyFailure)
.When(
Condition.NumberLessThanEquals(JsonPath.StringAt("$.Database.Replication.ElapsedTimeInMinutes"), 5),
new Pass(this, "MaxReplicationWaitTimeIsNotExceeded", new PassEntirePayloadProps())
.Next(
new Wait(this, "WaitForReplication", new WaitProps
{
Time = WaitTime.Duration(Duration.Minutes(1)),
})
.Next(
incrementElapsedReplicationWaitTime
.AddCatch(notifyFailure)
.Next(checkIfReplicationComplete))))
.Otherwise(notifyFailure));
putCurrentZipHash
.AddCatch(notifyFailure)
.Next(moveZipFile);
moveZipFile
.AddCatch(notifyFailure)
.Next(deleteStagedZipFile);
deleteStagedZipFile
.AddCatch(notifyFailure)
.Next(updateActiveSchemaParameter);
updateActiveSchemaParameter
.AddCatch(notifyFailure)
.Next(new Pass(this, "Succeed", new PassProps
{
Result = Result.FromObject(new Dictionary<string, object> { { "IsSuccess", true } }),
}).Next(resetIsRunningParameter));
notifyFailure
.Next(new Pass(this, "Fail", new PassProps
{
Result = Result.FromObject(new Dictionary<string, object> { { "IsSuccess", false } }),
})
.Next(resetIsRunningParameter));
resetIsRunningParameter
.Next(new Choice(this, "WasSuccessful")
.When(
Condition.BooleanEquals(JsonPath.StringAt("$.IsSuccess"), true),
new Succeed(this, "Success"))
.When(
Condition.BooleanEquals(JsonPath.StringAt("$.IsSuccess"), false),
new Fail(this, "Failure", new FailProps
{
Cause = JsonPath.StringAt("$.Error.Cause"),
})));
#endregion
_ = new StateMachine(this, "DataLoad", new StateMachineProps
{
Definition = start,
Logs = new LogOptions
{
Destination = new LogGroup(this, "DataLoadStateMachineLogs", new LogGroupProps
{
LogGroupName = $"/aws/vendedlogs/states/{props.AppEnvironment}EosDataLoadStateMachine",
RemovalPolicy = props.AppEnvironment.IsProd() ? RemovalPolicy.SNAPSHOT : RemovalPolicy.DESTROY,
}),
IncludeExecutionData = false,
Level = props.AppEnvironment.IsProd() ? LogLevel.ERROR : LogLevel.ALL,
},
StateMachineName = DataLoadStateMachineName,
});
}
What did you expect to happen?
I expected cdk synth
to be successful.
What actually happened?
Expand to see cdk synth -v output
> cdk synth -v
CDK toolkit version: 1.108.1 (build ae24d8a)
Command line arguments: {
_: [ 'synth' ],
v: 1,
verbose: 1,
lookups: true,
'ignore-errors': false,
ignoreErrors: false,
json: false,
j: false,
debug: false,
ec2creds: undefined,
i: undefined,
'version-reporting': undefined,
versionReporting: undefined,
'path-metadata': true,
pathMetadata: true,
'asset-metadata': true,
assetMetadata: true,
'role-arn': undefined,
r: undefined,
roleArn: undefined,
staging: true,
'no-color': false,
noColor: false,
fail: false,
quiet: false,
q: false,
'$0': 'cdk'
}
cdk.json: {
"app": "dotnet run -p src/EosInfrastructureAsCode/EosInfrastructureAsCode.csproj",
"context": {
"@aws-cdk/core:enableStackNameDuplicates": "true",
"aws-cdk:enableDiffNoFail": "true",
"@aws-cdk/core:stackRelativeExports": "true",
"@aws-cdk/aws-ecr-assets:dockerIgnoreSupport": true,
"@aws-cdk/aws-secretsmanager:parseOwnedSecretName": true,
"@aws-cdk/aws-kms:defaultKeyPolicies": true,
"@aws-cdk/core:newStyleStackSynthesis": true
},
"versionReporting": false
}
cdk.context.json: {
// REDACTED
}
merged settings: {
versionReporting: false,
pathMetadata: true,
output: 'cdk.out',
app: 'dotnet run -p src/EosInfrastructureAsCode/EosInfrastructureAsCode.csproj',
context: {
'@aws-cdk/core:enableStackNameDuplicates': 'true',
'aws-cdk:enableDiffNoFail': 'true',
'@aws-cdk/core:stackRelativeExports': 'true',
'@aws-cdk/aws-ecr-assets:dockerIgnoreSupport': true,
'@aws-cdk/aws-secretsmanager:parseOwnedSecretName': true,
'@aws-cdk/aws-kms:defaultKeyPolicies': true,
'@aws-cdk/core:newStyleStackSynthesis': true
},
debug: false,
assetMetadata: true,
toolkitBucket: {},
staging: true,
bundlingStacks: [ '*' ],
lookups: true
}
Determining if we're on an EC2 instance.
Does not look like an EC2 instance.
Toolkit stack: CDKToolkit
Setting "CDK_DEFAULT_REGION" environment variable to us-east-1
Resolving default credentials
Retrieved account ID REDACTED from disk cache
Setting "CDK_DEFAULT_ACCOUNT" environment variable to REDACTED
context: {
// REDACTED
'@aws-cdk/core:enableStackNameDuplicates': 'true',
'aws-cdk:enableDiffNoFail': 'true',
'@aws-cdk/core:stackRelativeExports': 'true',
'@aws-cdk/aws-ecr-assets:dockerIgnoreSupport': true,
'@aws-cdk/aws-secretsmanager:parseOwnedSecretName': true,
'@aws-cdk/aws-kms:defaultKeyPolicies': true,
'@aws-cdk/core:newStyleStackSynthesis': true,
'aws:cdk:enable-path-metadata': true,
'aws:cdk:enable-asset-metadata': true,
'aws:cdk:disable-version-reporting': true,
'aws:cdk:bundling-stacks': [ '*' ]
}
outdir: cdk.out
env: {
CDK_DEFAULT_REGION: 'us-east-1',
CDK_DEFAULT_ACCOUNT: 'REDACTED',
CDK_CONTEXT_JSON: '{ // REDACTED },"@aws-cdk/core:enableStackNameDuplicates":"true","aws-cdk:enableDiffNoFail":"true","@aws-cdk/core:stackRelativeExports":"true","@aws-cdk/aws-ecr-assets:dockerIgnoreSupport":true,"@aws-cdk/aws-secretsmanager:parseOwnedSecretName":true,"@aws-cdk/aws-kms:defaultKeyPolicies":true,"@aws-cdk/core:newStyleStackSynthesis":true,"aws:cdk:enable-path-metadata":true,"aws:cdk:enable-asset-metadata":true,"aws:cdk:disable-version-reporting":true,"aws:cdk:bundling-stacks":["*"]}',
CDK_OUTDIR: 'cdk.out',
CDK_CLI_ASM_VERSION: '12.0.0',
CDK_CLI_VERSION: '1.108.1'
}
<--- Last few GCs --->
[70929:0x1048cf000] 95835 ms: Mark-sweep (reduce) 4094.3 (4101.6) -> 4093.4 (4102.6) MB, 3073.6 / 0.0 ms (average mu = 0.082, current mu = 0.001) allocation failure scavenge might not succeed
[70929:0x1048cf000] 98881 ms: Mark-sweep (reduce) 4094.4 (4101.8) -> 4093.4 (4102.8) MB, 3040.6 / 0.0 ms (average mu = 0.044, current mu = 0.002) allocation failure scavenge might not succeed
<--- JS stacktrace --->
FATAL ERROR: Ineffective mark-compacts near heap limit Allocation failed - JavaScript heap out of memory
1: 0x1013024b5 node::Abort() (.cold.1) [/usr/local/bin/node]
2: 0x1000b1919 node::Abort() [/usr/local/bin/node]
3: 0x1000b1a7f node::OnFatalError(char const*, char const*) [/usr/local/bin/node]
4: 0x1001f5bb7 v8::Utils::ReportOOMFailure(v8::internal::Isolate*, char const*, bool) [/usr/local/bin/node]
5: 0x1001f5b53 v8::internal::V8::FatalProcessOutOfMemory(v8::internal::Isolate*, char const*, bool) [/usr/local/bin/node]
6: 0x1003a2ed5 v8::internal::Heap::FatalProcessOutOfMemory(char const*) [/usr/local/bin/node]
7: 0x1003a497a v8::internal::Heap::RecomputeLimits(v8::internal::GarbageCollector) [/usr/local/bin/node]
8: 0x1003a00a5 v8::internal::Heap::PerformGarbageCollection(v8::internal::GarbageCollector, v8::GCCallbackFlags) [/usr/local/bin/node]
9: 0x10039d9d0 v8::internal::Heap::CollectGarbage(v8::internal::AllocationSpace, v8::internal::GarbageCollectionReason, v8::GCCallbackFlags) [/usr/local/bin/node]
10: 0x1003ac0da v8::internal::Heap::AllocateRawWithLightRetrySlowPath(int, v8::internal::AllocationType, v8::internal::AllocationOrigin, v8::internal::AllocationAlignment) [/usr/local/bin/node]
11: 0x1003ac161 v8::internal::Heap::AllocateRawWithRetryOrFailSlowPath(int, v8::internal::AllocationType, v8::internal::AllocationOrigin, v8::internal::AllocationAlignment) [/usr/local/bin/node]
12: 0x100379f52 v8::internal::Factory::NewFillerObject(int, bool, v8::internal::AllocationType, v8::internal::AllocationOrigin) [/usr/local/bin/node]
13: 0x1006fa238 v8::internal::Runtime_AllocateInYoungGeneration(int, unsigned long*, v8::internal::Isolate*) [/usr/local/bin/node]
14: 0x100a80639 Builtins_CEntry_Return1_DontSaveFPRegs_ArgvOnStack_NoBuiltinExit [/usr/local/bin/node]
Unhandled exception. Amazon.JSII.Runtime.JsiiException: Child process exited unexpectedly!
at Amazon.JSII.Runtime.Services.Runtime.ReadResponse()
at Amazon.JSII.Runtime.Services.Client.ReceiveResponse[TResponse]()
at Amazon.JSII.Runtime.Deputy.DeputyBase..ctor(DeputyProps props)
at Amazon.CDK.AWS.StepFunctions.State..ctor(DeputyProps props)
at Amazon.CDK.AWS.StepFunctions.TaskStateBase..ctor(DeputyProps props)
at Amazon.CDK.AWS.StepFunctions.Tasks.EcsRunTask..ctor(Construct scope, String id, IEcsRunTaskProps props)
at EosInfrastructureAsCode.DataLoad.EosDataLoadStateMachineStack..ctor(Construct scope, String id, EosDataLoadStateMachineStackProps props) in /Users/dillonodonovan/source/repos/FDB.Eos/EosInfrastructureAsCode/src/EosInfrastructureAsCode/DataLoad/EosDataLoadStateMachineStack.cs:line 82
at EosInfrastructureAsCode.Program.AddEosDataLoadStateMachineStack(App app, AppEnvironment appEnv) in /Users/dillonodonovan/source/repos/FDB.Eos/EosInfrastructureAsCode/src/EosInfrastructureAsCode/Program.cs:line 50
at EosInfrastructureAsCode.Program.Main() in /Users/dillonodonovan/source/repos/FDB.Eos/EosInfrastructureAsCode/src/EosInfrastructureAsCode/Program.cs:line 21
Subprocess exited with error 134
Error: Subprocess exited with error 134
at ChildProcess.<anonymous> (/usr/local/lib/node_modules/aws-cdk/lib/api/cxapp/exec.ts:122:23)
at ChildProcess.emit (events.js:376:20)
at ChildProcess.emit (domain.js:470:12)
at Process.ChildProcess._handle.onexit (internal/child_process.js:277:12)
Environment
- CDK CLI Version : 1.108.1
- Framework Version: 1.108.0
- Node.js Version: v14.17.0
- OS : macOS Catalina 10.15.7
- Language (Version): .NET 5.0
Other
Initially I stumbled upon #3325, but I’ve narrowed down the change to the 1.108.0 release with the step-functions bug fix. I did try the suggestion (increase the Node heap size), but this does not make any difference.
To me, this seems like either a regression was introduced in #14628, or my usage was wrong and working until then.
I’m assuming there’s some sort of accidental infinite recursion, but I’m not entirely sure why/how.
This is 🐛 Bug Report
Issue Analytics
- State:
- Created 2 years ago
- Reactions:1
- Comments:22 (21 by maintainers)
Top GitHub Comments
Very odd, I think the
private
key in the lambda-layer-awscli package.json should actually be removed, not set tofalse
. Try that, then package it, then continue with packing the entire monorepo.No need to support task token in
ContainerOverride.command
as it’s defined as an array of strings andJsonPath
throws an error since the task token must be provided in an object, not an array:https://github.com/aws/aws-cdk/blob/0db3effa033fd3bcc8903884e86f37e4a8154afe/packages/%40aws-cdk/aws-stepfunctions/lib/json-path.ts#L133-L137