Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 8 additions & 0 deletions .projenrc.ts
Original file line number Diff line number Diff line change
Expand Up @@ -324,7 +324,15 @@ const backEndApp = new awscdk.AwsCdkTypeScriptApp({
eslint: true,
jest: true,
jestOptions: {
// Recycle a worker once it exceeds this heap so accumulated memory (v8 coverage +
// CDK synth) is freed between suites rather than growing for the worker's lifetime.
extraCliOptions: ['--workerIdleMemoryLimit=2GB'],
jestConfig: {
// Cap parallelism. The test/infra/** suites each synthesize full CDK stacks and use
// ~1.4GB heap apiece; at the default (cpuCount-1) worker count their aggregate RSS,
// plus v8 coverage, exceeds the 16GB CI runner and the OS OOM-kills the run (exit 1
// with no Jest summary). Limiting workers keeps peak memory well under the runner.
maxWorkers: '50%',
// Ensure Jest can resolve tsconfig path aliases used by lambda handlers/tests.
moduleNameMapper: {
'^@BE/(.*)$': '<rootDir>/src/app/$1',
Expand Down
2 changes: 1 addition & 1 deletion packages/back-end/.projen/tasks.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions packages/back-end/package.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading