Interface EvidenceMeasurement.Builder

  • Method Details

    • quantity

      EvidenceMeasurement.Builder quantity(String quantity)

      What was measured. Absent on a metric anomaly, where the anomaly itself already names the metric.

      Parameters:
      quantity - What was measured. Absent on a metric anomaly, where the anomaly itself already names the metric.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • statistic

      EvidenceMeasurement.Builder statistic(String statistic)

      How the quantity was aggregated, as a CloudWatch statistic name — "Sum", "Average", "Maximum", "Minimum", "SampleCount" or a percentile. Absent when nothing aggregated the figure in CloudWatch's sense, as on a derived error rate or request rate.

      Parameters:
      statistic - How the quantity was aggregated, as a CloudWatch statistic name — "Sum", "Average", "Maximum", "Minimum", "SampleCount" or a percentile. Absent when nothing aggregated the figure in CloudWatch's sense, as on a derived error rate or request rate.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • unit

      Unit of currentValue, expectedValue, expectedLower and expectedUpper. On a metric anomaly this is the unit CloudWatch published the metric as, so it is absent when the metric was published without one, and on a counted statistic, which has no unit.

      Parameters:
      unit - Unit of currentValue, expectedValue, expectedLower and expectedUpper. On a metric anomaly this is the unit CloudWatch published the metric as, so it is absent when the metric was published without one, and on a counted statistic, which has no unit.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • transform

      EvidenceMeasurement.Builder transform(String transform)

      Transform applied before comparison. Absent when the raw value was compared.

      Parameters:
      transform - Transform applied before comparison. Absent when the raw value was compared.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • currentValue

      EvidenceMeasurement.Builder currentValue(Double currentValue)

      The value observed in this window.

      Parameters:
      currentValue - The value observed in this window.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • expectedValue

      EvidenceMeasurement.Builder expectedValue(Double expectedValue)

      The point prediction. Absent when the detector produces a band instead.

      Parameters:
      expectedValue - The point prediction. Absent when the detector produces a band instead.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • expectedLower

      EvidenceMeasurement.Builder expectedLower(Double expectedLower)

      Lower bound of the expected range. Absent when the detector produces a point prediction instead, or bounds only the other side.

      Parameters:
      expectedLower - Lower bound of the expected range. Absent when the detector produces a point prediction instead, or bounds only the other side.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • expectedUpper

      EvidenceMeasurement.Builder expectedUpper(Double expectedUpper)

      Upper bound of the expected range. Absent when the detector produces a point prediction instead, or bounds only the other side.

      Parameters:
      expectedUpper - Upper bound of the expected range. Absent when the detector produces a point prediction instead, or bounds only the other side.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • threshold

      EvidenceMeasurement.Builder threshold(Double threshold)

      The value the comparison had to cross for this detector to fire, in the same unit as currentValue. Distinct from expectedLower and expectedUpper, which describe the learned normal range: a detector can fire on a boundary it chose rather than on the edge of that range. Absent whenever the band itself was the boundary, which is every anomaly but a trace one today.

      Parameters:
      threshold - The value the comparison had to cross for this detector to fire, in the same unit as currentValue. Distinct from expectedLower and expectedUpper, which describe the learned normal range: a detector can fire on a boundary it chose rather than on the edge of that range. Absent whenever the band itself was the boundary, which is every anomaly but a trace one today.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • sampleCount

      EvidenceMeasurement.Builder sampleCount(Integer sampleCount)

      How many units the figures were computed over — calls for an error rate, turns for a per-turn quantity, events for a log count, buckets for a volume drop. A rate alone cannot distinguish 5 failures in 20 calls from 5 in 20,000.

      Parameters:
      sampleCount - How many units the figures were computed over — calls for an error rate, turns for a per-turn quantity, events for a log count, buckets for a volume drop. A rate alone cannot distinguish 5 failures in 20 calls from 5 in 20,000.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • periodMinutes

      EvidenceMeasurement.Builder periodMinutes(Integer periodMinutes)

      Minutes the figures cover: the aggregation bucket width on most detectors, and the elapsed span of the episode so far on detectors that report running totals.

      Parameters:
      periodMinutes - Minutes the figures cover: the aggregation bucket width on most detectors, and the elapsed span of the episode so far on detectors that report running totals.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • baselineIsNew

      EvidenceMeasurement.Builder baselineIsNew(Boolean baselineIsNew)

      True when the expectation came from a newly learned, still-thin baseline, so the comparison is less reliable than usual.

      Parameters:
      baselineIsNew - True when the expectation came from a newly learned, still-thin baseline, so the comparison is less reliable than usual.
      Returns:
      Returns a reference to this object so that method calls can be chained together.