Documentation
¶
Index ¶
- Variables
- type Config
- func (x *Config) ClearCredentials()
- func (x *Config) GetArn() string
- func (x *Config) GetCredentials() *Credentials
- func (x *Config) GetCredentialsProfile() string
- func (x *Config) GetHostRewrite() string
- func (x *Config) GetInvocationMode() Config_InvocationMode
- func (x *Config) GetPayloadPassthrough() bool
- func (x *Config) HasCredentials() bool
- func (*Config) ProtoMessage()
- func (x *Config) ProtoReflect() protoreflect.Message
- func (x *Config) Reset()
- func (x *Config) SetArn(v string)
- func (x *Config) SetCredentials(v *Credentials)
- func (x *Config) SetCredentialsProfile(v string)
- func (x *Config) SetHostRewrite(v string)
- func (x *Config) SetInvocationMode(v Config_InvocationMode)
- func (x *Config) SetPayloadPassthrough(v bool)
- func (x *Config) String() string
- type Config_InvocationMode
- type Config_builder
- type Credentials
- func (x *Credentials) GetAccessKeyId() string
- func (x *Credentials) GetSecretAccessKey() string
- func (x *Credentials) GetSessionToken() string
- func (*Credentials) ProtoMessage()
- func (x *Credentials) ProtoReflect() protoreflect.Message
- func (x *Credentials) Reset()
- func (x *Credentials) SetAccessKeyId(v string)
- func (x *Credentials) SetSecretAccessKey(v string)
- func (x *Credentials) SetSessionToken(v string)
- func (x *Credentials) String() string
- type Credentials_builder
- type PerRouteConfig
- func (x *PerRouteConfig) ClearInvokeConfig()
- func (x *PerRouteConfig) GetInvokeConfig() *Config
- func (x *PerRouteConfig) HasInvokeConfig() bool
- func (*PerRouteConfig) ProtoMessage()
- func (x *PerRouteConfig) ProtoReflect() protoreflect.Message
- func (x *PerRouteConfig) Reset()
- func (x *PerRouteConfig) SetInvokeConfig(v *Config)
- func (x *PerRouteConfig) String() string
- type PerRouteConfig_builder
Constants ¶
This section is empty.
Variables ¶
View Source
var ( Config_InvocationMode_name = map[int32]string{ 0: "SYNCHRONOUS", 1: "ASYNCHRONOUS", } Config_InvocationMode_value = map[string]int32{ "SYNCHRONOUS": 0, "ASYNCHRONOUS": 1, } )
Enum value maps for Config_InvocationMode.
View Source
var File_envoy_extensions_filters_http_aws_lambda_v3_aws_lambda_proto protoreflect.FileDescriptor
Functions ¶
This section is empty.
Types ¶
type Config ¶
type Config struct {
// The ARN of the AWS Lambda to invoke when the filter is engaged
// Must be in the following format:
// arn:<partition>:lambda:<region>:<account-number>:function:<function-name>
Arn string `protobuf:"bytes,1,opt,name=arn,proto3" json:"arn,omitempty"`
// Whether to transform the request (headers and body) to a JSON payload or pass it as is.
PayloadPassthrough bool `protobuf:"varint,2,opt,name=payload_passthrough,json=payloadPassthrough,proto3" json:"payload_passthrough,omitempty"`
// Determines the way to invoke the Lambda function.
InvocationMode Config_InvocationMode `` /* 175-byte string literal not displayed */
// Indicates that before signing headers, the host header will be swapped with
// this value. If not set or empty, the original host header value
// will be used and no rewrite will happen.
//
// .. note::
//
// This rewrite affects both signing and host header forwarding. However, this
// option shouldn't be used with
// :ref:`HCM host rewrite <envoy_v3_api_field_config.route.v3.RouteAction.host_rewrite_literal>` given that the
// value set here would be used for signing whereas the value set in the HCM would be used
// for host header forwarding which is not the desired outcome.
//
// Changing the value of the host header can result in a different route to be selected
// if an HTTP filter after AWS lambda re-evaluates the route (clears route cache).
HostRewrite string `protobuf:"bytes,4,opt,name=host_rewrite,json=hostRewrite,proto3" json:"host_rewrite,omitempty"`
// Specifies the credentials profile to be used from the AWS credentials file.
// This parameter is optional. If set, it will override the value set in the AWS_PROFILE env variable and
// the provider chain is limited to the AWS credentials file Provider.
// If credentials configuration is provided, this configuration will be ignored.
// If this field is provided, then the default providers chain specified in the documentation will be ignored.
// (See :ref:`default credentials providers <config_http_filters_aws_lambda_credentials>`).
CredentialsProfile string `protobuf:"bytes,5,opt,name=credentials_profile,json=credentialsProfile,proto3" json:"credentials_profile,omitempty"`
// Specifies the credentials to be used. This parameter is optional and if it is set,
// it will override other providers and will take precedence over credentials_profile.
// The provider chain is limited to the configuration credentials provider.
// If this field is provided, then the default providers chain specified in the documentation will be ignored.
// (See :ref:`default credentials providers <config_http_filters_aws_lambda_credentials>`).
//
// .. warning::
//
// Distributing the AWS credentials via this configuration should not be done in production.
Credentials *Credentials `protobuf:"bytes,6,opt,name=credentials,proto3" json:"credentials,omitempty"`
// contains filtered or unexported fields
}
AWS Lambda filter config [#next-free-field: 7]
func (*Config) GetCredentials ¶
func (x *Config) GetCredentials() *Credentials
func (*Config) GetInvocationMode ¶
func (x *Config) GetInvocationMode() Config_InvocationMode
func (*Config) ProtoReflect ¶
func (x *Config) ProtoReflect() protoreflect.Message
func (*Config) SetCredentials ¶
func (x *Config) SetCredentials(v *Credentials)
func (*Config) SetInvocationMode ¶
func (x *Config) SetInvocationMode(v Config_InvocationMode)
type Config_InvocationMode ¶
type Config_InvocationMode int32
const ( // This is the more common mode of invocation, in which Lambda responds after it has completed the function. In // this mode the output of the Lambda function becomes the response of the HTTP request. Config_SYNCHRONOUS Config_InvocationMode = 0 // In this mode Lambda responds immediately but continues to process the function asynchronously. This mode can be // used to signal events for example. In this mode, Lambda responds with an acknowledgment that it received the // call which is translated to an HTTP 200 OK by the filter. Config_ASYNCHRONOUS Config_InvocationMode = 1 )
func (Config_InvocationMode) Descriptor ¶
func (Config_InvocationMode) Descriptor() protoreflect.EnumDescriptor
func (Config_InvocationMode) Enum ¶
func (x Config_InvocationMode) Enum() *Config_InvocationMode
func (Config_InvocationMode) Number ¶
func (x Config_InvocationMode) Number() protoreflect.EnumNumber
func (Config_InvocationMode) String ¶
func (x Config_InvocationMode) String() string
func (Config_InvocationMode) Type ¶
func (Config_InvocationMode) Type() protoreflect.EnumType
type Config_builder ¶
type Config_builder struct {
// The ARN of the AWS Lambda to invoke when the filter is engaged
// Must be in the following format:
// arn:<partition>:lambda:<region>:<account-number>:function:<function-name>
Arn string
// Whether to transform the request (headers and body) to a JSON payload or pass it as is.
PayloadPassthrough bool
// Determines the way to invoke the Lambda function.
InvocationMode Config_InvocationMode
// Indicates that before signing headers, the host header will be swapped with
// this value. If not set or empty, the original host header value
// will be used and no rewrite will happen.
//
// .. note::
//
// This rewrite affects both signing and host header forwarding. However, this
// option shouldn't be used with
// :ref:`HCM host rewrite <envoy_v3_api_field_config.route.v3.RouteAction.host_rewrite_literal>` given that the
// value set here would be used for signing whereas the value set in the HCM would be used
// for host header forwarding which is not the desired outcome.
//
// Changing the value of the host header can result in a different route to be selected
// if an HTTP filter after AWS lambda re-evaluates the route (clears route cache).
HostRewrite string
// Specifies the credentials profile to be used from the AWS credentials file.
// This parameter is optional. If set, it will override the value set in the AWS_PROFILE env variable and
// the provider chain is limited to the AWS credentials file Provider.
// If credentials configuration is provided, this configuration will be ignored.
// If this field is provided, then the default providers chain specified in the documentation will be ignored.
// (See :ref:`default credentials providers <config_http_filters_aws_lambda_credentials>`).
CredentialsProfile string
// Specifies the credentials to be used. This parameter is optional and if it is set,
// it will override other providers and will take precedence over credentials_profile.
// The provider chain is limited to the configuration credentials provider.
// If this field is provided, then the default providers chain specified in the documentation will be ignored.
// (See :ref:`default credentials providers <config_http_filters_aws_lambda_credentials>`).
//
// .. warning::
//
// Distributing the AWS credentials via this configuration should not be done in production.
Credentials *Credentials
// contains filtered or unexported fields
}
func (Config_builder) Build ¶
func (b0 Config_builder) Build() *Config
type Credentials ¶
type Credentials struct {
// AWS access key id.
AccessKeyId string `protobuf:"bytes,1,opt,name=access_key_id,json=accessKeyId,proto3" json:"access_key_id,omitempty"`
// AWS secret access key.
SecretAccessKey string `protobuf:"bytes,2,opt,name=secret_access_key,json=secretAccessKey,proto3" json:"secret_access_key,omitempty"`
// AWS session token.
// This parameter is optional. If it is set to empty string it will not be consider in the request.
// It is required if temporary security credentials retrieved directly from AWS STS operations are used.
SessionToken string `protobuf:"bytes,3,opt,name=session_token,json=sessionToken,proto3" json:"session_token,omitempty"`
// contains filtered or unexported fields
}
AWS Lambda Credentials config.
func (*Credentials) GetAccessKeyId ¶
func (x *Credentials) GetAccessKeyId() string
func (*Credentials) GetSecretAccessKey ¶
func (x *Credentials) GetSecretAccessKey() string
func (*Credentials) GetSessionToken ¶
func (x *Credentials) GetSessionToken() string
func (*Credentials) ProtoMessage ¶
func (*Credentials) ProtoMessage()
func (*Credentials) ProtoReflect ¶
func (x *Credentials) ProtoReflect() protoreflect.Message
func (*Credentials) Reset ¶
func (x *Credentials) Reset()
func (*Credentials) SetAccessKeyId ¶
func (x *Credentials) SetAccessKeyId(v string)
func (*Credentials) SetSecretAccessKey ¶
func (x *Credentials) SetSecretAccessKey(v string)
func (*Credentials) SetSessionToken ¶
func (x *Credentials) SetSessionToken(v string)
func (*Credentials) String ¶
func (x *Credentials) String() string
type Credentials_builder ¶
type Credentials_builder struct {
// AWS access key id.
AccessKeyId string
// AWS secret access key.
SecretAccessKey string
// AWS session token.
// This parameter is optional. If it is set to empty string it will not be consider in the request.
// It is required if temporary security credentials retrieved directly from AWS STS operations are used.
SessionToken string
// contains filtered or unexported fields
}
func (Credentials_builder) Build ¶
func (b0 Credentials_builder) Build() *Credentials
type PerRouteConfig ¶
type PerRouteConfig struct {
InvokeConfig *Config `protobuf:"bytes,1,opt,name=invoke_config,json=invokeConfig,proto3" json:"invoke_config,omitempty"`
// contains filtered or unexported fields
}
Per-route configuration for AWS Lambda. This can be useful when invoking a different Lambda function or a different version of the same Lambda depending on the route.
func (*PerRouteConfig) ClearInvokeConfig ¶
func (x *PerRouteConfig) ClearInvokeConfig()
func (*PerRouteConfig) GetInvokeConfig ¶
func (x *PerRouteConfig) GetInvokeConfig() *Config
func (*PerRouteConfig) HasInvokeConfig ¶
func (x *PerRouteConfig) HasInvokeConfig() bool
func (*PerRouteConfig) ProtoMessage ¶
func (*PerRouteConfig) ProtoMessage()
func (*PerRouteConfig) ProtoReflect ¶
func (x *PerRouteConfig) ProtoReflect() protoreflect.Message
func (*PerRouteConfig) Reset ¶
func (x *PerRouteConfig) Reset()
func (*PerRouteConfig) SetInvokeConfig ¶
func (x *PerRouteConfig) SetInvokeConfig(v *Config)
func (*PerRouteConfig) String ¶
func (x *PerRouteConfig) String() string
type PerRouteConfig_builder ¶
type PerRouteConfig_builder struct {
InvokeConfig *Config
// contains filtered or unexported fields
}
func (PerRouteConfig_builder) Build ¶
func (b0 PerRouteConfig_builder) Build() *PerRouteConfig
Source Files
¶
- aws_lambda.pb.go
Click to show internal directories.
Click to hide internal directories.