https://github.com/nideveloper/cdk-lambda-powertuner
A simple CDK wrapper for the AWS Lambda Powertuner step function
https://github.com/nideveloper/cdk-lambda-powertuner
Last synced: about 1 year ago
JSON representation
A simple CDK wrapper for the AWS Lambda Powertuner step function
- Host: GitHub
- URL: https://github.com/nideveloper/cdk-lambda-powertuner
- Owner: nideveloper
- License: apache-2.0
- Created: 2020-05-06T15:45:01.000Z (about 6 years ago)
- Default Branch: master
- Last Pushed: 2023-01-06T05:16:36.000Z (over 3 years ago)
- Last Synced: 2024-12-06T19:15:33.179Z (over 1 year ago)
- Language: TypeScript
- Homepage:
- Size: 2.14 MB
- Stars: 5
- Watchers: 2
- Forks: 5
- Open Issues: 13
-
Metadata Files:
- Readme: README.md
- License: LICENSE.txt
Awesome Lists containing this project
README
# CDK Lambda Power Tuner
This is simply a CDK wrapper for the SAM/SAR application - [aws-lambda-power-tuning](https://github.com/alexcasalboni/aws-lambda-power-tuning)
>Note this is an alpha module, it needs thoroughly tested before being production recommended
All of the lambda logic is cloned on build from that source repo with only the stepfunction definition being defined in this project.
This enables you to now do this:

## Deploying the state machine
Import it into any CDK stack and then `cdk deploy`
## Running The Tuner
This is the same as [here](https://github.com/alexcasalboni/aws-lambda-power-tuning#how-to-execute-the-state-machine-web-console)
## Differences from [aws-lambda-power-tuning](https://github.com/alexcasalboni/aws-lambda-power-tuning)
Since this uses AWS CDK to build and deploy the step function, we need to play by the rules of CDK.
The method of integrating Lambda functions as a step into your workflow via ARN has been deprecated by the team.
They have chosen to support integrating via function name. For reference see [issue](https://github.com/aws/aws-cdk/issues/7709)
This means that the payloads coming back from the Lambda functions contain an extra abstraction layer of data not present in the SAR application.
To make this work without rewriting the Lambda functions so that I can always pull the latest code on every build I
had to introduce adapters between the step function Lambda tasks to strip out this abstraction layer. This is their only purpose
