ext_procv3

package
v1.33.0-20240424200609... Latest Latest
Warning

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

Go to latest
Published: unknown License: Apache-2.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ProcessingMode_HeaderSendMode_name = map[int32]string{
		0: "DEFAULT",
		1: "SEND",
		2: "SKIP",
	}
	ProcessingMode_HeaderSendMode_value = map[string]int32{
		"DEFAULT": 0,
		"SEND":    1,
		"SKIP":    2,
	}
)

Enum value maps for ProcessingMode_HeaderSendMode.

View Source
var (
	ProcessingMode_BodySendMode_name = map[int32]string{
		0: "NONE",
		1: "STREAMED",
		2: "BUFFERED",
		3: "BUFFERED_PARTIAL",
	}
	ProcessingMode_BodySendMode_value = map[string]int32{
		"NONE":             0,
		"STREAMED":         1,
		"BUFFERED":         2,
		"BUFFERED_PARTIAL": 3,
	}
)

Enum value maps for ProcessingMode_BodySendMode.

View Source
var File_envoy_extensions_filters_http_ext_proc_v3_ext_proc_proto protoreflect.FileDescriptor
View Source
var File_envoy_extensions_filters_http_ext_proc_v3_processing_mode_proto protoreflect.FileDescriptor

Functions

This section is empty.

Types

type ExtProcOverrides

type ExtProcOverrides struct {

	// Set a different processing mode for this route than the default.
	ProcessingMode *ProcessingMode `protobuf:"bytes,1,opt,name=processing_mode,json=processingMode,proto3" json:"processing_mode,omitempty"`
	// [#not-implemented-hide:]
	// Set a different asynchronous processing option than the default.
	AsyncMode bool `protobuf:"varint,2,opt,name=async_mode,json=asyncMode,proto3" json:"async_mode,omitempty"`
	// [#not-implemented-hide:]
	// Set different optional attributes than the default setting of the
	// “request_attributes“ field.
	RequestAttributes []string `protobuf:"bytes,3,rep,name=request_attributes,json=requestAttributes,proto3" json:"request_attributes,omitempty"`
	// [#not-implemented-hide:]
	// Set different optional properties than the default setting of the
	// “response_attributes“ field.
	ResponseAttributes []string `protobuf:"bytes,4,rep,name=response_attributes,json=responseAttributes,proto3" json:"response_attributes,omitempty"`
	// Set a different gRPC service for this route than the default.
	GrpcService *v3.GrpcService `protobuf:"bytes,5,opt,name=grpc_service,json=grpcService,proto3" json:"grpc_service,omitempty"`
	// Options related to the sending and receiving of dynamic metadata.
	// Lists of forwarding and receiving namespaces will be overridden in their entirety,
	// meaning the most-specific config that specifies this override will be the final
	// config used. It is the prerogative of the control plane to ensure this
	// most-specific config contains the correct final overrides.
	MetadataOptions *MetadataOptions `protobuf:"bytes,6,opt,name=metadata_options,json=metadataOptions,proto3" json:"metadata_options,omitempty"`
	// Additional metadata to include into streams initiated to the ext_proc gRPC
	// service. This can be used for scenarios in which additional ad hoc
	// authorization headers (e.g. “x-foo-bar: baz-key“) are to be injected or
	// when a route needs to partially override inherited metadata.
	GrpcInitialMetadata []*v3.HeaderValue `protobuf:"bytes,7,rep,name=grpc_initial_metadata,json=grpcInitialMetadata,proto3" json:"grpc_initial_metadata,omitempty"`
	// contains filtered or unexported fields
}

