Tempo: dashboard feature tracking (#61210)

* grafana_tempo_dashboard_loaded

* Update version

* Updates

* Added more tracking stats + updates
This commit is contained in:
Joey Tawadrous
2023-01-13 16:31:44 +00:00
committed by GitHub
parent 98cadb3aa0
commit 58c4c95e92
3 changed files with 211 additions and 1 deletions

View File

@@ -1,11 +1,17 @@
import { DataSourcePlugin } from '@grafana/data';
import { DataSourcePlugin, DashboardLoadedEvent } from '@grafana/data';
import { getAppEvents } from '@grafana/runtime';
import CheatSheet from './CheatSheet';
import { TempoQueryField } from './QueryEditor/QueryField';
import { ConfigEditor } from './configuration/ConfigEditor';
import { TempoDatasource } from './datasource';
import { onDashboardLoadedHandler } from './tracking';
import { TempoQuery } from './types';
export const plugin = new DataSourcePlugin(TempoDatasource)
.setQueryEditor(TempoQueryField)
.setConfigEditor(ConfigEditor)
.setQueryEditorHelp(CheatSheet);
// Subscribe to on dashboard loaded event so that we can track plugin adoption
getAppEvents().subscribe<DashboardLoadedEvent<TempoQuery>>(DashboardLoadedEvent, onDashboardLoadedHandler);