feat: expose template insights as Prometheus metrics (#10325)

This commit is contained in:
Marcin Tojek
2023-10-19 08:45:12 +00:00
committed by GitHub
parent 997493d4ae
commit c4f590581e
11 changed files with 555 additions and 0 deletions
+1
View File
@@ -145,6 +145,7 @@ type sqlcQuerier interface {
// that interval will be shorter than a full one. If there is no data for a selected
// interval/template, it will be included in the results with 0 active users.
GetTemplateInsightsByInterval(ctx context.Context, arg GetTemplateInsightsByIntervalParams) ([]GetTemplateInsightsByIntervalRow, error)
GetTemplateInsightsByTemplate(ctx context.Context, arg GetTemplateInsightsByTemplateParams) ([]GetTemplateInsightsByTemplateRow, error)
// GetTemplateParameterInsights does for each template in a given timeframe,
// look for the latest workspace build (for every workspace) that has been
// created in the timeframe and return the aggregate usage counts of parameter