Repository navigation
Commit 49e2515
authored
feat!: deliver notifications outside the lock, one sink per operator, no runtime-async (#217)
* feat(scheduling)!: deliver notifications outside the lock
- Route every synchronous operator, sink and subject through DeliveryGate and SerializedDelivery, so no observer or user callback runs while a lock is held.
- Replace the public abstract witness, coordinator and scheduler bases with interfaces, embedded state structs and static helpers.
- Add the Serialize operator, SerializeSignal, SerializeWitness, SerializedSignal and Signal.Serialized, which serialize notifications without a lock.
- Add CurrentValueSignal, CurrentValueWitness, CurrentValueDelivery and ICurrentValueReader for latest-value sources that are read on subscribe.
- Add SyncLatestSlot and the slot subscription extensions, so a custom coordinator wires its sources without computing completion bits.
- Add DisposableSet, an inline set that holds a few disposables without allocating a list.
- Fix Switch never completing when an inner sequence finishes during its own subscribe.
- Run the handler and callbacks of the async subscribe sink outside its queue lock.
- Remove the unused Handle, SequencerWorkItem, SequencerWorkItemDisposal and Extensions ConcurrencyRaceHelpers helpers.
- Make CoalescingDispatchState, DispatchWorkState and IDispatchHost public API of ReactiveUI.Primitives.Reactive, so a custom UI sequencer can be written outside this repository. Each platform package now references them instead of compiling its own copy.
- Move PendingNotifications and PendingDelivery into an internal namespace, since they are storage details of SerializedDelivery rather than something a caller builds against.
- Update Microsoft.NET.Test.Sdk to 18.10.1 and TUnit to 1.68.0.
- Drop the .NET Framework leg from both benchmark projects, which cannot compile there: the generator harness needs AppContext.GetData and a generic Enum.GetValues, and the comparison benchmarks need GeneratedRegex.
- Resolve the .NET Framework polyfill sources from the props file's own directory, so a project nested below src finds them.
- Adopt the shared analyzer set in .editorconfig and update the NuGet packages that are not deliberately pinned.
- Add benchmarks covering every touched production file, including a diagnostics benchmark for the observable-event generator.
- Give the Avalonia and Blazor benchmarks their own assemblies, which target .NET only, so the main benchmark project keeps its .NET Framework leg.
- Add dispatchable workflows that run the benchmark projects, one for a suite run and one comparing two commits.
BREAKING CHANGE: Six public types are removed. Implement an interface and hold the matching state struct instead of deriving: WitnessAsync1 parent 8aba4af commit 49e2515
810 files changed
Lines changed: 68774 additions & 19283 deletions
File tree
- .github/workflows
- src
- Polyfills
- ReactiveUI.Disposables
- Disposables
- PublicAPI
- net10.0
- net11.0
- net462
- net472
- net481
- net48
- net8.0
- net9.0
- ReactiveUI.Primitives.Async.Core
- Advanced
- Disposables
- Helpers
- Mixins
- Observables
- Operators
- PublicAPI
- net10.0
- net11.0
- net462
- net472
- net481
- net48
- net8.0
- net9.0
- ReactiveUI.Primitives.Async.Reactive/PublicAPI
- net10.0
- net11.0
- net462
- net472
- net481
- net48
- net8.0
- net9.0
- ReactiveUI.Primitives.Async/PublicAPI
- net10.0
- net11.0
- net462
- net472
- net481
- net48
- net8.0
- net9.0
- ReactiveUI.Primitives.Avalonia.Reactive
- Concurrency
- PublicAPI
- net10.0
- net11.0
- net8.0
- net9.0
- ReactiveUI.Primitives.Avalonia/PublicAPI
- net10.0
- net11.0
- net8.0
- net9.0
- ReactiveUI.Primitives.Blazor.Reactive
- Concurrency
- PublicAPI
- net10.0
- net11.0
- net8.0
- net9.0
- ReactiveUI.Primitives.Blazor
- Concurrency
- PublicAPI
- net10.0
- net11.0
- net8.0
- net9.0
- ReactiveUI.Primitives.Core
- Advanced
- Concurrency
- PublicAPI
- net10.0
- net11.0
- net462
- net472
- net481
- net48
- net8.0
- net9.0
- Signals
- ReactiveUI.Primitives.Extensions.Core
- Internal
- Operators
- ReactiveUI.Primitives.Maui.Reactive
- Concurrency
- PublicAPI
- net10.0
- net11.0
- ReactiveUI.Primitives.Reactive
- Concurrency
- Disposables
- Platforms
- android
- apple
- PublicAPI
- net10.0-android
- net10.0-ios
- net10.0-maccatalyst
- net10.0-macos
- net10.0-tvos
- net10.0
- net11.0-android
- net11.0-ios
- net11.0-maccatalyst
- net11.0-macos
- net11.0-tvos
- net11.0
- net462
- net472
- net481
- net48
- net8.0
- net9.0
- ReactiveUI.Primitives.WinForms.Reactive
- Concurrency
- PublicAPI
- net10.0-windows
- net11.0-windows
- net462
- net472
- net481
- net48
- net8.0-windows
- net9.0-windows
- ReactiveUI.Primitives.WinForms/PublicAPI
- net10.0-windows
- net11.0-windows
- net462
- net472
- net481
- net48
- net8.0-windows
- net9.0-windows
- ReactiveUI.Primitives.WinUI.Reactive
- Concurrency
- PublicAPI
- net10.0-windows10.0.19041.0
- net11.0-windows10.0.19041.0
- net8.0-windows10.0.19041.0
- net9.0-windows10.0.19041.0
- ReactiveUI.Primitives.WinUI/PublicAPI
- net10.0-windows10.0.19041.0
- net11.0-windows10.0.19041.0
- net8.0-windows10.0.19041.0
- net9.0-windows10.0.19041.0
- ReactiveUI.Primitives.Wpf.Reactive
- Concurrency
- PublicAPI
- net10.0-windows
- net11.0-windows
- net462
- net472
- net481
- net48
- net8.0-windows
- net9.0-windows
- ReactiveUI.Primitives.Wpf/PublicAPI
- net10.0-windows
- net11.0-windows
- net462
- net472
- net481
- net48
- net8.0-windows
- net9.0-windows
- ReactiveUI.Primitives
- Concurrency
- PublicAPI
- net10.0-android
- net10.0-ios
- net10.0-maccatalyst
- net10.0-macos
- net10.0-tvos
- net10.0
- net11.0-android
- net11.0-ios
- net11.0-maccatalyst
- net11.0-macos
- net11.0-tvos
- net11.0
- net462
- net472
- net481
- net48
- net8.0
- net9.0
- benchmarks
- ReactiveUI.Primitives.Avalonia.Benchmarks
- ReactiveUI.Primitives.Benchmarks
- ReactiveUI.Primitives.Blazor.Benchmarks
- ReactiveUI.Primitives.ObservableEvents.Benchmarks
- tests
- ReactiveUI.Disposables.Tests
- ReactiveUI.Primitives.Async.Tests
- Internals
- ReactiveUI.Primitives.Blazor.Reactive.Tests
- ReactiveUI.Primitives.Blazor.Tests
- ReactiveUI.Primitives.Extensions.Tests
- Common
- Internal
- Operators
- ReactiveUI.Primitives.Reactive.Tests
- ReactiveUI.Primitives.Tests
- Common
Some content is hidden
Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.
Large diffs are not rendered by default.
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
18 | 18 | | |
19 | 19 | | |
20 | 20 | | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
21 | 24 | | |
22 | 25 | | |
23 | 26 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
197 | 197 | | |
198 | 198 | | |
199 | 199 | | |
| 200 | + | |
| 201 | + | |
| 202 | + | |
| 203 | + | |
| 204 | + | |
| 205 | + | |
| 206 | + | |
| 207 | + | |
| 208 | + | |
| 209 | + | |
| 210 | + | |
| 211 | + | |
| 212 | + | |
| 213 | + | |
| 214 | + | |
| 215 | + | |
| 216 | + | |
| 217 | + | |
| 218 | + | |
| 219 | + | |
| 220 | + | |
| 221 | + | |
| 222 | + | |
| 223 | + | |
| 224 | + | |
| 225 | + | |
| 226 | + | |
| 227 | + | |
| 228 | + | |
| 229 | + | |
| 230 | + | |
| 231 | + | |
| 232 | + | |
| 233 | + | |
| 234 | + | |
| 235 | + | |
| 236 | + | |
| 237 | + | |
| 238 | + | |
| 239 | + | |
| 240 | + | |
200 | 241 | | |
201 | 242 | | |
202 | 243 | | |
| |||
0 commit comments