http

package
v1.8.0 Latest Latest
Warning

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

Go to latest
Published: Nov 30, 2022 License: Apache-2.0 Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AddFlags

func AddFlags(flags *pflag.FlagSet)

AddFlags registers persistent flags for the HTTP output.

Types

type Config

type Config struct {
	outputs.TLSConfig
	// Enabled determines whether HTTP output is enabled.
	Enabled bool `mapstructure:"enabled"`
	// Endpoints contains a collection of URLs to which the events are sent.
	Endpoints []string `mapstructure:"endpoints"`
	// Timeout represents the timeout for the HTTP requests.
	Timeout time.Duration `mapstructure:"timeout"`
	// ProxyURL specifies the HTTP proxy URL.
	ProxyURL string `mapstructure:"proxy-url"`
	// ProxyUsername is the username for proxy authentication.
	ProxyUsername string `mapstructure:"proxy-username"`
	// ProxyPassword is the password for proxy authentication.
	ProxyPassword string `mapstructure:"proxy-password"`
	// Method determines the HTTP verb in the requests.
	Method string `mapstructure:"method"`
	// Username is the username for the basic HTTP authentication.
	Username string `mapstructure:"username"`
	// Password is the password for the basic HTTP authentication.
	Password string `mapstructure:"password"`
	// Headers contains a list of additional headers in the HTTP request
	Headers map[string]string `mapstructure:"headers"`
	// EnableGzip specifies whether the gzip compression is enabled.
	EnableGzip bool `mapstructure:"enable-gzip"`
	// Serializer indicates the serializer for the HTTP request body.
	Serializer outputs.Serializer `mapstructure:"serializer"`
}

Config contains the options for tweaking the HTTP output behaviour.

Jump to

Keyboard shortcuts

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