Class BurstFilter.Builder

All Implemented Interfaces:
Builder<BurstFilter>
Enclosing class:
BurstFilter

public static class BurstFilter.Builder extends AbstractFilter.AbstractFilterBuilder<BurstFilter.Builder> implements Builder<BurstFilter>
  • Constructor Details

    • Builder

      public Builder()
  • Method Details

    • setLevel

      public BurstFilter.Builder setLevel(Level level)
      Sets the logging level to use.
      Parameters:
      level - the logging level to use.
      Returns:
      this
    • setRate

      public BurstFilter.Builder setRate(float rate)
      Sets the average number of events per second to allow.
      Parameters:
      rate - the average number of events per second to allow. This must be a positive number.
      Returns:
      this
    • setMaxBurst

      public BurstFilter.Builder setMaxBurst(long maxBurst)
      Sets the maximum number of events that can occur before events are filtered for exceeding the average rate.
      Parameters:
      maxBurst - Sets the maximum number of events that can occur before events are filtered for exceeding the average rate. The default is 10 times the rate.
      Returns:
      this
    • build

      public BurstFilter build()
      Description copied from interface: Builder
      Builds the object after all configuration has been set. This will use default values for any unspecified attributes for the object.
      Specified by:
      build in interface Builder<BurstFilter>
      Returns:
      the configured instance.