Summary
Create a unified error code registry document that catalogs all error code ranges across the ecosystem, verifies no overlaps, and provides a lookup reference.
Parent Issue
Part of: [EPIC] docs: Address documentation gaps across all ecosystem systems (#325)
Background (Why)
The kcenon ecosystem uses a decentralized error code registry where each system is allocated a range:
- common_system: -1 to -99
- thread_system: -100 to -199
- logger_system: -200 to -299
- container_system: -300 to -399
- monitoring_system: -400 to -499
- database_system: -500 to -599
- network_system: -600 to -699
However, there is no centralized document verifying:
- Actual error codes defined in each system
- Whether any codes overlap between systems
- What each specific error code means
- How to handle cross-system error propagation
Scope (What)
Create docs/ERROR_CODES.md covering:
1. Error Code Range Allocation
| System |
Range |
Allocated |
Used |
Available |
| common_system |
-1 to -99 |
99 |
? |
? |
| thread_system |
-100 to -199 |
100 |
? |
? |
| logger_system |
-200 to -299 |
100 |
? |
? |
| container_system |
-300 to -399 |
100 |
? |
? |
| monitoring_system |
-400 to -499 |
100 |
? |
? |
| database_system |
-500 to -599 |
100 |
? |
? |
| network_system |
-600 to -699 |
100 |
? |
? |
2. Per-System Error Code Catalog
For each system, list every defined error code:
-1: UNKNOWN_ERROR — General unknown error
-2: INVALID_ARGUMENT — Invalid function argument
...
3. Error Code Lookup
- How to look up error code meaning programmatically
- Error code to string conversion API
- Logging error codes with context
4. Cross-System Error Handling
- How errors propagate across system boundaries
- Error wrapping and context addition
- Best practices for multi-system error handling
5. Error Code Verification
- Script or test to verify no overlapping codes
- CI integration for error code uniqueness
Acceptance Criteria
Summary
Create a unified error code registry document that catalogs all error code ranges across the ecosystem, verifies no overlaps, and provides a lookup reference.
Parent Issue
Part of: [EPIC] docs: Address documentation gaps across all ecosystem systems (#325)
Background (Why)
The kcenon ecosystem uses a decentralized error code registry where each system is allocated a range:
However, there is no centralized document verifying:
Scope (What)
Create
docs/ERROR_CODES.mdcovering:1. Error Code Range Allocation
2. Per-System Error Code Catalog
For each system, list every defined error code:
3. Error Code Lookup
4. Cross-System Error Handling
5. Error Code Verification
Acceptance Criteria