1

I have a webhook endpoint where our service provider send a payload which I have to respond to within 2 seconds. I've been getting way too many timeout errors from the service provider, meaning I wasn't able to respond within 2 seconds.

I did some digging as to when the Fargate Server gets the payload vs when the ALB receives it. I went through some of the access logs from the ALB and found that it takes about a second or so to pass the payload from ALB to the fargate server.

Here's the timestamp at which the request arrived to the ALB - 15:19:20.01 and my server recieved it at - 15:19:21.69.

There's over a second of difference, I wanna know how to reduce it. One of the solution I thought of was that instead of registering my domain + the URI to the service provider to send webhook to, I set my IP + the URI so there's no need of forwarding done by ALB.

Let me know what you guys think.

EDIT - The solution I thought of was pretty stupid because fargate provides a new IP everytime a new task is deployed (as far as I know). Also the ALB forwards the request / payload to the ECS Target Group, just throwing this fact in as well.

3
  • are you using hostnames and a remote resolver? it could be a dns issue in that case
    – djdomi
    Commented May 22, 2022 at 6:55
  • hey, I was going through my ALB logs and found that the request_processing_time for ALB is 0.001 which is perfect but elb_status_code is 460, and from the documentation here, its because of the fact that "the client closed the connection with the load balancer before the idle timeout period elapsed.". I don't know how to fix that, maybe I'll contact my service provider and what their timeout for connection is? Not sure honestly.
    – Sahil
    Commented May 22, 2022 at 7:53
  • 1
    I would always suggest first contact the service provider with a ticket before trying to assk on a public Q&A site imho
    – djdomi
    Commented May 22, 2022 at 12:03

0

You must log in to answer this question.

Browse other questions tagged .