Connecting AWS DevOps Agent to OpenSearch for Incident Management
AWS DevOps Agent now connects to OpenSearch using MCP, automating incident response and closing the loop from alert to analysis.
- Topic
- DevOps
- Reading time
- 5 min
- Length
- 1,066 words
- Published
- Oct 18, 2026
11:58 pm IST
In this article
The AWS DevOps Agent now integrates directly with Amazon OpenSearch, offering a closed-loop incident response system that automates the process from alert detection to root cause analysis. This new setup leverages the Model Context Protocol (MCP) to streamline the incident response workflow, minimizing manual intervention, especially crucial when alerts come at inconvenient times. This integration can significantly reduce the time engineers spend on investigating alerts, allowing for quicker resolution of incidents.
Why Connect AWS DevOps Agent to OpenSearch?
Traditionally, when an alert is triggered in systems like OpenSearch, it requires a human to investigate and correlate data from multiple sources to determine the root cause. This can be a time-consuming process, especially during off-hours. By connecting AWS DevOps Agent to OpenSearch using MCP, the alert triggers the agent to automatically query the logs and traces, correlating them with AWS CloudTrail and Amazon CloudWatch, and delivering a root cause analysis. This automation closes the loop between detection and response, potentially saving hours that would otherwise be spent manually investigating issues.
How to Deploy the OpenSearch MCP Server
For integrating AWS DevOps Agent with OpenSearch, the setup must begin with deploying the MCP server. According to the source article, you have three options depending on your AWS region and operational preference:
- Self-managed on Amazon ECS: This option is available in all regions and involves running the MCP server on ECS Fargate behind a network load balancer. It's crucial to use a Network Load Balancer (NLB) instead of an Application Load Balancer (ALB) due to the nature of the streamable-HTTP transport that the MCP server uses. The NLB operates at Layer 4 (TCP), ensuring that HTTP framing remains untouched, which is essential for maintaining the integrity of the Server-Sent Events (SSE) used by the MCP server.
- Amazon Bedrock AgentCore: This is a managed service option available in regions where AgentCore is supported. It provides a one-click CloudFormation template to deploy the MCP server. This method simplifies deployment but is only available in select regions.
- OpenSearch 3.3+ Built-in MCP: For domains running OpenSearch 3.3 or later, the MCP server is built-in, eliminating the need for an external server deployment. This option is the most straightforward but requires your OpenSearch domain to be on version 3.3 or above.
For each deployment path, ensure your TLS certificates are correctly configured, as the AWS DevOps Agent requires HTTPS endpoints with a matching subject alternative name (SAN) for secure communication. This configuration ensures that the VPC Lattice validates the certificate against the host address, a critical step for establishing a secure connection.
Registering the MCP Server with AWS DevOps Agent
Once the MCP server is up and running, the next step is to register it as a Capability Provider with the AWS DevOps Agent. This allows the agent to invoke its tools during investigations. The registration process involves setting up a private connection for the self-managed ECS path, while the AgentCore and built-in options do not require this step. Each path has different authentication requirements, such as API keys, OAuth, or SigV4.
Configuring FGAC Role Mapping
OpenSearch domains with FGAC require explicit mapping between IAM roles and OpenSearch backend roles to authorize access. Without this mapping, authenticated requests can still be denied. Identifying and configuring the correct role mapping is crucial to ensure the AWS DevOps Agent can query your observability indices. This step is vital for maintaining security while allowing necessary access for automated incident response.
Wiring Up Alert Routing
Finally, to complete the closed-loop system, you need to wire up the alert routing. This involves deploying a webhook forwarder Lambda function that transforms SNS notifications into HMAC-signed payloads compatible with the AWS DevOps Agent's Event Channel. This setup allows for automatic incident investigations triggered by OpenSearch alerts without human intervention.
What This Doesn't Solve
While this closed-loop system automates much of the incident response process, it doesn't eliminate the need for human oversight entirely. Engineers still need to configure and maintain the system, ensure role mappings are correct, and manage any edge cases where automation might not yet be sufficient. Additionally, regions without support for Amazon Bedrock AgentCore must rely on self-managed solutions, which require more operational overhead.
In my experience working with AI-driven incident response systems, the integration of AWS DevOps Agent with OpenSearch is a significant step forward in automating incident management. However, it's important to continuously monitor the system's performance and adjust configurations as needed to ensure optimal functionality. For those managing large-scale applications where quick incident response is critical, this integration can provide substantial benefits in reducing downtime and improving system reliability.
FAQs
- Is this integration available in all AWS regions?
While the self-managed ECS option is available everywhere, the Bedrock AgentCore option is region-specific. Check the availability in your region before proceeding. - What are the prerequisites for setting up this integration?
You need an Amazon OpenSearch Service managed domain with FGAC enabled, AWS DevOps Agent enabled, and tools like AWS CDK and AWS CLI configured. - Can I use this setup with older versions of OpenSearch?
The built-in MCP server option requires OpenSearch 3.3 or later. For earlier versions, you need to use the self-managed or AgentCore paths. - How does the system ensure data security during automated responses?
Data security is managed via FGAC role mappings and secure TLS communications, ensuring only authorized access to data and tools.
Worked Example: Deploying the MCP Server on ECS
To deploy the MCP server on Amazon ECS, follow these detailed steps:
- Generate a TLS Certificate: Create a self-signed certificate with a subject alternative name (SAN) that matches your NLB DNS name. Import this certificate into AWS Certificate Manager (ACM) and save the certificate ARN for later use.
- Define the MCP Server in Your CDK App: Use the provided CDK snippet to run the opensearch-mcp-server-py as an Amazon ECS Fargate service behind an internal NLB. Deploy the stack using the command
cdk deploy --require-approval broadening --region <region>. Note the NLB DNS and task role ARN from the stack outputs, which will be needed for configuring the private connection and FGAC mapping. - Configure the NLB: Ensure that the NLB has a security group attached at creation time, allowing VPC Lattice resource gateway ENIs to reach it. This is critical for the private connection to function correctly.
- Verify the Setup: Once deployed, test the MCP server's connectivity and ensure it can communicate with AWS DevOps Agent by checking the logs and confirming that the expected endpoints are accessible.
Sources
Closed-loop incident response: connect AWS DevOps Agent to OpenSearch
Every claim above was checked against this source before publishing. The analysis, the code and the opinions are mine.
Frequently asked
Is this integration available in all AWS regions?
While the self-managed ECS option is available everywhere, the Bedrock AgentCore option is region-specific. Check the availability in your region before proceeding.
What are the prerequisites for setting up this integration?
You need an Amazon OpenSearch Service managed domain with FGAC enabled, AWS DevOps Agent enabled, and tools like AWS CDK and AWS CLI configured.
Can I use this setup with older versions of OpenSearch?
The built-in MCP server option requires OpenSearch 3.3 or later. For earlier versions, you need to use the self-managed or AgentCore paths.
How does the system ensure data security during automated responses?
Data security is managed via FGAC role mappings and secure TLS communications, ensuring only authorized access to data and tools.