agentimpl

package
v0.0.0-...-46749fd Latest Latest
Warning

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

Go to latest
Published: Dec 27, 2024 License: Apache-2.0 Imports: 55 Imported by: 0

Documentation

Overview

Package agentimpl contains the implementation of the logs agent component.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Module

func Module() fxutil.Module

Module defines the fx options for this component.

func NewServerlessLogsAgent

func NewServerlessLogsAgent(tagger tagger.Component) agent.ServerlessLogsAgent

NewServerlessLogsAgent creates a new instance of the logs agent for serverless

func SetUpLaunchers

func SetUpLaunchers(conf configComponent.Component, sourceProvider *sources.ConfigSources) (chan *message.Message, *launchers.Launchers, pipeline.Provider)

SetUpLaunchers creates intializes the launcher. The launchers schedule the tailers to read the log files provided by the analyze-logs command

Types

type SchedulerProvider

type SchedulerProvider struct {
	fx.Out

	Scheduler schedulers.Scheduler `group:"log-agent-scheduler"`
}

SchedulerProvider provides a scheduler for the log Agent.

func NewSchedulerProvider

func NewSchedulerProvider(scheduler schedulers.Scheduler) SchedulerProvider

NewSchedulerProvider returns a new SchedulerProvider.

type StatusProvider

type StatusProvider struct{}

StatusProvider is the type for logs agent status methods

func NewStatusProvider

func NewStatusProvider() *StatusProvider

NewStatusProvider fetches the status and returns a service wrapping it

func (StatusProvider) AddGlobalWarning

func (p StatusProvider) AddGlobalWarning(key string, warning string)

AddGlobalWarning keeps track of a warning message to display on the status.

func (StatusProvider) HTML

func (p StatusProvider) HTML(verbose bool, buffer io.Writer) error

HTML renders the HTML output

func (StatusProvider) JSON

func (p StatusProvider) JSON(verbose bool, stats map[string]interface{}) error

JSON populates the status map

func (StatusProvider) Name

func (p StatusProvider) Name() string

Name returns the name

func (StatusProvider) RemoveGlobalWarning

func (p StatusProvider) RemoveGlobalWarning(key string)

RemoveGlobalWarning loses track of a warning message that does not need to be displayed on the status anymore.

func (StatusProvider) Section

func (p StatusProvider) Section() string

Section returns the section

func (StatusProvider) Text

func (p StatusProvider) Text(verbose bool, buffer io.Writer) error

Text renders the text output

Jump to

Keyboard shortcuts

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