grafana 数据源最大数据点

grafana datasource max data points

开发 Grafana 数据源插件是否有办法更改返回到面板的最大数据点数?

传递给 datasource.query 函数的请求对象如下所示:

{
  "range": { "from": "2015-12-22T03:06:13.851Z", "to": "2015-12-22T06:48:24.137Z" },
  "interval": "5s",
  "targets": [
    { "refId": "B", "target": "upper_75" },
    { "refId": "A", "target": "upper_90" }
  ],
  "format": "json",
  "maxDataPoints": 2495 //decided by the panel
}

根据代码注释(来自 docsmaxDataPoints 由小组决定。

无法覆盖此值?

您可以使用 plugin.json 中的此设置在查询选项中启用 maxDataPoints:

"queryOptions": {
   "maxDataPoints": true
},

此功能未记录...