Live data from Hacker News

Netlify Edge Functions: A new serverless runtime powered by Deno

netlify.com

61–70 of 166 posts

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

#61

Netlify pricing has always been confusing to me, but I'm not entirely sure why. I guess I'm more accustomed to pay-as-you-go in this space (CFW) than tiered plans (Netlify bundles their features into starter/pro/business). It seems that the free plan is 3M invocations/mo, starter is 15M/mo, and business is 150M/mo, but there aren't any ways to increase those limits (business says to contact them for higher limits). P…

> Personally I'd prefer true pay-as-you-go without hard limits, even if it's a bit more expensive.

Please, a hard no to that. That's the worse aspect of AWS, Azure and all those new huge hosting centers - hard to calculate the real cost and set a budget.

I don't know about Netlify, but the old Linode (before it got acquired), was flexible with its "hard" limits in a plan - for example, if your site got slashdotted / Digged (or was that dug?) and suddenly saw a spike on its resource, exceeding the limits, they were quite accommodating in not charging their users for the unexpected extra usage. Linode even wouldn't mind an occasional surge in resource a few times a year. But if it happened more frequently, they would recommend that you upgrade to a more suitable plan. They earned a lot of goodwill that way from their clients who really appreciated that their server / site wasn't unexpectedly taken offline because of a resource crunch they hadn't paid for and / or anticipated.

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

#62
post #36

I would love to jump over to something like Vercel or Netlify Edge, but maddeningly none of these platforms give you control over the cache key. I have pages that are server-side rendered with Cache-Control headers, but because our visitors come with unique tracking params on the end of their URL (e.g. from Mailchimp or Branch), we would essentially have no cache hits. It seems the only way to have control over this…

Why don't you just link to an API route, consume the tracking params, set a cookie, and redirect to a statically rendered page?

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

#63
post #48

Earlier quoted context omitted.

> mainly as a weapon against rising cloud deployment costs. Cloud Functions is literally code you're running in the cloud. And the moment you approach their limit(ation)s, you will see the same "rising cloud deployment costs" > Running a WASM engine on the cloud means ... a fraction of the overhead of a container or nodejs environment You do realise that there are other languages than javascript in nodejs? That there…

I sought to unserstand "serverless" but every deployment diagram I have ever seen show things that look an aweful lot like they run on... servers? Maybe I don't get the idea (and honestly I was too lazy to put in the legwork), but when I hear something like "serverless" I imagine some p2p javascript federated decentralized beast where the shared state is stored through magic and tricks with the users clients and ther…

> Instead it seems like a buzzword (?) for a weirdly niche way of running things that someone with a 4 Euro/Month nginx instance that hosts 10 websites will probably never understand.

That's exactly it. It's a way to intermittently run a piece of code in a managed environment. You're basically guaranteed that the environment is setup, and that the code will start up and execute. That is basically it.

People are extremely enamoured with it, for no apparent reason. The only usecase I've found for myself so far is running small analytics BigQuery queries to look for easily detectable anomalies once a day and send a Slack message if something's wrong. This way you avoid etting up a separate Kubernetes job etc. Makes no sense outside of GCP.

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

#64

Earlier quoted context omitted.

Deno is an offline runtime. Similar to nodejs. Not an infrastructure.

https://news.ycombinator.com/item?id=31085357

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

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

#65
post #16

Earlier quoted context omitted.

I agree about WASM. I am sort of worried that Deno may be too late tbh. Why would I bother with an interpreted language at all when I can code in any language I want and run it anywhere with WASM?

The "any language" advantage of WASM is theoretical. Each language is at a different level of support of WASM, libraries aren't all caught up and at the same point for all languages, etc... I love the promise of WASM, but every time I look at it I get lost in a sea of acronyms, and my optimistic ideas of using language X with library Y on runtime Z are dashed because there is some missing piece somewhere. If anything…

Agreed. There is also the lack of a GC in WASM and Denos' use of existing web standard APIs.

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

#66
post #13

Earlier quoted context omitted.

> 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

Even if it doesn't reduce latency, it could reduce bandwidth and load on other servers. (Or increase it, if it's used badly.)

I can't imagine a successful argument that you use less compute cycles spinning up Edge functions to interact with your app than just hitting an already-running API endpoint on an already-running server. And rearranging your load just because you can isn't worth consideration.

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

#67
post #15

Earlier quoted context omitted.

Thanks! Any useful pros and cons vs Cloudflare Workers?

One of the big reasons for going with Deno is that it's an open runtime closely based on web standards. You can download the open source Deno Cli and all code written for our edge layer will run exactly the same there. As more and more front-end frameworks starts leaning in on running part of their code at the edge, we felt it was important to champion and open, portable runtime for this layer vs a proprietary runtim…

Cloudflare uses v8 and the client is open: https://github.com/cloudflare/wrangler

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

#68
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…

Really, really dumb question. I've seen a lot of node/python/etc serverless offerings. Is there something where you just provide a binary and its executed each time?

For example, I write a simple single responsibility piece of code in Go `add_to_cart.go` and build it, deploy it, and somehow map it to some network request. dot slash pass args, and return the result?

No need to have containers or runtime?

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

#69

This is a new concept for me, what is the use case for edge functions?

You have a hosted static web app but want to dynamically change the tags in your index.html to provide a unique url preview for each route (/about, /careers, etc)

Why would one want to do this? For analytics?
Post reply on HN