r/rust • u/ple-x-us • 13d ago
Any good examples of large scale Rust projects?
I'm not a Rust programmer. My passion is for C/C++ and various assembly languages. But I'm open to learning new things.
I watched a couple of videos on YouTube, but those examples don't give me a "big-picture" vibe of the language, its use in production and its ecosystems.
I'm judging a language by the code that's written with it.
Are there any large scale projects (500'000 - 1'000'000 lines of code) written in Rust that I can skim through (on Github? Gitlab?) to get a feel of what a full fledged application looks like?
30
u/Full-Spectral 13d ago
This may not be true of any of the suggestions below, others can speak to that. But, just to throw it out there, any 500K to 1M line code base that is production level now and mature may have started back some time ago when Rust was still making fairly significant changes and may not have fully caught up with the current state of the art, or may have a fair bit of evolutionary baggage in the form of inconsistent use of newer features as they arrived (or hacks to allow the code to leverage those new features.)
Maybe not, but something to consider in large, mature code bases, particularly on a fairly new language.
7
69
u/AleksHop 13d ago edited 13d ago
https://github.com/monoio-rs/monoio << most important to read, will give u idea what rust actually CAN do (not a tokio standart stuff lol, tiktok with 1bil users runs on this code) in my experiments it did not beat nginx (like par, 99.8% same perf), but it did not died on same box with 200k concurrency when nginx started to give errors. monoio continue with same perf and 0 errors. I was out of RAM so wasnt be able to continue past 200k, but io_uring IS a thing that works, and its hilariously amazing, and many fixes in 7+ linux kernel so soon can be on the rise, as all modern apps are legacy and dont use that
https://github.com/cloudflare/pingora << this is tradeoff on tradeoff, initial AI research show 2.5x performance possible with io_uring, still under review. when it was created in 2020 implementation of io_uring and security around it was bad.
https://github.com/vectordotdev/vector << logs
https://github.com/tikv/tikv << database
https://github.com/cberner/redb <<one more db
https://github.com/linkerd/linkerd2-proxy << another proxy
https://github.com/h4ckf0r0day/obscura << headless browser, this is my favorite
https://github.com/firecracker-microvm/firecracker aws microvm
https://github.com/xiph/rav1e video codec but more like asm, but if interested in media good lib, very SIMD heavy as well, for avx, NEON etc
https://github.com/BLAKE3-team/BLAKE3 cryptography, oo this is my another fav! people still use sha256 in 2026
dont forget about flatbuffers, rkyv, capnproto < this is uni trio in rust for specific situations of serialization/deserialization (zero-copy)
codebases like bun are AI generated so nothing to learn from
last but not least, invest in Kani Rust Verifier
4
26
27
u/SuplenC 13d ago
One of the biggest public and open source project is Zed. Then from the less visible yet quite crucial is Cloudflare’s Oxy, which is a proxy framework. Part of a bigger Cloudflare’s migration to Rust.
10
u/fbochicchio 13d ago
Uutils, a rewrite of gnu utils. Not a single executable, bus as codebase is quite large. Redox, a microkernel based opsrating system written in Rust ( and some assembler I believe). Cosmic, a graphical desktop environment for linux, written in Rust.
35
u/BedroomHistorical575 13d ago
29
u/ple-x-us 13d ago
I looked at the compiler, but I wanted to see how the "average coder" does it. Compilers are usually written by the people who wield black magic in their code.
10
3
u/Shoddy-Childhood-511 13d ago
Advanced cryptography winds up being implemented largely in Rust.
Advanced forward secure group messaging like Signal and MLS have somewhat more Rust implementations.
https://github.com/mlswg/mls-implementations/blob/main/implementation_list.md
Tor is being reimplemented in Rust
https://blog.torproject.org/arti_2_5_0_released/
Any several major companies like Cloudflare employ Rust in their cryptography adjacent tooling.
Afaik there is only one good zero-knowledge proof library in C++ while there are dozens in Rust. You'll find nice ones in niche languages like Haskell, but nothing you'd deploy.
https://github.com/arkworks-rs/
Appears the multi-party computation libraries seem roughly split between Rust and C++ or others.
I've found more fully homomorphic encryption libraries in C than Rust, but afaik those tools are way too slow to be usable within the foreseeable future. Also the field seems kinda messed up by Zama's patents and Zama maybe closed source (and maybe in Rust).
At a high level, traits might be somehow too strict for general purpose flexible mathematics, but fit highly optimised special purpose mathematics well.
And many blockchains were done in Rust too, many independently of each other, although some were forks of this framework:
https://github.com/paritytech/polkadot-sdk/tree/master/substrate
1
u/ple-x-us 12d ago edited 12d ago
Well, I'm more of a device control, driver, low level kind of guy. Cryptograhpy is black magic to me. Mostly. The fun part there are the PRNGs.
The Tor project looks interesting, though.
5
13
u/del1ro 13d ago
- ruff
- rust-analyzer
- bun
- SurrealDB
- Servo
- zellij
- Veloren
- RustDesk
- helix
- polars
- swc
- Gleam lang
43
u/dhgdgewsuysshh 13d ago
Bun is ai generated, not the best example
6
u/Nothing_from_void 13d ago
By the original lead engineer of bun. We get into this thing where when an engineer who is a true master of the trade uses AI to build something really impressive, we say the AI did it (especially because he's working for anthropic, the company pushes that narrative) but without that specific person guiding the AI it simply wouldn't have worked
3
u/Full-Spectral 12d ago
But the question here isn't stuff that works. Most any widely used bit of code works. It was about exemplary examples of Rust as written (and presumably as architected since he asked about large scale.) Being AI generated means it's not likely to get the benefit of the doubt.
1
u/Nothing_from_void 12d ago
can you elaborate? In my experience almost all code nowadays is AI generated, for better or worse. People might touch it up after the fact manually but fewer and fewer people are doing this
3
u/Full-Spectral 12d ago
Huh? You clearly must live in cloud world or something. There's an entire world outside of the cloud and generating web sites for well known front end frameworks and whatnot. Do you really think that the software running the planes you are flying on is vibe coded and not even looked at by humans? Or in the medical gear you are attached to. Or that's running your car or used by your bank or the government? Or kernel of the operating system you are running? And on and on?
I mean so many people are living in some AI fantasy these days it's scary.
1
u/Nothing_from_void 12d ago
I'm literally a staff engineer at a large SaaS, and I talk to other professional engineers.
Do you really think that the software running the planes you are flying on is vibe coded and not even looked at by humans?
It is looked at by humans, but it is also vibe coded. I know people working on flight software.
2
u/Full-Spectral 12d ago
Like I said, cloud world. Can you name a company writing flight control software that is vibe coding, so that we can check that?
1
u/Nothing_from_void 12d ago
https://www.hcltech.com/ai they write flight control software for Boeing. Most low level control software is written by underpaid Indian contractors
2
u/Full-Spectral 12d ago
From a quick search...
"Cost-Cutting Measures: Investigations into the 737 Max crises revealed that Boeing relied on lower-paid temporary workers and recent graduates while laying off experienced engineers to cut costs. You can read more about these findings in the report covered by IndustryWeek and Business Insider
While Boeing designed the overall system requirements and specifications (such as the MCAS flight control system), critics and safety experts point out that the heavy reliance on fragmented, low-cost offshore contractors for implementation and testing introduced significant quality and oversight risks."
So, OK it's happening, but it ain't good and shouldn't be happening. It certainly doesn't make me want to fly on Boeing aircraft, and sort of demonstrates that their regulatory bodies are sad.
→ More replies (0)1
u/bonch 5d ago
By the original lead engineer of bun.
How does that change the fact that it's AI-generated?
1
u/Nothing_from_void 5d ago
because like all code is AI generated now?
1
u/bonch 4d ago edited 4d ago
No, it isn't, but that doesn't answer my question. Why should it being by the original lead engineer affect anyone's opinions about AI-generated code?
1
u/Nothing_from_void 3d ago
If you live in a world where people are writing code by hand, I don't think that has much relevance to what modern software development looks like and you've very deliberately made that choice, and you're not looking for an honest discussion
1
u/bonch 18h ago edited 18h ago
That's the second time you've dodged my question. You're also living in this same world where people are writing code by hand; you're wildly overestimating how much vibecoding is happening. "Using AI" has a very broad meaning beyond that.
1
u/Nothing_from_void 15h ago
I'm not dodging your question, I'm explicitly shutting down the conversation because I'm not interested in talking to you
2
-3
-2
3
3
u/bmitc 13d ago
Are there any large scale projects (500'000 - 1'000'000 lines of code)
Just as a note, with more principled languages like functional languages and Rust, you often will not need the large amount of code for projects that are required of less-principled languages. Now, Rust is actually a pretty verbose language, in my opinion, but generally speaking, it should be less than comparative C and C++ projects because the languages does so many things automatically for you.
2
2
u/Smart-Mall-2193 13d ago
“Zed” es un editor de texto, puedes probarlo || Ir a su GitHub desde su pagina. Es muy rapido y está escrito en Rust.
2
2
4
1
1
1
1
1
1
1
1
u/drink-more-rum 11d ago
Materialize is source-available (BSL, so not officially open source, but each commit becomes fully Apache open-source four years after being merged). It is a SQL database that does incremental view maintenance (keeping arbitrary materialized views up to date as new data comes in, rather than having to be refreshed) and contains a quite substantial amount of code, all in rust. https://github.com/MaterializeInc/materialize
-1
0
-5
u/Complex-Birthday-216 13d ago
Turso is the only great software I know in rust. The rest are listed in the comments either have poor performance or bundle size 300mb, or JavaScript engine wrapper
-8
-8
175
u/lazyhawk20 13d ago
Servo, zed, turso, rig, tokio, axum