Overrides that may be set on a per-route basis [#next-free-field: 8]

func (*ExtProcOverrides) Descriptor deprecated

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

Deprecated: Use ExtProcOverrides.ProtoReflect.Descriptor instead.

func (*ExtProcOverrides) GetAsyncMode

func (x *ExtProcOverrides) GetAsyncMode() bool

func (*ExtProcOverrides) GetGrpcInitialMetadata

func (x *ExtProcOverrides) GetGrpcInitialMetadata() []*v3.HeaderValue

func (*ExtProcOverrides) GetGrpcService

func (x *ExtProcOverrides) GetGrpcService() *v3.GrpcService

func (*ExtProcOverrides) GetMetadataOptions

func (x *ExtProcOverrides) GetMetadataOptions() *MetadataOptions

func (*ExtProcOverrides) GetProcessingMode

func (x *ExtProcOverrides) GetProcessingMode() *ProcessingMode

func (*ExtProcOverrides) GetRequestAttributes

func (x *ExtProcOverrides) GetRequestAttributes() []string

func (*ExtProcOverrides) GetResponseAttributes

func (x *ExtProcOverrides) GetResponseAttributes() []string

func (*ExtProcOverrides) ProtoMessage

func (*ExtProcOverrides) ProtoMessage()

func (*ExtProcOverrides) ProtoReflect

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

func (*ExtProcOverrides) Reset

func (x *ExtProcOverrides) Reset()

func (*ExtProcOverrides) String

func (x *ExtProcOverrides) String() string

type ExtProcPerRoute

type ExtProcPerRoute struct {

	// Types that are assignable to Override:
	//
	//	*ExtProcPerRoute_Disabled
	//	*ExtProcPerRoute_Overrides
	Override isExtProcPerRoute_Override `protobuf_oneof:"override"`
	// contains filtered or unexported fields
}

Extra settings that may be added to per-route configuration for a virtual host or cluster.

func (*ExtProcPerRoute) Descriptor deprecated

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

Deprecated: Use ExtProcPerRoute.ProtoReflect.Descriptor instead.

func (*ExtProcPerRoute) GetDisabled

func (x *ExtProcPerRoute) GetDisabled() bool

func (*ExtProcPerRoute) GetOverride

func (m *ExtProcPerRoute) GetOverride() isExtProcPerRoute_Override

func (*ExtProcPerRoute) GetOverrides

func (x *ExtProcPerRoute) GetOverrides() *ExtProcOverrides

func (*ExtProcPerRoute) ProtoMessage

func (*ExtProcPerRoute) ProtoMessage()

func (*ExtProcPerRoute) ProtoReflect

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

func (*ExtProcPerRoute) Reset

func (x *ExtProcPerRoute) Reset()

func (*ExtProcPerRoute) String

func (x *ExtProcPerRoute) String() string

type ExtProcPerRoute_Disabled

type ExtProcPerRoute_Disabled struct {
	// Disable the filter for this particular vhost or route.
	// If disabled is specified in multiple per-filter-configs, the most specific one will be used.
	Disabled bool `protobuf:"varint,1,opt,name=disabled,proto3,oneof"`
}

type ExtProcPerRoute_Overrides

type ExtProcPerRoute_Overrides struct {
	// Override aspects of the configuration for this route. A set of
	// overrides in a more specific configuration will override a "disabled"
	// flag set in a less-specific one.
	Overrides *ExtProcOverrides `protobuf:"bytes,2,opt,name=overrides,proto3,oneof"`
}

type ExternalProcessor

type ExternalProcessor struct {

	// Configuration for the gRPC service that the filter will communicate with.
	// The filter supports both the "Envoy" and "Google" gRPC clients.
	GrpcService *v3.GrpcService `protobuf:"bytes,1,opt,name=grpc_service,json=grpcService,proto3" json:"grpc_service,omitempty"`
	// By default, if the gRPC stream cannot be established, or if it is closed
	// prematurely with an error, the filter will fail. Specifically, if the
	// response headers have not yet been delivered, then it will return a 500
	// error downstream. If they have been delivered, then instead the HTTP stream to the
	// downstream client will be reset.
	// With this parameter set to true, however, then if the gRPC stream is prematurely closed
	// or could not be opened, processing continues without error.
	FailureModeAllow bool `protobuf:"varint,2,opt,name=failure_mode_allow,json=failureModeAllow,proto3" json:"failure_mode_allow,omitempty"`
	// Specifies default options for how HTTP headers, trailers, and bodies are
	// sent. See ProcessingMode for details.
	ProcessingMode *ProcessingMode `protobuf:"bytes,3,opt,name=processing_mode,json=processingMode,proto3" json:"processing_mode,omitempty"`
	// Envoy provides a number of :ref:`attributes <arch_overview_attributes>`
	// for expressive policies. Each attribute name provided in this field will be
	// matched against that list and populated in the request_headers message.
	// See the :ref:`attribute documentation <arch_overview_request_attributes>`
	// for the list of supported attributes and their types.
	RequestAttributes []string `protobuf:"bytes,5,rep,name=request_attributes,json=requestAttributes,proto3" json:"request_attributes,omitempty"`
	// Envoy provides a number of :ref:`attributes <arch_overview_attributes>`
	// for expressive policies. Each attribute name provided in this field will be
	// matched against that list and populated in the response_headers message.
	// See the :ref:`attribute documentation <arch_overview_attributes>`
	// for the list of supported attributes and their types.
	ResponseAttributes []string `protobuf:"bytes,6,rep,name=response_attributes,json=responseAttributes,proto3" json:"response_attributes,omitempty"`
	// Specifies the timeout for each individual message sent on the stream and
	// when the filter is running in synchronous mode. Whenever the proxy sends
	// a message on the stream that requires a response, it will reset this timer,
	// and will stop processing and return an error (subject to the processing mode)
	// if the timer expires before a matching response is received. There is no
	// timeout when the filter is running in asynchronous mode. Zero is a valid
	// config which means the timer will be triggered immediately. If not
	// configured, default is 200 milliseconds.
	MessageTimeout *durationpb.Duration `protobuf:"bytes,7,opt,name=message_timeout,json=messageTimeout,proto3" json:"message_timeout,omitempty"`
	// Optional additional prefix to use when emitting statistics. This allows to distinguish
	// emitted statistics between configured *ext_proc* filters in an HTTP filter chain.
	StatPrefix string `protobuf:"bytes,8,opt,name=stat_prefix,json=statPrefix,proto3" json:"stat_prefix,omitempty"`
	// Rules that determine what modifications an external processing server may
	// make to message headers. If not set, all headers may be modified except
	// for "host", ":authority", ":scheme", ":method", and headers that start
	// with the header prefix set via
	// :ref:`header_prefix <envoy_v3_api_field_config.bootstrap.v3.Bootstrap.header_prefix>`
	// (which is usually "x-envoy").
	// Note that changing headers such as "host" or ":authority" may not in itself
	// change Envoy's routing decision, as routes can be cached. To also force the
	// route to be recomputed, set the
	// :ref:`clear_route_cache <envoy_v3_api_field_service.ext_proc.v3.CommonResponse.clear_route_cache>`
	// field to true in the same response.
	MutationRules *v31.HeaderMutationRules `protobuf:"bytes,9,opt,name=mutation_rules,json=mutationRules,proto3" json:"mutation_rules,omitempty"`
	// Specify the upper bound of
	// :ref:`override_message_timeout <envoy_v3_api_field_service.ext_proc.v3.ProcessingResponse.override_message_timeout>`
	// If not specified, by default it is 0, which will effectively disable the “override_message_timeout“ API.
	MaxMessageTimeout *durationpb.Duration `protobuf:"bytes,10,opt,name=max_message_timeout,json=maxMessageTimeout,proto3" json:"max_message_timeout,omitempty"`
	// Prevents clearing the route-cache when the
	// :ref:`clear_route_cache <envoy_v3_api_field_service.ext_proc.v3.CommonResponse.clear_route_cache>`
	// field is set in an external processor response.
	DisableClearRouteCache bool `` /* 133-byte string literal not displayed */
	// Allow headers matching the “forward_rules“ to be forwarded to the external processing server.
	// If not set, all headers are forwarded to the external processing server.
	ForwardRules *HeaderForwardingRules `protobuf:"bytes,12,opt,name=forward_rules,json=forwardRules,proto3" json:"forward_rules,omitempty"`
	// Additional metadata to be added to the filter state for logging purposes. The metadata
	// will be added to StreamInfo's filter state under the namespace corresponding to the
	// ext_proc filter name.
	FilterMetadata *structpb.Struct `protobuf:"bytes,13,opt,name=filter_metadata,json=filterMetadata,proto3" json:"filter_metadata,omitempty"`
	// If “allow_mode_override“ is set to true, the filter config :ref:`processing_mode
	// <envoy_v3_api_field_extensions.filters.http.ext_proc.v3.ExternalProcessor.processing_mode>`
	// can be overridden by the response message from the external processing server
	// :ref:`mode_override <envoy_v3_api_field_service.ext_proc.v3.ProcessingResponse.mode_override>`.
	// If not set, “mode_override“ API in the response message will be ignored.
	AllowModeOverride bool `protobuf:"varint,14,opt,name=allow_mode_override,json=allowModeOverride,proto3" json:"allow_mode_override,omitempty"`
	// If set to true, ignore the
	// :ref:`immediate_response <envoy_v3_api_field_service.ext_proc.v3.ProcessingResponse.immediate_response>`
	// message in an external processor response. In such case, no local reply will be sent.
	// Instead, the stream to the external processor will be closed. There will be no
	// more external processing for this stream from now on.
	DisableImmediateResponse bool `` /* 137-byte string literal not displayed */
	// Options related to the sending and receiving of dynamic metadata.
	MetadataOptions *MetadataOptions `protobuf:"bytes,16,opt,name=metadata_options,json=metadataOptions,proto3" json:"metadata_options,omitempty"`
	// If true, send each part of the HTTP request or response specified by ProcessingMode
	// without pausing on filter chain iteration. It is "Send and Go" mode that can be used
	// by external processor to observe Envoy data and status. In this mode:
	//
	// 1. Only STREAMED body processing mode is supported and any other body processing modes will be
	// ignored. NONE mode(i.e., skip body processing) will still work as expected.
	//
	// 2. External processor should not send back processing response, as any responses will be ignored.
	// This also means that
	// :ref:`message_timeout <envoy_v3_api_field_extensions.filters.http.ext_proc.v3.ExternalProcessor.message_timeout>`
	// restriction doesn't apply to this mode.
	//
	// 3. External processor may still close the stream to indicate that no more messages are needed.
	//
	// .. warning::
	//
	//	Flow control is necessary mechanism to prevent the fast sender (either downstream client or upstream server)
	//	from overwhelming the external processor when its processing speed is slower.
	//	This protective measure is being explored and developed but has not been ready yet, so please use your own
	//	discretion when enabling this feature.
	//	This work is currently tracked under https://github.com/envoyproxy/envoy/issues/33319.
	ObservabilityMode bool `protobuf:"varint,17,opt,name=observability_mode,json=observabilityMode,proto3" json:"observability_mode,omitempty"`
	// contains filtered or unexported fields
}

The filter communicates with an external gRPC service called an "external processor" that can do a variety of things with the request and response:

* Access and modify the HTTP headers on the request, response, or both * Access and modify the HTTP request and response bodies * Access and modify the dynamic stream metadata * Immediately send an HTTP response downstream and terminate other processing

The filter communicates with the server using a gRPC bidirectional stream. After the initial request, the external server is in control over what additional data is sent to it and how it should be processed.

By implementing the protocol specified by the stream, the external server can choose:

  • Whether it receives the response message at all
  • Whether it receives the message body at all, in separate chunks, or as a single buffer
  • Whether subsequent HTTP requests are transmitted synchronously or whether they are sent asynchronously.
  • To modify request or response trailers if they already exist

The filter supports up to six different processing steps. Each is represented by a gRPC stream message that is sent to the external processor. For each message, the processor must send a matching response.

  • Request headers: Contains the headers from the original HTTP request.
  • Request body: Delivered if they are present and sent in a single message if the BUFFERED or BUFFERED_PARTIAL mode is chosen, in multiple messages if the STREAMED mode is chosen, and not at all otherwise.
  • Request trailers: Delivered if they are present and if the trailer mode is set to SEND.
  • Response headers: Contains the headers from the HTTP response. Keep in mind that if the upstream system sends them before processing the request body that this message may arrive before the complete body.
  • Response body: Sent according to the processing mode like the request body.
  • Response trailers: Delivered according to the processing mode like the request trailers.

By default, the processor sends only the request and response headers messages. This may be changed to include any of the six steps by changing the processing_mode setting of the filter configuration, or by setting the mode_override of any response from the external processor. The latter is only enabled if allow_mode_override is set to true. This way, a processor may, for example, use information in the request header to determine whether the message body must be examined, or whether the proxy should simply stream it straight through.

All of this together allows a server to process the filter traffic in fairly sophisticated ways. For example:

  • A server may choose to examine all or part of the HTTP message bodies depending on the content of the headers.
  • A server may choose to immediately reject some messages based on their HTTP headers (or other dynamic metadata) and more carefully examine others.
  • A server may asynchronously monitor traffic coming through the filter by inspecting headers, bodies, or both, and then decide to switch to a synchronous processing mode, either permanently or temporarily.

The protocol itself is based on a bidirectional gRPC stream. Envoy will send the server :ref:`ProcessingRequest <envoy_v3_api_msg_service.ext_proc.v3.ProcessingRequest>` messages, and the server must reply with :ref:`ProcessingResponse <envoy_v3_api_msg_service.ext_proc.v3.ProcessingResponse>`.

Stats about each gRPC call are recorded in a :ref:`dynamic filter state <arch_overview_advanced_filter_state_sharing>` object in a namespace matching the filter name.

[#next-free-field: 18]

func (*ExternalProcessor) Descriptor deprecated

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

Deprecated: Use ExternalProcessor.ProtoReflect.Descriptor instead.

func (*ExternalProcessor) GetAllowModeOverride

func (x *ExternalProcessor) GetAllowModeOverride() bool

func (*ExternalProcessor) GetDisableClearRouteCache

func (x *ExternalProcessor) GetDisableClearRouteCache() bool

func (*ExternalProcessor) GetDisableImmediateResponse

func (x *ExternalProcessor) GetDisableImmediateResponse() bool

func (*ExternalProcessor) GetFailureModeAllow

func (x *ExternalProcessor) GetFailureModeAllow() bool

func (*ExternalProcessor) GetFilterMetadata

func (x *ExternalProcessor) GetFilterMetadata() *structpb.Struct

func (*ExternalProcessor) GetForwardRules

func (x *ExternalProcessor) GetForwardRules() *HeaderForwardingRules

func (*ExternalProcessor) GetGrpcService

func (x *ExternalProcessor) GetGrpcService() *v3.GrpcService

func (*ExternalProcessor) GetMaxMessageTimeout

func (x *ExternalProcessor) GetMaxMessageTimeout() *durationpb.Duration

func (*ExternalProcessor) GetMessageTimeout

func (x *ExternalProcessor) GetMessageTimeout() *durationpb.Duration

func (*ExternalProcessor) GetMetadataOptions

func (x *ExternalProcessor) GetMetadataOptions() *MetadataOptions

func (*ExternalProcessor) GetMutationRules

func (x *ExternalProcessor) GetMutationRules() *v31.HeaderMutationRules

func (*ExternalProcessor) GetObservabilityMode

func (x *ExternalProcessor) GetObservabilityMode() bool

func (*ExternalProcessor) GetProcessingMode

func (x *ExternalProcessor) GetProcessingMode() *ProcessingMode

func (*ExternalProcessor) GetRequestAttributes

func (x *ExternalProcessor) GetRequestAttributes() []string

func (*ExternalProcessor) GetResponseAttributes

func (x *ExternalProcessor) GetResponseAttributes() []string

func (*ExternalProcessor) GetStatPrefix

func (x *ExternalProcessor) GetStatPrefix() string

func (*ExternalProcessor) ProtoMessage

func (*ExternalProcessor) ProtoMessage()

func (*ExternalProcessor) ProtoReflect

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

func (*ExternalProcessor) Reset

func (x *ExternalProcessor) Reset()

func (*ExternalProcessor) String

func (x *ExternalProcessor) String() string

type HeaderForwardingRules

type HeaderForwardingRules struct {

	// If set, specifically allow any header in this list to be forwarded to the external
	// processing server. This can be overridden by the below “disallowed_headers“.
	AllowedHeaders *v32.ListStringMatcher `protobuf:"bytes,1,opt,name=allowed_headers,json=allowedHeaders,proto3" json:"allowed_headers,omitempty"`
	// If set, specifically disallow any header in this list to be forwarded to the external
	// processing server. This overrides the above “allowed_headers“ if a header matches both.
	DisallowedHeaders *v32.ListStringMatcher `protobuf:"bytes,2,opt,name=disallowed_headers,json=disallowedHeaders,proto3" json:"disallowed_headers,omitempty"`
	// contains filtered or unexported fields
}

The HeaderForwardingRules structure specifies what headers are allowed to be forwarded to the external processing server.

This works as below:

  1. If neither “allowed_headers“ nor “disallowed_headers“ is set, all headers are forwarded.
  2. If both “allowed_headers“ and “disallowed_headers“ are set, only headers in the “allowed_headers“ but not in the “disallowed_headers“ are forwarded.
  3. If “allowed_headers“ is set, and “disallowed_headers“ is not set, only headers in the “allowed_headers“ are forwarded.
  4. If “disallowed_headers“ is set, and “allowed_headers“ is not set, all headers except headers in the “disallowed_headers“ are forwarded.

func (*HeaderForwardingRules) Descriptor deprecated

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

Deprecated: Use HeaderForwardingRules.ProtoReflect.Descriptor instead.

func (*HeaderForwardingRules) GetAllowedHeaders

func (x *HeaderForwardingRules) GetAllowedHeaders() *v32.ListStringMatcher

func (*HeaderForwardingRules) GetDisallowedHeaders

func (x *HeaderForwardingRules) GetDisallowedHeaders() *v32.ListStringMatcher

func (*HeaderForwardingRules) ProtoMessage

func (*HeaderForwardingRules) ProtoMessage()

func (*HeaderForwardingRules) ProtoReflect

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

func (*HeaderForwardingRules) Reset

func (x *HeaderForwardingRules) Reset()

func (*HeaderForwardingRules) String

func (x *HeaderForwardingRules) String() string

type MetadataOptions

type MetadataOptions struct {

	// Describes which typed or untyped dynamic metadata namespaces to forward to
	// the external processing server.
	ForwardingNamespaces *MetadataOptions_MetadataNamespaces `protobuf:"bytes,1,opt,name=forwarding_namespaces,json=forwardingNamespaces,proto3" json:"forwarding_namespaces,omitempty"`
	// Describes which typed or untyped dynamic metadata namespaces to accept from
	// the external processing server. Set to empty or leave unset to disallow writing
	// any received dynamic metadata. Receiving of typed metadata is not supported.
	ReceivingNamespaces *MetadataOptions_MetadataNamespaces `protobuf:"bytes,2,opt,name=receiving_namespaces,json=receivingNamespaces,proto3" json:"receiving_namespaces,omitempty"`
	// contains filtered or unexported fields
}

The MetadataOptions structure defines options for the sending and receiving of dynamic metadata. Specifically, which namespaces to send to the server, whether metadata returned by the server may be written, and how that metadata may be written.

func (*MetadataOptions) Descriptor deprecated

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

Deprecated: Use MetadataOptions.ProtoReflect.Descriptor instead.

func (*MetadataOptions) GetForwardingNamespaces

func (x *MetadataOptions) GetForwardingNamespaces() *MetadataOptions_MetadataNamespaces

func (*MetadataOptions) GetReceivingNamespaces

func (x *MetadataOptions) GetReceivingNamespaces() *MetadataOptions_MetadataNamespaces

func (*MetadataOptions) ProtoMessage

func (*MetadataOptions) ProtoMessage()

func (*MetadataOptions) ProtoReflect

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

func (*MetadataOptions) Reset

func (x *MetadataOptions) Reset()

func (*MetadataOptions) String

func (x *MetadataOptions) String() string

type MetadataOptions_MetadataNamespaces

type MetadataOptions_MetadataNamespaces struct {

	// Specifies a list of metadata namespaces whose values, if present,
	// will be passed to the ext_proc service as an opaque *protobuf::Struct*.
	Untyped []string `protobuf:"bytes,1,rep,name=untyped,proto3" json:"untyped,omitempty"`
	// Specifies a list of metadata namespaces whose values, if present,
	// will be passed to the ext_proc service as a *protobuf::Any*. This allows
	// envoy and the external processing server to share the protobuf message
	// definition for safe parsing.
	Typed []string `protobuf:"bytes,2,rep,name=typed,proto3" json:"typed,omitempty"`
	// contains filtered or unexported fields
}

func (*MetadataOptions_MetadataNamespaces) Descriptor deprecated

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

Deprecated: Use MetadataOptions_MetadataNamespaces.ProtoReflect.Descriptor instead.

func (*MetadataOptions_MetadataNamespaces) GetTyped

func (*MetadataOptions_MetadataNamespaces) GetUntyped

func (x *MetadataOptions_MetadataNamespaces) GetUntyped() []string

func (*MetadataOptions_MetadataNamespaces) ProtoMessage

func (*MetadataOptions_MetadataNamespaces) ProtoMessage()

func (*MetadataOptions_MetadataNamespaces) ProtoReflect

func (*MetadataOptions_MetadataNamespaces) Reset

func (*MetadataOptions_MetadataNamespaces) String

type ProcessingMode

type ProcessingMode struct {

	// How to handle the request header. Default is "SEND".
	RequestHeaderMode ProcessingMode_HeaderSendMode `` /* 192-byte string literal not displayed */
	// How to handle the response header. Default is "SEND".
	ResponseHeaderMode ProcessingMode_HeaderSendMode `` /* 195-byte string literal not displayed */
	// How to handle the request body. Default is "NONE".
	RequestBodyMode ProcessingMode_BodySendMode `` /* 184-byte string literal not displayed */
	// How do handle the response body. Default is "NONE".
	ResponseBodyMode ProcessingMode_BodySendMode `` /* 187-byte string literal not displayed */
	// How to handle the request trailers. Default is "SKIP".
	RequestTrailerMode ProcessingMode_HeaderSendMode `` /* 195-byte string literal not displayed */
	// How to handle the response trailers. Default is "SKIP".
	ResponseTrailerMode ProcessingMode_HeaderSendMode `` /* 198-byte string literal not displayed */
	// contains filtered or unexported fields
}

[#next-free-field: 7]

func (*ProcessingMode) Descriptor deprecated

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

Deprecated: Use ProcessingMode.ProtoReflect.Descriptor instead.

func (*ProcessingMode) GetRequestBodyMode

func (x *ProcessingMode) GetRequestBodyMode() ProcessingMode_BodySendMode

func (*ProcessingMode) GetRequestHeaderMode

func (x *ProcessingMode) GetRequestHeaderMode() ProcessingMode_HeaderSendMode

func (*ProcessingMode) GetRequestTrailerMode

func (x *ProcessingMode) GetRequestTrailerMode() ProcessingMode_HeaderSendMode

func (*ProcessingMode) GetResponseBodyMode

func (x *ProcessingMode) GetResponseBodyMode() ProcessingMode_BodySendMode

func (*ProcessingMode) GetResponseHeaderMode

func (x *ProcessingMode) GetResponseHeaderMode() ProcessingMode_HeaderSendMode

func (*ProcessingMode) GetResponseTrailerMode

func (x *ProcessingMode) GetResponseTrailerMode() ProcessingMode_HeaderSendMode

func (*ProcessingMode) ProtoMessage

func (*ProcessingMode) ProtoMessage()

func (*ProcessingMode) ProtoReflect

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

func (*ProcessingMode) Reset

func (x *ProcessingMode) Reset()

func (*ProcessingMode) String

func (x *ProcessingMode) String() string

type ProcessingMode_BodySendMode

type ProcessingMode_BodySendMode int32

Control how the request and response bodies are handled When body mutation by external processor is enabled, ext_proc filter will always remove the content length header in three cases below because content length can not be guaranteed to be set correctly: 1) STREAMED BodySendMode: header processing completes before body mutation comes back. 2) BUFFERED_PARTIAL BodySendMode: body is buffered and could be injected in different phases. 3) BUFFERED BodySendMode + SKIP HeaderSendMode: header processing (e.g., update content-length) is skipped.

