orion-error Documentation
orion-error is the Rust implementation of the WuKong error governance model.
At the documentation entry point, the most important framing is this:
- contract channel — stable identity, category, retryability, visibility
- diagnostic channel — detail, source chain, operation context, key fields
- adaptive output — HTTP / RPC / CLI / log projections generated by policy
In this crate, those ideas map to:
#[derive(OrionError)]for stable semantic identitiesStructError<R>as the unified runtime carriersource_err(...)for first entry and semantic-boundary wrappingconv_err()for reason remapping without rebuilding the error storyreport()/identity_snapshot()/exposure(...)for boundary output
Suggested reading order: start with the user guide to learn concepts and usage, then check the developer guide for public API contracts and release details.
User Guide
| Document | Description |
|---|---|
| Why orion-error | Error governance motivation and examples |
| Tutorial | Getting started tutorial |
| Protocol Contract | Exposure projection contract |
| Report / Exposure Boundary | Diagnostic vs exposure boundary |
| Logging | Logging integration |
| Comparison with thiserror | Differences and coexistence |
| Ecosystem Comparison | anyhow / thiserror / color-eyre / orion-error |
| Large-Scale Error Governance Manifesto | WuKong model, governance principles, and industrial validation |
| Design Constraints | Known design constraints |
Developer Guide
| Document | Description |
|---|---|
| API Contract | Public API boundaries |
| Compatibility Migration | Migration from older APIs |
| Public Surface Grading | Layered export grading |
| Release Checklist | Pre-release checks |
| Performance Benchmarks | Allocation benchmarks |
When docs and implementation conflict, src/, tests/, examples/ are authoritative.