This modifies the digital twin exporter to use the recently introduced ask:device-manager:${type}:get-last-measures ask to retrieve the measures of a digital twin, instead of relying on the measures embedded in their documents.
This is in preparation for the removal of the measures and lastMeasuredAt fields in the documents of the assets and devices collections.
Other changes
A new mechanism has been introduced in the abstract exporter, the export stream augmenters, that are used to modify the exporter search results right before they get written to the export stream.
Digital twin exporter tests were also updated to check the exact values of the export results, and to sort the export client-side (because sorting by measure in the request is no longer supported).
Breaking changes
This deprecates the use of the measures and lastMeasuredAt fields in the query and sort parameters of the export request.
In the IoT Platform, the following places were identified that will be affected by this deprecation:
Devices.vue: the device export request allows filtering by measure type, which will no longer be possible.
OrphanDeviceList.vue: the device export request allows filtering by measure type, which will no longer be possible.
What does this PR do ?
This modifies the digital twin exporter to use the recently introduced
ask:device-manager:${type}:get-last-measures
ask to retrieve the measures of a digital twin, instead of relying on the measures embedded in their documents.This is in preparation for the removal of the
measures
andlastMeasuredAt
fields in the documents of the assets and devices collections.Other changes
A new mechanism has been introduced in the abstract exporter, the export stream augmenters, that are used to modify the exporter search results right before they get written to the export stream.
Digital twin exporter tests were also updated to check the exact values of the export results, and to sort the export client-side (because sorting by measure in the request is no longer supported).
Breaking changes
This deprecates the use of the
measures
andlastMeasuredAt
fields in thequery
andsort
parameters of the export request.In the IoT Platform, the following places were identified that will be affected by this deprecation:
Part of KZLPRD-438.