Telemetry Aggregation
The aggregation of telemetry into new telemetry records (monthly averages, annual sums, etc.) is achieved through workflow triggers and actions. This section will guide you in setting up telemetry aggregation workflows. Assetas will continually update aggregated telemetry over the time period specified in the workflow set up, meaning that if updated records are imported, the aggregated telemetry will revise automatically to capture those updated records. Please note that aggregated telemetry will not update immediately; the frequency of the workflow will determine how quickly aggregated values are calculated and updated.
Please note that if a telemetry aggregation trigger does not have input values to aggregate, it will not populate zeroes for the aggregated value.
Step 1: Create or import non-aggregated telemetry
Initial telemetry values may be created by adding data manually, performing a one-time data import, or setting up a recurring data import process.
Step 2: Create aggregated telemetry types
Reusing existing telemetry types for capturing aggregated telemetry is not recommended, because there is a risk of values to be overwritten if the telemetry type, active date, unit, and asset are identical. Assetas recommends creating new telemetry types for aggregated records (for example, Monthly Runtime or Annual Incidents).
Step 3: Create workflow triggers
The workflow trigger performs the task of the data aggregation but does not set a new telemetry value yet (that’s the job of the workflow action). Once a new workflow is created for the purpose of aggregating telemetry, consider the types of assets and telemetry being impacted. Does aggregation only occur at a particular asset type? For how long will updated telemetry records be accepted? What types of telemetry are impacted? What kind of grouping will occur (weekly, monthly, annually, etc.)? What kinds of aggregation will be performed (sum or average)?
Some background for the example below: Field Office assets capture a single telemetry data point, with a Count of 1, every time an ‘OSHA recordable’ incident occurs and is attributed to the Field Office. The goal for this workflow is to aggregate individual incident counts into a Monthly incident count per Field Office. These monthly values will be continuously updated over the course of the year if new incidents are assigned to the Field Office (for example, if the current date is September 1st and a new incident in the month of February of the current year is captured, the February monthly total will update).
Set up your workflow trigger(s), including one Telemetry Aggregate trigger. Within this Telemetry Aggregate trigger, complete the following fields:
- Telemetry Type: the type of telemetry that will be aggregated. In the example, we’re aggregating OSHA Recordable Incidents.
- Unit of Measure: the unit of measure of the telemetry being aggregated. In the example, the OSHA Recordable Incidents have a unit of Count.
- Date Grouping: the grouping to apply for the aggregate. In the example, we’re grouping incidents over the month, so we’ve chosen Month as the Date Grouping.
- Rounding: the rounding to apply to the aggregated value. This comes into play when mathematical functions are being performed on the aggregated value. For individual Counts, these display in whole numbers, so we set the Rounding to 0 to continue displaying whole numbers for the aggregated values.
- Earliest Date: the earliest date over which aggregation should occur. You may either hardcode a date or use variables in the dropdown to set an earliest date. In this example, we are aggregating monthly values over the course of the current year (so if updates are made to previous months, aggregated values will update based on values starting on January 1). We’ve selected First Day of the Year, or {YearStart} as the appropriate Earliest Date. If we only wanted values to update over the course of the current month and not consider updates to any month prior, we’d select First Day of the Month, or {Month Start}.
- Latest Date: the latest date over which aggregation should occur. You may either hardcode a date or use variables in the dropdown to set a latest date. In this example, we are aggregating monthly values over the course of the current year (so aggregated values will update through December 31). We’ve selected Last Day of the Year, or {YearEnd} as the appropriate Latest Date. In this particular example, Last Day of the Month or {MonthEnd} would also work, if you wanted to exclude the preemptive aggregation of any future values through the end of the year.
Step 4: Create workflow actions
The workflow action of Set Telemetry performs the task of setting the aggregated telemetry, from the trigger, to the Assets that triggered the workflow.
The example below displays the workflow action to set the telemetry that was aggregated in the trigger. In this example, we’re setting new telemetry at each Field Office of the monthly sum total of ‘OSHA recordable’ incident counts, with an active date of the first day of the month and an inactive date of the last day of the month.
Set up your workflow action(s), including at least one Set Telemetry action. Within this Set Telemetry action, complete the following fields:
- Telemetry Type: the telemetry type to use for the aggregated telemetry, which should be different from the telemetry type used in the Telemetry Aggregate trigger.
- Unit of Measure: the unit of measure to use for the aggregated telemetry. This may be the same as the Unit of Measure used in the Telemetry Aggregate trigger, or it may be different depending on the type of data being aggregated.
- Telemetry Tag: the telemetry tag to set for the aggregated data. This field is optional.
- Active Date: the active date of the aggregated telemetry. This date may be hardcoded, but it is far more likely that you will use the Triggering Group Active Date, or {TriggeringGroupActiveDate} variable. This variable sets the active date of the aggregated telemetry to the first day of the Date Grouping specified in the Telemetry Aggregate trigger. In the example, since we use Monthly as the Date Grouping, the {TriggeringGroupActiveDate} variable would set the Active Date to the first day of the grouping month.
- Inactive Date: the inactive date of the aggregated telemetry. This date may be hardcoded, but it is far more likely that you will use the Triggering Group Inactive Date, or {TriggeringGroupInactiveDate} variable. This variable sets the inactive date of the aggregated telemetry to the last day of the Date Grouping specified in the Telemetry Aggregate trigger. In the example, since we use Monthly as the Date Grouping, the {TriggeringGroupInactiveDate} variable would set the Inactive Date to the last day of the grouping month.
- Numeric Value: the aggregated value to set for the new telemetry. Use the Triggering Telemetry Sum ({TriggeringSumNumericValue}) or Triggering Telemetry Average ({TriggeringAvgNumbericValue}) variables to choose a sum or an average of the telemetry within each grouping. In the example, we’ve selected the Triggering Telemetry Sum to sum the individual ‘OSHA recordable’ incident counts over the course of each month.
Step 5: Validate triggers and perform a test run
In the triggers section, select the ‘Validate’ button to validate that the triggers you’ve chosen are performing as expected. You’ll see any errors and the number of items that match your triggers in the lower left-hand informational message on the screen.
To perform a test run, set the Earliest Date and Latest Date in the Telemetry Aggregation trigger to a narrow enough date range to test your workflow adequately, without running it for the entire data set. Click the ‘View’ button in the Schedule section to see the Scheduled Job that is associated to the workflow. Click ‘Run’ to run your workflow immediately. Once the Scheduled Job has completed, check that new telemetry has been set at your impacted assets, that aggregation has completed as expected, and that the active and inactive date range is appropriate.
Step 6: Schedule workflow
Once testing is complete, you may schedule your workflow for automatic execution on a regular frequency. Click the ‘View’ button in the Schedule section to see the Scheduled Job that is associated to the workflow. Click ‘Edit’ to adjust your frequency settings.