Class WarnThenDebugLogger

java.lang.Object
io.micrometer.common.util.internal.logging.WarnThenDebugLogger

public class WarnThenDebugLogger extends Object
InternalLogger which logs at warn level at first and then logs at debug level for the rest.
Since:
1.1.8
  • Constructor Details

    • WarnThenDebugLogger

      public WarnThenDebugLogger(Class<?> clazz)
    • WarnThenDebugLogger

      public WarnThenDebugLogger(String name)
      Creates a new WarnThenDebugLogger instance with the specified name.
      Parameters:
      name - logger name
      Since:
      1.13.0
  • Method Details

    • isEnabled

      public boolean isEnabled()
      This may be useful to have different behavior before/after logging once.
      Returns:
      whether this logger is enabled or not
      Since:
      1.16.0
    • log

      public void log(String message, @Nullable Throwable ex)
    • log

      public void log(String message)
    • log

      public void log(Supplier<String> messageSupplier, @Nullable Throwable ex)
    • log

      public void log(Supplier<String> messageSupplier)