http

package
v0.0.0-...-a101f2f Latest Latest
Warning

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

Go to latest
Published: Dec 9, 2024 License: AGPL-3.0 Imports: 17 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewHTTPFilter

func NewHTTPFilter(c *config.Config) (pipeline.Filter, error)

func NewWildcardHTTPFilter

func NewWildcardHTTPFilter(c *config.Config) (pipeline.Filter, error)

Types

type HTTPFilter

type HTTPFilter struct {
	Schema          string   `config:"schema"`
	SkipFailureHost bool     `config:"skip_failure_host"`
	Host            string   `config:"host"`
	Hosts           []string `config:"hosts"`

	//host
	MaxConnection       int `config:"max_connection_per_node"`
	MaxResponseBodySize int `config:"max_response_size"`
	MaxRetryTimes       int `config:"max_retry_times"`
	RetryDelayInMs      int `config:"retry_delay_in_ms"`

	SkipCleanupHopHeaders bool `config:"skip_cleanup_hop_headers"`
	SkipEnrichMetadata    bool `config:"skip_metadata_enrich"`

	MaxConnWaitTimeout    time.Duration `config:"max_conn_wait_timeout"`
	MaxIdleConnDuration   time.Duration `config:"max_idle_conn_duration"`
	MaxConnDuration       time.Duration `config:"max_conn_duration"`
	Timeout               time.Duration `config:"timeout"`
	ReadTimeout           time.Duration `config:"read_timeout"`
	WriteTimeout          time.Duration `config:"write_timeout"`
	ReadBufferSize        int           `config:"read_buffer_size"`
	WriteBufferSize       int           `config:"write_buffer_size"`
	TLSInsecureSkipVerify bool          `config:"tls_insecure_skip_verify"`

	TLSConfig *config.TLSConfig `config:"tls"` //client tls config

	MaxRedirectsCount int  `config:"max_redirects_count"`
	FollowRedirects   bool `config:"follow_redirects"`
	HTTPPool          *fasthttp.RequestResponsePool
	// contains filtered or unexported fields
}

func (*HTTPFilter) Filter

func (filter *HTTPFilter) Filter(ctx *fasthttp.RequestCtx)

func (*HTTPFilter) Name

func (filter *HTTPFilter) Name() string

type WildcardDomainFilter

type WildcardDomainFilter struct {
	Schema          string `config:"schema"`
	SkipFailureHost bool   `config:"skip_failure_host"`
	Suffix          string `config:"suffix"`
	Domain          string `config:"domain"`

	//host
	MaxConnection       int `config:"max_connection_per_node"`
	MaxResponseBodySize int `config:"max_response_size"`
	MaxRetryTimes       int `config:"max_retry_times"`
	RetryDelayInMs      int `config:"retry_delay_in_ms"`

	SkipCleanupHopHeaders bool `config:"skip_cleanup_hop_headers"`
	SkipEnrichMetadata    bool `config:"skip_metadata_enrich"`

	MaxConnWaitTimeout    time.Duration `config:"max_conn_wait_timeout"`
	MaxIdleConnDuration   time.Duration `config:"max_idle_conn_duration"`
	MaxConnDuration       time.Duration `config:"max_conn_duration"`
	Timeout               time.Duration `config:"timeout"`
	ReadTimeout           time.Duration `config:"read_timeout"`
	WriteTimeout          time.Duration `config:"write_timeout"`
	ReadBufferSize        int           `config:"read_buffer_size"`
	WriteBufferSize       int           `config:"write_buffer_size"`
	TLSInsecureSkipVerify bool          `config:"tls_insecure_skip_verify"`

	TLSConfig *config.TLSConfig `config:"tls"` //client tls config

	MaxRedirectsCount int  `config:"max_redirects_count"`
	FollowRedirects   bool `config:"follow_redirects"`
	HTTPPool          *fasthttp.RequestResponsePool
	// contains filtered or unexported fields
}

func (*WildcardDomainFilter) Filter

func (filter *WildcardDomainFilter) Filter(ctx *fasthttp.RequestCtx)

func (*WildcardDomainFilter) Name

func (filter *WildcardDomainFilter) Name() string

Jump to

Keyboard shortcuts

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