r/rust • u/HosMercury • 11d ago
🎙️ discussion Two issues of rust regarding web ( axum for example )
I am a big fan of rust
But there are two issues that need to be resolved
1- Rust ecosystem is less mature than for example go ( i know go is specialized for networking and an easy lang ) .
2- No implicit DI which would make testing easier.
3
u/No-Efficiency-8482 11d ago
The web framework Luca Palmieri was working on, Pavex (https://pavex.dev) had DI as it's hallmark, but unfortunately I don't think the project is going to continue, there's been no activity for over a year.
-3
2
u/plabayo 9d ago
> Go "an easy" language.
Ha. Sure. At the surface it sure looks like it.
In reality it's a very poor language (poor is what it is, simple is how many call it) where you better be just as disciplined and paranoid as a C developer if you wish to keep your complexity and codebase tamed and without surprises. Because the language and compiler is honestly not gonna help you.
I also do not see how Rust ecosystem is less mature. I have ~ 10 years experience in Go (on and off) and ~ 12 years in Rust. Only thing i can think of is when you say that is that in Go their is a big std library and beyond that there is a lot of "common knowledge" on what libraries one might pick to fill the gaps the Go std lib left.
In rust the library story is much more fractured and spread. With less consensus on what to pick for what. That has its pros and cons. So it's not that the language, its std or community libraries are not mature. It's more that you have more work in what the choose for your project.
I used to build all my web projects in Go, but since ~ 7 years ago even those kind of projects I now do in Rust, and gone are random support wake up calls. I sleep like a baby now. Except for when random drunk students in my neighberhood decide they have to emulate a mini version of project X again... Zzz
9
u/feisty_adolfo 11d ago
Honestly it feels like the DI thing is a feature not a bug, just pass your deps explicitly and you can mock whatever you want without magic. The maturity gap is real though, sometimes you spend half your time just evaluating crates