http

package
v0.0.0-...-949823d Latest Latest
Warning

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

Go to latest
Published: Nov 10, 2024 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type HTTP

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

HTTP returns HTTP middleware pipelines. These pipelines dynamically update the middleware chain when a component is added or removed from the store. Callers need only build a Pipeline once for a given spec.

func New

func New() *HTTP

New returns a new HTTP middleware store.

func (*HTTP) Add

func (h *HTTP) Add(spec Spec)

Add adds a middleware to the store.

func (*HTTP) BuildPipelineFromSpec

func (h *HTTP) BuildPipelineFromSpec(name string, spec *config.PipelineSpec) middleware.HTTP

BuildPipelineFromSpec builds a middleware pipeline from a spec. The returned Pipeline will dynamically update handlers when middleware components are added or removed from the store.

func (*HTTP) Remove

func (h *HTTP) Remove(name string)

Remove removes a middleware from the store.

type Spec

type Spec struct {
	Component      compapi.Component
	Implementation middleware.HTTP
}

Spec is a specification for a creating a middleware.

Jump to

Keyboard shortcuts

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