Hacker News new | past | comments | ask | show | jobs | submit login

What makes anything "serverless", when it has to run on a server?



I always understood "serverless" as, your main application isn't running all the time, but once you make a request to it, another process starts your main application and then your request gets forwarded to the "main" application.

But I never really got it, so I may be completely wrong.


Kinda, but you are describing an implementation detail. More broadly, here's how it works:

Infrastructure as a Service (IaaS) - you rent a VM with a publicly accessible IP address. Everything else – patching/updating the OS, deploying your application code or binaries, process lifecycle management, logs, TLS certs, load balancing multiple servers and more – is your responsibility. Example: EC2.

Platform as a Service (PaaS) - the provider also manages the OS for your VM, including deploying and running your code on it, restarts, a logging pipeline, providing a HTTPS URL, scaling to multiple servers and more. All you have to do is write your application code to start a web server and listen for web requests on a particular port. Example: Heroku.

Functions as a Service (FaaS) - this goes one step further, and the concepts of web servers, ports and HTTP requests/responses are also abstracted out from your application code (hence "serverless"). You write a function with a set of inputs and outputs, and it's up to the platform to execute this function whenever demanded. The request can be sent via HTTP or a message queue or something else entirely. Your code itself doesn't have to care. Example: AWS Lambda


Practically, it's always running, as otherwise you'll get a cold start delay, but that's close enough. It doesn't mean there's no server, so the "lol how is it serverless if you have a server" meme is tiring.


It means it doesn't run on specific servers that you manage.


But the article starts with "I run a Dokku server on a $7/month VPS", so author meant something else (probably just wrong usage). Maybe Dokku has 2 modes, where you can launch it on classic server (fixed price per month) or deploy on pay-as-you-use platform (https://www.cloudflare.com/learning/serverless/what-is-serve...). Calling something serverless without trying it first is deceiving.


So every website I do not own is serverless?


Yeah something like GitHub pages is serverless.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: