IoT TwinMaker and Grafana integration where component has multiple list properties
Hello! I'm currently trying to create a dashboard where one component of an entity has multiple property definitions of the list type.
My property definitions and lambda function seem to be operating as intended. Using the "Test" functionality in the AWS IoT TwinMaker console shows me the following:
{
"assetId": {
"propertyReference": {
"componentName": "master_task_list",
"entityId": "AllTasks",
"propertyName": "assetId"
},
"propertyValue": {
"stringValue": "master_task_list"
}
},
"assetType": {
"propertyReference": {
"componentName": "master_task_list",
"entityId": "AllTasks",
"propertyName": "assetType"
},
"propertyValue": {
"stringValue": "task_list"
}
},
"robotIdList": {
"propertyReference": {
"componentName": "master_task_list",
"externalIdProperty": {},
"entityId": "AllTasks",
"propertyName": "robotIdList"
},
"propertyValue": {
"listValue": [
{
"stringValue": "3e2b4d1d-a86f-4f7b-a436-46e7653f7fef"
}
]
}
},
"siteArn": {
"propertyReference": {
"componentName": "master_task_list",
"entityId": "AllTasks",
"propertyName": "siteArn"
},
"propertyValue": {
"stringValue": "arn:aws:iotroborunner:us-east-1:<accountId>:site/<siteId>"
}
},
"stateList": {
"propertyReference": {
"componentName": "master_task_list",
"externalIdProperty": {},
"entityId": "AllTasks",
"propertyName": "stateList"
},
"propertyValue": {
"listValue": [
{
"stringValue": "ACTIVE"
}
]
}
},
"taskIdList": {
"propertyReference": {
"componentName": "master_task_list",
"externalIdProperty": {},
"entityId": "AllTasks",
"propertyName": "taskIdList"
},
"propertyValue": {
"listValue": [
{
"stringValue": "0ed00afe-c55f-4311-9468-4dca01b1625d"
}
]
}
},
"waypointsList": {
"propertyReference": {
"componentName": "master_task_list",
"externalIdProperty": {},
"entityId": "AllTasks",
"propertyName": "waypointsList"
},
"propertyValue": {
"listValue": [
{
"stringValue": "[(0, 0, 5), (40.529312, -74.626496, 5), (40.52904, -74.6267648, 5), (40.529152, -74.6268927, 5), (40.5291568, -74.6268862, 0)]"
}
]
}
}
}
Which tells me all the values are being reported correctly as their respective types. However, when issuing a request from Grafana using the IoT TwinMaker data source, the query inspector asks for multiple properties, but only one comes back The query:
{
"queries": [
{
"componentName": "master_task_list",
"entityId": "AllTasks",
"properties": [
"waypointsList",
"taskIdList",
"robotIdList",
"stateList"
],
"queryType": "GetPropertyValue",
"refId": "A",
"componentTypeId": "com.defuzzy.task_list",
"datasource": "AWS IoT TwinMaker",
"datasourceId": 3,
"intervalMs": 10000,
"maxDataPoints": 2738
}
],
"range": {
"from": "2022-04-26T22:54:24.962Z",
"to": "2022-04-27T04:54:24.962Z",
"raw": {
"from": "now-6h",
"to": "now"
}
},
"from": "1651013664962",
"to": "1651035264962"
}
The response
{
"results": {
"A": {
"frames": [
{
"schema": {
"name": "waypointsList",
"refId": "A",
"meta": {
"custom": {}
},
"fields": [
{
"name": "Value",
"type": "string",
"typeInfo": {
"frame": "string",
"nullable": true
}
}
]
},
"data": {
"values": [
[
"[(0, 0, 5), (40.529312, -74.626496, 5), (40.52904, -74.6267648, 5), (40.529152, -74.6268927, 5), (40.5291568, -74.6268862, 0)]"
]
]
}
}
]
}
}
}
Even if I only ask for one (different) property, I still only get one property back (waypointsList
in this case).
Am I doing something wrong? This feels a little broken. Any help would be appreciated!
Thank you for reaching out!
I've confirmed this bug and submitted an issue in our plugin's github repo: https://github.com/grafana/grafana-iot-twinmaker-app/issues/42
Will follow up with Grafana to make the fix.
Relevant questions
Relational mutations in Graphql Amplify
asked a month agoDifferentiating Messages from aws.greengrass.telemetry.NucleusEmitter in a multi-core deployment
asked 3 days agoBest way to restart a Greengrass component, from another component
asked 4 months agoLaunch Announcement: AWS IoT TwinMaker is now generally available
asked a month agoManaged Grafana - Add Images to Dashboard
asked 3 months agoGreengrass v2 add component
Accepted Answerasked 7 months agoTwinMaker: using lambda to fetch data for non-timeSeries properties
Accepted Answerasked a month agoSiteWise ingestion rules coming from IoT Core
asked 2 months agoIoT TwinMaker and Grafana integration where component has multiple list properties
asked 25 days agoHow do I run an IoT Job on a GG v2 core?
asked a year ago
Awesome, thank you!