[Failed-Request-Alert-Tuning] Assign Appropriate HTTP Status Code for Immature Records error #3392
Labels
internal
For changes that affect the project's internal workings but not its outward-facing functionality.
Milestone
Description
The error caused by immature records in the Mirror Node (MN) is currently returning an HTTP 500 status code. This triggers the failed-request-too-high alerts unnecessarily, making it difficult to identify and prioritize critical issues. Since this scenario is expected behavior and not indicative of a server error, it should use a more appropriate HTTP status code.
This change will ensure that alerts are only triggered for critical issues while maintaining visibility of immature record occurrences through metrics for observability.
Solution
• Define a dedicated error type specifically for scenarios involving immature records.
• Update the HTTP status code for the “immature records found” error to 502 (Bad Gateway) instead of 500.
The text was updated successfully, but these errors were encountered: