Bedrock.DataPlane.Materializer.Olivine.Reading (bedrock v0.5.3)
View SourceManages read request tasks and waitlists for Olivine storage.
Handles active task tracking, process monitoring, and waitlist management for read operations that cannot be immediately satisfied.
Summary
Functions
Returns the set of active task PIDs.
Handle a get request with full lifecycle management (async, waitlist, task tracking). Returns {updated_manager, result}.
Handle a get_range request with full lifecycle management (async, waitlist, task tracking). Returns {updated_manager, result}.
Creates a new empty read request manager.
Removes all waiting fetches for a version and processes them with fetch logic. Returns updated_manager.
Removes an active task from tracking with telemetry.
Shuts down the read request manager by waiting for active tasks and notifying waiting fetches.
Types
@type t() :: %Bedrock.DataPlane.Materializer.Olivine.Reading{ active_tasks: MapSet.t(pid()), waiting_fetches: Bedrock.Internal.WaitingList.t() }
Functions
Returns the set of active task PIDs.
@spec handle_get( t(), Bedrock.DataPlane.Materializer.Olivine.Reading.ReadingContext.t(), Bedrock.key() | Bedrock.KeySelector.t(), Bedrock.version(), keyword() ) :: {t(), term()}
Handle a get request with full lifecycle management (async, waitlist, task tracking). Returns {updated_manager, result}.
@spec handle_get_range( t(), Bedrock.DataPlane.Materializer.Olivine.Reading.ReadingContext.t(), Bedrock.key() | Bedrock.KeySelector.t(), Bedrock.key() | Bedrock.KeySelector.t(), Bedrock.version(), keyword() ) :: {t(), term()}
Handle a get_range request with full lifecycle management (async, waitlist, task tracking). Returns {updated_manager, result}.
@spec new() :: t()
Creates a new empty read request manager.
@spec notify_waiting_fetches( t(), Bedrock.DataPlane.Materializer.Olivine.Reading.ReadingContext.t(), Bedrock.version() ) :: t()
Removes all waiting fetches for a version and processes them with fetch logic. Returns updated_manager.
Removes an active task from tracking with telemetry.
@spec shutdown(t()) :: :ok
Shuts down the read request manager by waiting for active tasks and notifying waiting fetches.