headers

package
v1.18.0-beta24 Latest Latest
Warning

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

Go to latest
Published: Oct 1, 2024 License: Apache-2.0 Imports: 21 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

View Source
var File_github_com_solo_io_gloo_projects_gloo_api_v1_options_headers_headers_proto protoreflect.FileDescriptor

Functions

This section is empty.

Types

type HeaderManipulation

type HeaderManipulation struct {

	// Specifies a list of HTTP headers that should be added to each request
	// handled by this route or virtual host. For more information, including
	// details on header value syntax, see the
	// [Envoy documentation](https://www.envoyproxy.io/docs/envoy/latest/configuration/http/http_conn_man/headers.html#) .
	RequestHeadersToAdd []*core.HeaderValueOption `protobuf:"bytes,1,rep,name=request_headers_to_add,json=requestHeadersToAdd,proto3" json:"request_headers_to_add,omitempty"`
	// Specifies a list of HTTP headers that should be removed from each request
	// handled by this route or virtual host.
	RequestHeadersToRemove []string `` /* 131-byte string literal not displayed */
	// Specifies a list of HTTP headers that should be added to each response
	// handled by this route or host. For more information, including
	// details on header value syntax, see the
	// [Envoy documentation](https://www.envoyproxy.io/docs/envoy/latest/configuration/http/http_conn_man/headers.html# .
	ResponseHeadersToAdd []*HeaderValueOption `protobuf:"bytes,3,rep,name=response_headers_to_add,json=responseHeadersToAdd,proto3" json:"response_headers_to_add,omitempty"`
	// Specifies a list of HTTP headers that should be removed from each response
	// handled by this route or virtual host.
	ResponseHeadersToRemove []string `` /* 134-byte string literal not displayed */
	// contains filtered or unexported fields
}

This plugin provides configuration options to append and remove headers from requests and responses HeaderManipulation can be specified on routes, virtual hosts, or weighted destinations

func (*HeaderManipulation) Clone added in v1.8.24

func (m *HeaderManipulation) Clone() proto.Message

Clone function

func (*HeaderManipulation) Descriptor deprecated

func (*HeaderManipulation) Descriptor() ([]byte, []int)

Deprecated: Use HeaderManipulation.ProtoReflect.Descriptor instead.

func (*HeaderManipulation) Equal

func (m *HeaderManipulation) Equal(that interface{}) bool

Equal function

func (*HeaderManipulation) GetRequestHeadersToAdd

func (x *HeaderManipulation) GetRequestHeadersToAdd() []*core.HeaderValueOption

func (*HeaderManipulation) GetRequestHeadersToRemove

func (x *HeaderManipulation) GetRequestHeadersToRemove() []string

func (*HeaderManipulation) GetResponseHeadersToAdd

func (x *HeaderManipulation) GetResponseHeadersToAdd() []*HeaderValueOption

func (*HeaderManipulation) GetResponseHeadersToRemove

func (x *HeaderManipulation) GetResponseHeadersToRemove() []string

func (*HeaderManipulation) Hash deprecated added in v1.2.13

func (m *HeaderManipulation) Hash(hasher hash.Hash64) (uint64, error)

Hash function

Deprecated: due to hashing implemention only using field values. The omission of the field name in the hash calculation can lead to hash collisions. Prefer the HashUnique function instead.

func (*HeaderManipulation) HashUnique

func (m *HeaderManipulation) HashUnique(hasher hash.Hash64) (uint64, error)

HashUnique function generates a hash of the object that is unique to the object by hashing field name and value pairs. Replaces Hash due to original hashing implemention only using field values. The omission of the field name in the hash calculation can lead to hash collisions.

func (*HeaderManipulation) ProtoMessage

func (*HeaderManipulation) ProtoMessage()

func (*HeaderManipulation) ProtoReflect added in v1.6.0

func (x *HeaderManipulation) ProtoReflect() protoreflect.Message

func (*HeaderManipulation) Reset

func (x *HeaderManipulation) Reset()

func (*HeaderManipulation) String

func (x *HeaderManipulation) String() string

type HeaderValue

type HeaderValue struct {

	// Header name.
	Key string `protobuf:"bytes,1,opt,name=key,proto3" json:"key,omitempty"`
	// Header value.
	Value string `protobuf:"bytes,2,opt,name=value,proto3" json:"value,omitempty"`
	// contains filtered or unexported fields
}

