Beispiel #1
0
        public LogstashTcpLoggerProvider(LogstashOptions options)
        {
            var appName = AppDomain.CurrentDomain.FriendlyName;

            _disposed    = false;
            _netStash    = new NetStashLog(options.Host, options.Port, appName, options.AppName ?? appName);
            _extraValues = options.ExtraValues ?? new Dictionary <string, string>();
        }
 public static ILoggerFactory AddLogtash(this ILoggerFactory loggerFactory, LogstashOptions options)
 {
     loggerFactory.AddProvider(new LogstashTcpLoggerProvider(options));
     return(loggerFactory);
 }