diff --git a/bin/app.ts b/bin/app.ts index 1262c62e..04f22c28 100644 --- a/bin/app.ts +++ b/bin/app.ts @@ -131,7 +131,7 @@ export class APIPipeline extends Stack { // Prod us-east-2 const prodUsEast2Stage = new APIStage(this, 'prod-us-east-2', { env: { account: '830217277613', region: 'us-east-2' }, - provisionedConcurrency: 150, + provisionedConcurrency: 70, internalApiKey: internalApiKey.secretValue.toString(), chatbotSNSArn: 'arn:aws:sns:us-east-2:644039819003:SlackChatbotTopic', envVars: { diff --git a/bin/stacks/api-stack.ts b/bin/stacks/api-stack.ts index 298647be..0c05b45b 100644 --- a/bin/stacks/api-stack.ts +++ b/bin/stacks/api-stack.ts @@ -274,7 +274,7 @@ export class APIStack extends cdk.Stack { const switchLambdaAlias = new aws_lambda.Alias(this, `SwitchLiveAlias`, { aliasName: 'live', version: switchLambda.currentVersion, - provisionedConcurrentExecutions: provisionedConcurrency > 0 ? provisionedConcurrency : undefined, + provisionedConcurrentExecutions: 0, }); const mockQuoteLambda = new aws_lambda_nodejs.NodejsFunction(this, 'mockQuote', { @@ -326,7 +326,7 @@ export class APIStack extends cdk.Stack { const rfqLambdaAlias = new aws_lambda.Alias(this, `RfqLiveAlias`, { aliasName: 'live', version: integrationRfqLambda.currentVersion, - provisionedConcurrentExecutions: provisionedConcurrency > 0 ? provisionedConcurrency : undefined, + provisionedConcurrentExecutions: 0, }); if (provisionedConcurrency > 0) { @@ -341,7 +341,7 @@ export class APIStack extends cdk.Stack { quoteTarget.node.addDependency(quoteLambdaAlias); quoteTarget.scaleToTrackMetric('QuoteProvConcTracking', { - targetValue: 0.8, + targetValue: 0.7, predefinedMetric: aws_asg.PredefinedMetric.LAMBDA_PROVISIONED_CONCURRENCY_UTILIZATION, }); }