public SpamGuardingLoggerDecorator( [NotNull] string componentName, [NotNull] ILogger logger, [NotNull] ISpamGuard <Microsoft.Extensions.Logging.LogLevel> spamGuard) { _componentName = componentName ?? throw new ArgumentNullException(nameof(componentName)); _logger = logger ?? throw new ArgumentNullException(nameof(logger)); _spamGuard = spamGuard ?? throw new ArgumentNullException(nameof(spamGuard)); }
internal SlackLoggerProvider( [NotNull] string azureQueueConnectionString, [NotNull] string azureQueuesBaseName, [NotNull] ISpamGuard <Microsoft.Extensions.Logging.LogLevel> spamGuard, [NotNull] Func <Microsoft.Extensions.Logging.LogLevel, string> channelResolver, bool filterOutChaosException) { _spamGuard = spamGuard ?? throw new ArgumentNullException(nameof(spamGuard)); _channelResolver = channelResolver ?? throw new ArgumentNullException(nameof(channelResolver)); _loggers = new ConcurrentDictionary <string, ILogger>(); _sender = new SlackLogEntriesSender(azureQueueConnectionString, azureQueuesBaseName); _filterOutChaosException = filterOutChaosException; }