Skip to content

Commit 17a7ba3

Browse files
chetanchoudhary-sumoamee-sumosumoanema
authored
Amazon Apps Documentation update: Automatic creation of Fields, FERs and OOB Monitors for 3 Apps (#5796)
* Adding Monitors, Automatic field FER creation information to 3 Amazon apps * Update amazon-bedrock.md * Update amazon-ec2-auto-scaling.md * Update amazon-opensearch.md * Update amazon-ec2-auto-scaling.md * Update amazon-bedrock.md * Update amazon-ec2-auto-scaling.md * Update amazon-opensearch.md * Update amazon-bedrock.md --------- Co-authored-by: Amee Lepcha <[email protected]> Co-authored-by: Alekh Nema <[email protected]>
1 parent dee4178 commit 17a7ba3

File tree

3 files changed

+156
-82
lines changed

3 files changed

+156
-82
lines changed

docs/integrations/amazon-aws/amazon-bedrock.md

Lines changed: 44 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -179,7 +179,6 @@ The Amazon Bedrock app uses the following logs and metrics:
179179

180180
### Sample queries
181181

182-
183182
```sql title="Successful Event Locations (CloudTrail log based)"
184183
account=* region=us-east-1 namespace=aws/bedrock "\"eventSource\":\"bedrock.amazonaws.com\"" !errorCode
185184
| json "eventSource", "eventName", "eventType", "sourceIPAddress", "errorCode", "errorMessage" nodrop
@@ -264,7 +263,7 @@ account=* region=* namespace=aws/bedrock modelid=* metric=Invocations statistic=
264263

265264
## Collecting logs and metrics for the Amazon Bedrock app
266265

267-
### Collect CloudWatch Metrics
266+
### Collecting CloudWatch metrics
268267

269268
Sumo Logic supports collecting metrics using two source types:
270269

@@ -274,7 +273,7 @@ Sumo Logic supports collecting metrics using two source types:
274273
* Namespace for **Amazon Bedrock** Service is **AWS/Bedrock**.
275274
* ​​​**Metadata**. Add an **account** field to the source and assign it a value that is a friendly name/alias to your AWS account from which you are collecting metrics. Metrics can be queried via the “account field”.
276275

277-
### Collect Amazon Bedrock CloudTrail logs
276+
### Collecting Amazon Bedrock CloudTrail logs
278277

279278
1. Add an [AWS CloudTrail Source](/docs/send-data/hosted-collectors/amazon-aws/aws-cloudtrail-source.md) to your Hosted Collector.
280279
* **Name**. Enter a name to display the new Source.
@@ -285,14 +284,14 @@ Sumo Logic supports collecting metrics using two source types:
285284
* **Source Category**. Enter `aws/observability/cloudtrail/logs`.
286285
* **Fields**. Add an **account** field and assign it a value that is a friendly name/alias to your AWS account from which you are collecting logs. Logs can be queried via the “account field”.
287286
* **Access Key ID and Secret Access Key**. Enter your Amazon [Access Key ID and Secret Access Key](http://docs.aws.amazon.com/AWSSimpleQueueService/latest/SQSGettingStartedGuide/AWSCredentials.html). Learn how to use Role-based access to AWS [here](/docs/send-data/hosted-collectors/amazon-aws/aws-sources).
288-
* **Log File Discovery** > **Scan Interval**. Use the default of 5 minutes. Alternately, enter the frequency. Sumo Logic will scan your S3 bucket for new data. Learn how to configure **Log File Discovery** [here](/docs/send-data/hosted-collectors/amazon-aws/aws-sources).
287+
* **Log File Discovery** > **Scan Interval**. Use the default of 5 minutes. Alternatively, enter the frequency. Sumo Logic will scan your S3 bucket for new data. Learn how to configure **Log File Discovery** [here](/docs/send-data/hosted-collectors/amazon-aws/aws-sources).
289288
* **Enable Timestamp Parsing**. Select the **Extract timestamp information from log file entries** check box.
290289
* **Time Zone**. Select **Ignore time zone from the log file and instead use**, and select **UTC** from the dropdown.
291290
* **Timestamp Format.** Select **Automatically detect the format**.
292291
* **Enable Multiline Processing**. Select the **Detect messages spanning multiple lines** check box, and select **Infer Boundaries**.
293292
2. Click **Save**.
294293

295-
### Collect Amazon Bedrock CloudWatch logs
294+
### Collecting Amazon Bedrock CloudWatch logs
296295

297296
To enable Amazon Bedrock CloudWatch Logs, follow the steps mentioned in [AWS Documentation](https://docs.aws.amazon.com/bedrock/latest/userguide/model-invocation-logging.html)
298297

@@ -302,26 +301,25 @@ Ensure that when configuring `CloudWatch Logs`, the log group name follows the p
302301

303302
<img src={useBaseUrl('img/integrations/amazon-aws/Amazon-Bedrock-Settings.png')} alt="Amazon Bedrock Setting" style={{border: '1px solid gray'}} />
304303

305-
306304
Sumo Logic supports several methods for collecting logs from Amazon CloudWatch. You can choose either of them to collect logs:
307305

308306
- **AWS Kinesis Firehose for Logs**. Configure an [AWS Kinesis Firehose for Logs](/docs/send-data/hosted-collectors/amazon-aws/aws-kinesis-firehose-logs-source/#create-an-aws-kinesis-firehose-for-logssource) (Recommended); or
309307
- **Lambda Log Forwarder**. Configure a collection of Amazon CloudWatch Logs using our AWS Lambda function using a Sumo Logic provided CloudFormation template, as described in [Amazon CloudWatch Logs](/docs/send-data/collect-from-other-data-sources/amazon-cloudwatch-logs/) or configure collection without using CloudFormation, see [Collect Amazon CloudWatch Logs using a Lambda Function](/docs/send-data/collect-from-other-data-sources/amazon-cloudwatch-logs/collect-with-lambda-function/).<br/>
310308

311-
- While configuring the CloudWatch log source, following fields can be added in the source:
309+
- While configuring the CloudWatch log source, the following fields can be added to the source:
312310
- Add an **account** field and assign it a value which is a friendly name/alias to your AWS account from which you are collecting logs. Logs can be queried via the **account** field.
313311
- Add a **region** field and assign it the value of the respective AWS region where the **Bedrock** exists.
314-
- Add an **accountId** field and assign it the value of the respective AWS account id which is being used.
312+
- Add an **accountId** field and assign it the value of the respective AWS account ID that is being used.
315313

316314
<img src={useBaseUrl('https://sumologic-app-data-v2.s3.amazonaws.com/dashboards/AWS-Lambda/lamda-cw-logs-source-fields.png')} alt="Fields" />
317315

318-
### Field in Field Schema
316+
### Configure field in field schema
319317

320-
1. [**New UI**](/docs/get-started/sumo-logic-ui). In the main Sumo Logic menu select **Data Management**, and then under **Logs** select **Fields**. You can also click the **Go To...** menu at the top of the screen and select **Fields**. <br/>[**Classic UI**](/docs/get-started/sumo-logic-ui-classic). In the main Sumo Logic menu, select **Manage Data > Logs > Fields**.
318+
1. [**New UI**](/docs/get-started/sumo-logic-ui). In the main Sumo Logic menu, select **Data Management**, and then under **Logs** select **Fields**. You can also click the **Go To...** menu at the top of the screen and select **Fields**. <br/>[**Classic UI**](/docs/get-started/sumo-logic-ui-classic). In the main Sumo Logic menu, select **Manage Data > Logs > Fields**.
321319
1. Search for the `modelId` field.
322320
1. If not present, create it. Learn how to create and manage fields [here](/docs/manage/fields#manage-fields).
323321

324-
### Field Extraction Rule(s)
322+
### Configure Field Extraction Rule(s)
325323

326324
Create a Field Extraction Rule for CloudTrail Logs. Learn how to create a Field Extraction Rule [here](/docs/manage/field-extractions/create-field-extraction-rule).
327325

@@ -357,7 +355,7 @@ if (isEmpty(namespace),"unknown",namespace) as namespace
357355
| fields namespace, modelId
358356
```
359357
360-
### Centralized AWS CloudTrail log collection
358+
### Collecting Centralized AWS CloudTrail logs
361359
362360
In case you have a centralized collection of CloudTrail logs and are ingesting them from all accounts into a single Sumo Logic CloudTrail log source, create the following Field Extraction Rule to map a proper AWS account(s) friendly name/alias. Create it if not already present / update it as required.
363361
@@ -369,11 +367,11 @@ Scope (Specific Data): _sourceCategory=aws/observability/cloudtrail/logs
369367
370368
**Parse Expression**:
371369
372-
Enter a parse expression to create an “account” field that maps to the alias you set for each sub account. For example, if you used the `“dev”` alias for an AWS account with ID `"956882123456"` and the `“prod”` alias for an AWS account with ID `"567680881046"`, your parse expression would look like:
370+
Enter a parse expression to create an “account” field that maps to the alias you set for each sub-account. For example, if you used the `“dev”` alias for an AWS account with ID `"956882123456"` and the `“prod”` alias for an AWS account with ID `"567680881046"`, your parse expression would look like:
373371
374372
```sql
375373
| json "recipientAccountId"
376-
// Manually map your aws account id with the AWS account alias you setup earlier for individual child account
374+
// Manually map your AWS account id with the AWS account alias you set up earlier for the individual child account
377375
| "" as account
378376
| if (recipientAccountId = "956882123456", "dev", account) as account
379377
| if (recipientAccountId = "567680881046", "prod", account) as account
@@ -388,30 +386,38 @@ import AppInstall from '../../reuse/apps/app-install-v2.md';
388386
389387
<AppInstall/>
390388
389+
As part of the app installation process, the following fields will be created by default:
390+
391+
* `account`: The friendly name or alias assigned to the AWS account.
392+
* `region`: The geographical region where the AWS resource is located (for example, us-east-1 or eu-west-2).
393+
* `accountid`: The unique 12-digit identifier for the AWS account where the resource is present.
394+
* `namespace`: The AWS service namespace that the resource or metric belongs to (for example, AWS/EC2 or AWS/S3).
395+
* `modelid`: A specific identifier for the LLM Model within an AWS Bedrock.
396+
391397
## Viewing the Bedrock dashboards
392398
393399
We highly recommend you view these dashboards in the [AWS Observability view](/docs/dashboards/explore-view/#aws-observability) of the AWS Observability solution.
394400
395401
### Overview
396402
397-
The **Amazon Bedrock - Overview** dashboard provides a overall heath of Bedrock service based logs and metrics.
403+
The **Amazon Bedrock - Overview** dashboard provides an overall health of the Bedrock service based on logs and metrics.
398404
399405
Use this dashboard to:
400406
* Monitor locations of successful and failed Amazon Bedrock user activity events.
401407
* Monitor all read-only and non-read-only events.
402-
* Monitor most active users working on Bedrock infrastructure and various events invoked on Bedrock service.
408+
* Monitor the most active users working on the Bedrock infrastructure and various events invoked on the Bedrock service.
403409
404410
<img src={useBaseUrl('img/integrations/amazon-aws/Amazon-Bedrock-Overview.png')} alt="Amazon Bedrock dashboard" style={{border: '1px solid gray'}} />
405411
406412
### CloudTrail Audit Overview
407413
408-
The **Amazon Bedrock - CloudTrail Audit Overview** dashboard provides a record of actions taken by a user, role, or an AWS service in Amazon Bedrock. CloudTrail captures all API calls for Amazon Bedrock as events.
414+
The **Amazon Bedrock - CloudTrail Audit Overview** dashboard provides a record of actions taken by a user, role, or AWS service in Amazon Bedrock. CloudTrail captures all API calls for Amazon Bedrock as events.
409415
410416
Use this dashboard to:
411417
* Monitor Amazon Bedrock-related audit logs using CloudTrail Events.
412418
* Monitor locations of successful and failed Amazon Bedrock user activity events.
413419
* Monitor all read-only and non-read-only events.
414-
* Monitor most active users working on Bedrock infrastructure and various events invoked on Bedrock service.
420+
* Monitor the most active users working on the Bedrock infrastructure and various events invoked on the Bedrock service.
415421
416422
<img src={useBaseUrl('img/integrations/amazon-aws/Amazon-Bedrock-CloudTrail-Audit-Overview.png')} alt="Amazon Bedrock dashboard" style={{border: '1px solid gray'}} />
417423
@@ -422,21 +428,36 @@ The **Amazon Bedrock - Model Invocation Log Analysis** dashboard provides insigh
422428
Use this dashboard to:
423429
* Monitor Amazon Bedrock-related audit logs using CloudWatch Events.
424430
* Monitor operational events and the models being utilized.
425-
* Monitor most active users working on Bedrock service.
431+
* Monitor the most active users working on the Bedrock service.
426432
427433
<img src={useBaseUrl('img/integrations/amazon-aws/Amazon-Bedrock-Model-Invocation-Log-Analysis.png')} alt="Amazon Bedrock dashboard" style={{border: '1px solid gray'}} />
428434
429435
### Runtime Performance Monitoring
430436
431-
The **Amazon Bedrock - Runtime Performance Monitoring** dashboard provides statistical insights of runtime model invocation metrics.
437+
The **Amazon Bedrock - Runtime Performance Monitoring** dashboard provides statistical insights into runtime model invocation metrics.
432438
433439
Use this dashboard to:
434-
* Monitor all Invocations related metrics.
435-
* Monitor and track of input and output tokens.
440+
* Monitor all invocations-related metrics.
441+
* Monitor and track input and output tokens.
436442
* Monitor and track images in the output.
437443
438444
<img src={useBaseUrl('img/integrations/amazon-aws/Amazon-Bedrock-Runtime-Performance-Monitoring.png')} alt="Amazon Bedrock dashboard" style={{border: '1px solid gray'}} />
439445
446+
## Create monitors for Amazon Bedrock app
447+
448+
import CreateMonitors from '../../reuse/apps/create-monitors.md';
449+
450+
<CreateMonitors/>
451+
452+
### Amazon Bedrock alerts
453+
454+
| Name | Description | Alert Condition | Recover Condition |
455+
|:--|:--|:--|:--|
456+
| `Amazon Bedrock - Delete Action Detected` | This alert is triggered when a Delete API call to the Amazon Bedrock environment is detected. | Count > 0 | Count < = 0 |
457+
| `Amazon Bedrock - High Model Invocation Latency` | This alert is triggered when the average time to receive a response from a Bedrock model exceeds a configurable threshold in milliseconds. High latency can directly impact the user experience of your applications. | Count > 5000 | Count < = 5000 |
458+
| `Amazon Bedrock - High Number of Access Denied Errors` | This alert is triggered when there is a spike in AccessDeniedException errors in CloudTrail for the Bedrock service. This could indicate misconfigured IAM policies or a potential security threat. | Count > 5 | Count < = 5 |
459+
| `Amazon Bedrock - Model Invocation Server Error Detection` | This alert is triggered when the number of server-side errors from model invocations increases more than a configurable value (Default 5). This can indicate issues with the service, your input data, or permissions. | Count > 5 | Count < = 5 |
460+
440461
## Upgrade/Downgrade the Amazon Bedrock app (Optional)
441462
442463
import AppUpdate from '../../reuse/apps/app-update.md';
@@ -447,4 +468,4 @@ import AppUpdate from '../../reuse/apps/app-update.md';
447468
448469
import AppUninstall from '../../reuse/apps/app-uninstall.md';
449470
450-
<AppUninstall/>
471+
<AppUninstall/>

0 commit comments

Comments
 (0)