Telemetry data schema
kidproquo opened this issue · 4 comments
kidproquo commented
Type of issue
- Bug
- New feature
- [ x] Improvement
Description
How can we specify a telemetry schema for an actual device? The simulation service has a spec for this but nothing for a real device.
ppathan commented
Hi @kidproquo
The schema for telemetry message is just json data format. It has _unit property but not required to show on the telemetry chart in the UI.
This is the sample message and the data
section is used to show points on telemetry chart.
{
"id": "truck-02.0;1530639961103",
"doc.schemaversion": 1,
"doc.schema": "d2cmessage",
"device.id": "truck-02.0",
"device.msg.schema": "device-sensors;v1",
"data.schema": "StreamingJobs",
"device.msg.created": 1530639961103,
"device.msg.received": 1530639961103,
"data": {
"latitude": 47.2557756983126,
"longitude": -121.174945042825,
"speed": 29.5333629637181,
"speed_unit": "mph",
"temperature": 49.2050887991744,
"temperature_unit": "F"
},
"_rid": "YiRNAIyK4wABAAAAAAAAAA==",
"_self": "dbs/YiRNAA==/colls/YiRNAIyK4wA=/docs/YiRNAIyK4wABAAAAAAAAAA==/",
"_etag": "\"0100e807-0000-0000-0000-5b3bb7450000\"",
"_attachments": "attachments/",
"_ts": 1530640197
}
Are you not able to see the telemetry data from your physical device show up on chart in the UI?
kidproquo commented
Thanks @ppathan. What about the ASA service? Does it need to know this schema for analytics?
ppathan commented
The ASA service is pass through to CosmosDB for telemetry messages and uses the same schema.