28 lines
816 B
C#
28 lines
816 B
C#
using System;
|
|
using System.Collections.Generic;
|
|
using System.Linq;
|
|
using System.Text;
|
|
using System.Threading;
|
|
using System.Threading.Tasks;
|
|
using Domain.Events;
|
|
using MediatR;
|
|
using Microsoft.Extensions.Logging;
|
|
|
|
namespace QRCodeService.Application.DomainEventHandler.LinkCreated
|
|
{
|
|
public class LogWhenLinkCreatedDomainEventHandler : INotificationHandler<LinkCreatedDomainEvent>
|
|
{
|
|
readonly ILogger<LogWhenLinkCreatedDomainEventHandler> logger;
|
|
|
|
public LogWhenLinkCreatedDomainEventHandler(ILogger<LogWhenLinkCreatedDomainEventHandler> logger)
|
|
{
|
|
this.logger = logger;
|
|
}
|
|
|
|
public async Task Handle(LinkCreatedDomainEvent notification, CancellationToken cancellationToken)
|
|
{
|
|
logger.LogInformation("domainEvent: link");
|
|
}
|
|
}
|
|
}
|