agent

package
v0.11.2-rc1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 13, 2023 License: Apache-2.0 Imports: 54 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var TimeDeltaMillis = time.Minute.Milliseconds()

Functions

func Scheme

func Scheme(ctx context.Context) meta.Scheme

Types

type HttpServer

type HttpServer struct {
	apiextensions.UnsafeHTTPAPIExtensionServer
	// contains filtered or unexported fields
}

func NewHttpServer

func NewHttpServer(ct health.ConditionTracker, lg *zap.SugaredLogger) *HttpServer

func (*HttpServer) ConfigureRoutes

func (s *HttpServer) ConfigureRoutes(router *gin.Engine)

func (*HttpServer) SetEnabled

func (s *HttpServer) SetEnabled(enabled bool)

func (*HttpServer) SetRemoteWriteClient

func (s *HttpServer) SetRemoteWriteClient(client clients.Locker[remotewrite.RemoteWriteClient])

type MetricsNode

type MetricsNode struct {
	capabilityv1.UnsafeNodeServer
	controlv1.UnsafeHealthServer

	// we only need a subset of the methods
	remoteread.UnsafeRemoteReadAgentServer
	// contains filtered or unexported fields
}

func (*MetricsNode) AddConfigListener

func (m *MetricsNode) AddConfigListener(ch drivers.MetricsNodeConfigurator)

func (*MetricsNode) AddNodeDriver added in v0.9.2

func (m *MetricsNode) AddNodeDriver(driver drivers.MetricsNodeDriver)

func (*MetricsNode) Discover added in v0.8.2

func (*MetricsNode) GetHealth

func (m *MetricsNode) GetHealth(_ context.Context, _ *emptypb.Empty) (*corev1.Health, error)

func (*MetricsNode) GetTargetStatus added in v0.8.2

func (*MetricsNode) Info

func (*MetricsNode) SetClients added in v0.9.2

func (m *MetricsNode) SetClients(
	nodeClient node.NodeMetricsCapabilityClient,
	identityClient controlv1.IdentityClient,
	healthListenerClient controlv1.HealthListenerClient,
)

func (*MetricsNode) SetRemoteWriter added in v0.8.2

func (m *MetricsNode) SetRemoteWriter(client clients.Locker[remotewrite.RemoteWriteClient])

func (*MetricsNode) Start added in v0.8.2

func (*MetricsNode) Stop added in v0.8.2

func (*MetricsNode) SyncNow

func (m *MetricsNode) SyncNow(_ context.Context, req *capabilityv1.Filter) (*emptypb.Empty, error)

type Plugin

type Plugin struct {
	// contains filtered or unexported fields
}

func NewPlugin

func NewPlugin(ctx context.Context) *Plugin

func (*Plugin) ConfigureNode added in v0.10.0

func (p *Plugin) ConfigureNode(nodeId string, cfg *node.MetricsCapabilityConfig) error

func (*Plugin) StreamServers

func (p *Plugin) StreamServers() []streamext.Server

func (*Plugin) UseStreamClient

func (p *Plugin) UseStreamClient(cc grpc.ClientConnInterface)

type RemoteReader added in v0.8.2

type RemoteReader interface {
	Read(ctx context.Context, endpoint string, request *prompb.ReadRequest) (*prompb.ReadResponse, error)
}

func NewRemoteReader added in v0.8.2

func NewRemoteReader(prometheusClient *http.Client) RemoteReader

type RuleStreamer

type RuleStreamer struct {
	// contains filtered or unexported fields
}

func (*RuleStreamer) Run

func (*RuleStreamer) SetRemoteWriteClient

func (s *RuleStreamer) SetRemoteWriteClient(client remotewrite.RemoteWriteClient)

type TargetRunMetadata added in v0.8.2

type TargetRunMetadata struct {
	Target *remoteread.Target
	Query  *remoteread.Query
}

type TargetRunner added in v0.8.2

type TargetRunner interface {
	Start(target *remoteread.Target, query *remoteread.Query) error
	Stop(name string) error
	GetStatus(name string) (*remoteread.TargetStatus, error)
	SetRemoteWriteClient(client clients.Locker[remotewrite.RemoteWriteClient])
	SetRemoteReaderClient(client RemoteReader)
}

func NewTargetRunner added in v0.8.2

func NewTargetRunner(logger *zap.SugaredLogger) TargetRunner

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL