Documentation ¶
Index ¶
- Variables
- type Lua
- func (*Lua) Descriptor() ([]byte, []int)deprecated
- func (x *Lua) GetDefaultSourceCode() *v3.DataSource
- func (x *Lua) GetInlineCode() stringdeprecated
- func (x *Lua) GetSourceCodes() map[string]*v3.DataSource
- func (x *Lua) GetStatPrefix() string
- func (*Lua) ProtoMessage()
- func (x *Lua) ProtoReflect() protoreflect.Message
- func (x *Lua) Reset()
- func (x *Lua) String() string
- func (m *Lua) Validate() error
- func (m *Lua) ValidateAll() error
- type LuaMultiError
- type LuaPerRoute
- func (*LuaPerRoute) Descriptor() ([]byte, []int)deprecated
- func (x *LuaPerRoute) GetDisabled() bool
- func (x *LuaPerRoute) GetName() string
- func (m *LuaPerRoute) GetOverride() isLuaPerRoute_Override
- func (x *LuaPerRoute) GetSourceCode() *v3.DataSource
- func (*LuaPerRoute) ProtoMessage()
- func (x *LuaPerRoute) ProtoReflect() protoreflect.Message
- func (x *LuaPerRoute) Reset()
- func (x *LuaPerRoute) String() string
- func (m *LuaPerRoute) Validate() error
- func (m *LuaPerRoute) ValidateAll() error
- type LuaPerRouteMultiError
- type LuaPerRouteValidationError
- func (e LuaPerRouteValidationError) Cause() error
- func (e LuaPerRouteValidationError) Error() string
- func (e LuaPerRouteValidationError) ErrorName() string
- func (e LuaPerRouteValidationError) Field() string
- func (e LuaPerRouteValidationError) Key() bool
- func (e LuaPerRouteValidationError) Reason() string
- type LuaPerRoute_Disabled
- type LuaPerRoute_Name
- type LuaPerRoute_SourceCode
- type LuaValidationError
Constants ¶
This section is empty.
Variables ¶
var File_envoy_extensions_filters_http_lua_v3_lua_proto protoreflect.FileDescriptor
Functions ¶
This section is empty.
Types ¶
type Lua ¶
type Lua struct { // The Lua code that Envoy will execute. This can be a very small script that // further loads code from disk if desired. Note that if JSON configuration is used, the code must // be properly escaped. YAML configuration may be easier to read since YAML supports multi-line // strings so complex scripts can be easily expressed inline in the configuration. // // This field is deprecated. Please use // :ref:`default_source_code <envoy_v3_api_field_extensions.filters.http.lua.v3.Lua.default_source_code>`. // Only one of :ref:`inline_code <envoy_v3_api_field_extensions.filters.http.lua.v3.Lua.inline_code>` // or :ref:`default_source_code <envoy_v3_api_field_extensions.filters.http.lua.v3.Lua.default_source_code>` // can be set for the Lua filter. // // Deprecated: Marked as deprecated in envoy/extensions/filters/http/lua/v3/lua.proto. InlineCode string `protobuf:"bytes,1,opt,name=inline_code,json=inlineCode,proto3" json:"inline_code,omitempty"` // Map of named Lua source codes that can be referenced in :ref:`LuaPerRoute // <envoy_v3_api_msg_extensions.filters.http.lua.v3.LuaPerRoute>`. The Lua source codes can be // loaded from inline string or local files. // // Example: // // .. code-block:: yaml // // source_codes: // hello.lua: // inline_string: | // function envoy_on_response(response_handle) // -- Do something. // end // world.lua: // filename: /etc/lua/world.lua // SourceCodes map[string]*v3.DataSource `` /* 182-byte string literal not displayed */ // The default Lua code that Envoy will execute. If no per route config is provided // for the request, this Lua code will be applied. DefaultSourceCode *v3.DataSource `protobuf:"bytes,3,opt,name=default_source_code,json=defaultSourceCode,proto3" json:"default_source_code,omitempty"` // Optional additional prefix to use when emitting statistics. By default // metrics are emitted in *.lua.* namespace. If multiple lua filters are // configured in a filter chain, the stats from each filter instance can // be emitted using custom stat prefix to distinguish emitted // statistics. For example: // // .. code-block:: yaml // // http_filters: // - name: envoy.filters.http.lua // typed_config: // "@type": type.googleapis.com/envoy.extensions.filters.http.lua.v3.Lua // stat_prefix: foo_script # This emits lua.foo_script.errors etc. // - name: envoy.filters.http.lua // typed_config: // "@type": type.googleapis.com/envoy.extensions.filters.http.lua.v3.Lua // stat_prefix: bar_script # This emits lua.bar_script.errors etc. // StatPrefix string `protobuf:"bytes,4,opt,name=stat_prefix,json=statPrefix,proto3" json:"stat_prefix,omitempty"` // contains filtered or unexported fields }
func (*Lua) Descriptor
deprecated
func (*Lua) GetDefaultSourceCode ¶ added in v3.2.0
func (x *Lua) GetDefaultSourceCode() *v3.DataSource
func (*Lua) GetInlineCode
deprecated
func (*Lua) GetSourceCodes ¶
func (x *Lua) GetSourceCodes() map[string]*v3.DataSource
func (*Lua) GetStatPrefix ¶ added in v3.4.0
func (*Lua) ProtoMessage ¶
func (*Lua) ProtoMessage()
func (*Lua) ProtoReflect ¶
func (x *Lua) ProtoReflect() protoreflect.Message
func (*Lua) Validate ¶
Validate checks the field values on Lua with the rules defined in the proto definition for this message. If any rules are violated, the first error encountered is returned, or nil if there are no violations.
func (*Lua) ValidateAll ¶
ValidateAll checks the field values on Lua with the rules defined in the proto definition for this message. If any rules are violated, the result is a list of violation errors wrapped in LuaMultiError, or nil if none found.
type LuaMultiError ¶
type LuaMultiError []error
LuaMultiError is an error wrapping multiple validation errors returned by Lua.ValidateAll() if the designated constraints aren't met.
func (LuaMultiError) AllErrors ¶
func (m LuaMultiError) AllErrors() []error
AllErrors returns a list of validation violation errors.
func (LuaMultiError) Error ¶
func (m LuaMultiError) Error() string
Error returns a concatenation of all the error messages it wraps.
type LuaPerRoute ¶
type LuaPerRoute struct { // Types that are assignable to Override: // *LuaPerRoute_Disabled // *LuaPerRoute_Name // *LuaPerRoute_SourceCode Override isLuaPerRoute_Override `protobuf_oneof:"override"` // contains filtered or unexported fields }
func (*LuaPerRoute) Descriptor
deprecated
func (*LuaPerRoute) Descriptor() ([]byte, []int)
Deprecated: Use LuaPerRoute.ProtoReflect.Descriptor instead.
func (*LuaPerRoute) GetDisabled ¶
func (x *LuaPerRoute) GetDisabled() bool
func (*LuaPerRoute) GetName ¶
func (x *LuaPerRoute) GetName() string
func (*LuaPerRoute) GetOverride ¶
func (m *LuaPerRoute) GetOverride() isLuaPerRoute_Override
func (*LuaPerRoute) GetSourceCode ¶
func (x *LuaPerRoute) GetSourceCode() *v3.DataSource
func (*LuaPerRoute) ProtoMessage ¶
func (*LuaPerRoute) ProtoMessage()
func (*LuaPerRoute) ProtoReflect ¶
func (x *LuaPerRoute) ProtoReflect() protoreflect.Message
func (*LuaPerRoute) Reset ¶
func (x *LuaPerRoute) Reset()
func (*LuaPerRoute) String ¶
func (x *LuaPerRoute) String() string
func (*LuaPerRoute) Validate ¶
func (m *LuaPerRoute) Validate() error
Validate checks the field values on LuaPerRoute with the rules defined in the proto definition for this message. If any rules are violated, the first error encountered is returned, or nil if there are no violations.
func (*LuaPerRoute) ValidateAll ¶
func (m *LuaPerRoute) ValidateAll() error
ValidateAll checks the field values on LuaPerRoute with the rules defined in the proto definition for this message. If any rules are violated, the result is a list of violation errors wrapped in LuaPerRouteMultiError, or nil if none found.
type LuaPerRouteMultiError ¶
type LuaPerRouteMultiError []error
LuaPerRouteMultiError is an error wrapping multiple validation errors returned by LuaPerRoute.ValidateAll() if the designated constraints aren't met.
func (LuaPerRouteMultiError) AllErrors ¶
func (m LuaPerRouteMultiError) AllErrors() []error
AllErrors returns a list of validation violation errors.
func (LuaPerRouteMultiError) Error ¶
func (m LuaPerRouteMultiError) Error() string
Error returns a concatenation of all the error messages it wraps.
type LuaPerRouteValidationError ¶
type LuaPerRouteValidationError struct {
// contains filtered or unexported fields
}
LuaPerRouteValidationError is the validation error returned by LuaPerRoute.Validate if the designated constraints aren't met.
func (LuaPerRouteValidationError) Cause ¶
func (e LuaPerRouteValidationError) Cause() error
Cause function returns cause value.
func (LuaPerRouteValidationError) Error ¶
func (e LuaPerRouteValidationError) Error() string
Error satisfies the builtin error interface
func (LuaPerRouteValidationError) ErrorName ¶
func (e LuaPerRouteValidationError) ErrorName() string
ErrorName returns error name.
func (LuaPerRouteValidationError) Field ¶
func (e LuaPerRouteValidationError) Field() string
Field function returns field value.
func (LuaPerRouteValidationError) Key ¶
func (e LuaPerRouteValidationError) Key() bool
Key function returns key value.
func (LuaPerRouteValidationError) Reason ¶
func (e LuaPerRouteValidationError) Reason() string
Reason function returns reason value.
type LuaPerRoute_Disabled ¶
type LuaPerRoute_Disabled struct { // Disable the Lua 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 LuaPerRoute_Name ¶
type LuaPerRoute_Name struct { // A name of a Lua source code stored in // :ref:`Lua.source_codes <envoy_v3_api_field_extensions.filters.http.lua.v3.Lua.source_codes>`. Name string `protobuf:"bytes,2,opt,name=name,proto3,oneof"` }
type LuaPerRoute_SourceCode ¶
type LuaPerRoute_SourceCode struct { // A configured per-route Lua source code that can be served by RDS or provided inline. SourceCode *v3.DataSource `protobuf:"bytes,3,opt,name=source_code,json=sourceCode,proto3,oneof"` }
type LuaValidationError ¶
type LuaValidationError struct {
// contains filtered or unexported fields
}
LuaValidationError is the validation error returned by Lua.Validate if the designated constraints aren't met.
func (LuaValidationError) Cause ¶
func (e LuaValidationError) Cause() error
Cause function returns cause value.
func (LuaValidationError) Error ¶
func (e LuaValidationError) Error() string
Error satisfies the builtin error interface
func (LuaValidationError) ErrorName ¶
func (e LuaValidationError) ErrorName() string
ErrorName returns error name.
func (LuaValidationError) Field ¶
func (e LuaValidationError) Field() string
Field function returns field value.
func (LuaValidationError) Key ¶
func (e LuaValidationError) Key() bool
Key function returns key value.
func (LuaValidationError) Reason ¶
func (e LuaValidationError) Reason() string
Reason function returns reason value.