Implementing (part of) a BitTorrent client in Rust

Jon Gjengset · 115K views · 2023 · 4:09:16

Open on YouTube

C, C++, Rust, Go & systems languagesNetworking & internet infrastructureSoftware practice, open source & careerstutorial

Why Hacker News recommends it

HN recommends it as a comprehensive walkthrough of the build-your-own-BitTorrent challenge and as an introduction to CodeCrafters.

What it is

Jon Gjengset's roughly four-hour live stream implementing part of a BitTorrent client in Rust, following CodeCrafters' test-guided challenge. He builds from scratch and shows idiomatic error handling along the way.

Recommended by 2 HN commenters across 2 different months, 2023 to 2023.

What Hacker News said

Recommends sarupbanskota · 2023-11 · on “Show HN: I built a guided Build your own DNS Server challenge”

(CodeCrafters team here). Out of curiosity, is there a reason why you prefer video format vs. interactive? e.g out of habit, when I'm having a meal, I like watching "course videos" or streams occasionally. Is yours similar? P.S. Jon Gjengset did a comprehensive stream going through the Build your own BitTorrent challenge [this video] , if you're interested in Rust

Recommends joshka · 2023-12 · on “Show HN: Rqbit – bittorent CLI and desktop app written in Rust”

Take a watch of Jon Gjengset's vids on this (there's a codecrafters challenge for building out a bittorent protocol that he's going through). - [this video] - [LINK]

Cites Jonhoo · 2023-10 · on “Build Your Own BitTorrent”

Oh hey, that's me! A better link is [this video] which has chapter marks and has the power outage in the middle spliced away :p

Cites zoogeny · 2023-10 · on “"Useless Ruby sugar": Pattern matching (Pt. 1)”

I was thinking of `guard` in Swift when I was writing but I haven't used it so I was unsure of its exact semantics. It is a bit of a shame it is only useable on optionals and not on arbitrary types. Nice to see a full pattern matching guard in Rust. I think the terminating `?` operator makes it a bit less necessary as I would guess a large portion of cases where I would want that early-return behavior I would just take advantage of that operator. But their choice to reuse `else` makes a lot of sense and the pattern reads well. I was watching the recent Rust stream by Jon Gjengset where he builds a BitTorrent implementation [1]. One thing he did frequently was add a `.context` method to funct

Cites methou · 2023-11 · on “CodeCrafters CEO adds his paid service as a next step after finishing Rustlings”

I found that CodeCrafters is quite fun after watching an video on Youtube[0], and shared it with my friends who might also be interested. The feedback I got was quite similar to the community: - really interesting idea, but - pricing is absurd, not gonna pay 100$ for these, and - their minimal paid plan at 40$/mo is a lie, with a fine print: Available as a one-time payment for 3 months or 1 year access. - Lack of in depth implementation of the projects, i.e for the free HTTP server project, it stopped at "Post a file", lack of beefy & fun stuff like for example HTTP 1.1 Pipelining I believe the value (the fun) it would provide me would be about the same level of Ace Combat 7 (I paid ~40$US),