@shinyaz

AgentCore Gateway target deployment validates MCP server connectivity

Pointed a Gateway target at an unreachable MCP server URL and agentcore deploy failed with a CloudFormation ROLLBACK.

Output
CDK deploy failed: ❌ AgentCore-MyProject-default failed: ToolkitError:
The stack named AgentCore-MyProject-default failed creation, it may need to
be manually deleted from the AWS console: ROLLBACK_COMPLETE: Resource handler
returned message: "GatewayTarget XXXXX failed to stabilize, status: FAILED,
reason: Failed to connect and fetch tools from the provided MCP target server.
Error - Apache transport request failed"

During Gateway target creation, AgentCore actually connects to the MCP server and fetches the tool list. If the server is down or the URL is wrong, the entire CloudFormation stack rolls back.

The failed stack stays in ROLLBACK_COMPLETE and may need manual deletion:

Terminal
aws cloudformation delete-stack \
  --stack-name AgentCore-MyProject-default \
  --region ap-northeast-1

External MCP server availability directly affects deployment success. Use reliable endpoints.

Share this post

Shinya Tahara

Shinya Tahara

Solutions Architect @ AWS

I'm a Solutions Architect at AWS, providing technical guidance primarily to financial industry customers. I share learnings about cloud architecture and AI/ML on this site.The views and opinions expressed on this site are my own and do not represent the official positions of my employer.