Interface DistributionSummary

All Superinterfaces:
Meter, Wrapper

public interface DistributionSummary extends Meter
Records a distribution of values (e.g., sizes of responses returned by a server).
  • Method Details

    • builder

      Creates a builder for a new DistributionSummary using the specified statistics builder.
      Parameters:
      name - name for the summary
      configBuilder - distribution stats config for the summary
      Returns:
      new builder
    • builder

      static DistributionSummary.Builder builder(String name)
      Creates a builder for a new DistributionSummary using default distribution statistics.
      Parameters:
      name - name for the summary
      Returns:
      new builder
    • record

      void record(double amount)
      Updates the statistics kept by the summary with the specified amount.
      Parameters:
      amount - Amount for an event being measured. For example, if the size in bytes of responses from a server. If the amount is less than 0 the value will be dropped.
    • count

      long count()
      Returns the current count of observations in the distribution summary.
      Returns:
      number of observations recorded in the summary
    • totalAmount

      double totalAmount()
      Returns the total of the observations recorded by the distribution summary.
      Returns:
      total across all recorded events
    • mean

      double mean()
      Returns the mean of the observations recorded by the distribution summary.
      Returns:
      average value of events recorded in the summary
    • max

      double max()
      Returns the maximum value among the observations recorded by the distribution summary.
      Returns:
      maximum value of recorded events
    • snapshot

      HistogramSnapshot snapshot()
      Returns a HistogramSnapshot of the current state of the distribution summary.
      Returns:
      snapshot