4 ms·
Does Lambda have a good version control or CI workflow? My biggest question is how to develop severless functions with a team of developers.
by everdev 8y ago
Does Lambda have a good version control or CI workflow? My biggest question is how to develop severless functions with a team of developers.
- not_kurt_godel 8y agoYou can utilize lambda traffic shifting in conjunction with CodeDeploy and Code Pipelines to do safe A/B (aka Blue/Green) deployments. It has some rough edges but overall works well. Check out these docs to get started: https://github.com/awslabs/serverless-application-model/blob/a09929bcdd7cd6083d5c344ce5a64208a56bc4a6/docs/safe_lambda_deployments.rst#traffic-shifting-using-codedeploy https://github.com/awslabs/serverless-application-model/blob... It's also possible to use API Gateway canary deployments and dedicated "preprod" stages as well - the benefit being you can, in theory, use traffic shifting lifecycle hooks to deploy a new version completely isolated from customer traffic and test it before incrementally rolling out your main A/B deployment. I created an experimental proof-of-concept for this but haven't had the time to flesh it out for production usage, but would very much like to at some point. tl;dr The answer to your question is yes, there is a good story around CI with Lambda using the AWS ecosystem. However Lambda alone is not something that should be relied on for long-term or definitive versioning on its own. Edit: thinking about your question more, it seems you are assuming that individual developers will directly edit Lambda function code in the console and you want to track versions or trigger deployments based on that activity. You absolutely should not ever be editing Lambda code manually directly in the console outside of one-off experiments/prototypes that are completely unrelated to dev/test/production. Always keep your Lambda function code under source control and deploy using zips uploaded to S3 and CloudFormation (the serverless framework[1] provides good tooling for this, though we don't use it - instead we use SAM and our own internal tools). [1] https://serverless.com/ https://serverless.com/
- mooreds 8y agoThis looks useful: https://github.com/awslabs/serverless-application-model/blob/develop/docs/safe_lambda_deployments.rst https://github.com/awslabs/serverless-application-model/blob...