Files
2026-05-27 23:29:53 +01:00

1.1 KiB

Tasks — network-plugin-content-delivery-store

Blocked on: network-plugin-content-delivery (core), @suaveplan/drive.

1. Implementation

  • 1.1 src/store/chunk-store.ts — ChunkStore over @suaveplan/drive (pluggable ChunkStoreAdapter).
  • 1.2 LRU + TTL eviction with maxBytes and maxAgeMs budgets.
  • 1.3 Bus events: cd:chunk-stored, cd:chunk-evicted.
  • 1.4 Wire ContentDeliveryPlugin.store getter through the facade.
  • 1.5 Add ChunkStoreConfig to ContentDeliveryPluginConfig as an optional field.

2. Tests

  • 2.1 src/store/chunk-store.spec-conformance.test.ts — put/get, TTL, LRU.
  • 2.2 src/store/chunk-store.eviction.spec-conformance.test.ts — eviction order under mixed traffic.

3. Verify

  • 3.1 bunx turbo lint typecheck test --filter=@suaveplan/network-plugin-content-delivery green.
  • 3.2 bunx turbo test:coverage --filter=@suaveplan/network-plugin-content-delivery 100/100/100/100.
  • 3.3 bun scripts/openspec-conformance.ts @suaveplan/network-plugin-content-delivery PASS (build green; CLAUDE-Rule-11 runner imports verified).