From 997d5c477d8e1f099c2333a654d2dbaa2a594376 Mon Sep 17 00:00:00 2001 From: Himanshu Rai Date: Wed, 7 May 2025 17:22:35 +0530 Subject: [PATCH 1/7] code changes for testing lambda version --- .github/workflows/release-temp.yaml | 56 +++++++++++++++++++++++++++++ lambda-template.yaml | 40 +++++++++++++++++++-- 2 files changed, 93 insertions(+), 3 deletions(-) create mode 100644 .github/workflows/release-temp.yaml diff --git a/.github/workflows/release-temp.yaml b/.github/workflows/release-temp.yaml new file mode 100644 index 0000000..e44d0f4 --- /dev/null +++ b/.github/workflows/release-temp.yaml @@ -0,0 +1,56 @@ +name: Build and Deploy Template files + +on: + pull_request: + branches: + - develop + +jobs: + build-and-deploy: + runs-on: ubuntu-latest + permissions: + id-token: write + contents: write + steps: + - name: Checkout code + uses: actions/checkout@v4 + + - name: Setup Go + uses: actions/setup-go@v5 + with: + go-version: '1.22' + + - name: Install AWS SAM CLI + run: | + pip install aws-sam-cli + + # Update the LambdaInstrumentationVersion in lambda-template.yaml + - name: Update LambdaInstrumentationVersion in lambda-template.yaml + run: | + # Extract the version from version.go + cat lambda-template.yaml + version=$(grep 'const InstrumentationVersion' src/common/version.go | awk -F '"' '{print $2}') + echo "Extracted version: $version" + + # Replace the version in lambda-template.yaml + sed -i "s/LambdaInstrumentationVersion: '.*'/LambdaInstrumentationVersion: '$version'/" lambda-template.yaml + cat lambda-template.yaml + + # modify lambda CodeUri to production as s3 bucket destination + - name: Set up Python + uses: actions/setup-python@v2 + with: + python-version: '3.x' + + - name: Install ruamel + run: | + python -m pip install --upgrade pip + pip install ruamel.yaml + + - name: Run Python Script to Update lambda-template.yaml + run: python workflow-scripts/update_lambda_template.py + + - name: Verify the changes + run: cat lambda-template.yaml + + \ No newline at end of file diff --git a/lambda-template.yaml b/lambda-template.yaml index 6da697d..d36b216 100644 --- a/lambda-template.yaml +++ b/lambda-template.yaml @@ -1,7 +1,10 @@ AWSTemplateFormatVersion: "2010-09-09" Transform: AWS::Serverless-2016-10-31 Description: New Relic Template to forward logs using S3 bucket and/or cloudwatch using lambda - +Mappings: + VersionMap: + MetricsForwarder: + LambdaInstrumentationVersion: '1.0.0' #This will be dynamially updated by release workflow Metadata: AWS::ServerlessRepo::Application: Name: NewRelic-log-forwarding @@ -30,7 +33,9 @@ Metadata: default: 'Common Attributes to be added to the log events' StoreNRLicenseKeyInSecretManager: default: 'Store New Relic License Key in AWS Secrets Manager' - + EventBridgeScheduleExpression: + default: 'Expression for EventBridge rule' + Parameters: LicenseKey: Type: String @@ -68,7 +73,14 @@ Parameters: Default: "true" AllowedValues: - "true" - - "false" + - "false" + EventBridgeScheduleExpression: + Type: String + Description: "The schedule expression for the EventBridge rule. Defaults to rate(5 minutes)" + Default: "rate(5 minutes)" + AllowedPattern: "^rate\\([0-9]+ (minutes|hours)\\)$" + ConstraintDescription: "The parameter value must be a valid rate expression." + Conditions: ShouldCreateSecret: !Equals [ !Ref StoreNRLicenseKeyInSecretManager, "true" ] @@ -453,6 +465,28 @@ Resources: LambdaFunctionArn: !GetAtt NewRelicLogsServerlessLogForwarder.Arn InvalidLogGroups: !GetAtt NewRelicLogsResourceForLogGroupArnConstruction.InvalidLogGroups + NewRelicMetricsForwarderTrigger: + Type: 'AWS::CloudFormation::Stack' + Properties: + TemplateURL: https://s3.us-east-2.amazonaws.com/unified-lambda-serverless/logging-metrics-template.yaml + Parameters: + LicenseKey: !Ref LicenseKey + NewRelicRegion: !Ref NewRelicRegion + NewRelicAccountId: !Ref NewRelicAccountId + StoreNRLicenseKeyInSecretManager: !Ref StoreNRLicenseKeyInSecretManager + EventBridgeScheduleExpression: !Ref EventBridgeScheduleExpression + LogForwarderLambdaInputJSON: + Fn::Sub: + - | + [ + { + "Arn": "${NewRelicLogsServerlessLogForwarder.Arn}", + "InstrumentationVersion": "${lambda_instrumentation_version}" + } + ] + - lambda_instrumentation_version: !FindInMap [VersionMap, MetricsForwarder, LambdaInstrumentationVersion] + LogForwarderFirehoseInputJSON: "" + Outputs: NewRelicLogsLambdaFunctionArn: Description: The ARN of the Lambda function. From c0e3afcbb894e7e91720bda926f7d9975b221f90 Mon Sep 17 00:00:00 2001 From: Himanshu Rai Date: Wed, 7 May 2025 17:44:37 +0530 Subject: [PATCH 2/7] adding LambdaInstrumetationversion to mapping --- .github/workflows/release-temp.yaml | 24 ++++++++++------------ workflow-scripts/update_lambda_template.py | 5 +++++ 2 files changed, 16 insertions(+), 13 deletions(-) diff --git a/.github/workflows/release-temp.yaml b/.github/workflows/release-temp.yaml index e44d0f4..9c801c9 100644 --- a/.github/workflows/release-temp.yaml +++ b/.github/workflows/release-temp.yaml @@ -24,18 +24,6 @@ jobs: run: | pip install aws-sam-cli - # Update the LambdaInstrumentationVersion in lambda-template.yaml - - name: Update LambdaInstrumentationVersion in lambda-template.yaml - run: | - # Extract the version from version.go - cat lambda-template.yaml - version=$(grep 'const InstrumentationVersion' src/common/version.go | awk -F '"' '{print $2}') - echo "Extracted version: $version" - - # Replace the version in lambda-template.yaml - sed -i "s/LambdaInstrumentationVersion: '.*'/LambdaInstrumentationVersion: '$version'/" lambda-template.yaml - cat lambda-template.yaml - # modify lambda CodeUri to production as s3 bucket destination - name: Set up Python uses: actions/setup-python@v2 @@ -53,4 +41,14 @@ jobs: - name: Verify the changes run: cat lambda-template.yaml - \ No newline at end of file + # Update the LambdaInstrumentationVersion in lambda-template.yaml + - name: Update LambdaInstrumentationVersion in lambda-template.yaml + run: | + # Extract the version from version.go + cat lambda-template.yaml + version=$(grep 'const InstrumentationVersion' src/common/version.go | awk -F '"' '{print $2}') + echo "Extracted version: $version" + + # Replace the version in lambda-template.yaml + sed -i "s/LambdaInstrumentationVersion: '.*'/LambdaInstrumentationVersion: '$version'/" lambda-template.yaml + cat lambda-template.yaml \ No newline at end of file diff --git a/workflow-scripts/update_lambda_template.py b/workflow-scripts/update_lambda_template.py index 6814220..223231d 100644 --- a/workflow-scripts/update_lambda_template.py +++ b/workflow-scripts/update_lambda_template.py @@ -17,6 +17,11 @@ } mappings = { + 'VersionMap':{ + 'MetricsForwarder': { + 'LambdaInstrumentationVersion': '1.0.0' + } + }, 'RegionToS3Bucket': { 'us-east-1': {'BucketArn': 'unified-logging-lambda-code-us-east-1'}, 'us-east-2': {'BucketArn': 'unified-logging-lambda-code-us-east-2'}, From 183bf30a6e456cac70a2eb773e1cde5e7095371e Mon Sep 17 00:00:00 2001 From: Himanshu Rai Date: Wed, 7 May 2025 17:55:09 +0530 Subject: [PATCH 3/7] changes to handle single quotes --- .github/workflows/release-temp.yaml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/release-temp.yaml b/.github/workflows/release-temp.yaml index 9c801c9..d08215b 100644 --- a/.github/workflows/release-temp.yaml +++ b/.github/workflows/release-temp.yaml @@ -50,5 +50,6 @@ jobs: echo "Extracted version: $version" # Replace the version in lambda-template.yaml - sed -i "s/LambdaInstrumentationVersion: '.*'/LambdaInstrumentationVersion: '$version'/" lambda-template.yaml + #sed -i "s/LambdaInstrumentationVersion: '.*'/LambdaInstrumentationVersion: '$version'/" lambda-template.yaml + sed -i "s/LambdaInstrumentationVersion: [^ ]*/LambdaInstrumentationVersion: $version/" lambda-template.yaml cat lambda-template.yaml \ No newline at end of file From 6a38c9ab95375dab5764e71c2d2da95046c60681 Mon Sep 17 00:00:00 2001 From: Himanshu Rai Date: Wed, 7 May 2025 17:57:23 +0530 Subject: [PATCH 4/7] single quotes related changes --- lambda-template.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lambda-template.yaml b/lambda-template.yaml index d36b216..1952bb1 100644 --- a/lambda-template.yaml +++ b/lambda-template.yaml @@ -4,7 +4,7 @@ Description: New Relic Template to forward logs using S3 bucket and/or cloudwatc Mappings: VersionMap: MetricsForwarder: - LambdaInstrumentationVersion: '1.0.0' #This will be dynamially updated by release workflow + LambdaInstrumentationVersion: 1.0.0 #This will be dynamially updated by release workflow Metadata: AWS::ServerlessRepo::Application: Name: NewRelic-log-forwarding From 927d3215e56505631b49d0c09af57c869d1977ce Mon Sep 17 00:00:00 2001 From: Himanshu Rai Date: Wed, 7 May 2025 18:01:47 +0530 Subject: [PATCH 5/7] code changes to integrate metrics forwarder with lambda --- .github/workflows/release-temp.yaml | 55 ------------------- .github/workflows/release-template-files.yaml | 13 ++++- logging-firehose-metric-polling.yaml | 12 +++- logging-firehose-metric-stream.yaml | 10 ++++ logging-lambda-firehose-metric-polling.yaml | 14 ++++- logging-lambda-firehose-metric-stream.yaml | 10 ++++ logging-lambda-firehose-template.yaml | 15 ++++- logging-lambda-metric-polling.yaml | 12 +++- logging-lambda-metric-stream.yaml | 10 ++++ 9 files changed, 88 insertions(+), 63 deletions(-) delete mode 100644 .github/workflows/release-temp.yaml diff --git a/.github/workflows/release-temp.yaml b/.github/workflows/release-temp.yaml deleted file mode 100644 index d08215b..0000000 --- a/.github/workflows/release-temp.yaml +++ /dev/null @@ -1,55 +0,0 @@ -name: Build and Deploy Template files - -on: - pull_request: - branches: - - develop - -jobs: - build-and-deploy: - runs-on: ubuntu-latest - permissions: - id-token: write - contents: write - steps: - - name: Checkout code - uses: actions/checkout@v4 - - - name: Setup Go - uses: actions/setup-go@v5 - with: - go-version: '1.22' - - - name: Install AWS SAM CLI - run: | - pip install aws-sam-cli - - # modify lambda CodeUri to production as s3 bucket destination - - name: Set up Python - uses: actions/setup-python@v2 - with: - python-version: '3.x' - - - name: Install ruamel - run: | - python -m pip install --upgrade pip - pip install ruamel.yaml - - - name: Run Python Script to Update lambda-template.yaml - run: python workflow-scripts/update_lambda_template.py - - - name: Verify the changes - run: cat lambda-template.yaml - - # Update the LambdaInstrumentationVersion in lambda-template.yaml - - name: Update LambdaInstrumentationVersion in lambda-template.yaml - run: | - # Extract the version from version.go - cat lambda-template.yaml - version=$(grep 'const InstrumentationVersion' src/common/version.go | awk -F '"' '{print $2}') - echo "Extracted version: $version" - - # Replace the version in lambda-template.yaml - #sed -i "s/LambdaInstrumentationVersion: '.*'/LambdaInstrumentationVersion: '$version'/" lambda-template.yaml - sed -i "s/LambdaInstrumentationVersion: [^ ]*/LambdaInstrumentationVersion: $version/" lambda-template.yaml - cat lambda-template.yaml \ No newline at end of file diff --git a/.github/workflows/release-template-files.yaml b/.github/workflows/release-template-files.yaml index fdd62b5..a294cee 100644 --- a/.github/workflows/release-template-files.yaml +++ b/.github/workflows/release-template-files.yaml @@ -4,8 +4,6 @@ on: push: branches: - main - paths: - - '*.yaml' jobs: build-and-deploy: @@ -43,6 +41,17 @@ jobs: - name: Verify the changes run: cat lambda-template.yaml + # Update the LambdaInstrumentationVersion in lambda-template.yaml + - name: Update LambdaInstrumentationVersion in lambda-template.yaml + run: | + # Extract the version from version.go + version=$(grep 'const InstrumentationVersion' src/common/version.go | awk -F '"' '{print $2}') + echo "Extracted version: $version" + + # Replace the version in lambda-template.yaml + sed -i "s/LambdaInstrumentationVersion: [^ ]*/LambdaInstrumentationVersion: $version/" lambda-template.yaml + cat lambda-template.yaml + - name: Configure AWS Credentials uses: aws-actions/configure-aws-credentials@v3 with: diff --git a/logging-firehose-metric-polling.yaml b/logging-firehose-metric-polling.yaml index 97d709a..ce24e2e 100644 --- a/logging-firehose-metric-polling.yaml +++ b/logging-firehose-metric-polling.yaml @@ -40,6 +40,7 @@ Metadata: - LoggingS3BackupBucketName - EnableCloudWatchLoggingForFirehose - StoreNRLicenseKeyInSecretManager + - EventBridgeScheduleExpression ParameterLabels: IntegrationName: @@ -65,7 +66,9 @@ Metadata: CommonAttributes: default: 'Common Attributes to be added to the log events' StoreNRLicenseKeyInSecretManager: - default: 'Store New Relic License Key in AWS Secrets Manager' + default: 'Store New Relic License Key in AWS Secrets Manager' + EventBridgeScheduleExpression: + default: 'Expression for EventBridge rule' Parameters: IAMRoleName: @@ -144,6 +147,12 @@ Parameters: AllowedValues: - "true" - "false" + EventBridgeScheduleExpression: + Type: String + Description: "The schedule expression for the EventBridge rule. Defaults to rate(5 minutes)" + Default: "rate(5 minutes)" + AllowedPattern: "^rate\\([0-9]+ (minutes|hours)\\)$" + ConstraintDescription: "The parameter value must be a valid rate expression." Resources: NewRelicLogsFirehose: @@ -160,6 +169,7 @@ Resources: EnableCloudWatchLoggingForFirehose: !Ref EnableCloudWatchLoggingForFirehose CommonAttributes: !Ref CommonAttributes StoreNRLicenseKeyInSecretManager: !Ref StoreNRLicenseKeyInSecretManager + EventBridgeScheduleExpression: !Ref EventBridgeScheduleExpression # New Relic Metrics Polling Stack NewrelicMetricsPollingStack: diff --git a/logging-firehose-metric-stream.yaml b/logging-firehose-metric-stream.yaml index 5ca3062..69aed25 100644 --- a/logging-firehose-metric-stream.yaml +++ b/logging-firehose-metric-stream.yaml @@ -44,6 +44,7 @@ Metadata: - LoggingS3BackupBucketName - EnableCloudWatchLoggingForFirehose - StoreNRLicenseKeyInSecretManager + - EventBridgeScheduleExpression - Label: default: 'AWS Config Service Configuration (Optional)' @@ -88,6 +89,8 @@ Metadata: default: 'Common Attributes to be added to the log events' StoreNRLicenseKeyInSecretManager: default: 'Store New Relic License Key in AWS Secrets Manager' + EventBridgeScheduleExpression: + default: 'Expression for EventBridge rule' Parameters: IAMRoleName: @@ -206,6 +209,12 @@ Parameters: AllowedValues: - "true" - "false" + EventBridgeScheduleExpression: + Type: String + Description: "The schedule expression for the EventBridge rule. Defaults to rate(5 minutes)" + Default: "rate(5 minutes)" + AllowedPattern: "^rate\\([0-9]+ (minutes|hours)\\)$" + ConstraintDescription: "The parameter value must be a valid rate expression." Resources: NewRelicLogsFirehose: @@ -222,6 +231,7 @@ Resources: EnableCloudWatchLoggingForFirehose: !Ref EnableCloudWatchLoggingForFirehose CommonAttributes: !Ref CommonAttributes StoreNRLicenseKeyInSecretManager: !Ref StoreNRLicenseKeyInSecretManager + EventBridgeScheduleExpression: !Ref EventBridgeScheduleExpression # New Relic Metrics Stack NewrelicMetricsStack: diff --git a/logging-lambda-firehose-metric-polling.yaml b/logging-lambda-firehose-metric-polling.yaml index 8b29f00..31eb442 100644 --- a/logging-lambda-firehose-metric-polling.yaml +++ b/logging-lambda-firehose-metric-polling.yaml @@ -40,7 +40,8 @@ Metadata: - LoggingFirehoseStreamName - LoggingS3BackupBucketName - EnableCloudWatchLoggingForFirehose - - StoreNRLicenseKeyInSecretManager + - StoreNRLicenseKeyInSecretManager + - EventBridgeScheduleExpression ParameterLabels: IntegrationName: @@ -69,6 +70,8 @@ Metadata: default: 'Enables CloudWatch logging for Logging Firehose stream' StoreNRLicenseKeyInSecretManager: default: 'Store New Relic License Key in AWS Secrets Manager' + EventBridgeScheduleExpression: + default: 'Expression for EventBridge rule' Parameters: IAMRoleName: @@ -148,7 +151,13 @@ Parameters: Default: "true" AllowedValues: - "true" - - "false" + - "false" + EventBridgeScheduleExpression: + Type: String + Description: "The schedule expression for the EventBridge rule. Defaults to rate(5 minutes)" + Default: "rate(5 minutes)" + AllowedPattern: "^rate\\([0-9]+ (minutes|hours)\\)$" + ConstraintDescription: "The parameter value must be a valid rate expression." Resources: NewRelicLogsLoggingLambdaFirehose: @@ -166,6 +175,7 @@ Resources: LoggingS3BackupBucketName: !Ref LoggingS3BackupBucketName EnableCloudWatchLoggingForFirehose: !Ref EnableCloudWatchLoggingForFirehose StoreNRLicenseKeyInSecretManager: !Ref StoreNRLicenseKeyInSecretManager + EventBridgeScheduleExpression: !Ref EventBridgeScheduleExpression # New Relic Metrics Polling Stack NewrelicMetricsPollingStack: diff --git a/logging-lambda-firehose-metric-stream.yaml b/logging-lambda-firehose-metric-stream.yaml index 467d511..e4eac83 100644 --- a/logging-lambda-firehose-metric-stream.yaml +++ b/logging-lambda-firehose-metric-stream.yaml @@ -46,6 +46,7 @@ Metadata: - LoggingS3BackupBucketName - EnableCloudWatchLoggingForFirehose - StoreNRLicenseKeyInSecretManager + - EventBridgeScheduleExpression - Label: default: 'AWS Config Service Configuration (Optional)' @@ -92,6 +93,8 @@ Metadata: default: 'Enables CloudWatch logging for Logging Firehose stream' StoreNRLicenseKeyInSecretManager: default: 'Store New Relic License Key in AWS Secrets Manager' + EventBridgeScheduleExpression: + default: 'Expression for EventBridge rule' Parameters: IAMRoleName: @@ -212,6 +215,12 @@ Parameters: AllowedValues: - "true" - "false" + EventBridgeScheduleExpression: + Type: String + Description: "The schedule expression for the EventBridge rule. Defaults to rate(5 minutes)" + Default: "rate(5 minutes)" + AllowedPattern: "^rate\\([0-9]+ (minutes|hours)\\)$" + ConstraintDescription: "The parameter value must be a valid rate expression." Resources: NewRelicLogsLoggingLambdaFirehose: @@ -229,6 +238,7 @@ Resources: LoggingS3BackupBucketName: !Ref LoggingS3BackupBucketName EnableCloudWatchLoggingForFirehose: !Ref EnableCloudWatchLoggingForFirehose StoreNRLicenseKeyInSecretManager: !Ref StoreNRLicenseKeyInSecretManager + EventBridgeScheduleExpression: !Ref EventBridgeScheduleExpression # New Relic Metrics Stack NewrelicMetricsStack: diff --git a/logging-lambda-firehose-template.yaml b/logging-lambda-firehose-template.yaml index 9e368d2..3e41a20 100644 --- a/logging-lambda-firehose-template.yaml +++ b/logging-lambda-firehose-template.yaml @@ -36,7 +36,9 @@ Metadata: default: 'Enables CloudWatch logging for Logging Firehose stream' StoreNRLicenseKeyInSecretManager: default: 'Store New Relic License Key in AWS Secrets Manager' - + EventBridgeScheduleExpression: + default: 'Expression for EventBridge rule' + Parameters: LicenseKey: Type: String @@ -96,7 +98,14 @@ Parameters: Default: "true" AllowedValues: - "true" - - "false" + - "false" + EventBridgeScheduleExpression: + Type: String + Description: "The schedule expression for the EventBridge rule. Defaults to rate(5 minutes)" + Default: "rate(5 minutes)" + AllowedPattern: "^rate\\([0-9]+ (minutes|hours)\\)$" + ConstraintDescription: "The parameter value must be a valid rate expression." + Resources: @@ -112,6 +121,7 @@ Resources: LogGroupConfig: "" CommonAttributes: !Ref CommonAttributes StoreNRLicenseKeyInSecretManager: !Ref StoreNRLicenseKeyInSecretManager + EventBridgeScheduleExpression: !Ref EventBridgeScheduleExpression NewRelicLogsFirehose: Type: 'AWS::CloudFormation::Stack' @@ -127,4 +137,5 @@ Resources: EnableCloudWatchLoggingForFirehose: !Ref EnableCloudWatchLoggingForFirehose CommonAttributes: !Ref CommonAttributes StoreNRLicenseKeyInSecretManager: !Ref StoreNRLicenseKeyInSecretManager + EventBridgeScheduleExpression: !Ref EventBridgeScheduleExpression \ No newline at end of file diff --git a/logging-lambda-metric-polling.yaml b/logging-lambda-metric-polling.yaml index 48caafd..2e5f8af 100644 --- a/logging-lambda-metric-polling.yaml +++ b/logging-lambda-metric-polling.yaml @@ -39,6 +39,7 @@ Metadata: - LogGroupConfig - CommonAttributes - StoreNRLicenseKeyInSecretManager + - EventBridgeScheduleExpression ParameterLabels: IntegrationName: @@ -61,6 +62,8 @@ Metadata: default: 'Common Attributes to be added to the log events' StoreNRLicenseKeyInSecretManager: default: 'Store New Relic License Key in AWS Secrets Manager' + EventBridgeScheduleExpression: + default: 'Expression for EventBridge rule' Parameters: IAMRoleName: @@ -118,7 +121,13 @@ Parameters: Default: "true" AllowedValues: - "true" - - "false" + - "false" + EventBridgeScheduleExpression: + Type: String + Description: "The schedule expression for the EventBridge rule. Defaults to rate(5 minutes)" + Default: "rate(5 minutes)" + AllowedPattern: "^rate\\([0-9]+ (minutes|hours)\\)$" + ConstraintDescription: "The parameter value must be a valid rate expression." Resources: NewRelicLogsLoggingLambda: @@ -133,6 +142,7 @@ Resources: LogGroupConfig : !Ref LogGroupConfig CommonAttributes : !Ref CommonAttributes StoreNRLicenseKeyInSecretManager: !Ref StoreNRLicenseKeyInSecretManager + EventBridgeScheduleExpression: !Ref EventBridgeScheduleExpression # New Relic Metrics Polling Stack NewrelicMetricsPollingStack: diff --git a/logging-lambda-metric-stream.yaml b/logging-lambda-metric-stream.yaml index ffe71f4..812ea2d 100644 --- a/logging-lambda-metric-stream.yaml +++ b/logging-lambda-metric-stream.yaml @@ -43,6 +43,7 @@ Metadata: - LogGroupConfig - CommonAttributes - StoreNRLicenseKeyInSecretManager + - EventBridgeScheduleExpression - Label: default: 'AWS Config Service Configuration (Optional)' @@ -83,6 +84,8 @@ Metadata: default: 'Common Attributes to be added to the log events' StoreNRLicenseKeyInSecretManager: default: 'Store New Relic License Key in AWS Secrets Manager' + EventBridgeScheduleExpression: + default: 'Expression for EventBridge rule' Parameters: IAMRoleName: @@ -181,6 +184,12 @@ Parameters: AllowedValues: - "true" - "false" + EventBridgeScheduleExpression: + Type: String + Description: "The schedule expression for the EventBridge rule. Defaults to rate(5 minutes)" + Default: "rate(5 minutes)" + AllowedPattern: "^rate\\([0-9]+ (minutes|hours)\\)$" + ConstraintDescription: "The parameter value must be a valid rate expression." Resources: NewRelicLogsLoggingLambda: @@ -195,6 +204,7 @@ Resources: LogGroupConfig : !Ref LogGroupConfig CommonAttributes : !Ref CommonAttributes StoreNRLicenseKeyInSecretManager: !Ref StoreNRLicenseKeyInSecretManager + EventBridgeScheduleExpression: !Ref EventBridgeScheduleExpression # New Relic Metrics Stack NewrelicMetricsStack: From 1099d5c00be80eacc6c78781f83a6a30e69b3a8d Mon Sep 17 00:00:00 2001 From: Himanshu Rai Date: Mon, 7 Jul 2025 13:42:57 +0530 Subject: [PATCH 6/7] code changes to support monitoring tier and using same secret manager --- lambda-template.yaml | 28 ++++++++++++++------ logging-firehose-metric-polling.yaml | 24 ++++++++++------- logging-firehose-metric-stream.yaml | 24 ++++++++++------- logging-lambda-firehose-metric-polling.yaml | 24 ++++++++++------- logging-lambda-firehose-metric-stream.yaml | 24 ++++++++++------- logging-lambda-firehose-template.yaml | 29 ++++++++++++--------- logging-lambda-metric-polling.yaml | 24 ++++++++++------- logging-lambda-metric-stream.yaml | 26 +++++++++++------- 8 files changed, 128 insertions(+), 75 deletions(-) diff --git a/lambda-template.yaml b/lambda-template.yaml index 1952bb1..a333eb8 100644 --- a/lambda-template.yaml +++ b/lambda-template.yaml @@ -33,8 +33,8 @@ Metadata: default: 'Common Attributes to be added to the log events' StoreNRLicenseKeyInSecretManager: default: 'Store New Relic License Key in AWS Secrets Manager' - EventBridgeScheduleExpression: - default: 'Expression for EventBridge rule' + MonitoringTier: + default: 'Metrics Monitoring Collection Tier' Parameters: LicenseKey: @@ -74,12 +74,18 @@ Parameters: AllowedValues: - "true" - "false" - EventBridgeScheduleExpression: + MonitoringTier: Type: String - Description: "The schedule expression for the EventBridge rule. Defaults to rate(5 minutes)" - Default: "rate(5 minutes)" - AllowedPattern: "^rate\\([0-9]+ (minutes|hours)\\)$" - ConstraintDescription: "The parameter value must be a valid rate expression." + Description: | + Determines the metrics collection frequency and detail level: + - None: Send No metrics + - Basic: Limited metrics every 15 minutes + - Advanced: Full metrics every 5 minutes + Default: "Basic" + AllowedValues: + - "None" + - "Basic" + - "Advanced" Conditions: @@ -87,6 +93,7 @@ Conditions: AddS3Trigger: !Not [ !Equals [!Ref S3BucketNames , ""]] AddCloudwatchTrigger: !Not [ !Equals [!Ref LogGroupConfig , ""]] IsCommonAttributesNotBlank: !Not [!Equals [!Ref CommonAttributes, ""]] + EnableMetricsForwarder: !Not [ !Equals [!Ref MonitoringTier, "None"]] Resources: NewRelicLogsLicenseKeySecret: @@ -467,14 +474,19 @@ Resources: NewRelicMetricsForwarderTrigger: Type: 'AWS::CloudFormation::Stack' + Condition: EnableMetricsForwarder Properties: TemplateURL: https://s3.us-east-2.amazonaws.com/unified-lambda-serverless/logging-metrics-template.yaml Parameters: LicenseKey: !Ref LicenseKey + LicenseKeySecretArn: !If + - ShouldCreateSecret + - !Sub '{ "LicenseKey": "${NewRelicLogsLicenseKeySecret}" }' + - "" NewRelicRegion: !Ref NewRelicRegion NewRelicAccountId: !Ref NewRelicAccountId StoreNRLicenseKeyInSecretManager: !Ref StoreNRLicenseKeyInSecretManager - EventBridgeScheduleExpression: !Ref EventBridgeScheduleExpression + MonitoringTier: !Ref MonitoringTier LogForwarderLambdaInputJSON: Fn::Sub: - | diff --git a/logging-firehose-metric-polling.yaml b/logging-firehose-metric-polling.yaml index ce24e2e..b34e844 100644 --- a/logging-firehose-metric-polling.yaml +++ b/logging-firehose-metric-polling.yaml @@ -40,7 +40,7 @@ Metadata: - LoggingS3BackupBucketName - EnableCloudWatchLoggingForFirehose - StoreNRLicenseKeyInSecretManager - - EventBridgeScheduleExpression + - MonitoringTier ParameterLabels: IntegrationName: @@ -67,8 +67,8 @@ Metadata: default: 'Common Attributes to be added to the log events' StoreNRLicenseKeyInSecretManager: default: 'Store New Relic License Key in AWS Secrets Manager' - EventBridgeScheduleExpression: - default: 'Expression for EventBridge rule' + MonitoringTier: + default: 'Metrics Monitoring Collection Tier' Parameters: IAMRoleName: @@ -147,12 +147,18 @@ Parameters: AllowedValues: - "true" - "false" - EventBridgeScheduleExpression: + MonitoringTier: Type: String - Description: "The schedule expression for the EventBridge rule. Defaults to rate(5 minutes)" - Default: "rate(5 minutes)" - AllowedPattern: "^rate\\([0-9]+ (minutes|hours)\\)$" - ConstraintDescription: "The parameter value must be a valid rate expression." + Description: | + Determines the metrics collection frequency and detail level: + - None: Send No metrics + - Basic: Limited metrics every 15 minutes + - Advanced: Full metrics every 5 minutes + Default: "Basic" + AllowedValues: + - "None" + - "Basic" + - "Advanced" Resources: NewRelicLogsFirehose: @@ -169,7 +175,7 @@ Resources: EnableCloudWatchLoggingForFirehose: !Ref EnableCloudWatchLoggingForFirehose CommonAttributes: !Ref CommonAttributes StoreNRLicenseKeyInSecretManager: !Ref StoreNRLicenseKeyInSecretManager - EventBridgeScheduleExpression: !Ref EventBridgeScheduleExpression + MonitoringTier: !Ref MonitoringTier # New Relic Metrics Polling Stack NewrelicMetricsPollingStack: diff --git a/logging-firehose-metric-stream.yaml b/logging-firehose-metric-stream.yaml index 69aed25..f5249ec 100644 --- a/logging-firehose-metric-stream.yaml +++ b/logging-firehose-metric-stream.yaml @@ -44,7 +44,7 @@ Metadata: - LoggingS3BackupBucketName - EnableCloudWatchLoggingForFirehose - StoreNRLicenseKeyInSecretManager - - EventBridgeScheduleExpression + - MonitoringTier - Label: default: 'AWS Config Service Configuration (Optional)' @@ -89,8 +89,8 @@ Metadata: default: 'Common Attributes to be added to the log events' StoreNRLicenseKeyInSecretManager: default: 'Store New Relic License Key in AWS Secrets Manager' - EventBridgeScheduleExpression: - default: 'Expression for EventBridge rule' + MonitoringTier: + default: 'Metrics Monitoring Collection Tier' Parameters: IAMRoleName: @@ -209,12 +209,18 @@ Parameters: AllowedValues: - "true" - "false" - EventBridgeScheduleExpression: + MonitoringTier: Type: String - Description: "The schedule expression for the EventBridge rule. Defaults to rate(5 minutes)" - Default: "rate(5 minutes)" - AllowedPattern: "^rate\\([0-9]+ (minutes|hours)\\)$" - ConstraintDescription: "The parameter value must be a valid rate expression." + Description: | + Determines the metrics collection frequency and detail level: + - None: Send No metrics + - Basic: Limited metrics every 15 minutes + - Advanced: Full metrics every 5 minutes + Default: "Basic" + AllowedValues: + - "None" + - "Basic" + - "Advanced" Resources: NewRelicLogsFirehose: @@ -231,7 +237,7 @@ Resources: EnableCloudWatchLoggingForFirehose: !Ref EnableCloudWatchLoggingForFirehose CommonAttributes: !Ref CommonAttributes StoreNRLicenseKeyInSecretManager: !Ref StoreNRLicenseKeyInSecretManager - EventBridgeScheduleExpression: !Ref EventBridgeScheduleExpression + MonitoringTier: !Ref MonitoringTier # New Relic Metrics Stack NewrelicMetricsStack: diff --git a/logging-lambda-firehose-metric-polling.yaml b/logging-lambda-firehose-metric-polling.yaml index 31eb442..06a7e5b 100644 --- a/logging-lambda-firehose-metric-polling.yaml +++ b/logging-lambda-firehose-metric-polling.yaml @@ -41,7 +41,7 @@ Metadata: - LoggingS3BackupBucketName - EnableCloudWatchLoggingForFirehose - StoreNRLicenseKeyInSecretManager - - EventBridgeScheduleExpression + - MonitoringTier ParameterLabels: IntegrationName: @@ -70,8 +70,8 @@ Metadata: default: 'Enables CloudWatch logging for Logging Firehose stream' StoreNRLicenseKeyInSecretManager: default: 'Store New Relic License Key in AWS Secrets Manager' - EventBridgeScheduleExpression: - default: 'Expression for EventBridge rule' + MonitoringTier: + default: 'Metrics Monitoring Collection Tier' Parameters: IAMRoleName: @@ -152,12 +152,18 @@ Parameters: AllowedValues: - "true" - "false" - EventBridgeScheduleExpression: + MonitoringTier: Type: String - Description: "The schedule expression for the EventBridge rule. Defaults to rate(5 minutes)" - Default: "rate(5 minutes)" - AllowedPattern: "^rate\\([0-9]+ (minutes|hours)\\)$" - ConstraintDescription: "The parameter value must be a valid rate expression." + Description: | + Determines the metrics collection frequency and detail level: + - None: Send No metrics + - Basic: Limited metrics every 15 minutes + - Advanced: Full metrics every 5 minutes + Default: "Basic" + AllowedValues: + - "None" + - "Basic" + - "Advanced" Resources: NewRelicLogsLoggingLambdaFirehose: @@ -175,7 +181,7 @@ Resources: LoggingS3BackupBucketName: !Ref LoggingS3BackupBucketName EnableCloudWatchLoggingForFirehose: !Ref EnableCloudWatchLoggingForFirehose StoreNRLicenseKeyInSecretManager: !Ref StoreNRLicenseKeyInSecretManager - EventBridgeScheduleExpression: !Ref EventBridgeScheduleExpression + MonitoringTier: !Ref MonitoringTier # New Relic Metrics Polling Stack NewrelicMetricsPollingStack: diff --git a/logging-lambda-firehose-metric-stream.yaml b/logging-lambda-firehose-metric-stream.yaml index e4eac83..7260751 100644 --- a/logging-lambda-firehose-metric-stream.yaml +++ b/logging-lambda-firehose-metric-stream.yaml @@ -46,7 +46,7 @@ Metadata: - LoggingS3BackupBucketName - EnableCloudWatchLoggingForFirehose - StoreNRLicenseKeyInSecretManager - - EventBridgeScheduleExpression + - MonitoringTier - Label: default: 'AWS Config Service Configuration (Optional)' @@ -93,8 +93,8 @@ Metadata: default: 'Enables CloudWatch logging for Logging Firehose stream' StoreNRLicenseKeyInSecretManager: default: 'Store New Relic License Key in AWS Secrets Manager' - EventBridgeScheduleExpression: - default: 'Expression for EventBridge rule' + MonitoringTier: + default: 'Metrics Monitoring Collection Tier' Parameters: IAMRoleName: @@ -215,12 +215,18 @@ Parameters: AllowedValues: - "true" - "false" - EventBridgeScheduleExpression: + MonitoringTier: Type: String - Description: "The schedule expression for the EventBridge rule. Defaults to rate(5 minutes)" - Default: "rate(5 minutes)" - AllowedPattern: "^rate\\([0-9]+ (minutes|hours)\\)$" - ConstraintDescription: "The parameter value must be a valid rate expression." + Description: | + Determines the metrics collection frequency and detail level: + - None: Send No metrics + - Basic: Limited metrics every 15 minutes + - Advanced: Full metrics every 5 minutes + Default: "Basic" + AllowedValues: + - "None" + - "Basic" + - "Advanced" Resources: NewRelicLogsLoggingLambdaFirehose: @@ -238,7 +244,7 @@ Resources: LoggingS3BackupBucketName: !Ref LoggingS3BackupBucketName EnableCloudWatchLoggingForFirehose: !Ref EnableCloudWatchLoggingForFirehose StoreNRLicenseKeyInSecretManager: !Ref StoreNRLicenseKeyInSecretManager - EventBridgeScheduleExpression: !Ref EventBridgeScheduleExpression + MonitoringTier: !Ref MonitoringTier # New Relic Metrics Stack NewrelicMetricsStack: diff --git a/logging-lambda-firehose-template.yaml b/logging-lambda-firehose-template.yaml index 3e41a20..7fa4c69 100644 --- a/logging-lambda-firehose-template.yaml +++ b/logging-lambda-firehose-template.yaml @@ -36,9 +36,9 @@ Metadata: default: 'Enables CloudWatch logging for Logging Firehose stream' StoreNRLicenseKeyInSecretManager: default: 'Store New Relic License Key in AWS Secrets Manager' - EventBridgeScheduleExpression: - default: 'Expression for EventBridge rule' - + MonitoringTier: + default: 'Metrics Monitoring Collection Tier' + Parameters: LicenseKey: Type: String @@ -99,12 +99,18 @@ Parameters: AllowedValues: - "true" - "false" - EventBridgeScheduleExpression: + MonitoringTier: Type: String - Description: "The schedule expression for the EventBridge rule. Defaults to rate(5 minutes)" - Default: "rate(5 minutes)" - AllowedPattern: "^rate\\([0-9]+ (minutes|hours)\\)$" - ConstraintDescription: "The parameter value must be a valid rate expression." + Description: | + Determines the metrics collection frequency and detail level: + - None: Send No metrics + - Basic: Limited metrics every 15 minutes + - Advanced: Full metrics every 5 minutes + Default: "Basic" + AllowedValues: + - "None" + - "Basic" + - "Advanced" Resources: @@ -121,8 +127,8 @@ Resources: LogGroupConfig: "" CommonAttributes: !Ref CommonAttributes StoreNRLicenseKeyInSecretManager: !Ref StoreNRLicenseKeyInSecretManager - EventBridgeScheduleExpression: !Ref EventBridgeScheduleExpression - + MonitoringTier: !Ref MonitoringTier + NewRelicLogsFirehose: Type: 'AWS::CloudFormation::Stack' Properties: @@ -137,5 +143,4 @@ Resources: EnableCloudWatchLoggingForFirehose: !Ref EnableCloudWatchLoggingForFirehose CommonAttributes: !Ref CommonAttributes StoreNRLicenseKeyInSecretManager: !Ref StoreNRLicenseKeyInSecretManager - EventBridgeScheduleExpression: !Ref EventBridgeScheduleExpression - \ No newline at end of file + MonitoringTier: !Ref MonitoringTier diff --git a/logging-lambda-metric-polling.yaml b/logging-lambda-metric-polling.yaml index 2e5f8af..08f1f1a 100644 --- a/logging-lambda-metric-polling.yaml +++ b/logging-lambda-metric-polling.yaml @@ -39,7 +39,7 @@ Metadata: - LogGroupConfig - CommonAttributes - StoreNRLicenseKeyInSecretManager - - EventBridgeScheduleExpression + - MonitoringTier ParameterLabels: IntegrationName: @@ -62,8 +62,8 @@ Metadata: default: 'Common Attributes to be added to the log events' StoreNRLicenseKeyInSecretManager: default: 'Store New Relic License Key in AWS Secrets Manager' - EventBridgeScheduleExpression: - default: 'Expression for EventBridge rule' + MonitoringTier: + default: 'Metrics Monitoring Collection Tier' Parameters: IAMRoleName: @@ -122,12 +122,18 @@ Parameters: AllowedValues: - "true" - "false" - EventBridgeScheduleExpression: + MonitoringTier: Type: String - Description: "The schedule expression for the EventBridge rule. Defaults to rate(5 minutes)" - Default: "rate(5 minutes)" - AllowedPattern: "^rate\\([0-9]+ (minutes|hours)\\)$" - ConstraintDescription: "The parameter value must be a valid rate expression." + Description: | + Determines the metrics collection frequency and detail level: + - None: Send No metrics + - Basic: Limited metrics every 15 minutes + - Advanced: Full metrics every 5 minutes + Default: "Basic" + AllowedValues: + - "None" + - "Basic" + - "Advanced" Resources: NewRelicLogsLoggingLambda: @@ -142,7 +148,7 @@ Resources: LogGroupConfig : !Ref LogGroupConfig CommonAttributes : !Ref CommonAttributes StoreNRLicenseKeyInSecretManager: !Ref StoreNRLicenseKeyInSecretManager - EventBridgeScheduleExpression: !Ref EventBridgeScheduleExpression + MonitoringTier: !Ref MonitoringTier # New Relic Metrics Polling Stack NewrelicMetricsPollingStack: diff --git a/logging-lambda-metric-stream.yaml b/logging-lambda-metric-stream.yaml index 812ea2d..aa33239 100644 --- a/logging-lambda-metric-stream.yaml +++ b/logging-lambda-metric-stream.yaml @@ -43,7 +43,7 @@ Metadata: - LogGroupConfig - CommonAttributes - StoreNRLicenseKeyInSecretManager - - EventBridgeScheduleExpression + - MonitoringTier - Label: default: 'AWS Config Service Configuration (Optional)' @@ -84,8 +84,8 @@ Metadata: default: 'Common Attributes to be added to the log events' StoreNRLicenseKeyInSecretManager: default: 'Store New Relic License Key in AWS Secrets Manager' - EventBridgeScheduleExpression: - default: 'Expression for EventBridge rule' + MonitoringTier: + default: 'Metrics Monitoring Collection Tier' Parameters: IAMRoleName: @@ -184,12 +184,18 @@ Parameters: AllowedValues: - "true" - "false" - EventBridgeScheduleExpression: - Type: String - Description: "The schedule expression for the EventBridge rule. Defaults to rate(5 minutes)" - Default: "rate(5 minutes)" - AllowedPattern: "^rate\\([0-9]+ (minutes|hours)\\)$" - ConstraintDescription: "The parameter value must be a valid rate expression." + MonitoringTier: + Type: String + Description: | + Determines the metrics collection frequency and detail level: + - None: Send No metrics + - Basic: Limited metrics every 15 minutes + - Advanced: Full metrics every 5 minutes + Default: "Basic" + AllowedValues: + - "None" + - "Basic" + - "Advanced" Resources: NewRelicLogsLoggingLambda: @@ -204,7 +210,7 @@ Resources: LogGroupConfig : !Ref LogGroupConfig CommonAttributes : !Ref CommonAttributes StoreNRLicenseKeyInSecretManager: !Ref StoreNRLicenseKeyInSecretManager - EventBridgeScheduleExpression: !Ref EventBridgeScheduleExpression + MonitoringTier: !Ref MonitoringTier # New Relic Metrics Stack NewrelicMetricsStack: From c1b075247f6d3c0b59efb8a1dbf18e357137161e Mon Sep 17 00:00:00 2001 From: Himanshu Rai Date: Mon, 7 Jul 2025 23:49:28 +0530 Subject: [PATCH 7/7] code changes for passing only secret manager arn --- lambda-template.yaml | 4 ++-- logging-firehose-metric-polling.yaml | 2 +- logging-firehose-metric-stream.yaml | 2 +- logging-lambda-firehose-metric-polling.yaml | 2 +- logging-lambda-firehose-metric-stream.yaml | 2 +- logging-lambda-firehose-template.yaml | 2 +- logging-lambda-metric-polling.yaml | 2 +- logging-lambda-metric-stream.yaml | 2 +- 8 files changed, 9 insertions(+), 9 deletions(-) diff --git a/lambda-template.yaml b/lambda-template.yaml index a333eb8..e2dca12 100644 --- a/lambda-template.yaml +++ b/lambda-template.yaml @@ -77,7 +77,7 @@ Parameters: MonitoringTier: Type: String Description: | - Determines the metrics collection frequency and detail level: + Determines the metrics collection frequency and detail level for Lambda Log Forwarder - None: Send No metrics - Basic: Limited metrics every 15 minutes - Advanced: Full metrics every 5 minutes @@ -481,7 +481,7 @@ Resources: LicenseKey: !Ref LicenseKey LicenseKeySecretArn: !If - ShouldCreateSecret - - !Sub '{ "LicenseKey": "${NewRelicLogsLicenseKeySecret}" }' + - !Ref NewRelicLogsLicenseKeySecret - "" NewRelicRegion: !Ref NewRelicRegion NewRelicAccountId: !Ref NewRelicAccountId diff --git a/logging-firehose-metric-polling.yaml b/logging-firehose-metric-polling.yaml index b34e844..65305f2 100644 --- a/logging-firehose-metric-polling.yaml +++ b/logging-firehose-metric-polling.yaml @@ -150,7 +150,7 @@ Parameters: MonitoringTier: Type: String Description: | - Determines the metrics collection frequency and detail level: + Determines the metrics collection frequency and detail level for Firehose Log Forwarder - None: Send No metrics - Basic: Limited metrics every 15 minutes - Advanced: Full metrics every 5 minutes diff --git a/logging-firehose-metric-stream.yaml b/logging-firehose-metric-stream.yaml index f5249ec..897f985 100644 --- a/logging-firehose-metric-stream.yaml +++ b/logging-firehose-metric-stream.yaml @@ -212,7 +212,7 @@ Parameters: MonitoringTier: Type: String Description: | - Determines the metrics collection frequency and detail level: + Determines the metrics collection frequency and detail level for Firehose Log Forwarder - None: Send No metrics - Basic: Limited metrics every 15 minutes - Advanced: Full metrics every 5 minutes diff --git a/logging-lambda-firehose-metric-polling.yaml b/logging-lambda-firehose-metric-polling.yaml index 06a7e5b..5cd45a4 100644 --- a/logging-lambda-firehose-metric-polling.yaml +++ b/logging-lambda-firehose-metric-polling.yaml @@ -155,7 +155,7 @@ Parameters: MonitoringTier: Type: String Description: | - Determines the metrics collection frequency and detail level: + Determines the metrics collection frequency and detail level for Log Forwarder: - None: Send No metrics - Basic: Limited metrics every 15 minutes - Advanced: Full metrics every 5 minutes diff --git a/logging-lambda-firehose-metric-stream.yaml b/logging-lambda-firehose-metric-stream.yaml index 7260751..88607da 100644 --- a/logging-lambda-firehose-metric-stream.yaml +++ b/logging-lambda-firehose-metric-stream.yaml @@ -218,7 +218,7 @@ Parameters: MonitoringTier: Type: String Description: | - Determines the metrics collection frequency and detail level: + Determines the metrics collection frequency and detail level for Log Forwarder: - None: Send No metrics - Basic: Limited metrics every 15 minutes - Advanced: Full metrics every 5 minutes diff --git a/logging-lambda-firehose-template.yaml b/logging-lambda-firehose-template.yaml index 7fa4c69..8258d1e 100644 --- a/logging-lambda-firehose-template.yaml +++ b/logging-lambda-firehose-template.yaml @@ -102,7 +102,7 @@ Parameters: MonitoringTier: Type: String Description: | - Determines the metrics collection frequency and detail level: + Determines the metrics collection frequency and detail level for Log Forwarder: - None: Send No metrics - Basic: Limited metrics every 15 minutes - Advanced: Full metrics every 5 minutes diff --git a/logging-lambda-metric-polling.yaml b/logging-lambda-metric-polling.yaml index 08f1f1a..d4b55be 100644 --- a/logging-lambda-metric-polling.yaml +++ b/logging-lambda-metric-polling.yaml @@ -125,7 +125,7 @@ Parameters: MonitoringTier: Type: String Description: | - Determines the metrics collection frequency and detail level: + Determines the metrics collection frequency and detail level for Lambda Log Forwarder: - None: Send No metrics - Basic: Limited metrics every 15 minutes - Advanced: Full metrics every 5 minutes diff --git a/logging-lambda-metric-stream.yaml b/logging-lambda-metric-stream.yaml index aa33239..f890cde 100644 --- a/logging-lambda-metric-stream.yaml +++ b/logging-lambda-metric-stream.yaml @@ -187,7 +187,7 @@ Parameters: MonitoringTier: Type: String Description: | - Determines the metrics collection frequency and detail level: + Determines the metrics collection frequency and detail level for Lambda Log Forwarder: - None: Send No metrics - Basic: Limited metrics every 15 minutes - Advanced: Full metrics every 5 minutes