|
| 1 | +# Changelog |
| 2 | + |
| 3 | +All notable changes to this workspace will be documented in this file. |
| 4 | + |
| 5 | +The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/), |
| 6 | +and this workspace adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). |
| 7 | + |
| 8 | +This is a lockstep workspace: all packages share the same version and release notes. |
| 9 | + |
| 10 | +## [Unreleased] |
| 11 | + |
| 12 | +### Changed |
| 13 | + |
| 14 | +- Updated dependencies to use latest versions: |
| 15 | + - `zooper_flutter_core: ^2.0.0` |
| 16 | + - `bounded: ^1.0.0` |
| 17 | + |
| 18 | +## [3.0.0] - 2026-01-10 |
| 19 | + |
| 20 | +### Changed |
| 21 | + |
| 22 | +- **BREAKING**: `RaiserEvent` is now a pure `abstract interface class` instead of a base class with implementation. |
| 23 | + - **Note: Using `RaiserEvent` is completely optional - `EventBus` works with ANY type.** |
| 24 | + - If you choose to use `RaiserEvent`, you must explicitly implement all three required properties: `id`, `occurredOn`, and `metadata`. |
| 25 | + - No more automatic property initialization - implement the interface explicitly. |
| 26 | + - This change allows events to use composition and multiple interfaces without inheritance constraints. |
| 27 | +- `RaiserEvent` now implements `ZooperDomainEvent` from `zooper_flutter_core` package. |
| 28 | +- Event IDs in `RaiserEvent` now use `EventId` type (ULID-based) instead of `String`. |
| 29 | + - IDs are generated via `EventId.fromUlid()` for better uniqueness guarantees. |
| 30 | + - Access raw string value via `event.id.value` when needed. |
| 31 | +- Renamed `RaiserEvent.timestamp` property to `occurredOn` for clarity and DDD alignment. |
| 32 | +- Removed `aggregateId` as a direct property from `RaiserEvent`. |
| 33 | + - Store aggregate identifiers in the `metadata` map instead: `metadata: {'aggregateId': 'user-123'}`. |
| 34 | + - Access via `event.metadata['aggregateId'] as String?`. |
| 35 | +- Removed helper mixins and convenience extensions. |
| 36 | +- Updated generator dependency constraints to `raiser: ^3.0.0` and `raiser_annotation: ^3.0.0`. |
| 37 | + |
| 38 | +### Important Note |
| 39 | + |
| 40 | +**`EventBus` is fully generic and does not require `RaiserEvent`.** You can publish and subscribe to any type. The `RaiserEvent` interface is purely optional for users who want standardized domain event metadata. |
| 41 | + |
| 42 | +## [2.0.1] - 2026-01-08 |
| 43 | + |
| 44 | +### Changed |
| 45 | + |
| 46 | +- Migrated generator implementation away from deprecated analyzer element APIs to remove deprecation warnings. |
| 47 | + |
| 48 | +## [2.0.0] - 2026-01-08 |
| 49 | + |
| 50 | +### Changed |
| 51 | + |
| 52 | +- **BREAKING**: Renamed `DomainEvent` to `RaiserEvent` to avoid naming conflicts with other packages. |
| 53 | +- Updated documentation references from `DomainEvent` to `RaiserEvent`. |
| 54 | +- Updated generator dependency constraints to `raiser: ^2.0.0` and `raiser_annotation: ^2.0.0`. |
| 55 | + |
| 56 | +## [1.0.0] - 2024-12-19 |
| 57 | + |
| 58 | +### Added |
| 59 | + |
| 60 | +- **EventBus** — Central dispatcher for publishing and routing domain events. |
| 61 | +- **DomainEvent** — Base class with automatic ID generation, timestamps, and optional aggregate ID. |
| 62 | +- **EventHandler<T>** — Type-safe interface for class-based event handlers. |
| 63 | +- **Subscription** — Handle for cancelling handler registrations. |
| 64 | +- **Priority-based ordering** — Higher priority handlers execute first. |
| 65 | +- **Error handling strategies**. |
| 66 | +- **AggregateException** — Collects multiple handler errors when using `continueOnError`. |
| 67 | +- **@RaiserHandler** annotation for marking event handler classes. |
| 68 | +- **@RaiserMiddleware** annotation for marking middleware classes. |
| 69 | +- Support for dependency injection through annotation metadata. |
| 70 | +- **Two-phase builder system** (`raiser_collecting` → `raiser_aggregating`). |
| 71 | +- **Automatic handler discovery** and **middleware discovery**. |
| 72 | +- Generated registration functions (`initRaiser()`, `initRaiserWithFactories()`, and named bus variants). |
| 73 | +- Dependency injection factory parameter generation. |
| 74 | +- Priority support and type-safe code generation. |
0 commit comments