Skip to content

Commit be36460

Browse files
author
Eugene Cheung
authored
feat: use ARM_64 architecture for Lambda handlers (#102)
1 parent e2eaf5a commit be36460

File tree

5 files changed

+28
-2
lines changed

5 files changed

+28
-2
lines changed

lib/dashboard/widget/BitmapWidget.ts

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,13 @@ import * as path from "path";
33
import { Duration, Tags } from "aws-cdk-lib";
44
import { IWidget } from "aws-cdk-lib/aws-cloudwatch";
55
import { Effect, PolicyStatement } from "aws-cdk-lib/aws-iam";
6-
import { Code, Function, IFunction, Runtime } from "aws-cdk-lib/aws-lambda";
6+
import {
7+
Architecture,
8+
Code,
9+
Function,
10+
IFunction,
11+
Runtime,
12+
} from "aws-cdk-lib/aws-lambda";
713
import { RetentionDays } from "aws-cdk-lib/aws-logs";
814
import { Construct } from "constructs";
915

@@ -35,6 +41,7 @@ export class BitmapWidgetRenderingSupport extends Construct {
3541
handler: "index.handler",
3642
memorySize: 128,
3743
runtime: Runtime.NODEJS_14_X,
44+
architecture: Architecture.ARM_64,
3845
timeout: Duration.seconds(60),
3946
logRetention: RetentionDays.ONE_DAY,
4047
});

lib/monitoring/aws-secretsmanager/SecretsManagerMetricsPublisher.ts

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,13 @@ import { Duration, Names } from "aws-cdk-lib";
44
import { Rule, RuleTargetInput, Schedule } from "aws-cdk-lib/aws-events";
55
import { LambdaFunction } from "aws-cdk-lib/aws-events-targets";
66
import { Effect, PolicyStatement } from "aws-cdk-lib/aws-iam";
7-
import { Code, Function, IFunction, Runtime } from "aws-cdk-lib/aws-lambda";
7+
import {
8+
Architecture,
9+
Code,
10+
Function,
11+
IFunction,
12+
Runtime,
13+
} from "aws-cdk-lib/aws-lambda";
814
import { RetentionDays } from "aws-cdk-lib/aws-logs";
915
import { ISecret } from "aws-cdk-lib/aws-secretsmanager";
1016
import { Construct } from "constructs";
@@ -35,6 +41,7 @@ export class SecretsManagerMetricsPublisher extends Construct {
3541
handler: "index.handler",
3642
memorySize: 128,
3743
runtime: Runtime.NODEJS_14_X,
44+
architecture: Architecture.ARM_64,
3845
timeout: Duration.seconds(60),
3946
logRetention: RetentionDays.ONE_DAY,
4047
});

test/dashboard/widget/__snapshots__/BitmapWidget.test.ts.snap

Lines changed: 3 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

test/facade/__snapshots__/MonitoringAspect.test.ts.snap

Lines changed: 3 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

test/monitoring/aws-secretsmanager/__snapshots__/SecretsManagerSecretMonitoring.test.ts.snap

Lines changed: 6 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)