# Scenario matrix

This matrix documents what the executable actually measures. “Native” means a
public primitive supplied by the package, without a custom compatibility layer.

| Scenario | usecase_forge | bloc | riverpod | mobx | redux |
|---|---|---|---|---|---|
| Current state read | `UseCase.current.state` | `Bloc.state` | `ProviderContainer.read` | `Observable.value` | `Store.state` |
| Sync command to one state | command → handler → `publish` | event → handler → `emit` | Notifier method → `state =` | `Action` → `Observable.value =` | `dispatch` → reducer |
| Async command after controlled Future | async handler | async event handler | async Notifier method | `AsyncAction` | controlled middleware |
| 1/10/100 listeners | snapshot stream | Bloc stream | `ProviderContainer.listen` | `Observable.observe` | `Store.onChange` |
| 10k/100k sequential updates | await state delivery for every command | await state delivery for every event | await provider delivery | action/delivery completes synchronously | await `onChange` delivery |
| 10/100 concurrent operations | concurrent handlers with controlled gates | default concurrent handlers | concurrent Notifier method calls | concurrent `AsyncAction` calls | concurrent middleware operations |
| Subscribe + current value | synchronous replay-latest subscription | `N/A`: stream does not replay | `fireImmediately: true` | `fireImmediately: true` | `N/A`: `onChange` does not replay |
| Runtime create + close | create `UseCase`, then `close` | create Bloc, then `close` | create container, then `dispose` | `N/A`: no runtime close for the primitive | create Store, then close `onChange` |
| Admission/Pending queue | fixed 100/1k/10k burst scale study | not emulated | not emulated | not emulated | not emulated |
| High-cardinality `rejectNew` conflict lookup | 100/1k/10k unrelated groups | not emulated | not emulated | not emulated | not emulated |
| `replace` with unrelated backlog | one replaced group behind 5k unrelated entries | not emulated | not emulated | not emulated | not emulated |
| Sequential blocked lane | measured separately | not emulated | not emulated | not emulated | not emulated |
| Busy sequential lane heads | 5k occupied lane heads | not emulated | not emulated | not emulated | not emulated |
| Rate-limit admission | measured separately | not emulated | not emulated | not emulated | not emulated |
| Cancellation storm | 5k started/cancelled executions | not emulated | not emulated | not emulated | not emulated |
| Terminal history read/write | measured separately | not emulated | not emulated | not emulated | not emulated |
| Instruction resolution | frozen defaults and registration override | not applicable | not applicable | not applicable | not applicable |
| Snapshot publisher without listeners | accepted updates, zero callbacks | not emulated | not emulated | not emulated | not emulated |
| Direct snapshot publisher callbacks | 1/10/100 listeners | not emulated | not emulated | not emulated | not emulated |

## Known semantic differences inside common rows

The common rows are close enough to be useful but not identical:

- UseCase Forge creates an execution entry and infrastructure-owned lifecycle;
  a state manager may only mutate and notify a value.
- Bloc dispatches typed events and, by default, processes events concurrently.
- Riverpod reads include lookup through its provider/container graph.
- MobX actions batch observable notifications until the action completes.
- Redux reducers are synchronous; asynchronous behavior belongs to middleware.
- Stream scheduling differs. The adapters preserve the package defaults and use
  deterministic delivery barriers instead of forcing a common schedule.
- All runtimes share one integer state in concurrent scenarios. “Independent”
  describes the controlled asynchronous executions, not separate stores.

## Explicit exclusions

- Provider is fully excluded by owner decision.
- Flutter bindings and widget rebuilds are deferred to the dedicated Flutter
  integration stage.
- DevTools, persistence, code generation, dependency injection, and test DSLs
  are compared architecturally, not timed.
- The suite does not install `flutter_bloc`, `flutter_riverpod`, `flutter_mobx`,
  `flutter_redux`, or any Provider package.
- Allocation counts and GC pauses require a separate VM-service profile and
  are not inferred from Stopwatch throughput.
