Re:The Adoption of Rust in Business
by pipe_connector on Tuesday February 07, 2023 @01:26PM
(#34696829)
500,000 requests/day is ~6 requests per second.
You could handle that with Ruby on a raspberry 1
Re:The Adoption of Rust in Business
by kouteiheika on Tuesday February 07, 2023 @02:48PM
(#34698344)
If you're just sending static pages, sure. Not if you're doing significant processing like I do. It's also an issue of scaling, where I could probably serve at least ~1000x more traffic on a single machine (and I know I'll never hit that much traffic). And if you don't need high availability (although I haven't had a single outage is over two years, thanks to Rust's reliability and focus on correctness) this simplifies your architecture and your deployment significantly, because now if you're on a single machine you don't have a distributed system, you don't even need caches, you don't need load balancers, you don't need to administer multiple machines, you don't need Kubernetes, backing everything up is very easy, etc.
(But of course, I'm not saying this is how everyone should do it. I'm just saying what the benefits are for me because Rust's so fast, so it allows me in my particular case to do this, which I wouldn't be able to do with e.g. Ruby because it'd be too slow.)
Is this a one person operation you’re describing or a commercial project developed by a team which is bringing in revenue? How long has it been in production and how long will it be developed and supported?
My concern regarding web Rust is focused on long-term viability and development speed, not performance which is a given or memory safety which is a standard in webdev.
I maintain a 180k+ line of code back-end web project and I use Rust. Best decision I've ever made.
I serve over half a millions of HTTPS requests per day. Everything hits the backend, no CDNs or caches of any kind. Average CPU usage on a cheap VPS? ~3%. Hugs of death? No such thing for me. It just runs itself without any supervision for months uninterrupted, so I can sleep at night and not get woken up by an outage. And refactoring is a breeze due to a strong type system, plus all other niceties that Rust has.
So for a complex project that you're going to maintain long-term? Rust is absolutely the right choice, even for backend web-dev. A throwaway CRUD e-commerce website made by a random webdev consulting company on the cheap? Okay, yeah, maybe here you're right, and I probably wouldn't pick Rust there either.