Skip to content
GitHubXDiscord

LogAnomalyDetectionIntegration

The LogAnomalyDetectionIntegration resource lets you manage AWS DevOpsGuru LogAnomalyDetectionIntegrations for anomaly detection in your log data.

Create a basic LogAnomalyDetectionIntegration with default settings.

import AWS from "alchemy/aws/control";
const logAnomalyIntegration = await AWS.DevOpsGuru.LogAnomalyDetectionIntegration("basicIntegration", {
adopt: false
});

Configure an integration to adopt an existing resource if it already exists.

const advancedLogAnomalyIntegration = await AWS.DevOpsGuru.LogAnomalyDetectionIntegration("advancedIntegration", {
adopt: true
});

Use Case: Integration with Existing Resources

Section titled “Use Case: Integration with Existing Resources”

Create an integration while ensuring that it adopts existing log resources if applicable.

const existingResourceIntegration = await AWS.DevOpsGuru.LogAnomalyDetectionIntegration("existingResourceIntegration", {
adopt: true
});

You can manage various aspects of the LogAnomalyDetectionIntegration, such as its ARN, creation time, and last update time, by referencing the returned properties after creation.

console.log("ARN:", existingResourceIntegration.Arn);
console.log("Creation Time:", existingResourceIntegration.CreationTime);
console.log("Last Update Time:", existingResourceIntegration.LastUpdateTime);