mirror of
https://github.com/grafana/grafana.git
synced 2025-02-25 18:55:37 -06:00
* Add adoption metrics for Cloud Monitoring - Add metrics to track each query type (MQL/Time Series Query, Builder/Time Series Filter, SLO, Annotation) * Remove hidden fields and account for pre 9.4 queries * Simplify object
24 lines
945 B
TypeScript
24 lines
945 B
TypeScript
import { reportInteraction } from '@grafana/runtime';
|
|
|
|
/**
|
|
* Loaded the first time a dashboard containing Cloudmonitoring queries is loaded (not on every render)
|
|
* Note: The queries used here are the ones pre-migration and pre-filterQuery
|
|
*/
|
|
export const trackCloudMonitoringDashboardLoaded = (props: CloudMonitoringDashboardLoadedProps) => {
|
|
reportInteraction('grafana_ds_cloudmonitoring_dashboard_loaded', props);
|
|
};
|
|
|
|
export type CloudMonitoringDashboardLoadedProps = {
|
|
grafana_version?: string;
|
|
dashboard_id: string;
|
|
org_id?: number;
|
|
/** number of non hidden queries of type TimeSeriesQuery (MQL) if any */
|
|
mql_queries: number;
|
|
/** number of non hidden queries of type TimeSeriesFilter (Builder) if any */
|
|
time_series_filter_queries: number;
|
|
/** number of non hidden queries of type SLO if any */
|
|
slo_queries: number;
|
|
/** number of non hidden queries of type annotation if any */
|
|
annotation_queries: number;
|
|
};
|