LastProcessedTimestamp

mdxWebApiCore.Metrics. LastProcessedTimestamp

Class which defines LastProcessedTimestamp

Constructor

new LastProcessedTimestamp()

Source:

Methods

(async) getLastProcessedTimestamp(documentDb, input) → {Promise.<Object>}

Description:
  • returns an object containing last processed timestamp.
Source:
Example
const mdx = require("@nvidia-mdx/web-api-core");
const elastic = new mdx.Utils.Elasticsearch({node: "elasticsearch-url"},databaseConfigMap);
let input = {sensorId: "abc"};
let lastProcessedTimestampObject = new mdx.Metrics.LastProcessedTimestamp();
let result = await lastProcessedTimestampObject.getLastProcessedTimestamp(elastic,input);
Parameters:
Name Type Description
documentDb Database Database Object
input Object Input object.
Properties
Name Type Attributes Description
sensorId string <optional>
Either sensorId or place should be present.
place string <optional>
Either sensorId or place should be present.
Returns:
Last Processed Timestamp is returned
Type
Promise.<Object>