RegisterQueryable registers the default routes associated with the querier module.
( queryable storage.SampleAndChunkQueryable, distributor Distributor, )
| 433 | // RegisterQueryable registers the default routes associated with the querier |
| 434 | // module. |
| 435 | func (a *API) RegisterQueryable( |
| 436 | queryable storage.SampleAndChunkQueryable, |
| 437 | distributor Distributor, |
| 438 | ) { |
| 439 | // these routes are always registered to the default server |
| 440 | a.RegisterRoute("/api/v1/user_stats", http.HandlerFunc(distributor.UserStatsHandler), true, "GET") |
| 441 | |
| 442 | a.RegisterRoute(path.Join(a.cfg.LegacyHTTPPrefix, "/user_stats"), http.HandlerFunc(distributor.UserStatsHandler), true, "GET") |
| 443 | } |
| 444 | |
| 445 | // RegisterQueryAPI registers the Prometheus API routes with the provided handler. |
| 446 | func (a *API) RegisterQueryAPI(handler http.Handler) { |
no test coverage detected