ADR 009: Readable logs and error codes
Status: accepted
Context
Logs must be clear and useful to maintain the platform and diagnose problems. They did not carry enough information to locate the source of a problem quickly or to understand the nature of an error.
Decision
- Module name. Every log entry includes the name of the module it comes from, in square
brackets:
[Portal],[Admin]. This locates the source of an entry and gives its context at a glance. - Error codes. Every exception or error in the logs carries a standardized error code, defined in a documented list.
- Reference and action plan. All error codes are listed in one document, with a description of each code and the action to take to resolve it. Developers and support teams use it as their guide.
- Progressive correction. Existing exceptions inherited from Open ENT NG are brought to this standard progressively, starting with the most critical and the most frequent.
Benefits
- Clarity. Logs are easier to read and more informative.
- Faster diagnosis. Error codes and their action plans lead to a quicker, better-targeted resolution.
- Better follow-up. One reference for error codes makes incidents and their resolutions easier to track.