The typical deployment workflow comprises one mandatory and two optional phases:
(optional) invoke the function – see the Invoke Function action of the AWS Lambda Function task
This effectively comprises a custom Bamboo task, which allows you to implement arbitrary functionality running in AWS Lambda instead of a dedicated task. |
create an event source mapping – see the Create Event Source Mapping action of the AWS Lambda Event Source Mapping task
Kinesis and DynamoDB streams can create a huge amount of events in a short time, so you might want to create an event source mapping in the Disabled state and update it to Enabled explicitly at a later stage once the deployment is properly tested. |
add appropriate permissions for the AWS resource to invoke the function – see the Add Permission action of the AWS Lambda Function task
As an alternative to using the AWS Lambda tasks built into Tasks for AWS, it is also possible to provision the Lambda components directly via the AWS CloudFormation Stack task and the corresponding CloudFormation resource types:
A typical workflow based on CloudFormation might look as follows: