Sync State Provider
Component Detail
Data Layer
low complexity
mobile
0
Dependencies
4
Dependents
0
Entities
0
Integrations
Description
Riverpod AsyncNotifier that holds and broadcasts sync state (pending mutation count, last sync timestamp, dead-letter count, and in-progress flag) to all consuming widgets. Written to by SyncQueueService and RetryBackoffService; read by SyncStatusWidget and SyncDiagnosticsPanel.
sync-state-provider
Responsibilities
- Maintain authoritative in-memory sync state as a Riverpod AsyncNotifier
- Expose reactive state stream for widget consumption without direct service coupling
- Provide synchronous snapshot accessor for non-reactive code paths
Interfaces
SyncStateProvider extends AsyncNotifier<SyncState>
updateState(SyncState state) -> void
ref.watch(syncStateProvider) -> AsyncValue<SyncState>
Relationships
Dependents (4)
Components that depend on this component