Send AWS CloudWatch metrics to AppSignal through Amazon Data Firehose

You can stream metrics from AWS CloudWatch to AppSignal using Amazon Data Firehose (formerly Kinesis Data Firehose). This allows you to monitor and analyze your AWS infrastructure metrics alongside your application metrics in AppSignal.

Complete the following steps to send CloudWatch metrics to AppSignal through Amazon Data Firehose:

  1. Set up an S3 bucket for failed deliveries
  2. Set up an IAM role for Data Firehose
  3. Create a Firehose stream
  4. Create a CloudWatch metric stream

Before you start, have the following information ready:

  • Your app's App-level Push API key. To find it, open the API keys settings page, or navigate to your organization settings and select Dev zone > API keys.
  • AWS account ID
  • AWS region

Set up an S3 bucket for failed deliveries

Amazon Data Firehose requires an S3 bucket to store records that fail to deliver. Create an S3 bucket through the AWS Console or CLI before proceeding.

Set up an IAM role for Data Firehose

Create an IAM role that allows Data Firehose to write to the S3 bucket. Use the following trust policy:

JSON
{ "Version": "2012-10-17", "Statement": [ { "Effect": "Allow", "Principal": { "Service": "firehose.amazonaws.com" }, "Action": "sts:AssumeRole", "Condition": { "StringEquals": { "sts:ExternalId": "<AWS_ACCOUNT_ID>" } } } ] }

Assign the following permissions policy to the role as an inline policy.

See Adding IAM identity permissions for instructions on creating inline policies for IAM roles.

JSON
{ "Version": "2012-10-17", "Statement": [ { "Effect": "Allow", "Action": [ "s3:AbortMultipartUpload", "s3:GetBucketLocation", "s3:GetObject", "s3:ListBucket", "s3:ListBucketMultipartUploads", "s3:PutObject" ], "Resource": [ "arn:aws:s3:::<FIREHOSE_S3_BUCKET>", "arn:aws:s3:::<FIREHOSE_S3_BUCKET>/*" ] } ] }

Replace <AWS_ACCOUNT_ID> with your AWS account ID and <FIREHOSE_S3_BUCKET> with the name of the S3 bucket you created in the previous step.

Create a Firehose stream

  1. Open the Amazon Data Firehose console and select Create Firehose stream.
  2. Select Direct PUT as the source.
  3. Select HTTP Endpoint as the destination.
  4. Under "Transform records", leave data transformation turned off.
  5. Enter the following URL as the HTTP endpoint URL:
Shell
https://appsignal-endpoint.net/metrics/aws-cloudwatch
  1. Enter your app's App-level Push API key as the Access key.
  2. Under "Content encoding", enable GZIP.
  3. Under "Backup settings", select the S3 bucket you created in the previous steps.
  4. Under "Advanced settings > Service access", select Choose existing IAM role and choose the IAM role you created in the previous steps.
  5. Select Create Firehose stream.

After creating the stream, use the Test with demo data feature on the Firehose stream page to verify the connection. If everything is configured correctly, test data appears in AppSignal.

Create a CloudWatch metric stream

  1. In the CloudWatch console, go to Metrics > Streams.
  2. Select Create metric stream.
  3. Select Custom setup with Firehose. Under Select your Amazon Data Firehose stream, choose the Firehose stream you created in the previous step.
  4. Select OpenTelemetry 1.0 as the output format.
  5. Select Create metric stream.

You can create multiple metric streams if you need to send metrics to different destinations or filter metrics differently for separate use cases.

CloudWatch metrics in AppSignal

Once configured, AppSignal receives metrics from any AWS service that emits metrics through CloudWatch. CloudWatch metrics don't appear automatically on an existing dashboard — you need to create a dashboard and add a chart that references the metric you want to see.

To view your CloudWatch metrics in AppSignal:

  1. In your app, go to Dashboards and select Add dashboard. Give it a title (for example, AWS CloudWatch) and create it.
  2. On the empty dashboard, select Add chart.
  3. In the Metric field, start typing aws_ to see the CloudWatch metrics AppSignal has received. AppSignal normalizes CloudWatch metric names to lowercase with underscores. For example, AWS/Firehose DeliveryToHttpEndpoint.Records becomes aws_firehose_delivery_to_http_endpoint_records.
  4. Select a metric, optionally add tags to filter by dimension (such as MetricStreamName or InstanceId), and select Create chart.

It can take a few minutes after setup for the first metrics to appear in the picker. If the list is empty, wait a couple of minutes and refresh.

Use custom dashboards to monitor your AWS infrastructure alongside your application metrics.

If you have questions or need help, contact us.