wheelamb

package module
v0.0.0-...-b4dac17 Latest Latest
Warning

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

Go to latest
Published: May 6, 2020 License: MIT Imports: 17 Imported by: 0

README

wheelamb

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type LambdaFunction

type LambdaFunction struct {
	CodeSha256   string
	FunctionName string
	CodeSize     int64
	RevisionID   string `json:"RevisionId"` // use uuid
	MemorySize   int64
	FunctionArn  string
	Version      string // "$LATEST",
	Timeout      int64
	LastModified time.Time
	Handler      string
	Runtime      string
	Description  *string
	// contains filtered or unexported fields
}

LambdaFunction describes lambda function settings. via https://docs.aws.amazon.com/cli/latest/reference/lambda/create-function.html

type LambdaRegistry

type LambdaRegistry struct {
	// contains filtered or unexported fields
}

LambdaRegistry holds lambda function settings in memory.

func NewLambdaRegistry

func NewLambdaRegistry() *LambdaRegistry

NewLambdaRegistry returns LambdaRegistry object.

func (*LambdaRegistry) Get

func (r *LambdaRegistry) Get(name string) *LambdaFunction

Get returns LambdaFucntion object from given name.

func (*LambdaRegistry) GetFromARN

func (r *LambdaRegistry) GetFromARN(arn string) *LambdaFunction

GetFromARN returns LambdaFunction object from given function arn.

func (*LambdaRegistry) Register

func (r *LambdaRegistry) Register(lf *LambdaFunction)

Register sets LambdaFunction into registry.

type LambdaService

type LambdaService struct {
	// contains filtered or unexported fields
}

LambdaService provides interfaces for operationg lambda functions.

func NewLambdaService

func NewLambdaService(docker docker.Docker, dir string, r *LambdaRegistry) *LambdaService

NewLambdaService returns LambdaService object.

func (*LambdaService) Close

func (s *LambdaService) Close() error

Close closes all lambda function containers.

func (*LambdaService) Create

Create creates new lambda function.

func (*LambdaService) InvokeAsync

InvokeAsync invokes lambda function without waiting response.

func (*LambdaService) InvokeSync

func (s *LambdaService) InvokeSync(ctx context.Context, input *lambda.InvokeInput) (*lambda.InvokeOutput, error)

InvokeSync invokes lambda function with waiting response.

type SourceMappingService

type SourceMappingService struct {
	// contains filtered or unexported fields
}

SourceMappingService provides interfaces for operating EventSourceMapping for lambda.

func (*SourceMappingService) CreateEventSourceMapping

func (s *SourceMappingService) CreateEventSourceMapping(ctx context.Context, input *lambda.CreateEventSourceMappingInput) error

CreateEventSourceMapping creates mappings for lambda invokation from sqs or kinesis streams.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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