MetricDomainEventHandler

Metric decorator for domain event handlers that collects metrics on domain event processing operations. This class wraps a DomainEventHandler and adds metrics collection with tags for aggregate name, event name, and processor name to track event handling performance and success rates.

Constructors

Link copied to clipboard
constructor(delegate: DomainEventHandler)

Properties

Link copied to clipboard
open override val delegate: DomainEventHandler

the underlying domain event handler implementation

Functions

Link copied to clipboard
open override fun handle(exchange: DomainEventExchange<*>): Mono<Void>

Handles a domain event exchange and collects metrics on the operation. Metrics collected include timing, success/failure rates, and tags for aggregate, event, and processor identification.

Link copied to clipboard

Wraps a DomainEventHandler with metrics collection capabilities. Returns a MetricDomainEventHandler that collects metrics on domain event handling operations.