I am trying to filter data from our geomap so that when I select a time frame up the top it should remove or show any data that matches that time period that is in our JSON file.
I tried the following with no success. Note for testing we are using a static file, but in practice we will have a dynamic JSON file which will update every minute. So I don’t know if we just reping the JSON url saying give only data that matches from start to now or what, but I don’t know how to do that in Grafana using infinity.
{
"type": "geomap",
"title": "Panel Title",
"gridPos": {
"x": 0,
"y": 0,
"w": 12,
"h": 8
},
"datasource": {
"uid": "edpi9c2zuqghse",
"type": "yesoreyeram-infinity-datasource"
},
"id": 26,
"targets": [
{
"datasource": {
"type": "yesoreyeram-infinity-datasource",
"uid": "edpi9c2zuqghse"
},
"refId": "A",
"type": "json",
"source": "url",
"format": "table",
"url": "https://storage.googleapis.com/cdn.podtoo.com/transcription/data.json",
"url_options": {
"method": "GET"
},
"root_selector": "",
"columns": [
{ "text": "latitude", "selector": "latitude" },
{ "text": "longitude", "selector": "longitude" },
{ "text": "name", "selector": "name" },
{ "text": "created", "selector": "created" }
],
"filters": [
{
"type": "date",
"column": "created",
"expression": ">=",
"value": "$__from"
},
{
"type": "date",
"column": "created",
"expression": "<=",
"value": "$__to"
}
]
}
],
"fieldConfig": {
"defaults": {
"custom": {
"hideFrom": {
"tooltip": false,
"viz": false,
"legend": false
}
},
"mappings": [],
"thresholds": {
"mode": "absolute",
"steps": [
{
"value": null,
"color": "green"
},
{
"value": 80,
"color": "red"
}
]
},
"color": {
"mode": "thresholds"
}
},
"overrides": []
},
"options": {
"view": {
"allLayers": true,
"id": "zero",
"lat": 0,
"lon": 0,
"zoom": 1
},
"controls": {
"showZoom": true,
"mouseWheelZoom": true,
"showAttribution": true,
"showScale": false,
"showMeasure": false,
"showDebug": false
},
"tooltip": {
"mode": "details"
},
"layers": [
{
"type": "markers",
"name": "Layer 1",
"config": {
"style": {
"size": {
"fixed": 5,
"min": 2,
"max": 15
},
"color": {
"fixed": "dark-green"
},
"opacity": 0.4,
"symbol": {
"mode": "fixed",
"fixed": "img/icons/marker/circle.svg"
},
"symbolAlign": {
"horizontal": "center",
"vertical": "center"
},
"textConfig": {
"fontSize": 12,
"textAlign": "center",
"textBaseline": "middle",
"offsetX": 0,
"offsetY": 0
},
"rotation": {
"fixed": 0,
"mode": "mod",
"min": -360,
"max": 360
}
},
"showLegend": true
},
"location": {
"mode": "coords",
"latField": "latitude",
"lonField": "longitude"
},
"tooltip": true,
"time": {
"timeField": "created"
}
}
]
},
"pluginVersion": "11.0.0"
}