Grafana Datasource Plugin¶
The Micromegas Grafana datasource plugin lets you query telemetry data directly in Grafana dashboards using SQL over the Apache Arrow FlightSQL protocol.
Overview¶
The plugin provides:
- SQL Query Builder: Visual interface for building queries with dropdowns for tables and columns
- Raw SQL Mode: Full SQL support for complex queries
- Multiple Authentication Methods: Choose between API keys or OAuth 2.0 client credentials
- Time-Series Visualization: Native support for Grafana time-series panels
- Table Support: Display query results in Grafana tables
Quick Start¶
Prerequisites¶
- Grafana 9.2.5 or later
- Micromegas analytics server (flight-sql-srv) running
- Authentication credentials (API key or OAuth 2.0 client credentials)
Installation¶
- Download the latest plugin release
- Extract to your Grafana plugins directory
- Restart Grafana
- Add Micromegas as a data source
For detailed installation instructions, see the Installation Guide.
Adding a Data Source¶
- Navigate to Configuration → Data Sources in Grafana
- Click Add data source
- Search for and select Micromegas
- Configure connection settings:
- Host: Your flight-sql-srv address (e.g.,
localhost:50051) - Authentication Method: Choose API Key or OAuth 2.0
- TLS/SSL: Enable if your server uses TLS
- Click Save & Test
For detailed configuration, see the Configuration Guide.
Key Features¶
Query Builder¶
The visual query builder helps you construct SQL queries:
- Select tables from dropdown
- Choose columns with autocomplete
- Add WHERE clauses with + button
- Switch to raw SQL for advanced queries
Authentication Options¶
Choose the authentication method that fits your environment:
- API Keys: Simple, direct authentication (recommended for quick setup)
- OAuth 2.0 Client Credentials: Enterprise-grade authentication with identity provider integration
See the Authentication Guide for setup instructions.
FlightSQL Protocol¶
The plugin uses Apache Arrow FlightSQL protocol for efficient data transfer:
- High-performance binary protocol
- Efficient columnar data format
- Streaming support for large result sets
- Compatible with any FlightSQL server
Documentation¶
- Installation - Install and set up the plugin
- Configuration - Configure connection settings
- Authentication - Set up API keys or OAuth 2.0
- Usage - Query builder and SQL examples
Development¶
For development instructions, see the grafana/DEVELOPMENT.md file in the repository.
Support¶
For issues or questions:
- GitHub Issues: madesroches/micromegas/issues
- Add label:
grafana-plugin
Related Documentation¶
- Query Guide - SQL query examples and patterns
- Schema Reference - Database schema documentation
- Authentication - Server-side authentication setup