Documentation
¶
Index ¶
Constants ¶
View Source
const MaxLambdaRetries = 3
MaxLambdaRetries is the number of times to try invoking a function before giving up and returning an error
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type FunctionConfig ¶
type FunctionConfig struct {
FunctionDeployment
Name string
RoleARN string
Timeout int64
MemorySize int64
CacheConfigInjector api.CacheConfigInjector
S3Key string
S3Bucket string
CodeHash string
// contains filtered or unexported fields
}
FunctionConfig holds the configuration of an individual Lambda function
func (*FunctionConfig) NeedsUpdate ¶
func (d *FunctionConfig) NeedsUpdate(cfg *lambda.FunctionConfiguration) bool
func (*FunctionConfig) Package ¶
func (d *FunctionConfig) Package() error
func (*FunctionConfig) Prepare ¶
func (d *FunctionConfig) Prepare() (*lambda.FunctionCode, error)
type FunctionDeployment ¶
type FunctionDeployment interface {
Package() error
NeedsUpdate(cfg *lambda.FunctionConfiguration) bool
Prepare() (*lambda.FunctionCode, error)
}
Wrapping Package generation and deployment-prepration into an interface for mocking and extension
type LambdaCacheConfigInjector ¶
type LambdaCacheConfigInjector interface {
api.CacheConfigInjector
ConfigureLambda(*lambda.CreateFunctionInput) error
}
type LambdaClient ¶
type LambdaClient struct {
Client lambdaiface.LambdaAPI
Polling api.PollingStrategy
}
LambdaClient wraps the AWS Lambda API and provides functions for deploying and invoking lambda functions
func NewLambdaClient ¶
func NewLambdaClient() *LambdaClient
NewLambdaClient initializes a new LambdaClient
func (*LambdaClient) DeleteFunction ¶
func (l *LambdaClient) DeleteFunction(functionName string) error
DeleteFunction tears down the given function
func (*LambdaClient) DeployFunction ¶
func (l *LambdaClient) DeployFunction(function *FunctionConfig) error
DeployFunction deploys the current directory as a lamba function
Click to show internal directories.
Click to hide internal directories.