Wire provider auth membership cache to chain-state coordinator#255
Open
danielbui12 wants to merge 1 commit into
Open
Wire provider auth membership cache to chain-state coordinator#255danielbui12 wants to merge 1 commit into
danielbui12 wants to merge 1 commit into
Conversation
Closes the auth revocation staleness window: MemberSet/MemberRemoved/ BucketDeleted events are now surfaced as typed StorageEvent variants and invalidate the affected bucket's MembershipCache entry on every finalized block, instead of only expiring on TTL. Also fixes a lost-update race in MembershipCache::get_role where a chain fetch already in flight could overwrite a concurrent invalidate() with stale membership, silently reopening the revocation window it was meant to close.
bkontur
reviewed
Jul 1, 2026
| "Admin" => Some(Role::Admin), | ||
| "Writer" => Some(Role::Writer), | ||
| "Reader" => Some(Role::Reader), | ||
| _ => None, |
Collaborator
There was a problem hiding this comment.
I am not sure here, ignore and "do not trigger invalidation", we need to probably land the typed PR #239 first to see
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.
Changes
Closes the auth revocation staleness window:
MemberSet/MemberRemoved/ BucketDeletedevents are now surfaced as typedStorageEventvariants and invalidate the affected bucket'sMembershipCacheentry on every finalized block, instead of only expiring on TTL.Also fixes a lost-update race in
MembershipCache::get_rolewhere a chain fetch already in flight could overwrite a concurrentinvalidate()with stale membership, silently reopening the revocation window it was meant to close.