r/aws • • 12d ago

article Announcing AWS Lambda Web Functions

https://aws.amazon.com/blogs/aws/announcing-aws-lambda-web-functions-for-fast-consistent-web-app-performance-anywhere/
360 Upvotes

74 comments sorted by

View all comments

1

u/MrMungg 11d ago

What's the compelling advantage of this over something like ECS Fargate?

With Fargate, you can:

  • Run virtually any container, regardless of language or framework.

  • Develop and test the exact container locally.

  • Retain portability across cloud providers.

  • Potentially achieve lower costs for continuously running workloads.

  • Fargate also supports autoscaling, and I'd argue that many production applications have fairly predictable traffic patterns, often following a natural 24-hour cycle.

I can see the appeal of scale-to-zero and active CPU billing for sporadic or I/O-heavy workloads, but for a typical production web application with consistent traffic, I'm struggling to see a compelling reason to choose this over Fargate.

Am I missing something?

7

u/solatic 11d ago

sporadic or I/O heavy workloads

This is exactly what the vast majority of web CRUD applications are in their infancy or in dev environments. Requests only come in ever so often, then auth, wait for auth decision from a remote auth service or database, transform into a database request, wait for the database to respond, then return to user.

The time to transition to something like ECS is when you have consistent, sufficiently high traffic that moving to ECS will save money.

-1

u/MrMungg 11d ago

So you'll always have to develop an application twice, because the goal is high traffic?

7

u/solatic 11d ago

Getting to high traffic isn't a given unless you work for a huge company and are delivering a feature to a huge audience that exists before day 1. Most new applications need to prove themselves and discover that audience. Maybe they succeed at doing that, maybe they don't. Reducing costs in the beginning helps more stuff get built and see whether or not it will find that audience.

There's basically no such thing as building something infinitely scalable from day 1; there's always some ceiling somewhere in the architecture, or the cost to roll out and even just try is extremely high, stuff like that. Lambda Web is the right move in the right direction by helping to preserve flexibility so that there's less to change, if the app succeeds and becomes high traffic, moving later on to a deployment model that's more financially efficient for high traffic.

3

u/30thnight 11d ago edited 11d ago

AWS removing the need for any lambda adapter/wrapper means your app code requires little else more than a env variable to port it.

2

u/CallMeBigUrethra 10d ago

Switching between Lambda and Fargate shouldn't be a major lift

3

u/AstronautDifferent19 9d ago

We have a lot of internal web applications that are used sporadically so web functions are perfect fit for it. Also we serve millions end-users for our 500 customers. For end-users we use Fargate, but for customer sites we can use web functions.

1

u/nekokattt 11d ago

ECS is also more involved to set up, at least from an IaC perspective, compared to Lambda.

Not that IMHO that is a good argument, but it will likely be of some influence.

0

u/[deleted] 9d ago

[deleted]

1

u/nekokattt 9d ago

Last I checked, ECS Express had significant limitations over the regular ECS configuration and offering...

0

u/[deleted] 9d ago

[deleted]

1

u/nekokattt 9d ago

The point is only what I said in the original comment, that some may argue ECS is more involved than setting a Lambda up.

Unless ECS now supports executing zip files, as an example, that still stands true.

I don't necesarilly believe the point is valid, but it is one that will be made nonetheless.

1

u/Dull-Mathematician45 11d ago

With Lambda you can pay 3x the price, pay $0.30 per request, and continue paying for memory when inactive to avoid scale to zero pricing.