cancel
Showing results for 
Search instead for 
Did you mean: 
Jasonatunr
Community Member

504 Gateway Time-out courses API

When calling the courses API I get a 504 Gateway Time-out error at random times. This is not a consistent error, but is happening once per month at least and I cannot find a cause to this problem. It doesn't seem to be related to outages and is always a 504 error when requesting 100 per_page from the courses endpoint API.

Does anyone have any experience with this error and anything they tried that may have worked?

Labels (1)
1 Reply
robotcars
Community Champion

Happened to me this morning too.

I, [2021-03-25T06:25:26.893253 #163982] INFO -- response: Status 504

This happens when Canvas is having trouble or communication between your device and Canvas are having trouble.

The only suggestion I have is if the response body looks like:

{"errors":[{"message":"An error occurred.","error_code":"bad_gateway"}]}
 
That you add some sleep/wait timeout and retry the request, persist as needed.
It's tricky to troubleshoot and replicate, and I still waffle with deciding to sleep or retry the job later.
 
Past Incidents
Mar 25, 2021
Resolved - This incident has been resolved.
Mar 25, 08:27 MDT
Update - We are continuing to monitor for any further issues.
Mar 25, 08:17 MDT
Monitoring - A fix has been implemented and we are monitoring the results.
Mar 25, 08:12 MDT
Identified - The issue has been identified and a fix is being implemented.
Mar 25, 07:07 MDT
Investigating - We are currently investigating this issue.
Mar 25, 06:48 MDT