Datasource: Overhaul plugin error handling and action buttons (#67014)

* - initial work on data source config page

* - add links to test status box
- add tracking function

* - add test for the DataSourceConfigAlert component

* - fix flicker of the alert box

* - fix the build

* - small improvements

* - fix failing build

* - fix failing unit tests

* - prettier and betterer fixes

* - fix failing e2e tests

* - fix build again

* - rewrite solution according to the PR comments

* - cleanup

* - fix failing e2e

* - use absolute path in link

* Minor fixes

---------

Co-authored-by: Torkel Ödegaard <torkel@grafana.com>
This commit is contained in:
Kuba Siemiatkowski
2023-04-28 15:57:17 +02:00
committed by GitHub
parent fe59b65f9e
commit f8faacd54a
22 changed files with 262 additions and 95 deletions

View File

@@ -2,6 +2,7 @@
import {
DataQueryRequest,
DataQueryResponse,
TestDataSourceResponse,
DataSourceApi,
DataSourceInstanceSettings,
MetricFindValue,
@@ -68,7 +69,7 @@ export class InputDatasource extends DataSourceApi<InputQuery, InputOptions> {
return Promise.resolve({ data: results });
}
testDatasource() {
testDatasource(): Promise<TestDataSourceResponse> {
return new Promise((resolve, reject) => {
let rowCount = 0;
let info = `${this.data.length} Series:`;