This PR makes it possible to use pre-defined dashboards when setting up a new InfluxDB v2 connection. When a database is not available in a v2 connection (missing V1 DBRP mapping), the implementation tries to create a v1 DBRP mapping so that the existing InfluxQL dashboards (and dashboard suggestions) work properly.
When a V2 connection is specified (InfluxDB v2 Auth is selected)
and the user presses Next, the implementation then tries to suggest dashboards. Newly in this PR, if it detects that there is no telegraf database, it attempts to create a v1 DBRP mapping for a v2 bucket of the same name as the database. If such a bucket exists and the DBRP mapping can be created, it creates a database and notifies a user with a message:
The suggested dashboards functionality immediately works OOTB.
The new functionality requires privileges that allow getting v2 buckets and creating v1 DBRP mapping, an admin (all-access) token for a v2 InfluxDB OSS is required.
[x] CHANGELOG.md updated with a link to the PR (not the Issue)
This PR makes it possible to use pre-defined dashboards when setting up a new InfluxDB v2 connection. When a database is not available in a v2 connection (missing V1 DBRP mapping), the implementation tries to create a v1 DBRP mapping so that the existing InfluxQL dashboards (and dashboard suggestions) work properly.
When a V2 connection is specified (InfluxDB v2 Auth is selected)
and the user presses
Next
, the implementation then tries to suggest dashboards. Newly in this PR, if it detects that there is notelegraf
database, it attempts to create a v1 DBRP mapping for a v2 bucket of the same name as the database. If such a bucket exists and the DBRP mapping can be created, it creates a database and notifies a user with a message:The
suggested dashboards
functionality immediately works OOTB.The new functionality requires privileges that allow getting v2 buckets and creating v1 DBRP mapping, an admin (all-access) token for a v2 InfluxDB OSS is required.