Goal
Create docs/architecture.md with diagrams (ASCII so they render in terminals and on GitHub) that document the high-level pipeline, plugin lifecycle, event flow, configuration loading, and concurrency model.
Files
pipeline/pipeline.go (read)
plugin/plugin.go (read)
internal/config/config.go (read)
docs/architecture.md (new)
Changes
Sections:
- High level overview: input plugin to pipeline to filter to output plugin. ASCII diagram showing the channel flow. Note the 1:1 architecture rule (one input, one filter set, one output).
- Plugin system: the
Plugin interface (Start, Stop, ErrorChan, InputChan, OutputChan), registration mechanism, and lifecycle states.
- Event flow: per-event-type emission triggers, channel flow, and error channel handling.
- Configuration: precedence diagram showing CLI flags overriding YAML overriding env vars. Per-plugin option loading.
- Concurrency model: which goroutines exist, how they coordinate shutdown via
Stop and sync.Once, and how the API server interacts with the pipeline.
Use ASCII art for diagrams so they render the same in terminal and browser.
Verification
- File renders on GitHub.
- Diagrams accurately describe current code.
- Cross-checks against
pipeline/pipeline.go and plugin/plugin.go confirm interface signatures and channel directions.
Dependencies
None.
Goal
Create
docs/architecture.mdwith diagrams (ASCII so they render in terminals and on GitHub) that document the high-level pipeline, plugin lifecycle, event flow, configuration loading, and concurrency model.Files
pipeline/pipeline.go(read)plugin/plugin.go(read)internal/config/config.go(read)docs/architecture.md(new)Changes
Sections:
Plugininterface (Start,Stop,ErrorChan,InputChan,OutputChan), registration mechanism, and lifecycle states.Stopandsync.Once, and how the API server interacts with the pipeline.Use ASCII art for diagrams so they render the same in terminal and browser.
Verification
pipeline/pipeline.goandplugin/plugin.goconfirm interface signatures and channel directions.Dependencies
None.