Infrastructure that heals itself
An autonomous agent that watches a live cloud system, reads its own failures, writes the fix, and redeploys — without a human in the loop. Built end to end in a single hackathon cycle for the Endava × Google Cloud Agentic AI Hackathon.
The healing loop
Detect → reason → act → verify
Every failure passes through the same four-stage loop, whether it's a null-reference bug in application code or an infrastructure misconfiguration like a service scaled to zero. The agent decides which class of failure it's facing, then picks the right remediation path on its own.
1
Detect
A CloudWatch alarm fires on a FATAL log pattern; SNS invokes the orchestrator Lambda automatically.
2
Reason
The diagnosis agent reads the logs and the LLM classifies the root cause — application bug versus infrastructure misconfiguration.
3
Act
For code bugs, the patch agent commits a real fix to GitHub; for infra issues, the ECS fix agent restores the service via the AWS API.
4
Verify
Tests confirm the patch is safe, then ECS redeploys the healed service.
Captured from a live run
What the agent actually does
This is an unedited heal cycle. A null-reference bug was injected into the running service; six seconds later it was diagnosed, patched, validated, and redeployed.
[18:30:53] ORCHESTRATOR Alarm triggered: infra-healer-fatal-errors. Classifying failure…
[18:30:54] DIAGNOSIS Found 8 error events. FATAL TypeError: Cannot read properties of undefined (reading 'metrics') in backend/server.js
[18:30:56] PATCH Added null guard for undefined MetricDataResults — commit bd108da
[18:30:58] VALIDATION Validation passed — 12/12 tests green
[18:30:59] DEPLOY ECS forced new deployment triggered. New tasks starting…
[18:30:59] COMPLETE Heal complete — no human intervention required.
12/12
Validation tests passed
Under the hood
Technologies & tools
A production-shaped cloud architecture — not a toy demo. Custom domain, HTTPS, load balancing, and a serverless orchestrator wired into real observability infrastructure.
Frontend
ReactViteRechartsJavaScript (ES6+)
Backend
Node.jsExpressREST APIs
AWS infrastructure
ECS FargateECRALBACMRoute 53AmplifyLambdaDynamoDBCloudWatchSNSIAM
AI / LLM
Google Gemini APIGroq APIAgentic tool-callingMulti-step reasoning
DevOps & tooling
DockerAWS CLIGitHub REST APIGitBash
Architecture patterns
Event-driven serverlessInfra as CLIObservability-driven remediationModel-agnostic orchestration