Versions in this module Expand all Collapse all v0 v0.0.1 Feb 29, 2024 Changes in this version + type Data struct + ActiveTargets []VMAgentAPITarget + DroppedTargets []VMAgentAPITarget + type EnvDiscovery struct + func NewEnvDiscovery(envvar string) *EnvDiscovery + func (e *EnvDiscovery) DiscoverEndpoints() ([]string, error) + type FileDiscovery struct + func NewFileDiscovery(fp string) *FileDiscovery + func (f *FileDiscovery) DiscoverEndpoints() ([]string, error) + type StaticMemDiscovery struct + func (s *StaticMemDiscovery) DiscoverEndpoints() ([]string, error) + type VMAgentAPICollection struct + func NewVMAgentCollection(discovery VMAgentDiscoverer) (*VMAgentAPICollection, error) + func (v *VMAgentAPICollection) CollectAll() []error + func (v *VMAgentAPICollection) Data() map[string]VMAgentAPIResponse + func (v *VMAgentAPICollection) Reconcile(newEndpoints []string) error + type VMAgentAPICollectionError struct + func (e VMAgentAPICollectionError) Error() string + func (e VMAgentAPICollectionError) Unwrap() error + type VMAgentAPICollector struct + func NewVMAgentAPICollector(s string, c *http.Client) (*VMAgentAPICollector, error) + func (v *VMAgentAPICollector) Collect() (VMAgentAPIResponse, error) + type VMAgentAPIResponse struct + Data Data + Status string + type VMAgentAPITarget struct + DiscoveredLabels map[string]string + Health string + Labels map[string]string + LastError string + LastSamplesScraped int + LastScrape time.Time + LastScrapeDuration float64 + ScrapePool string + ScrapeURL string + type VMAgentDiscoverer interface + DiscoverEndpoints func() ([]string, error)