gurix
d13844f219
feat(04-01): add AggregatePcap with timestamp-based windowing and gap-filling
...
- Add AggregatePcap to aggregate/window.go: reads ClassifiedPackets from channel,
assigns to time windows using Timestamp field (D-01), fills gaps with empty
snapshots (D-02: silence), fires onSnapshot callback per window (D-07)
- Add 7 tests covering basic, multiple windows, gaps, empty input, WindowIndex,
class counts, and onSnapshot callback
- All tests pass
2026-03-26 14:34:43 +01:00
gurix
f2bebaf554
feat(01-03): implement exit summary and verbose window output formatting
...
- Add PrintSummary writing per-protocol packet counts with percentages and TOTAL to io.Writer
- Add PrintWindowLine writing single verbose window activity line in [window N] CLASS:count format
- Add AccumulateTotals merging WindowSnapshot counts into cumulative totals map
- Output sorted alphabetically for deterministic display
- Add 6 tests: PrintSummary, PrintSummaryEmpty, PrintSummarySorted, PrintWindowLine, PrintWindowLineEmpty, AccumulateTotals
2026-03-25 12:17:28 +01:00
gurix
2a8fd7dd05
feat(01-03): implement ticker-driven window aggregator with TDD
...
- Add Aggregate function reading ClassifiedPackets, emitting WindowSnapshots per time window
- Add DefaultWindowMs=500 constant for configurable window duration
- Flush partial window on done channel close or closed events channel
- Call optional onSnapshot callback per window for verbose mode
- Add 5 tests: EmitsSnapshot, MultipleClasses, DoneFlushesPartial, EmptyWindow, WindowIndex
2026-03-25 12:16:36 +01:00