Files
xEventService/Providers/XBaseEventProducerService.cs
T
2026-09-06 00:17:56 +03:30

31 lines
875 B
C#

using xCommons.Extensions;
using xExceptions.Constants;
using xEventService.Extensions;
using xEventService.Configuration;
using Microsoft.Extensions.Logging;
namespace xEventService.Providers
{
public abstract class XBaseEventProducerService
{
protected readonly XEventServiceConfiguration configuration;
protected readonly ILogger<XBaseEventProducerService> logger;
protected XBaseEventProducerService(
XEventServiceConfiguration configuration,
ILogger<XBaseEventProducerService> logger
)
{
//
this.logger = logger;
this.configuration = configuration;
//
// Validate Configurations ...
if (!configuration.IsValid())
{
XException.InvalidConfiguration.Throw();
}
}
}
}