/// <summary>
 /// Use colored console stdout for logging (probably only useful for debugging and test scenarios)
 /// </summary>
 public static void ColoredConsole(this LoggingConfigurer configurer, LogLevel minLevel)
 {
     configurer.Use(new ConsoleLoggerFactory(colored: true)
     {
         MinLevel = minLevel
     });
 }
 /// <summary>
 /// Use colored console stdout for logging (probably only useful for debugging and test scenarios)
 /// and allow the colors to be customized
 /// </summary>
 public static void ColoredConsole(this LoggingConfigurer configurer, LoggingColors colors)
 {
     configurer.Use(new ConsoleLoggerFactory(colored: true)
     {
         Colors = colors
     });
 }
 /// <summary>
 /// Use colored console stdout for logging (probably only useful for debugging and test scenarios)
 /// and allow the colors to be customized
 /// </summary>
 public static void ColoredConsole(this LoggingConfigurer configurer, LoggingColors colors)
 {
     RebusLoggerFactory.Current = new ConsoleLoggerFactory(colored: true)
     {
         Colors = colors
     };
 }
Example #4
0
 /// <summary>
 /// Configures Rebus to use Log4net for all of its internal logging
 /// </summary>
 public static void Log4Net(this LoggingConfigurer configurer)
 {
     configurer.Use(new Log4NetLoggerFactory());
 }
 /// <summary>
 /// Disables logging completely. Why would you do that?
 /// </summary>
 public static void None(this LoggingConfigurer configurer)
 {
     configurer.Use(new NullLoggerFactory());
 }
 /// <summary>
 /// Use the .NET's <see cref="System.Diagnostics.Trace"/> for logging.
 /// </summary>
 public static void Trace(this LoggingConfigurer configurer)
 {
     configurer.Use(new TraceLoggerFactory());
 }
        /// <summary>
        /// Configures Rebus to use Serilog for all of its internal logging. Will automatically add a 'CorrelationId' variable as a Serilog
        /// context property when handling messages, allowing log output to include that.
        /// </summary>
        public static void Serilog(this LoggingConfigurer configurer)
        {
            configurer.Use(new SerilogLoggerFactory());

            SetUpEventHandler(configurer, DefaultCorrelationIdPropertyKey);
        }
Example #8
0
        /// <summary>
        /// Configures Rebus to use Serilog for all of its internal logging, using the given <see cref="configuration"/> to create
        /// all of its loggers. Will add as logger properties the headers specified as keys in the given <see cref="headerKeyToLoggerPropertyMappings"/>
        /// dictionary, using as logger property name the value for each given key.
        /// </summary>
        public static void Serilog(this LoggingConfigurer configurer, LoggerConfiguration configuration, IDictionary <string, string> headerKeyToLoggerPropertyMappings)
        {
            configurer.Use(new SerilogLoggerFactory(configuration));

            SetUpEventHandler(configurer, headerKeyToLoggerPropertyMappings);
        }
        /// <summary>
        /// Configures Rebus to use Log4net for all of its internal logging
        /// </summary>
        public static void Log4Net(this LoggingConfigurer configurer)
        {
            configurer.Use(new Log4NetLoggerFactory());

            SetUpEventHandler(configurer);
        }
Example #10
0
 public static void Log4Net(this LoggingConfigurer configurer)
 {
     RebusLoggerFactory.Current = new Log4NetLoggerFactory();
 }
Example #11
0
        /// <summary>
        /// Configures Rebus to use Serilog for all of its internal logging, using the given <see cref="configuration"/> to create
        /// all of its loggers. Automatically adds the <see cref="CorrelationIdLoggerProperty"/>
        /// logger property to the logging context when handling a message that has a <see cref="Headers.CorrelationId"/> header.
        /// </summary>
        public static void Serilog(this LoggingConfigurer configurer, LoggerConfiguration configuration)
        {
            configurer.Use(new SerilogLoggerFactory(configuration));

            SetUpEventHandler(configurer, DefaultHeaderKeyToLoggerPropertyMappings);
        }
Example #12
0
 protected override LoggingFeature Logging(LoggingConfigurer configure)
 {
     return(configure
            .Level("Frequency.Framework", LogLevel.Info)
            .Log4Net(LogLevel.Debug));
 }
 /// <summary>
 /// Use console stdout for logging (probably only useful for debugging and test scenarios)
 /// </summary>
 public static void Console(this LoggingConfigurer configurer)
 {
     RebusLoggerFactory.Current = new ConsoleLoggerFactory(colored: false);
 }
 /// <summary>
 /// Use the .NET's <see cref="System.Diagnostics.Trace"/> for logging.
 /// </summary>
 public static void Trace(this LoggingConfigurer configurer)
 {
     RebusLoggerFactory.Current = new TraceLoggerFactory();
 }
Example #15
0
 public static void NLog(this LoggingConfigurer configurer)
 {
     configurer.Use(new NLogLoggerFactory());
 }
        /// <summary>
        /// Configures Rebus to use Log4net for all of its internal logging
        /// </summary>
        public static void Log4Net(this LoggingConfigurer configurer, string correlationIdPropertyKey)
        {
            configurer.Use(new Log4NetLoggerFactory());

            SetUpEventHandler(configurer, correlationIdPropertyKey);
        }
Example #17
0
 public static void NLog(this LoggingConfigurer configurer)
 {
     RebusLoggerFactory.Current = new NLogLoggerFactory();
 }
 /// <summary>
 /// Use console stdout for logging (probably only useful for debugging and test scenarios)
 /// </summary>
 public static void Console(this LoggingConfigurer configurer)
 {
     configurer.Use(new ConsoleLoggerFactory(colored: false));
 }
Example #19
0
        /// <summary>
        /// Configures Rebus to use Serilog for all of its internal logging. Will automatically add a correlation ID variable as a Serilog
        /// context property under the key specified by <paramref name="overriddenCorrelationIdPropertyKey"/> when handling messages,
        /// allowing log output to include that.
        /// </summary>
        public static void Serilog(this LoggingConfigurer configurer, string overriddenCorrelationIdPropertyKey)
        {
            configurer.Use(new SerilogLoggerFactory());

            SetUpEventHandler(configurer, overriddenCorrelationIdPropertyKey);
        }
Example #20
0
 protected override LoggingFeature Logging(LoggingConfigurer configure)
 {
     return(configure.Log4Net(LogLevel.Debug));
 }