Skip to content

Commit

Permalink
feat(synthetics): add support for puppeteer 3.4 runtime (#19429)
Browse files Browse the repository at this point in the history
Fixes #19382


----

*By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license*
  • Loading branch information
ktheory committed Mar 18, 2022
1 parent 1bef14e commit 024b890
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 5 deletions.
8 changes: 4 additions & 4 deletions packages/@aws-cdk/aws-synthetics/README.md
Expand Up @@ -129,7 +129,7 @@ new synthetics.Canary(this, 'Inline Canary', {
code: synthetics.Code.fromInline('/* Synthetics handler code */'),
handler: 'index.handler', // must be 'index.handler'
}),
runtime: synthetics.Runtime.SYNTHETICS_NODEJS_PUPPETEER_3_3,
runtime: synthetics.Runtime.SYNTHETICS_NODEJS_PUPPETEER_3_4,
});

// To supply the code from your local filesystem:
Expand All @@ -138,7 +138,7 @@ new synthetics.Canary(this, 'Asset Canary', {
code: synthetics.Code.fromAsset(path.join(__dirname, 'canary')),
handler: 'index.handler', // must end with '.handler'
}),
runtime: synthetics.Runtime.SYNTHETICS_NODEJS_PUPPETEER_3_3,
runtime: synthetics.Runtime.SYNTHETICS_NODEJS_PUPPETEER_3_4,
});

// To supply the code from a S3 bucket:
Expand All @@ -149,7 +149,7 @@ new synthetics.Canary(this, 'Bucket Canary', {
code: synthetics.Code.fromBucket(bucket, 'canary.zip'),
handler: 'index.handler', // must end with '.handler'
}),
runtime: synthetics.Runtime.SYNTHETICS_NODEJS_PUPPETEER_3_3,
runtime: synthetics.Runtime.SYNTHETICS_NODEJS_PUPPETEER_3_4,
});
```

Expand Down Expand Up @@ -188,7 +188,7 @@ new synthetics.Canary(this, 'Vpc Canary', {
code: synthetics.Code.fromAsset(path.join(__dirname, 'canary')),
handler: 'index.handler',
}),
runtime: synthetics.Runtime.SYNTHETICS_NODEJS_PUPPETEER_3_3,
runtime: synthetics.Runtime.SYNTHETICS_NODEJS_PUPPETEER_3_4,
vpc,
});
```
Expand Down
12 changes: 11 additions & 1 deletion packages/@aws-cdk/aws-synthetics/lib/runtime.ts
Expand Up @@ -114,6 +114,16 @@ export class Runtime {
*/
public static readonly SYNTHETICS_NODEJS_PUPPETEER_3_3 = new Runtime('syn-nodejs-puppeteer-3.3', RuntimeFamily.NODEJS);

/**
* `syn-nodejs-puppeteer-3.4` includes the following:
* - Lambda runtime Node.js 12.x
* - Puppeteer-core version 5.5.0
* - Chromium version 88.0.4298.0
*
* @see https://docs.aws.amazon.com/AmazonCloudWatch/latest/monitoring/CloudWatch_Synthetics_Library_nodejs_puppeteer.html#CloudWatch_Synthetics_runtimeversion-nodejs-puppeteer-3.4
*/
public static readonly SYNTHETICS_NODEJS_PUPPETEER_3_4 = new Runtime('syn-nodejs-puppeteer-3.4', RuntimeFamily.NODEJS);

/**
* `syn-python-selenium-1.0` includes the following:
* - Lambda runtime Python 3.8
Expand All @@ -130,4 +140,4 @@ export class Runtime {
*/
public constructor(public readonly name: string, public readonly family: RuntimeFamily) {
}
}
}

0 comments on commit 024b890

Please sign in to comment.