---
library: "bootstrap"
slug: "Monitor"
name: "Monitor"
ref: "Monitor#d316"
hash: "sema:Monitor#mh:SHA-256:d31621c43589a14a237d53b3ff53c360b841cea6fe8fa8b7dc90724a686fcf8f"
type: "Primitives"
layer: "Infrastructure"
version: "0.11.0"
root: "a6a3d1ff0f982ee30430c5b42f3784c8ec901fd68482cfc1bc30899c1e5e48c5"
license: null
url: "https://semahash.org/vocabularies/bootstrap/patterns/Monitor"
---

# Monitor

Continuous observation of state over time

Infrastructure · Primitives

## Mechanism

A persistent process that uses a [Loop](https://semahash.org/vocabularies/bootstrap/patterns/Loop.md) to repeatedly execute [Observe](https://semahash.org/vocabularies/bootstrap/patterns/Observe.md) on a target [System](https://semahash.org/vocabularies/bootstrap/patterns/System.md) or [State](https://semahash.org/vocabularies/bootstrap/patterns/State.md) at defined intervals. It compares the observed state against a baseline or invariant, emitting a [Signal](https://semahash.org/vocabularies/bootstrap/patterns/Signal.md) if a deviation ([Anomaly](https://semahash.org/vocabularies/bootstrap/patterns/Anomaly.md)) is detected.

## Invariants

- Liveness: runs continuously or at `interval`.
- Perturbs what it observes: repeated [Observe](https://semahash.org/vocabularies/bootstrap/patterns/Observe.md) consumes resources at the target and leaves records there. The degree varies; the fact does not.

## Parameters

- interval: type=Duration, range=unspecified, description=Time between observation cycles

## Signature

- Loop(State)

## Failure modes

- Monitoring load becomes the [Anomaly](https://semahash.org/vocabularies/bootstrap/patterns/Anomaly.md): the observation cost is large enough to shift the baseline it is measuring against.
- Baseline drift: the target changes legitimately and the unchanged baseline reports it as deviation.

## Where this came from

—

## Builds on

- [Observe](https://semahash.org/vocabularies/bootstrap/patterns/Observe.md) (composes_with)
- [Loop](https://semahash.org/vocabularies/bootstrap/patterns/Loop.md) (composes_with)
- [State](https://semahash.org/vocabularies/bootstrap/patterns/State.md) (references)
- [System](https://semahash.org/vocabularies/bootstrap/patterns/System.md) (references)
- [Signal](https://semahash.org/vocabularies/bootstrap/patterns/Signal.md) (references)
- [Anomaly](https://semahash.org/vocabularies/bootstrap/patterns/Anomaly.md) (references)

## Used by

- [DetectorSelfTest](https://semahash.org/vocabularies/bootstrap/patterns/DetectorSelfTest.md) (references)
- [Heartbeat](https://semahash.org/vocabularies/bootstrap/patterns/Heartbeat.md) (references)
- [RolloutWatch](https://semahash.org/vocabularies/bootstrap/patterns/RolloutWatch.md) (references)

## Related

- [DetectorSelfTest](https://semahash.org/vocabularies/bootstrap/patterns/DetectorSelfTest.md)

## Identity

- Library: bootstrap 0.11.0 (root a6a3d1ff0f98)
- Ref: Monitor#d316
- Hash: sema:Monitor#mh:SHA-256:d31621c43589a14a237d53b3ff53c360b841cea6fe8fa8b7dc90724a686fcf8f

## Links

- Page: https://semahash.org/vocabularies/bootstrap/patterns/Monitor
- JSON: https://semahash.org/vocabularies/bootstrap/patterns/Monitor.json
- Library: https://semahash.org/vocabularies/bootstrap
- Library index: https://semahash.org/vocabularies/bootstrap/index.json
