4 ms·
How can you test this or other serverless apps? Is it possible to run a local env that replicates AWS?
by fabricexpert 7y ago
How can you test this or other serverless apps? Is it possible to run a local env that replicates AWS?
- Hortinstein 7y agoI was wondering this too a few years back when serverless started to gain traction. I remember thinking it sounded like a lot of mock infrastructure. Just did a search and found the following links interesting: https://medium.freecodecamp.org/the-best-ways-to-test-your-serverless-applications-40b88d6ee31e https://medium.freecodecamp.org/the-best-ways-to-test-your-s... https://github.com/lambci/docker-lambda https://github.com/lambci/docker-lambda It seems non-trivial to set up at this point EDIT: Still reading into it... https://serverless.com/framework/docs/providers/aws/guide/testing/ https://serverless.com/framework/docs/providers/aws/guide/te... Would love to here a best practice case study from someone who has deployed something like this
- ac360 7y agoWe've been building serverless application dev tools for ~4 years now. In the process, we've seen incredible efforts to emulate the cloud locally. The result is usually the same: it requires tons of effort, the work is often brittle, and it still is not identical to how your app will perform in the real cloud environment (e.g. you deploy and immediately run into an API limit error). Further, the reason developers mostly want local emulation is because deploying to the cloud is simpler too darn slow. Given this experience, our hypothesis is if we can greatly increase the speed of deployment, developers will be less interested in local emulation. With Serverless Components, we're now achieving incredible results. First deployment always takes a bit longer due to initial creation of resources, some of which are global (e.g. AWS IAM), but all Serverless Components are designed to deploy as fast as possible and we're aiming for ~5s max in deployment time as our key metric. We'll go into detail later about how we've been able to optimize this.