Self-healing Microservice Architecture Using Autonomous AI Agents for Cloud Applications
Johnson Chidi Iheanachor *
Department of Information and Communication Technology (ICT), Abia State University, Uturu, Abia State, Nigeria.
*Author to whom correspondence should be addressed.
Abstract
Cloud-native microservice applications provide scalability and deployment flexibility but remain susceptible to service failures, cascading faults, and delayed recovery. This study presents a Self-Healing Microservice Architecture (SHMA) that combines Kubernetes-based container orchestration, autonomous AI agents, a binary failure-prediction component, and reinforcement-learning-based recovery selection. The prototype was implemented with Spring Boot, Docker, Kubernetes, TensorFlow, Prometheus, Grafana, and PostgreSQL. Evaluation considered Mean Time to Recovery (MTTR), availability, recovery accuracy, response time, throughput, transaction success, and failure-prediction metrics. In the reported controlled testbed, MTTR decreased from 240 s to 48 s, availability increased from 98.2% to 99.8%, recovery accuracy increased from 84% to 98%, and service downtime decreased from 12 min to 2 min. The reported 1,000-observation confusion matrix yielded 95.7% accuracy, 96.5% precision, 95.2% recall, and 95.8% F1-score for failure prediction. In the increasing-workload experiment, response time remained at or below 1.18 s through 1,200 concurrent users, peak observed throughput reached 1,620 requests/s, and the successful transaction rate was 99.9%. These findings provide descriptive evidence that combining predictive monitoring with policy-driven recovery can improve fault-management responsiveness in a controlled Kubernetes environment. The results are interpreted within the limits of a single-cluster evaluation and aggregate point estimates, and broader generalisation requires repeated and multi-environment validation.
Keywords: Self-healing microservices, autonomous AI agents, cloud computing, Kubernetes, reinforcement learning, failure prediction