WIP: State Reconstructor#160
Draft
inxilpro wants to merge 62 commits into
Draft
Conversation
Co-Authored-By: Skyler Katz <skylerkatz@hey.com>
Co-Authored-By: Skyler Katz <skylerkatz@hey.com>
Co-Authored-By: Skyler Katz <skylerkatz@hey.com>
- Rename StateManager class to Scope and update all references - Create ReconstitutingScope that reconstitutes stale states on-demand by replaying their connected component of events - Add Scope::run() method for managing the current scope binding in the container - Add Scope::singleton(), all(), willPrune(), and prune() methods - Enable snapshot writing and pruning in Broker by implementing writeSnapshots() helper - Add StoresSnapshots dependency to Broker - Update cache contracts with values() method and prune-related methods - Remove incomplete StateReconstructor and ReconstitutingStateManager classes - Bind ReconstitutingScope in service provider - Update Replay to use Scope::run() for scope management - Rename StateManagerTest to ScopeTest and update test names - Fix Date::setTestNow() calls to include timestamps - Remove debug dump() statements from tests
…harvest merging - Restore snapshot hydration on the replay path (skip reconstitution but load from snapshots) - Fix isStale() to match singletons by type only, mirroring event storage - Fix harvest to merge into exact requested instances and never clobber live singletons - Hoist setReplaying(true) outside the replay loop - Add ReplayEvictionTest to pin snapshot reload during eviction
Pin states with in-flight events to prevent eviction during batch operations. Refactor MultiCache to support layered reads with backfill and separate read/write-only cache wrappers. Split authorize and validate into distinct phases. Fix StateIdentity to accept string IDs from database drivers. Add comprehensive cache and state identity tests.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Just posting this as a draft for discussion.