168
Views
3
Comments
OutSystems doesn't seem to respect rest endpoint timeout
Application Type
Reactive
Service Studio Version
11.53.30 (Build 61739)
Platform Version
11.14.1 (Build 34445)

In OutSystems, I am consuming an external REST API. I have a client action that calls the api integration. The endpoint I'm calling takes about two minutes or more to run before returning a response.

I am consistently getting a 504 timeout error at 1 minute, with an error message from CloudFront. Everywhere I can find to set a timeout, I have set it to 600 seconds, but it doesn't seem to respect this.

In my client action, I set the Server Request Timeout to 600

In my API Method, I set the Timeout in Seconds to 600


In Service Center, I set Server Request Timeout to 600


Yet when I call this endpoint, it always times out after one minute with this error:


Is there someplace else I need to update to get the timeout to actually work?

2021-10-09 07-57-44
Stefan Weber
 
MVP

Hi,

CloudFront has a default maximum origin response timeout of 60 seconds. See here for quotas of AWS CloudFront. https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/cloudfront-limits.html

So your origin behind Cloudfront CDN does not response within that timeframe thus leading to the 504 error.

Best

Stefan

UserImage.jpg
Elijah Cunningham

Thanks for the info.

Where exactly does CloudFront come into play? CloudFront isn't involved in the API endpoint we're calling, so is it a part of OutSystems' stack? And if so, does that mean that there is no way to increase the timeout past 60 seconds if hosting your app on the OutSystems Cloud?

2021-10-09 07-57-44
Stefan Weber
 
MVP

Just a guess. Could it be that the API you are consuming is running behind AWS API Gateway and this in turn is an origin to CloudFront to optimize edge consumption?

Iam not exactly sure, but i doubt that this message is coming from the OutSystems stack. On the other hand, i never had an endpoint which takes more than a few seconds to return something. You may open a support ticket with OutSystems just to be sure.

Best

Stefan

Community GuidelinesBe kind and respectful, give credit to the original source of content, and search for duplicates before posting.