Skip to content

Measurement Engine

Purpose

The Measurement Engine stores measurements submitted by engines associated with timestamps. These measurements could be used by various protocols. For example, the Networking Machine could use latency measurements to make routing decisions.

State

Messages Received

RecordMeasurementRequest

Add a measurement performed by an engine to the measurement database.

Reception:

RecordMeasurementRequestV1

Records with fields:

The query that needs to be executed to record the measurement in the database.

Triggers

RecordMeasurementResponseV1

Records with fields:

The query that needs to be executed to record the measurement in the database.

The success of the operation, indicating that the KV-pair was deleted successfully or not.

SubscribeMeasurementRequest

Subscribe to a measurement key in the dynamic configuration KV-store to get notified when the corresponding value changes.

Reception:

SubscribeMeasurementRequestV1

Records with fields:

The measurement query the subscriber wants to subscribe to from the measurement database.

Triggers

SubscribeMeasurementResponseV1

Records with fields:

The measurement query the subscriber is now subscribed to.

The success of the operation, indicating that the subscription attempt succeeded or failed.

The wall clock time of the moment that the subscriber was subscribed to this query.

Notifications Sent

MeasurementChanged

A notification is sent when a new measurement is recorded in the measurement database.

Records with fields:

The measurement query the subscriber is subscribed to (from the measurement database).

The measurement value from the query the subscriber is subscribed to.

The wall clock time of the moment the value was recorded.

Message Flow

sequenceDiagram
Any Local Engine ->>+ Measurement Engine: RecordMeasurementRequest
Measurement Engine -->>- Any Local Engine: RecordMeasurementResponse
Any Local Engine ->>+ Measurement Engine: SubscribeMeasurementRequest
Measurement Engine -->>- Any Local Engine: SubscribeMeasurementResponse