Add rooted derived-state events and bump 0.18.0#85
Merged
Conversation
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.
Description
Adds rooted provider-backed derived-state events and finalized epoch-boundary events to SOF, wires them through the runtime and built-in provider adapters, audits the new event surface, and bumps the publishable crate set to
0.18.0.This matters because the derived-state feed can now replay rooted vote/stake/sysvar/account observations and epoch transitions with explicit feed contracts, while strict capability expectations and built-in account-feed defaults now line up with the actual finalized-delivery semantics.
Changes
crates/sof-observer/src/framework/derived_state.rs: addedRootedAccountObservedandEpochBoundaryObservedfeed families, rooted-account classification, control-plane finalized epoch tracking, replay support, and targeted tests.crates/sof-observer/src/runtime.rs: routed finalized provider account updates into derived state, extended capability-policy coverage for rooted-authoritative consumers, and added runtime tests for provider-backed derived-state dispatch.crates/sof-observer/src/provider_stream/websocket.rs: defaulted account/program subscriptions tofinalizedunless commitment was explicitly set and added regression tests.crates/sof-observer/src/provider_stream/yellowstone.rs: defaulted account feeds tofinalizedunless commitment was explicitly set and added regression tests.crates/sof-observer/src/provider_stream/laserstream.rs: defaulted account feeds tofinalizedunless commitment was explicitly set and added regression tests.crates/sof-observer/tests/derived_state_runtime_restart_e2e.rs: extended restart replay coverage to rooted-account and epoch-boundary events and tightened the assertion to exact replay order.crates/sof-observer/src/provider_stream.rs: refreshed the public doctest for the currentTransactionEventshape.crates/sof-tx/src/adapters/derived_state.rsandcrates/sof-observer/src/framework/mod.rs: re-exported the new derived-state event surface to downstream consumers.crates/sof-observer/README.md,docs/gitbook/crates/sof.md, anddocs/architecture/derived-state-feed-contract.md: documented the new feed families, ingest surface, and finalized-default behavior for built-in account feeds.sof,sof-tx,sof-types,sof-solana-compat, andsof-gossip-tuningto0.18.0, updated internal dependency constraints, refreshed install snippets, and updatedCargo.lock.For slice-related changes, include:
AccountUpdateevents into derived-state replay, and downstream tx adapters can consume the new feed event types.processedmust now opt back in explicitly with.with_commitment(...Processed); no migration is needed for explicit configs.Motivation
Business motivation:
Technical motivation:
Alternative approaches considered:
Scope and impact
sofderived-state/runtime/provider-stream paths,sof-txderived-state adapters, release/docs metadata.RootedAccountObservedandEpochBoundaryObservedfeed families plus public re-exports; built-in account-feed defaults now use finalized commitment unless explicitly overridden.Testing
Commands/results:
Manual verification also included a local Agave
3.1.10+ Yellowstone12.2.0+solana.3.1.10plugin run from staged artifacts undertarget/, including validator startup,yellowstone-grpc-clientping/get-version, and a successful SOF Yellowstone example connection.Related issues and documentation
docs/architecture/README.mddocs/architecture/derived-state-feed-contract.mdReviewer checklist
docs/architecture/ard/0003-slice-dependency-contracts.md)Additional notes