You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+13-7Lines changed: 13 additions & 7 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,4 +1,5 @@
1
1
# Timeplus Grafana Datasource
2
+
2
3
Grafana data source plugin to connect to Timeplus and visualize streaming or batch queries.
3
4
4
5
## Overview / Introduction
@@ -14,6 +15,7 @@ A running Timeplus Proton or Timeplus Enterprise instance with TCP port 8463 (fo
14
15
## Getting Started
15
16
16
17
### Use the pre-built Docker Compose
18
+
17
19
The [docker-compose.yaml](docker-compose.yaml) in this folder ships a Grafana container, with the proton plugin pre-installed, as well as a data generator.
18
20
19
21
You start it with `docker compose up` and go to http://localhost:3000 to view the Carsharing dashboard.
@@ -22,7 +24,7 @@ A data source for Timeplus is created automatically.
22
24
23
25
### Use your own Grafana deployment
24
26
25
-
Download the latest version from https://d.timeplus.com/grafana/timeplus-proton-datasource-2.1.3.zip
27
+
Download the latest version from https://d.timeplus.com/grafana/timeplus-proton-datasource-2.1.4.zip
26
28
27
29
Unzip the file and copy the folder to the Grafana plugin directory, usually `/var/lib/grafana/plugins/`.
28
30
@@ -32,8 +34,8 @@ For example, on a Linux machine, you can run the following commands:
@@ -59,7 +61,9 @@ There are unbounded streaming query and bounded historical query in Timeplus, al
59
61

60
62
61
63
### Query Variables
62
-
You can define dashboard variables with this data source. Please make sure turning off the streaming query mode in the SQL to populate the variable values, and only return 1 or 2 columns. When there is 1 column returned, it will be set as both value and label. If there are 2 columns, the first column will be set as value and the second column as the label. You can also refer to `__from` and `__to` variables in the SQL to get the time range of the dashboard, e.g.:
64
+
65
+
You can define dashboard variables with this data source. Please make sure turning off the streaming query mode in the SQL to populate the variable values, and only return 1 or 2 columns. When there is 1 column returned, it will be set as both value and label. If there are 2 columns, the first column will be set as value and the second column as the label. You can also refer to `__from` and `__to` variables in the SQL to get the time range of the dashboard, e.g.:
66
+
63
67
```sql
64
68
SELECT distinct product_id FROM table(coinbase) where _tp_time < to_datetime($__to/1000) and _tp_time > to_datetime($__from/1000)
65
69
```
@@ -89,6 +93,7 @@ SELECT distinct product_id FROM table(coinbase) where _tp_time < to_datetime($_
89
93
```bash
90
94
mage -l
91
95
```
96
+
92
97
### Frontend
93
98
94
99
1. Install dependencies
@@ -110,12 +115,13 @@ SELECT distinct product_id FROM table(coinbase) where _tp_time < to_datetime($_
0 commit comments