brainy/tests/unit/utils
David Snelling da55be7520 fix: aggregation state adoption on reopen + single-flight backfill + query-cap ratchet removal
- AggregationIndex: defineAggregate before init no longer forces a backfill.
  init reconciles instead of clobbering: the app definition wins, persisted
  state is adopted on hash match, a write landing pre-adoption forces an exact
  rescan, and a successful state load clears the backfill flag. New ready()
  settles every adoption decision before query paths consult backfill state.
- brainy: backfills are single-flight and batched. Concurrent queries share one
  store walk and every pending aggregate fills from that same walk; the old
  behavior let each concurrent query wipe the others' partial state and start
  its own full walk, so a store under steady aggregate traffic never converged.
  queryAggregate also waits for persisted definitions before deciding an
  aggregate does not exist.
- paramValidation: recordQuery is telemetry-only. The duration-based cap
  ratchet (x0.8 per recorded query while lifetime-average exceeded 1s, floored
  at 1000 - below the documented 10000 auto floor, reported under a stale
  basis label) is removed; the cap comes from its construction-time basis or
  explicit overrides alone.
- storage: __aggregation_* and singleton system keys (brainy:entityIdMapper)
  are recognized before the unknown-key warning fires; routing is unchanged.
- docs: find-limits cap-immutability note, aggregation reopen/adoption
  semantics, RELEASES.md 8.5.1 entry.
2026-07-17 09:20:09 -07:00
..
collation.test.ts fix: deterministic code-point string collation for column store + aggregation 2026-05-26 17:35:18 -07:00
contentExtractor.test.ts feat: expand ContentCategory to universal 6-category set for highlight() 2026-01-27 13:44:58 -08:00
entity-id-mapper-stability.test.ts chore(8.0): final pre-RC1 sweep — API consistency, named errors, orphans, zero-cast codebase 2026-06-11 14:51:00 -07:00
entity-id-mapper-u32-ceiling.test.ts feat(8.0): GraphAccelerationProvider contract — the native graph-engine seam 2026-06-21 08:12:22 -07:00
memoryLimits.test.ts fix(8.0): drive query-cap off MemAvailable + floor auto-detected caps 2026-06-16 09:01:45 -07:00
metadataIndex-text-indexing.test.ts feat: add structured content extraction and batch embedding optimization to highlight() 2026-01-27 10:27:22 -08:00
metadataIndex-type-aware.test.ts chore(8.0): final pre-RC1 sweep — API consistency, named errors, orphans, zero-cast codebase 2026-06-11 14:51:00 -07:00
mutex.test.ts chore(8.0): final pre-RC1 sweep — API consistency, named errors, orphans, zero-cast codebase 2026-06-11 14:51:00 -07:00
paramValidation.test.ts fix: aggregation state adoption on reopen + single-flight backfill + query-cap ratchet removal 2026-07-17 09:20:09 -07:00
resultRanking.test.ts feat(8.0)!: flip requireSubtype default to true (BRAINY-8.0-SUBTYPE-CONTRACT § C-1) 2026-06-09 14:58:25 -07:00
roaring-bitmap-integration.test.ts fix: migrate from roaring (native C++) to roaring-wasm for universal compatibility 2025-10-14 10:24:59 -07:00
unifiedCache-eviction.test.ts refactor(8.0): final cleanup — drop HnswProvider alias + config.hnsw + 'hnsw' surface (scaffold step 6) 2026-06-09 13:28:53 -07:00