Add exportState and moduleSnapshot helpers across all module categories.

Fifth pass: complete measurement modules (sla-budget, histogram-gossip) with moduleSnapshot/toJSON; stats-exporter exportSnapshot; exportState() alias on modules with standard snapshot serialization.

Co-authored-by: Cursor <[email protected]>
This commit is contained in:
Raven Scott
2026-05-21 04:29:50 -04:00
co-authored by Cursor
parent 3af23c0d34
commit faf152a8ac
186 changed files with 776 additions and 0 deletions
@@ -139,6 +139,10 @@ class HyperP2PBandwidthShare extends EventEmitter {
return this.snapshot()
}
exportState () {
return this.toJSON()
}
async ready () {
if (this.swarm || !this.topic) return this
await initModuleSwarm(this, {