Our company runs applications on a Micro Service architecture that includes thousands of services. I am working on a backend application "X" that talks to 50+ services. Frontend services call my service "X" to execute requests on other services.
Problem:
Front end wants to show user friendly messages when something fails on other services.
- Other services do not return user friendly messages. It is not possible for me to request changes by other teams as there are several.
- There are no agreed error codes as such. Other services return a string error message. Currently, it is passed back to the UI. Sometimes the error messages are a pointer references (bad code :/)
Possible Solution:
Check for error message string and have a mapping in my service to a user friendly message. But things can break if the callee service changed their error message. Fallback to a default error message when a custom error mapping is not found.
Any more ideas on scalable and sustainable solution? Thanks!