Documentation ¶
Index ¶
- func ContextWithMaxNodes(parent context.Context, val int) context.Context
- func MaxNodesFromContext(ctx context.Context) (int, bool)
- func NewExportHandler(httpUtils httputils.Utils) http.HandlerFunc
- func NewIndexHandler(log *logrus.Logger, dir http.FileSystem, stats StatsReceiver, ...) http.Handler
- func NewIngestHandler(log *logrus.Logger, p ingestion.Ingester, ...) http.Handler
- func NewLabelValuesHandler(s storage.LabelValuesGetter, httpUtils httputils.Utils) http.HandlerFunc
- func NewLabelsHandler(s storage.LabelsGetter, httpUtils httputils.Utils) http.HandlerFunc
- type Config
- type Controller
- type ExemplarsHandler
- type Flags
- type HeatmapBuilder
- type HistoryHandler
- type IndexHandler
- type IndexHandlerConfig
- type NoopHeatmapBuilder
- type Notifier
- type Payload
- type RemoteReadHandler
- type RenderDiffHandler
- type RenderDiffParams
- type RenderDiffResponse
- type RenderHandler
- type StatsReceiver
- type TargetsResponse
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ContextWithMaxNodes ¶ added in v0.34.0
func MaxNodesFromContext ¶ added in v0.34.0
func NewExportHandler ¶ added in v0.14.0
func NewExportHandler(httpUtils httputils.Utils) http.HandlerFunc
func NewIndexHandler ¶ added in v0.14.0
func NewIndexHandler( log *logrus.Logger, dir http.FileSystem, stats StatsReceiver, notifier Notifier, cfg *IndexHandlerConfig, httpUtils httputils.Utils, ) http.Handler
func NewIngestHandler ¶ added in v0.3.0
func NewLabelValuesHandler ¶ added in v0.14.0
func NewLabelValuesHandler(s storage.LabelValuesGetter, httpUtils httputils.Utils) http.HandlerFunc
func NewLabelsHandler ¶ added in v0.14.0
func NewLabelsHandler(s storage.LabelsGetter, httpUtils httputils.Utils) http.HandlerFunc
Types ¶
type Config ¶ added in v0.2.1
type Config struct { Configuration *config.Server Logger *logrus.Logger // TODO(kolesnikovae): Ideally, Storage should be decomposed. *storage.Storage ingestion.Ingester *gorm.DB Notifier // The registerer is used for exposing server metrics. MetricsRegisterer prometheus.Registerer ExportedMetricsRegistry *prometheus.Registry ScrapeManager *scrape.Manager HistoryMgr history.Manager }
type Controller ¶
type Controller struct {
// contains filtered or unexported fields
}
func New ¶
func New(c Config) (*Controller, error)
func (*Controller) AppsCount ¶ added in v0.0.13
func (ctrl *Controller) AppsCount() int
func (*Controller) Drain ¶ added in v0.0.34
func (ctrl *Controller) Drain()
func (*Controller) Start ¶
func (ctrl *Controller) Start() error
func (*Controller) Stats ¶ added in v0.0.13
func (ctrl *Controller) Stats() map[string]int
func (*Controller) StatsInc ¶ added in v0.14.0
func (ctrl *Controller) StatsInc(name string)
func (*Controller) Stop ¶ added in v0.0.30
func (ctrl *Controller) Stop() error
type ExemplarsHandler ¶ added in v0.28.0
type ExemplarsHandler struct { StatsReceiver StatsReceiver HistoryManager history.Manager HTTPUtils httputils.Utils MaxNodesDefault int ExemplarsGetter storage.ExemplarsGetter ExemplarsMerger storage.ExemplarsMerger ExemplarsQuerier storage.ExemplarsQuerier HeatmapBuilder HeatmapBuilder }
func (ExemplarsHandler) MergeExemplars ¶ added in v0.28.0
func (h ExemplarsHandler) MergeExemplars(w http.ResponseWriter, r *http.Request)
func (ExemplarsHandler) QueryExemplars ¶ added in v0.28.0
func (h ExemplarsHandler) QueryExemplars(w http.ResponseWriter, r *http.Request)
type Flags ¶ added in v0.14.0
type Flags struct { EnableAdhocUI bool `json:"enableAdhocUI"` GoogleEnabled bool `json:"googleEnabled"` GitlabEnabled bool `json:"gitlabEnabled"` GithubEnabled bool `json:"githubEnabled"` InternalAuthEnabled bool `json:"internalAuthEnabled"` SignupEnabled bool `json:"signupEnabled"` ExportToFlamegraphDotComEnabled bool `json:"exportToFlamegraphDotComEnabled"` IsAuthRequired bool `json:"isAuthRequired"` ExemplarsPageEnabled bool `json:"exemplarsPageEnabled"` }
type HeatmapBuilder ¶ added in v0.28.0
type HeatmapBuilder interface {
BuildFromSketch(heatmap.HeatmapSketch) *heatmap.Heatmap
}
type HistoryHandler ¶ added in v0.28.0
type HistoryHandler struct {
// contains filtered or unexported fields
}
func NewHistoryHandler ¶ added in v0.28.0
func (*HistoryHandler) ServeHTTP ¶ added in v0.28.0
func (rh *HistoryHandler) ServeHTTP(w http.ResponseWriter, r *http.Request)
type IndexHandler ¶ added in v0.14.0
type IndexHandler struct {
// contains filtered or unexported fields
}
func (*IndexHandler) ServeHTTP ¶ added in v0.14.0
func (ih *IndexHandler) ServeHTTP(w http.ResponseWriter, r *http.Request)
type IndexHandlerConfig ¶ added in v0.14.0
type NoopHeatmapBuilder ¶ added in v0.28.0
type NoopHeatmapBuilder struct{}
func (NoopHeatmapBuilder) BuildFromSketch ¶ added in v0.28.0
func (NoopHeatmapBuilder) BuildFromSketch(heatmap.HeatmapSketch) *heatmap.Heatmap
type Notifier ¶ added in v0.2.2
type Notifier interface { // NotificationText returns message that will be displayed to user // on index page load. The message should point user to a critical problem. // TODO(kolesnikovae): we should poll for notifications (or subscribe). NotificationText() string }
type RemoteReadHandler ¶ added in v0.22.0
type RemoteReadHandler struct {
// contains filtered or unexported fields
}
func NewRemoteReadHandler ¶ added in v0.22.0
func NewRemoteReadHandler(r config.RemoteRead) (*RemoteReadHandler, error)
func (*RemoteReadHandler) ServeHTTP ¶ added in v0.22.0
func (rh *RemoteReadHandler) ServeHTTP(w http.ResponseWriter, r *http.Request)
type RenderDiffHandler ¶ added in v0.14.0
type RenderDiffHandler struct {
// contains filtered or unexported fields
}
func NewRenderDiffHandler ¶ added in v0.14.0
func NewRenderDiffHandler( l *logrus.Logger, s storage.Getter, dir http.FileSystem, stats StatsReceiver, maxNodesDefault int, httpUtils httputils.Utils, historyMgr history.Manager, ) *RenderDiffHandler
func (*RenderDiffHandler) ServeHTTP ¶ added in v0.14.0
func (rh *RenderDiffHandler) ServeHTTP(w http.ResponseWriter, r *http.Request)
type RenderDiffParams ¶ added in v0.0.38
type RenderDiffParams struct { LeftQuery string `json:"leftQuery"` LeftFrom string `json:"leftFrom"` LeftUntil string `json:"leftUntil"` RightQuery string `json:"rightQuery"` RightFrom string `json:"rightFrom"` RightUntil string `json:"rightUntil"` Format string `json:"format"` MaxNodes *int `json:"maxNodes,omitempty"` }
RenderDiffParams refers to the params accepted by the renderDiffHandler
type RenderDiffResponse ¶ added in v0.14.0
type RenderDiffResponse struct { *flamebearer.FlamebearerProfile Metadata renderMetadataResponse `json:"metadata"` }
RenderDiffResponse refers to the response of the renderDiffHandler
type RenderHandler ¶ added in v0.14.0
type RenderHandler struct {
// contains filtered or unexported fields
}
func NewRenderHandler ¶ added in v0.14.0
func NewRenderHandler( l *logrus.Logger, s storage.Getter, dir http.FileSystem, stats StatsReceiver, maxNodesDefault int, httpUtils httputils.Utils, historyMgr history.Manager, annotationsService api.AnnotationsService, ) *RenderHandler
func (*RenderHandler) ServeHTTP ¶ added in v0.14.0
func (rh *RenderHandler) ServeHTTP(w http.ResponseWriter, r *http.Request)
type StatsReceiver ¶ added in v0.14.0
type StatsReceiver interface {
StatsInc(name string)
}
type TargetsResponse ¶ added in v0.11.0
type TargetsResponse struct { Job string `json:"job"` TargetURL string `json:"url"` DiscoveredLabels labels.Labels `json:"discoveredLabels"` Labels labels.Labels `json:"labels"` Health scrape.TargetHealth `json:"health"` LastScrape time.Time `json:"lastScrape"` LastError string `json:"lastError"` LastScrapeDuration string `json:"lastScrapeDuration"` }
Source Files ¶
- build.go
- config.go
- context.go
- controller.go
- exemplars.go
- exemplars_merge.go
- exemplars_query.go
- export.go
- healthz.go
- history.go
- http.go
- index.go
- ingest.go
- labels.go
- labelvalues.go
- login.go
- mocks.go
- oauth_base.go
- oauth_github.go
- oauth_gitlab.go
- oauth_google.go
- remoteread.go
- render.go
- render_diff.go
- stats.go
- templates.go
Click to show internal directories.
Click to hide internal directories.