apiwrite

package
v1.1.2 Latest Latest
Warning

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

Go to latest
Published: Mar 19, 2024 License: AGPL-3.0 Imports: 16 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type API

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

func NewAPI

func NewAPI(cfg Config, ctxlogProvider ctxlog.Provider, ingester ingester.Ingester, tracer opentracing.Tracer) *API

func (*API) RegisterAll

func (a *API) RegisterAll(router *mux.Router)

RegisterAll registers all the routes that the API provides. As well as registering the Datadog APIs, it also registers a not-found handler. This method is used by the Cloud binaries.

func (*API) RegisterValidatePath

func (a *API) RegisterValidatePath(registerer route.Registerer)

func (*API) RegisterWritePath

func (a *API) RegisterWritePath(registerer route.Registerer)

type Config

type Config struct {
	Timeouts struct {
		V1 struct {
			// Write path
			Series   time.Duration `yaml:"series"`
			CheckRun time.Duration `yaml:"check_run"`
			Sketches time.Duration `yaml:"sketches"`
		} `yaml:"v1"`
		Intake time.Duration
	} `yaml:"timeouts"`
}

func (*Config) RegisterFlags

func (cfg *Config) RegisterFlags(flags *flag.FlagSet)

RegisterFlags adds the flags required to config this to the given FlagSet

func (*Config) RegisterFlagsWithPrefix

func (cfg *Config) RegisterFlagsWithPrefix(prefix string, flags *flag.FlagSet)

RegisterFlagsWithPrefix registers flags, adding the provided prefix if needed. If the prefix is not blank and doesn't end with '.', a '.' is appended to it.

type SeriesPushPayload

type SeriesPushPayload struct {
	Series ddstructs.Series `json:"series"`
}

Jump to

Keyboard shortcuts

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