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/07/15 07:00:36 UTC

[iotdb] branch master updated: [IOTDB-3833] fixed Grafana 9 connects to iotdb and reports expression should not be null (#6682)

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 2bf38a0b69 [IOTDB-3833] fixed Grafana 9 connects to iotdb and reports expression should not be null (#6682)
2bf38a0b69 is described below

commit 2bf38a0b69e15f5dcf99b6630851e7bf9a07110d
Author: CloudWise-Lukemiao <76...@users.noreply.github.com>
AuthorDate: Fri Jul 15 15:00:31 2022 +0800

    [IOTDB-3833] fixed Grafana 9 connects to iotdb and reports expression should not be null (#6682)
---
 grafana-plugin/pkg/plugin/plugin.go | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/grafana-plugin/pkg/plugin/plugin.go b/grafana-plugin/pkg/plugin/plugin.go
index e7de5f30ed..932f0e1fc0 100644
--- a/grafana-plugin/pkg/plugin/plugin.go
+++ b/grafana-plugin/pkg/plugin/plugin.go
@@ -185,8 +185,10 @@ func (d *IoTDBDataSource) query(cxt context.Context, pCtx backend.PluginContext,
 			qp.Control += " fill" + qp.FillClauses
 		}
 		qdReq = *NewQueryDataReq(expressions, prefixPaths, qp.StartTime, qp.EndTime, qp.Condition, qp.Control)
-	} else {
+	} else if qp.SqlType == "SQL: Full Customized" {
 		qdReq = *NewQueryDataReq(qp.Expression, qp.PrefixPath, qp.StartTime, qp.EndTime, qp.Condition, qp.Control)
+	} else {
+		return response
 	}
 	qpJson, _ := json.Marshal(qdReq)
 	reader := bytes.NewReader(qpJson)