
Write, Run, Debug — REslava.Result three-layer observability story
Pipeline diagrams generated at compile time are great for understanding structure. But structure tells you what could happen — not what did happen. That's where runtime observation comes in. REslava.Result has a three-layer story: ✏️ Write — add [ResultFlow] to any fluent Result method. The source generator emits a Mermaid diagram constant at compile time. You can paste it into GitHub, Notion, VS Code, or mermaid.live and see the entire pipeline shape before you ever run it. ▶️ Run — make your class partial. The same generator now emits a FlowProxy alongside the diagram. Call svc.Flow.Process(...) instead of svc.Process(...) and every node in the pipeline is traced automatically: output value, error type, elapsed milliseconds. The RingBufferObserver holds the last N traces in memory with zero allocation. 🐛 Debug — call svc.Flow.Debug.Process(...) for a single-trace debug run. The generator writes reslava-debug-{Method}.json to your bin/ folder automatically. The VS Code extension watch
Continue reading on Dev.to
Opens in a new tab


