Documentation
¶
Index ¶
- type Handler
- func (h *Handler) ApplyConfig(conf *config.Config) error
- func (h *Handler) Listener(address string, sem chan struct{}) (net.Listener, error)
- func (h *Handler) Listeners() ([]net.Listener, error)
- func (h *Handler) Quit() <-chan struct{}
- func (h *Handler) Reload() <-chan chan error
- func (h *Handler) Run(ctx context.Context, listeners []net.Listener, webConfig string) error
- func (h *Handler) SetReady(v ReadyStatus)
- type LocalStorage
- type Options
- type PrometheusVersion
- type ReadyStatus
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Handler ¶
type Handler struct {
// contains filtered or unexported fields
}
Handler serves various HTTP endpoints of the Prometheus server.
func (*Handler) ApplyConfig ¶
ApplyConfig updates the config field of the Handler struct.
func (*Handler) Quit ¶
func (h *Handler) Quit() <-chan struct{}
Quit returns the receive-only quit channel.
func (*Handler) Reload ¶
Reload returns the receive-only channel that signals configuration reload requests.
func (*Handler) SetReady ¶ added in v0.36.0
func (h *Handler) SetReady(v ReadyStatus)
SetReady sets the ready status of our web Handler.
type LocalStorage ¶
type LocalStorage interface {
storage.Storage
api_v1.TSDBAdminStats
}
type Options ¶
type Options struct {
Context context.Context
TSDBRetentionDuration model.Duration
TSDBDir string
TSDBMaxBytes units.Base2Bytes
LocalStorage LocalStorage
Storage storage.Storage
ExemplarStorage storage.ExemplarQueryable
QueryEngine *promql.Engine
LookbackDelta time.Duration
ScrapeManager *scrape.Manager
RuleManager *rules.Manager
Notifier *notifier.Manager
Version *PrometheusVersion
NotificationsGetter func() []notifications.Notification
NotificationsSub func() (<-chan notifications.Notification, func(), bool)
Flags map[string]string
ListenAddresses []string
CORSOrigin *regexp.Regexp
ReadTimeout time.Duration
MaxConnections int
ExternalURL *url.URL
RoutePrefix string
UseLocalAssets bool
UserAssetsPath string
ConsoleTemplatesPath string
ConsoleLibrariesPath string
UseOldUI bool
EnableLifecycle bool
EnableAdminAPI bool
PageTitle string
RemoteReadSampleLimit int
RemoteReadConcurrencyLimit int
RemoteReadBytesInFrame int
EnableRemoteWriteReceiver bool
EnableOTLPWriteReceiver bool
ConvertOTLPDelta bool
NativeOTLPDeltaIngestion bool
IsAgent bool
CTZeroIngestionEnabled bool
EnableTypeAndUnitLabels bool
AppendMetadata bool
AppName string
AcceptRemoteWriteProtoMsgs remoteapi.MessageTypes
Gatherer prometheus.Gatherer
Registerer prometheus.Registerer
}
Options for the web Handler.
type PrometheusVersion ¶
type PrometheusVersion = api_v1.PrometheusVersion
PrometheusVersion contains build information about Prometheus.
type ReadyStatus ¶ added in v0.300.0
type ReadyStatus uint32
const ( NotReady ReadyStatus = iota Ready Stopping )
Click to show internal directories.
Click to hide internal directories.