Class LoggingSamplers

java.lang.Object
io.confluent.kafka.schemaregistry.validator.core.LoggingSamplers

public final class LoggingSamplers extends Object
Factories for the log samplers used to rate-limit per-record validation logging.
  • Method Summary

    Modifier and Type
    Method
    Description
    static org.apache.kafka.common.utils.TimeBasedSampler
    all()
    A sampler that logs every event.
    static org.apache.kafka.common.utils.TimeBasedSampler
    perMinute(long samplesPerMin)
    A negative samplesPerMin suppresses logging entirely, zero logs everything, and a positive value caps logging at roughly that many samples per minute.

    Methods inherited from class Object

    equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Method Details

    • all

      public static org.apache.kafka.common.utils.TimeBasedSampler all()
      A sampler that logs every event. Stateless, so a single shared instance is safe.
    • perMinute

      public static org.apache.kafka.common.utils.TimeBasedSampler perMinute(long samplesPerMin)
      A negative samplesPerMin suppresses logging entirely, zero logs everything, and a positive value caps logging at roughly that many samples per minute.