common

package
v0.0.0-...-1d9613f Latest Latest
Warning

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

Go to latest
Published: Mar 5, 2018 License: Apache-2.0 Imports: 21 Imported by: 0

Documentation

Overview

Package common provides a set of common symbols needed by different packages, to avoid circular dependencies.

Package common provides a set of common symbols needed by different packages, to avoid circular dependencies.

Index

Constants

View Source
const (
	// DefaultConfPath points to the folder containing datadog.yaml
	DefaultConfPath = "/etc/datadog-agent"
	// DefaultLogFile points to the log file that will be used if not configured
	DefaultLogFile = "/var/log/datadog/agent.log"
)

Variables

View Source
var (
	// AC is the global object orchestrating checks' loading and running
	AC *autodiscovery.AutoConfig

	// Coll is the global collector instance
	Coll *collector.Collector

	// DSD is the global dogstastd instance
	DSD *dogstatsd.Server

	// MetadataScheduler is responsible to orchestrate metadata collection
	MetadataScheduler *metadata.Scheduler

	// Forwarder is the global forwarder instance
	Forwarder forwarder.Forwarder
)
View Source
var (
	// PyChecksPath holds the path to the python checks from integrations-core shipped with the agent
	PyChecksPath = filepath.Join(_here, "..", "..", "checks.d")
)

Functions

func AutoAddListeners

func AutoAddListeners(listeners []config.Listeners) []config.Listeners

AutoAddListeners checks if the listener auto is selected and adds the docker listener if the host support it no effect if the listeners already contain the docker one Note: auto listener isn't a real listener but a way to automatically starts other listeners TODO: support more listeners (kubelet, ...)

func GetDistPath

func GetDistPath() string

GetDistPath returns the fully qualified path to the 'dist' directory

func GetPythonPaths

func GetPythonPaths() []string

GetPythonPaths returns the paths (in order of precedence) from where the agent should load python modules and checks

func GetViewsPath

func GetViewsPath() string

GetViewsPath returns the fully qualified path to the 'gui/views' directory

func ImportConfig

func ImportConfig(oldConfigDir string, newConfigDir string, force bool) error

ImportConfig imports the agent5 configuration into the agent6 yaml config

func SetupAutoConfig

func SetupAutoConfig(confdPath string)

SetupAutoConfig configures the global AutoConfig:

  1. add the configuration providers
  2. add the check loaders

func SetupConfig

func SetupConfig(confFilePath string) error

SetupConfig fires up the configuration system

func StartAutoConfig

func StartAutoConfig()

StartAutoConfig starts the autoconfig:

  1. start polling the providers
  2. load all the configurations available at startup
  3. run all the Checks for each configuration found

Types

This section is empty.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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