내용으로 건너뛰기

Faster failover time

0

I have an app deployed across two regions;

Route53 ----> ALB (Region 1) ----> ECS services
        \---> ALB (Region 2) ----> ECS services 

I setup Route 53 with Traffic Flow using the Latency policy so incoming requests are sent to the region with lowest latency. It works.

If one of my region loses connection, traffic is automatically redirected to the surviving region. However, it takes a few minutes for this to happen and my users are getting 503 in the meantime. Is there anything I can do to make the failover faster?

질문됨 4년 전753회 조회

1개 답변
1
수락된 답변

Hi,

You can create a Route 53 health check for each region to validate application health, and configure the request interval and failure threshold according to your use case requirements.

In case of failure, Route53 will remove this record from the routing, while still resolving the DNS lookup using your latency based policy.

전문가

답변함 4년 전

  • Thanks. This improves the response time somewhat. I still get 503 for a minute when one region is down. Is there a way to re-architect my application so that detect which regions are responding and only then direct the traffic to them according to latency?

  • What TTL have you configured for the Route53 record? In order to respond quickly to changes in health status, AWS recommends to specify a TTL of 60 seconds or less when a health check is associated to a latency record. Given your use case requirements, you could reduce this value and combine with a retry policy at the client side.

  • Thanks. I set the TTL to 60 seconds in the Traffic Flow and it's failing over faster now.

로그인하지 않았습니다. 로그인해야 답변을 게시할 수 있습니다.

좋은 답변은 질문에 명확하게 답하고 건설적인 피드백을 제공하며 질문자의 전문적인 성장을 장려합니다.