Learning to Use Monitor Builder: Data Transformation

During the transform step, streaming data from the previous step (eg poll, push) is operated on in succession to identify some event and trigger actions. In this snippet, a falling-edge of 0.5 on a number data type.

  .transform<number, number>({
    keys: ['cratio'],
    pipelines: [
      Pipelines.threshold({
        type: 'falling-edge',
        threshold: 0.5,
      }),
    ],
  })

Many other data-stream processing features exist, including:

  • Windowing: fixed size, fixed time, fixed size sliding

  • Aggregation: average, min, max

  • Thresholding: rising edge, falling edge

More Examples:

An array diff pipeline can be used to track when items are added or removed from an array.

Last updated