Header name/value pair.

func (*HeaderValue) Clone added in v1.8.24

func (m *HeaderValue) Clone() proto.Message

Clone function

func (*HeaderValue) Descriptor deprecated

func (*HeaderValue) Descriptor() ([]byte, []int)

Deprecated: Use HeaderValue.ProtoReflect.Descriptor instead.

func (*HeaderValue) Equal

func (m *HeaderValue) Equal(that interface{}) bool

Equal function

func (*HeaderValue) GetKey

func (x *HeaderValue) GetKey() string

func (*HeaderValue) GetValue

func (x *HeaderValue) GetValue() string

func (*HeaderValue) Hash deprecated added in v1.2.13

func (m *HeaderValue) Hash(hasher hash.Hash64) (uint64, error)

Hash function

Deprecated: due to hashing implemention only using field values. The omission of the field name in the hash calculation can lead to hash collisions. Prefer the HashUnique function instead.

func (*HeaderValue) HashUnique

func (m *HeaderValue) HashUnique(hasher hash.Hash64) (uint64, error)

HashUnique function generates a hash of the object that is unique to the object by hashing field name and value pairs. Replaces Hash due to original hashing implemention only using field values. The omission of the field name in the hash calculation can lead to hash collisions.

func (*HeaderValue) ProtoMessage

func (*HeaderValue) ProtoMessage()

func (*HeaderValue) ProtoReflect added in v1.6.0

func (x *HeaderValue) ProtoReflect() protoreflect.Message

func (*HeaderValue) Reset

func (x *HeaderValue) Reset()

func (*HeaderValue) String

func (x *HeaderValue) String() string

type HeaderValueOption

type HeaderValueOption struct {

	// Header name/value pair that this option applies to.
	Header *HeaderValue `protobuf:"bytes,1,opt,name=header,proto3" json:"header,omitempty"`
	// Specifies if the value should be appended or overwrite an existing header. Defaults to true.
	// If set to true, this maps to Envoy's `append_value: APPEND_IF_EXISTS_OR_ADD`, where the value gets be appended the header's value(s) if exists, or created if it does not.
	// If set to false, this maps to Envoy's `append_value: OVERWRITE_IF_EXISTS_OR_ADD`, where the header's value will be overwritten if it exists, or created if it does not.
	Append *wrapperspb.BoolValue `protobuf:"bytes,2,opt,name=append,proto3" json:"append,omitempty"`
	// contains filtered or unexported fields
}

Header name/value pair plus option to control append behavior.

func (*HeaderValueOption) Clone added in v1.8.24

func (m *HeaderValueOption) Clone() proto.Message

Clone function

func (*HeaderValueOption) Descriptor deprecated

func (*HeaderValueOption) Descriptor() ([]byte, []int)

Deprecated: Use HeaderValueOption.ProtoReflect.Descriptor instead.

func (*HeaderValueOption) Equal

func (m *HeaderValueOption) Equal(that interface{}) bool

Equal function

func (*HeaderValueOption) GetAppend

func (x *HeaderValueOption) GetAppend() *wrapperspb.BoolValue

func (*HeaderValueOption) GetHeader

func (x *HeaderValueOption) GetHeader() *HeaderValue

func (*HeaderValueOption) Hash deprecated added in v1.2.13

func (m *HeaderValueOption) Hash(hasher hash.Hash64) (uint64, error)

Hash function

Deprecated: due to hashing implemention only using field values. The omission of the field name in the hash calculation can lead to hash collisions. Prefer the HashUnique function instead.

func (*HeaderValueOption) HashUnique

func (m *HeaderValueOption) HashUnique(hasher hash.Hash64) (uint64, error)

HashUnique function generates a hash of the object that is unique to the object by hashing field name and value pairs. Replaces Hash due to original hashing implemention only using field values. The omission of the field name in the hash calculation can lead to hash collisions.

func (*HeaderValueOption) ProtoMessage

func (*HeaderValueOption) ProtoMessage()

func (*HeaderValueOption) ProtoReflect added in v1.6.0

func (x *HeaderValueOption) ProtoReflect() protoreflect.Message

func (*HeaderValueOption) Reset

func (x *HeaderValueOption) Reset()

func (*HeaderValueOption) String

func (x *HeaderValueOption) String() string

Jump to

Keyboard shortcuts

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