In Envoy's http1 codec implementation, removing content length will enable chunked transfer encoding whenever feasible. The recipient (either client or server) must be able to parse and decode the chunked transfer coding. (see `details in RFC9112 <https://tools.ietf.org/html/rfc9112#section-7.1>`_).

In BUFFERED BodySendMode + SEND HeaderSendMode, content length header is allowed but it is external processor's responsibility to set the content length correctly matched to the length of mutated body. If they don't match, the corresponding body mutation will be rejected and local reply will be sent with an error message.

const (
	// Do not send the body at all. This is the default.
	ProcessingMode_NONE ProcessingMode_BodySendMode = 0
	// Stream the body to the server in pieces as they arrive at the
	// proxy.
	ProcessingMode_STREAMED ProcessingMode_BodySendMode = 1
	// Buffer the message body in memory and send the entire body at once.
	// If the body exceeds the configured buffer limit, then the
	// downstream system will receive an error.
	ProcessingMode_BUFFERED ProcessingMode_BodySendMode = 2
	// Buffer the message body in memory and send the entire body in one
	// chunk. If the body exceeds the configured buffer limit, then the body contents
	// up to the buffer limit will be sent.
	ProcessingMode_BUFFERED_PARTIAL ProcessingMode_BodySendMode = 3
)

