Monitoring Amazon Q Business with Amazon CloudWatch - Amazon Q Business

Monitoring Amazon Q Business with Amazon CloudWatch

You can monitor Amazon Q Business using Amazon CloudWatch, which collects raw data and processes it into readable, near real-time metrics. These statistics are kept for 15 months, so that you can access historical information and gain a better perspective on how your web application or service is performing. You can also set alarms that watch for certain thresholds, and send notifications or take actions when those thresholds are met. For more information, see the Amazon CloudWatch User Guide.

Use CloudWatch Metrics for Amazon Q Business

To use metrics, you must specify the following information:

  • The metric namespace. A namespace is a CloudWatch container Amazon Q uses to publish its metrics into. If you are using the CloudWatch ListMetrics API or the list-metrics command to view the metrics for Amazon Q Business, specify AWS/QBusiness for the namespace.

  • The metric dimension. A dimension is a name-value pair that helps you to uniquely identify a metric, for example, ApplicationId can be a dimension name. Specifying a metric dimension is optional.

  • The metric name. For example, DocumentsIndexed.

You can get monitoring data for Amazon Q Business by using the AWS Management Console, the AWS CLI, or the CloudWatch API. You can also use the CloudWatch API through one of the Amazon AWS Software Development Kits (SDKs) or the CloudWatch API tools. The console displays a series of graphs based on the raw data from the CloudWatch API. Depending on your needs, you might prefer to use either the graphs displayed in the console or retrieved from the API.

The following table shows some common uses for the metrics. These are suggestions to get you started, not a comprehensive list.

How do I? Relevant metrics

How do I track how many documents were indexed successfully?

Use the DocumentsIndexed metrics.

How do I monitor end user experience?

Use the ThumbsUpCount and ThumbsDownCountmetrics.

You must have the appropriate CloudWatch permissions to monitor Amazon Q Business with CloudWatch. For more information, see Identity and access management for Amazon CloudWatch in the Amazon CloudWatch User Guide.

View Amazon Q Business metrics

The following steps show how to access Amazon Q Business metrics using the CloudWatch console.

To view metrics (console)
  1. Open the CloudWatch console at https://console.aws.amazon.com/cloudwatch/.

  2. Choose Metrics, choose the All Metrics tab, and then choose AWS/QBusiness.

  3. Choose the metric dimension.

  4. Choose the metric that you want from the list, and choose a time period for the graph.

Create an alarm

You can create a CloudWatch alarm that sends an Amazon Simple Notification Service (Amazon SNS) message when the alarm changes state. An alarm watches a single metric over a time period that you specify. It performs one or more actions based on the value of the metric relative to a given threshold over a number of time periods. The action is a notification sent to an Amazon SNS topic or an Auto Scaling policy.

Alarms invoke actions for sustained state changes only. CloudWatch alarms don't invoke actions simply because they are in a particular state. The state must have changed and have been maintained for a specified number of time periods.

To create an alarm based on an Amazon Textract metric, see Create a CloudWatch Alarm Based on a CloudWatch Metric.

To set an alarm (console)
  1. Sign in to the AWS Management Console and open the CloudWatch console at https://console.aws.amazon.com/cloudwatch/.

  2. In the navigation pane, choose Alarms, and choose Create Alarm. This opens the Create Alarm Wizard.

  3. Choose Select metric.

  4. In the All metrics tab, choose an AWS/QBusiness metric for your application, index, and data source. Also set the time as set number of hours, days, weeks, or custom.

  5. Choose your statistic. For example, Average. Also choose your alarm trigger time period as a set number of minutes, hours, per day, or custom.

  6. Choose your threshold to trigger the alarm, whether to use a static value or a band and the condition to meet for the threshold.

  7. Choose the alarm state for the trigger, whether the metric must fall outside your set threshold, or another state. Select who/which email to send the alarm notification to.

  8. Choose Next. Add a name and optional description for your alarm. Choose Next.

  9. Choose Create Alarm.

Amazon Q Business metrics

The following table shows the metrics that Amazon Q Business sends to CloudWatch in real time.

Metric name Unit Description

ThumbsUpCount

Count

The feedback count for thumbs up.

Valid dimensions: ApplicationId

ThumbsDownCount

Count

The feedback count for thumbs down.

Valid dimensions: ApplicationId

DocumentsIndexed

Count

The number of documents that were indexed.

Valid dimensions: ApplicationId, IndexId,DataSourceId

DocumentsFailedToIndex

Count

The number of documents that failed to index.

Valid dimensions: ApplicationId,IndexId,DataSourceId

DocumentsFailedToIndexDueToCDE

Count

The number of documents that failed to index because of custom document enrichment.

Valid dimensions: ApplicationId, IndexId, DataSourceId

DocumentCount

Count

The number of documents. This metric is published every 15 minutes.

Valid dimensions: ApplicationId, IndexId

ExtractedTextSize

MB

Size of the extracted text

Valid dimensions: ApplicationId, IndexId

ActionInvocationCount

Count

The number of actions invoked.

Valid dimensions: ApplicationID, PluginID

ActionErrorCount

Count

The number of errors because of actions.

Valid dimensions: ApplicationId, PluginID