You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@iotdb.apache.org by ha...@apache.org on 2022/11/23 16:02:32 UTC

[iotdb] branch master updated: Grafana plugin request and return parameter adjustment (#8117)

This is an automated email from the ASF dual-hosted git repository.

haonan pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/iotdb.git


The following commit(s) were added to refs/heads/master by this push:
     new bdd7e1b9ca Grafana plugin request and return parameter adjustment (#8117)
bdd7e1b9ca is described below

commit bdd7e1b9ca9ebc9adc2b4bd69d9c82664b3d288b
Author: CloudWise-Lukemiao <76...@users.noreply.github.com>
AuthorDate: Thu Nov 24 00:02:25 2022 +0800

    Grafana plugin request and return parameter adjustment (#8117)
---
 docs/UserGuide/Ecosystem-Integration/Grafana-Plugin.md    | 2 +-
 docs/zh/UserGuide/Ecosystem-Integration/Grafana-Plugin.md | 2 +-
 grafana-plugin/pkg/plugin/plugin.go                       | 8 ++++----
 3 files changed, 6 insertions(+), 6 deletions(-)

diff --git a/docs/UserGuide/Ecosystem-Integration/Grafana-Plugin.md b/docs/UserGuide/Ecosystem-Integration/Grafana-Plugin.md
index 03afa016b2..abe2bf6537 100644
--- a/docs/UserGuide/Ecosystem-Integration/Grafana-Plugin.md
+++ b/docs/UserGuide/Ecosystem-Integration/Grafana-Plugin.md
@@ -105,7 +105,7 @@ If compiling successful, you can see that the `distribution/target` directory co
 * Modify Grafana configuration file: the file is in(`${Grafana directory}\conf\defaults.ini`), and do the following modifications:
 
   ```ini
-  allow_loading_unsigned_plugins = iotdb
+  allow_loading_unsigned_plugins = apache-iotdb-datasource
   ```
 * Modify the location of Grafana's plugin directory: the file is in(`${Grafana directory}\conf\defaults.ini`), and do the following modifications:
   
diff --git a/docs/zh/UserGuide/Ecosystem-Integration/Grafana-Plugin.md b/docs/zh/UserGuide/Ecosystem-Integration/Grafana-Plugin.md
index efaf9a8a0a..c816dc35f1 100644
--- a/docs/zh/UserGuide/Ecosystem-Integration/Grafana-Plugin.md
+++ b/docs/zh/UserGuide/Ecosystem-Integration/Grafana-Plugin.md
@@ -119,7 +119,7 @@ git clone https://github.com/apache/iotdb.git
 * 修改Grafana的配置文件:找到配置文件(`${Grafana文件目录}\conf\defaults.ini`),并进行如下的修改:
 
   ```ini
-  allow_loading_unsigned_plugins = iotdb
+  allow_loading_unsigned_plugins = apache-iotdb-datasource
   ```
 * 修改Grafana 的插件目录位置:找到配置文件(`${Grafana文件目录}\conf\defaults.ini`),并进行如下的修改:
 
diff --git a/grafana-plugin/pkg/plugin/plugin.go b/grafana-plugin/pkg/plugin/plugin.go
index 31db7b6dfa..fce2031076 100644
--- a/grafana-plugin/pkg/plugin/plugin.go
+++ b/grafana-plugin/pkg/plugin/plugin.go
@@ -125,9 +125,9 @@ type queryParam struct {
 
 type QueryDataReq struct {
 	Expression []string `json:"expression"`
-	PrefixPath []string `json:"prefixPath"`
-	StartTime  int64    `json:"startTime"`
-	EndTime    int64    `json:"endTime"`
+	PrefixPath []string `json:"prefix_path"`
+	StartTime  int64    `json:"start_time"`
+	EndTime    int64    `json:"end_time"`
 	Condition  string   `json:"condition"`
 	Control    string   `json:"control"`
 }
@@ -136,7 +136,7 @@ type QueryDataResponse struct {
 	Expressions []string    `json:"expressions"`
 	Timestamps  []int64     `json:"timestamps"`
 	Values      [][]interface{} `json:"values"`
-	ColumnNames interface{} `json:"columnNames"`
+	ColumnNames interface{} `json:"column_names"`
 	Code        int32       `json:"code"`
 	Message     string      `json:"message"`
 }