modulepackage
1.0.1
Repository: https://github.com/auditr-io/lambdahooks-go.git
Documentation: pkg.go.dev
# README
lambdahooks-go
Lambda pre and post execution hooks
# Functions
AddPostHook adds a post hook to be notified after execution.
AddPreHook adds a pre hook to be notified before execution.
Init sets up the hooks before use Overrides defaults as needed.
RemovePostHook removes a post hook.
RemovePreHook removes a pre hook.
Start wraps the handler and starts the AWS lambda handler TODO: do we need this here?.
WithDeadlineCushion overrides the default deadline cushion with given cushion.
WithPostHooks adds a list of post hooks in the order they are provided.
WithPreHooks adds a list of pre hooks in the order they are provided.
WithStarterFunc overrides the default starter function with given function.
Wrap wraps the handler so the agent can intercept and record events Processes the handler according to the lambda rules below: Rules:
* handler must be a function * handler may take between 0 and two arguments.
# Constants
DefaultTimeout is the default timeout limit https://docs.aws.amazon.com/lambda/latest/dg/configuration-console.html.
MaxDeadlineCushion is the timeout limit for deadline cushion.
# Type aliases
Option is an option to override defaults.