Fix ECS ElastiCache Timeout Issue

Job ID: 39813058

Budget: ₹600 – ₹1,500 INR

My container-based API runs on Amazon ECS inside a private VPC and relies on an AWS ElastiCache (managed Redis) cluster. Every request that needs Redis now ends in a 504 Gateway Timeout; CloudWatch logs show constant socket timeouts when the task tries to reach the cluster.

I need someone to trace why my tasks can no longer maintain a stable connection, resolve the root cause, and leave the service healthy. Possibilities I have considered—but haven’t confirmed—include security-group rules, subnet routing, connection limits, mis-tuned Redis client settings, or an overloaded ElastiCache node.

What I expect from you
• Inspect ECS task networking, VPC routing tables, security groups, and ElastiCache metrics/logs
• Pinpoint the exact reason for the timeouts
• Implement or guide the required fix (network rule change, Redis parameter tweak, client-side retry/pool adjustment, etc.)
• Verify that the API runs for at least 24 h with zero Redis timeouts, reflected in CloudWatch and an ALB 200-OK health check

You’ll need solid AWS VPC, ECS, and Redis expertise plus familiarity with CloudWatch Logs, VPC Flow Logs, and the AWS CLI/Console. Once complete, hand over a short summary of changes so I can keep the setup reproducible through Terraform.