Choosing a Computing Method: a Serverless SWOT Analysis

Written by taavi-rehemagi | Published 2022/02/10
Tech Story Tags: serverless | aws-lambda | aws-services | aws-serverless | analysis | observability | monitoring | serverless-architecture

TLDRThis is an attempt to create a decision framework and break down arguments for and against using serverless vs. other computing models. Strengths: Developers only focus on the business logic and that drastically increases development speed and time to market. Weaknesses: It's difficult to test locally and it's hard to navigate debugging data. The benefits outweigh the downsides of serverless, but if you make sure to structure your software right, the benefits greatly outweigh downsides. If you have any feedback, the comment section is all yours!via the TL;DR App

Building a serverless application means you usually trade in old issues for new ones. This is an attempt to create a decision framework and break down arguments for and against using serverless vs. other computing models.

If you ever find yourself deciding for or against serverless, the following tries to make the decision easier for you. Maybe you should save this post for future reference if you find it useful.

Or don't, it's up to you. No seriously, save it.

This is also an open document that I will keep improving in the future.

Strengths

  1. Faster time to market -- The real benefit of serverless is that developers only focus on the business logic and that drastically increases development speed and time to market.
  2. Scalability -- If you follow the right architectural patterns, serverless is very scalable.
  3. Cost-effectiveness -- In most cases, serverless is cheaper than other computing models although exceptions apply for some forms of compute-heavy data processing/background jobs.

Weaknesses

  1. Troubleshooting and testing -- It's difficult to test locally and it's difficult to navigate debugging data. You can set up a local environment for testing but it will take a lot of effort.
  2. Learning curve -- New patterns and tooling can take a while to learn and adopt.
  3. Developer onboarding -- Bigger learning curve for new developers mid-project.

Opportunities

  • Observable by default -- All serverless architectures are observable by default. Keep in mind that it does not mean you'll get any visibility, it just means that most of the data necessary to understand your service is actually available in AWS through:
  • APIs (CloudFormation, Lambda, API Gateway)
  • Logs (CloudWatch and CloudTrail)
  • Metrics (CloudWatch)

Services structure and visualize that information to make it navigable and simplify troubleshooting.

  1. SAML and other services -- If done well, you can get large parts of your service just by using available Lambda functions and services for auth etc.
  2. Hype -- Developers are excited to work with new technologies, meaning that they are less likely to quit and it's easier to hire.

Threats

  1. Performance issues and latency -- Poorly constructed architectures, cold starts and database connections running out.
  2. Lock in -- Hard to migrate to Docker containers later if for some reason that's necessary.
  3. Security -- Bigger surface area for loopholes and higher complexity for security audits.

Conclusion

As you can see there are significant upsides and downsides, but if you make sure to structure your software right, the benefits greatly outweigh the downsides!

If you have any feedback, the comment section is all yours. I'd love to hear what you have to say. I will be updating this analysis regularly.


Written by taavi-rehemagi | CEO of Dashbird. 13y experience as a software developer & 5y of building Serverless applications.
Published by HackerNoon on 2022/02/10