|
|
|
|
|
by jeroenhd
2105 days ago
|
|
I think it really depends on what kind of backend you're writing. If you're writing a simple CRUD web backend, I'd suggest avoiding Rust because other backend frameworks have a lot of boring side stuff (CSRF, security headers, form validation, you name it) already implemented while the more recent Rust frameworks are still missing them all over the place, requiring you to implement them yourself. It's not a lot of work to do it yourself, but it's boring, easy to get wrong and you need to check with docs and specs to see if what you're doing is even correct. For those cases, I'd recommend a classic such as Java+Spring or C#+ASP Core with their excellent plugins and addon ecosystems. If you're handling big data structures with loads of allocations and deallocations and complicated algorithms, Rust might be the language for you. The language shines and the lack of a GC shines at those workloads. The same is true for batched workloads that can be processed in parallel, because the restrictions Rust puts on object access makes it excellent to make assumptions about data access and ownership with little or no performance wasted on the framework around the threading library. As much as I like Rust and projects like Rocket.rs, I'm just not sure if the ecosystem is mature enough for it to be used for a production backend for web services. I'd wait a year or two for the Rust frameworks to gain more features and more quality of life improvements before actually using it. |
|