LocalData/FutureEnhancements.md
Matt Bruce 3f6856f124 Update Models, Protocols, Services + tests + docs
Summary:
- Sources: Models, Protocols, Services
- Tests: LocalDataTests.swift
- Docs: FutureEnhancements, README
- Added symbols: struct AnyStorageKey, struct StorageKeyDescriptor, protocol StorageKey, func registerCatalog, func validateUniqueKeys, func validateDescription
- Removed symbols: struct StorageKeyDescriptor, struct StorageKeyEntry, protocol StorageKey, func registerCatalog

Stats:
- 11 files changed, 85 insertions(+), 27 deletions(-)
2026-01-18 14:53:26 -06:00

702 B

Future Enhancements

Dynamic Key Names

LocalData currently enforces exact, statically-registered key names for auditability. If we decide to allow dynamic names later (e.g., per-account keys), the suggested design is:

  • Add a name rule type (e.g., StorageKeyNameRule) that supports exact and prefix matching.
  • Extend StorageKeyEntry to carry a name rule.
  • Update catalog registration to validate overlapping rules and duplicates.
  • Update StorageRouter validation to accept keys that match the registered rules.
  • Require a catalog entry that documents the dynamic name pattern and rationale.

This keeps audit behavior explicit while allowing a controlled, documented escape hatch.