Class LoggerConfig.Builder

java.lang.Object
com.couchbase.client.core.env.LoggerConfig.Builder
Enclosing class:
LoggerConfig

public static class LoggerConfig.Builder extends Object
  • Constructor Details

    • Builder

      public Builder()
  • Method Details

    • fallbackToConsole

      @Deprecated public LoggerConfig.Builder fallbackToConsole(boolean fallbackToConsole)
      Deprecated.
      SLF4J is used for all logging.
      This method has no effect.

      SLF4J is used for all logging. If you wish to log to the console, please configure your SLF4J binding accordingly.

      Parameters:
      fallbackToConsole - ignored
      Returns:
      this LoggerConfig.Builder for chaining purposes.
    • disableSlf4J

      @Deprecated public LoggerConfig.Builder disableSlf4J(boolean disableSlf4J)
      Deprecated.
      SFL4J is always used for logging.
      This method does nothing.
      Parameters:
      disableSlf4J - ignored
      Returns:
      this LoggerConfig.Builder for chaining purposes.
    • loggerName

      @Deprecated public LoggerConfig.Builder loggerName(String loggerName)
      Deprecated.
      the logging infrastructure picks the logger name automatically now based on the event type so it is easier to enable/disable logging or change the verbosity level for certain groups rather than having a single universal logger name.
      Allowed to set a custom logger name - does not have an effect and is deprecated.
      Parameters:
      loggerName - the custom logger name.
      Returns:
      this LoggerConfig.Builder for chaining purposes.
    • enableDiagnosticContext

      public LoggerConfig.Builder enableDiagnosticContext(boolean diagnosticContextEnabled)
      If enabled, and the user specifies a clientContext for a request, the client context is copied into the Mapped Diagnostic Context (MDC) when events related to that request are logged.

      Has no effect if the SLF4J binding does not support MDC.

      Disabled by default.

      Parameters:
      diagnosticContextEnabled - if the diagnostic context should be enabled.
      Returns:
      this LoggerConfig.Builder for chaining purposes.
    • consoleLogLevel

      @Deprecated public LoggerConfig.Builder consoleLogLevel(Level consoleLogLevel)
      Deprecated.
      This method has no effect. SLF4J is used for all logging.
      This method is deprecated, and has no effect.
      Parameters:
      consoleLogLevel - ignored
      Returns:
      this LoggerConfig.Builder for chaining purposes.
    • consoleLoggerFormatter

      @Deprecated public LoggerConfig.Builder consoleLoggerFormatter(LoggerFormatter loggerFormatter)
      Deprecated.
      Please configure logger output via SLF4J binding instead.
      This method has no effect.

      If you wish to customize the log output, please configure your SLF4J binding.

      Parameters:
      loggerFormatter - ignored
      Returns:
      this LoggerConfig.Builder for chaining purposes.
    • build

      public LoggerConfig build()
      Builds the LoggerConfig and makes it immutable.
      Returns:
      the built, immutable logger config.