Skip to content

Version 0.12.0

Pre-release
Pre-release
Compare
Choose a tag to compare
@github-actions github-actions released this 09 Apr 02:00
· 57 commits to main since this release
v0.12.0
fa0bbed

This release aligns the Dogma API with several best practices that have emerged since the last release.

Although this release includes a large number of changes there should be no breaking changes to applications that are already following these best practices.

  • Use RFC 4122 UUIDs for identity keys
  • Implement MessageDescription() on message types
  • Implement Validate() methods on message types

Otherwise, most significant change is the introduction of Routes() methods to handler configurer interfaces. Implementors should use Routes() in preference to the existing Consumes*Type() and Produces*Type() methods, which are now deprecated.

The Routes() API accepts arguments that use type parameters to communicate message types. It also offers more extensible interface that allows future support for per-message routing configuration without further breaking changes.

Added

  • [APP BC] Added MessageDescription() method to Message interface
  • [APP BC] Added Validate() method to Message interface
  • Added Command, Event and Timeout as aliases for Message in preparation for stricter static message typing

Routing API

  • [ENGINE BC] Added Routes() methods to handler configurer interfaces
  • Added HandlesCommand()
  • Added RecordsEvent()
  • Added HandlesEvent()
  • Added ExecutesCommand()
  • Added SchedulesTimeout()
  • Added Route interface
  • Added AggregateRoute interface
  • Added ProcessRoute interface
  • Added IntegrationRoute interface
  • Added ProjectionRoute interface

Projection delivery policies

  • Added ProjectionConfigurer.DeliveryPolicy()
  • Added ProjectionScope.IsPrimaryDelivery()
  • Added ProjectionDeliveryPolicy
  • Added UnicastProjectionDeliveryPolicy
  • Added BroadcastProjectionDeliveryPolicy

Changed

  • [APP BC] Handler and application identity keys must now be an RFC 4122 UUID string

Deprecated

The new Routes() API supersedes the following methods:

  • Deprecated ConsumesCommandType() methods, use Routes() with HandlesCommand[T]() instead
  • Deprecated ProducesCommandType() methods, use Routes() with ExecutesCommand[T]() instead
  • Deprecated ConsumesEventType() methods, use Routes() with HandlesEvent[T]() instead
  • Deprecated ProducesEventType() methods, use Routes() with RecordsEvent[T]() instead
  • Deprecated SchedulesTimeoutType() methods, use Routes() with SchedulesTimeout[T]() instead

Because Message now has MessageDescription() and Validate() methods, the following elements are no longer necessary:

  • Deprecated DescribableMessage
  • Deprecated DescribeMessage()
  • Deprecated ValidatableMessage
  • Deprecated ValidateMessage()

No engines except testkit are able to provide a meaningful implementation of EventRecorder without fundamental changes to the definition of an application.

  • Deprecated EventRecorder, use an IntegrationMessageHandler instead