Live data from Hacker News

Netlify Edge Functions: A new serverless runtime powered by Deno

netlify.com

131–140 of 166 posts

Re: Netlify Edge Functions: A new serverless runtime powered by Deno

#132

Earlier quoted context omitted.

Sure, but I think the GP was referring to a situation where revenue doesn’t match the traffic. Imagine the grandma scenario. Let’s say that she cooks and sells artisanal jams and jellies. With the help of her granddaughter, she creates a TikTok that goes viral. Her web store immediately sells out, and the traffic from the video hammers her website. She cannot react fast enough to enable back orders and so most of tho…

Then get peoples emails to notify when stock is up again. The worst thing it could happen is having your site down when many people want what you have. In any business, the hardest part and most expensive, by far, is sales and marketing. You wanna throw it all away to save 100 bucks on Amazon? That's insane!..

And how about a fun educational project you aren't expecting visitors for and make zero revenue from? AWS bills can far exceed 100 bucks. Paying thousands for... Exposure? That's insane!..

Re: Netlify Edge Functions: A new serverless runtime powered by Deno

#134

Earlier quoted context omitted.

Check out knative, it’s used for Google Cloud Run: https://knative.dev/docs/

What is the common spec for Knative? It seems like one runs an app as normal in a container and then the special scaling sauce is handled by Knative. When I think of a portable spec for serverless, I think of something more like a Trait of an Interface that needs to be implemented, less a app hosting model. If you think about it like that, then Web Assembly component model [1] would be a great fit for defining an int…

That would only be implementable by languages with a WASM output target though. Knative says that any container that responds to HTTP will work, and you could host those in different environments. It's much more general.

Re: Netlify Edge Functions: A new serverless runtime powered by Deno

#135
post #13
post #6

Earlier quoted context omitted.

The first link in the article points to this: https://www.netlify.com/products/#netlify-edge-functions How to use them Drop JavaScript or TypeScript functions inside an edge-functions directory in your project. Use cases Custom authentication, personalize ads, localize content, intercept and transform requests, perform split tests, and more.

> Use cases > A bunch of server functionality Why is that the use case? I don't see how an edge function can be faster than a centralized server endpoint if it has to reach out to literally any other component of the system involved in auth / persistence

You are replying to a message that very explicitly didn't say "A bunch of server functionality". Specifically, it said:

> Custom authentication

You can most definitely authenticate requests based on signed tokens and the like, meaning you don't necessarily need to reach any other component in the system.

> personalize ads

Same here. You can most definitely pick different adds depending on some cookie value or such, no need to reach anywhere. Even if you want to track what ads you've served, that can be done _after_ the response is sent to the user, meaning the extra latency of going to your persistence layer isn't perceived by the user.

> localize content

Again, you can have your translations in your edge function (or some edge cache if that platform supports it) and apply them at the edge. Admittedly this sounds like the shakiest use-case.

> intercept and transform requests

You can implement redirections, security headers, etc. in this layer. No need to go to your persistence layer.

> perform split tests

Same idea here. You can have multiple versions of (cached) pages and serve one or the other depending on the user's cookies, ip (country?), some frequency, etc.

You may be doing all these things from your backend layer, which is arguably easier, but it doesn't mean that they can't be offloaded to the edge and have a positive impact.

Re: Netlify Edge Functions: A new serverless runtime powered by Deno

#137
post #5

This is great news. I'm really rooting for a successful trend of Serverless runtimes, mainly as a weapon against rising cloud deployment costs. While the general trend today is to back the serverless environment with Javascript runtimes (Cloudflare runs its edge on top of V8, Netlify uses deno, most other serverless runtimes use nodejs), I'm optimistic that WebAssembly will take over this space eventually, for a bunc…

in what world is serverless cheaper?

The one where you only need a few invocations and with serverless: aren’t paying for an idling VM all of the other time. Arguably you may save yourself an ops team too.

Re: Netlify Edge Functions: A new serverless runtime powered by Deno

#138
post #81
post #5

This is great news. I'm really rooting for a successful trend of Serverless runtimes, mainly as a weapon against rising cloud deployment costs. While the general trend today is to back the serverless environment with Javascript runtimes (Cloudflare runs its edge on top of V8, Netlify uses deno, most other serverless runtimes use nodejs), I'm optimistic that WebAssembly will take over this space eventually, for a bunc…

> I'm really rooting for a successful trend of Serverless runtimes, mainly as a weapon against rising cloud deployment costs. How would that work? Don't these tend to facilitate cloud lock-in or at least be cloud-only in the sense that they make it hard to operate your own metal infrastructure?

There is KNative for that. But really folks are using serverless to _not_ have to operate their own iron and save themselves an ops team.

Re: Netlify Edge Functions: A new serverless runtime powered by Deno

#139
post #64

Earlier quoted context omitted.

That's discussing their subhosting offering, which is unrelated to the subject of this thread, the actual runtime.

You're being dense, that's from this thread, and explains this Netlify offering uses Deno's Deploy infrastructure.

You're right. I missed the link to the Deno blog and only saw 'Deno runtime' in this article.

Re: Netlify Edge Functions: A new serverless runtime powered by Deno

#140
post #105
post #78

Earlier quoted context omitted.

Netlify also uses aws and rackspace . They are in the business of selling PaaS on top of IaaS by adding value to developer workflows . They could host their own infra at large enough scale when that makes sense, the same way AWS decided after many years to make their own chips (graviton), but that is not their core identity like AWS is not a chip manufacturer.

It looks like Netlify is essentially reselling Deno Deploy as is, not building a higher-level service on top of it. And latency matters in CDNs.

(I work at Netlify, and worked on this)

It uses Deno Deploy for the actual execution of the function, but the whole workflow around it, routing and middleware API, integration with frameworks and the CDN are all Netlify. It's similar to how Netlify Functions use AWS Lambda for execution. It does add latency, but it's tens of ms, because it uses Deno Deploy nodes that are very close to the Netlify edge nodes. Deno Deploy is awesome, but Netlify has a much more complete platform, so the combination is best of both worlds.

Post reply on HN