func (ProcessingMode_BodySendMode) Descriptor

func (ProcessingMode_BodySendMode) Enum

func (ProcessingMode_BodySendMode) EnumDescriptor deprecated

func (ProcessingMode_BodySendMode) EnumDescriptor() ([]byte, []int)

Deprecated: Use ProcessingMode_BodySendMode.Descriptor instead.

func (ProcessingMode_BodySendMode) Number

func (ProcessingMode_BodySendMode) String

func (ProcessingMode_BodySendMode) Type

type ProcessingMode_HeaderSendMode

type ProcessingMode_HeaderSendMode int32

Control how headers and trailers are handled

const (
	// The default HeaderSendMode depends on which part of the message is being
	// processed. By default, request and response headers are sent,
	// while trailers are skipped.
	ProcessingMode_DEFAULT ProcessingMode_HeaderSendMode = 0
	// Send the header or trailer.
	ProcessingMode_SEND ProcessingMode_HeaderSendMode = 1
	// Do not send the header or trailer.
	ProcessingMode_SKIP ProcessingMode_HeaderSendMode = 2
)

func (ProcessingMode_HeaderSendMode) Descriptor

func (ProcessingMode_HeaderSendMode) Enum

func (ProcessingMode_HeaderSendMode) EnumDescriptor deprecated

func (ProcessingMode_HeaderSendMode) EnumDescriptor() ([]byte, []int)

Deprecated: Use ProcessingMode_HeaderSendMode.Descriptor instead.

func (ProcessingMode_HeaderSendMode) Number

func (ProcessingMode_HeaderSendMode) String

func (ProcessingMode_HeaderSendMode) Type

Jump to

Keyboard shortcuts

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