mullerpeter / databricks-grafana

Grafana Databricks integration allowing direct connection to Databricks to query and visualize Databricks data in Grafana.
Apache License 2.0
55 stars 4 forks source link

Configure plugin for Azure Databricks #16

Closed asantos2000 closed 1 year ago

asantos2000 commented 1 year ago

Could you provide an example of the plugin's configuration with Azure Databricks?

According to the documentation, the endpoint path is deprecated, but still working.

I can't configure the plugin, it returns a 404

Screen Shot 2023-03-10 at 14 39 54

I have success calling the API

curl -X GET --header "Authorization: Bearer $DATABRICKS_TOKEN" \ https://adb-1234567890123456.12.azuredatabricks.net/api/2.0/sql/warehouses/778d6587b7d84780

mullerpeter commented 1 year ago

Server Hostname & HTTP Path should be the same as in the connection details of the SQL Warehouse. This works for me on Azure Databricks.

The SQL Warehouses APIs 2.0 is used to configure SQL warehouses and not to issue queries to my knowledge.

CleanShot 2023-03-10 at 18 51 23@2x

mullerpeter commented 1 year ago

The 404 error appears because of the leading slash in the http path. The plugin expects the the HTTP path without leading slash. (i.e. sql/1.0/warehouse/...)

I added some regex to remove the leading slash on the configuration field in #18