Last updated at 24 August 2021 | Published at 14 March 2018
- Added a deprecated Consumer interface for easier upgrade from 0.8
- Added a new header AGGREGATE_ROOT_TYPE, which is added by the default aggregate root repository and exposed via a
getter on the
- [Serialization] Added a MySQL8DateFormatting serialization decorator to support MySQL 8 dates.
- Added missing scalar types for message header values (array/float/bool).
- Loosened the exception checking to be more in line with PHPUnit’s exception comparison.
- Aggregate root version is now correctly incremented per event.
EventSauce\EventSourcing\Consumerinterface was renamed to
- The dependency on
CodeGenerationmodule was extracted into a separate package
- The test utilities were extracted into a separate package
- The clock module was extracted into a separate package
- The serialization and upcasting is no longer generator based and now maps 1:1.
0.8.2 - 2020-11-01
- Support PHP 8
- Added typehints
- Cleaned up shipped artifact
0.8.1 - 2020-04-05
ramsey/uuidversion 3 and 4.
0.8.0 - 2019-12-21
Dispatch events with ease! The default MessageDispatchingEventDispatcher allows you to dispatched events, which dispatches Messages on your regular MessageDispatcher.
- The method
::timeZone(): DateTimeZonewas added to the
TestClock::moveForward(DateInterval $interval): voidwas added:
moveForwardwas introduces to make moving the test clock forward easier. Read how to use the SystemClock and the TestClock.
- Snapshotting 🤩
- Code Generation supports user defined interfaces for generated classes.
- A new
EventConsumerbase-class is provided to simplify event consumption.
- Aggregate version handling is now more accurate (inaccuracies could happen when reducing streams in upcasting).
- Message repositories are now expected to return the aggregate version as the
- Message repositories must now implement the
- Many things have return types now 👍
See the upgrade guide to 0.7.0.
- Event serialization is now converted to payload serialization. Generated commands now use the same serialization for easier tracing and logging.
- Aggregate root behaviour now has a private constructor.
See the upgrade guide to 0.6.0.
Test helpers (the ::withX methods) are now immutable.
BaseAggregateRoot has now been removed and all the traits have
been collapsed into one. This trait has been moved to the root namespace.
- Multiple interactions and intermediate persisting of aggregates now has correct versioning of messages.
- Code generation now handles types and type aliases better.
- symfony/yaml now allows ^3.2|^4.0
AggregateRootRepositoryis now an interface. The default implementation is the
Eventinterface is removed. A new
SerializableEventinterface is provided to aid the default serializers. If you use the default serializers your events must implement this interface. The methods are the same as the
Eventinterface, so effectively it’s an in-place replacement.
CodeDumperis changed to ensure code now implements the
AggregateRootTestCasenow allows you to overwrite the
aggregateRootRepositorymethod for if/when you have a custom implementation and still want all the benefits of the default test tooling.
- The Header::AGGREGATE_ROOT_ID is no longer converted to string in the default decorator but in the serializer.
- The Header::AGGREGATE_ROOT_ID_TYPE is now set in the serializer.
CodeDumpernow generated prettier code.
PointInTimerelated properties of the
Eventinterface are removed. The
DefaultHeadersDecoratornow ensures all events receive a
AggregateRootnow keeps track of a version, the
ConstructionBehaviourtrait has been updated to reflect this and shows how it’s implemented.
AggregateRootTestCasenow requires you to implement the
newAggregateRootIdmethod to be able to return a stable aggregate root id from the
MessageDispatcherChainis introduced to be able to chain multiple dispatchers together. This allows users to compose a dispatching system that combined synchronous and a-synchronous message handling.
BaseAggregateRootbehaviour is now extracted into traits so you can choice to implement certain concerns yourself without overriding methods.