-
Notifications
You must be signed in to change notification settings - Fork 56
Conversation
Your Render PR Server URL is https://near-explorer-frontend-with-indexer-pr-zl77.onrender.com. Follow its progress at https://dashboard.render.com/web/srv-c4tm3mc6fj3b4nv5vji0. |
Thank you! 👍 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We should return some HTTP error status code when the diff is more than 30 blocks, so we can just plug it into the services that use HTTP status codes to reason about the service health.
I like this idea. Reference https://en.wikipedia.org/wiki/List_of_HTTP_status_codes I think of 5xx as it's obviously a server error, not the client. So I can suggest either 500 Internal Server Error (which is easy to connect with third-party service) or 503 as we can consider that Service is unavailable. So I can propose to return the data I'm returning currently + status 200 if the diff is between 30 blocks and 500/503 if diff is more than 30. WDYT @frol @telezhnaya ? |
HTTP 503 sounds the most appropriate here |
9631412
to
1cc1461
Compare
I will merge it later today batched with some other PRs. |
No description provided.