grafana-aws-athena-datasource
grafana-aws-athena-datasource copied to clipboard
Always Empty Result with Query String
Hello, thanks for your work. I am trying to create a table with variables to fetch data from AWS Athena. I have tried the plugin and it only worked when i provided the execution id
of a previous query from Athena console. When I tried to send the query from Grafana in Query String
field the response is always empty.
- Workgroup is defined.
- I have set the S3 location as an s3 uri and the provided ARN has read/write permission to provided bucket.
Am I missing something? You can find the query inspector result below.
{
"request": {
"url": "api/ds/query",
"method": "POST",
"data": {
"queries": [
{
"region": "default",
"workgroup": "my_workgroup",
"queryExecutionId": "",
"timestampColumn": "",
"valueColumn": "",
"legendFormat": "{{ }}",
"timeFormat": "",
"maxRows": "100",
"cacheDuration": "60s",
"queryString": "SELECT * FROM my_database.my_table LIMIT 10",
"refId": "A",
"datasource": "AWS Athena",
"inputs": [],
"outputLocation": "s3://my-aws-athena-query-results/my-folder/",
"datasourceId": 13,
"intervalMs": 30000,
"maxDataPoints": 1488,
"orgId": 1
}
],
"range": {
"from": "2020-11-23T06:42:08.766Z",
"to": "2020-11-23T18:42:08.766Z",
"raw": {
"from": "now-12h",
"to": "now"
}
},
"from": "1606113728766",
"to": "1606156928766"
}
},
"response": {
"results": {
"A": {
"refId": "A",
"series": null,
"tables": null,
"dataframes": []
}
}
}
}
For me the athena query was failing because the user didn't have write permissions to the output bucket