└── README.md /README.md: -------------------------------------------------------------------------------- 1 | # Learning Rust 2 | Material I come across which is beneficial to read through to learn the language. 3 | 4 | --- 5 | # Content 6 | 7 | ## Rust Overview 8 | 0. [Shamelss Plugs](#shameless-plugs) 9 | 1. [General Overview](#general-overview) 10 | 2. [Idiomatic Rust](#idiomatic-rust) 11 | 3. [Rust Features](#rust-features) 12 | 3.1 [Traits](#traits) 13 | 3.2 [Types](#types) 14 | 3.3 [Associated Types](#associated-types) 15 | 3.4 [Closures](#closures) 16 | 3.5 [Ownership](#ownership) 17 | 3.6 [Allocation and Memory](#allocation-and-lifetimes) 18 | 3.7 [Lifetimes](#lifetimes) 19 | 3.8 [Macros](#maros) 20 | 3.9 [Cargo](#cargo) 21 | 4. [specific Knowledge](#specific-knowledge) 22 | 4.1 [Iterator](#iterator) 23 | 4.2 [Options](#options) 24 | 4.3 [Documentation Testing](#documentation-testing) 25 | 5. [Complete Learning Websites](#complete-learning-websites) 26 | 6. [Tutorials](#tutorials) 27 | 7. [Project Ideas](#project-ideas) 28 | 8. [General Tinker](#general-tinker) 29 | 9. [Long form and General Knowledge](#long-form-and-general-knowledge) 30 | 31 | ## Rust Async/Web 32 | 1. [Async](#async) 33 | 2. [Concurrency](#concurrency) 34 | 3. [Futures](#futures) 35 | 4. [TCP, epoll, channels](#TCP,-epoll,-channels) 36 | 5. [gRPC](#grpc) 37 | 6. [Libraries](#libraries) 38 | 7. [Interesting Projects](#interesting-projects) 39 | 8. [General Web and Async KnowHow](#general-web-and-async-knowhow) 40 | 41 | ## Peer-to-Peer 42 | 1. [libp2p](#libp2p) 43 | 44 | --- 45 | 46 | ## Shameless plugs 47 | * [Rust Web Development book (Manning)](https://www.manning.com/books/rust-web-development) 48 | * [rustwebdevelopment.com](https://rustwebdevelopment.com) 49 | 50 | ## General Overview 51 | * [Rust for High-Level Programming Language Developers – IQDevs – Technology Excellence Redefined](https://iqdevs.github.io/Rust-for-High-Level-Programming-Language-Developers/) 52 | * [Learning-Rust/main.rs at master · Mathieu-Desrochers/Learning-Rust · GitHub](https://github.com/Mathieu-Desrochers/Learning-Rust/blob/master/src/main.rs) 53 | * [Oxide : The Essence of Rust](https://arxiv.org/pdf/1903.00982.pdf) 54 | * [Structure literals vs constructors in Rust](https://words.steveklabnik.com/structure-literals-vs-constructors-in-rust) 55 | 56 | ## Idiomatic Rust 57 | * [Binary Search in Rust](https://shane-o.dev/blog/binary-search-rust) 58 | * [Building a middleware from Scratch](https://github.com/tower-rs/tower/blob/master/guides/building-a-middleware-from-scratch.md) 59 | * [Iterators in Rust](https://www.newline.co/@uint/rust-iterators-a-guide--80e35528) 60 | * [Elegant APIs in Rust](https://deterministic.space/elegant-apis-in-rust.html) 61 | 62 | ## Rust Features 63 | ### Traits 64 | * [Abstraction without overhead: traits in Rust - The Rust Programming Language Blog](https://blog.rust-lang.org/2015/05/11/traits.html) 65 | * [Refactoring in Rust - Using Traits](https://fettblog.eu/refactoring-rust-introducing-traits/) 66 | * [Using traits for better testing](https://stackoverflow.com/questions/72817819/how-do-i-use-rust-traits-to-abstract-http-call-for-tests) 67 | * [Rust traits and dependecny injection](https://jmmv.dev/2022/04/rust-traits-and-dependency-injection.html) 68 | * [Advanced traits](https://doc.rust-lang.org/book/ch19-03-advanced-traits.html#specifying-placeholder-types-in-trait-definitions-with-associated-types) 69 | * [Rust Basics: the add Trait - Hashnode](https://chilimatic.hashnode.dev/rust-basics-the-add-trait-cjtoke4yh002t8hs1c61p82mz) 70 | 71 | ### Types 72 | * [A Gentle Introduction to Practical Types | Patterns in Cyberspace](https://leotindall.com/tutorial/a-gentle-introduction-to-practical-types/) 73 | 74 | ### Associated Types 75 | * [Advanced Traits - The Rust Programming Language](https://doc.rust-lang.org/book/ch19-03-advanced-traits.html#specifying-placeholder-types-in-trait-definitions-with-associated-types) 76 | 77 | ### Closures 78 | * [Closures: Anonymous Functions that Can Capture Their Environment - The Rust Programming Language](https://doc.rust-lang.org/book/ch13-01-closures.html) 79 | * [Finding Closure in Rust | Huon on the internet](http://huonw.github.io/blog/2015/05/finding-closure-in-rust/) 80 | 81 | ### Ownership 82 | * [Ownership in Rust, Part 1 – Thomas Countz – Medium](https://medium.com/@thomascountz/ownership-in-rust-part-1-112036b1126b) 83 | * [Ownership in Rust, Part 2 – Thomas Countz – Medium](https://medium.com/@thomascountz/ownership-in-rust-part-2-c3e1da89956e) 84 | * [Rust: Unlocking Systems Programming](https://www.infoq.com/presentations/rust-thread-safety) 85 | * [Stacked Borrows Implemented](https://www.ralfj.de/blog/2018/11/16/stacked-borrows-implementation.html) 86 | 87 | ### Allocation and Memory 88 | * [Allocations in Rust - speice.io](https://speice.io/2019/02/understanding-allocations-in-rust.html) 89 | 90 | ### Lifetimes 91 | * [Rust Lifetimes for the Uninitialised](https://asquera.de/blog/2018-01-29/rust-lifetimes-for-the-uninitialised/) 92 | * [Why can lifetimes not be inferred? - help - The Rust Programming Language Forum](https://users.rust-lang.org/t/why-can-lifetimes-not-be-inferred/25645) 93 | * [Lifetimes in Rust - Stack Overflow](https://stackoverflow.com/questions/17490716/lifetimes-in-rust?rq=1) 94 | * [Generic Types, Traits, and Lifetimes - The Rust Programming Language](https://doc.rust-lang.org/book/ch10-00-generics.html) 95 | 96 | ### Macros 97 | * [A Practical Intro to Macros in Rust 1.0](https://danielkeep.github.io/practical-intro-to-macros.html) 98 | * [The Little Book of Rust Macros](https://danielkeep.github.io/tlborm/book/README.html) 99 | * [Deriving Traits in Rust with Procedural Macros · naftuli.wtf](https://naftuli.wtf/2019/01/02/rust-derive-macros/) 100 | * [A Love Letter To RusT Macros](https://happens.lol/posts/a-love-letter-to-rust-macros/) 101 | 102 | ### Cargo 103 | * [Matthias Endler](https://matthias-endler.de/2018/cargo-inspect/) 104 | 105 | ## Specific Knowledge 106 | ### Iterator 107 | * [std::iter::Iterator - Rust](https://doc.rust-lang.org/std/iter/trait.Iterator.html) 108 | 109 | ### Options 110 | * [Rust: Using Options by example](http://www.ameyalokare.com/rust/2017/10/23/rust-options.html) 111 | 112 | ### Documentation Testing 113 | * [rust-by-example](https://doc.rust-lang.org/rust-by-example/testing/doc_testing.html) 114 | 115 | --- 116 | 117 | ## Complete Learning Websites 118 | * [Learning Rust](https://learning-rust.github.io/) 119 | * [Exercism.io - Rust track](https://exercism.io/tracks/rust) 120 | * [Rust Cookbook]( https://rust-lang-nursery.github.io/rust-cookbook/intro.html) 121 | * [Rustlings](https://github.com/rust-lang/rustlings) 122 | 123 | ## Tutorials 124 | * [Writing an OS in Rust](https://os.phil-opp.com/) 125 | * [Streaming gRPC with Rust – Kevin Hoffman – Medium](https://medium.com/@KevinHoffman/streaming-grpc-with-rust-d978fece5ef6) 126 | * [Introduction - Learning Rust With Entirely Too Many Linked Lists](https://rust-unofficial.github.io/too-many-lists/) 127 | * [Stanford CS140e - Operating Systems](https://github.com/dddrrreee/cs140e-win19) 128 | * [Implementing TCP in Rust (part 1) - YouTube](https://www.youtube.com/watch?v=bzja9fQWzdA) 129 | * [Build a cryptocurrency! - Blockchain in Rust #01: Blocks & Hashing - YouTube](https://www.youtube.com/watch?v=vJdT05zl6jk&list=PLwnSaD6BDfXL0RiKT_5nOIdxTxZWpPtAv&index=2&t=0s) 130 | * [Learn Parser Combinators](https://bodil.lol/parser-combinators/) 131 | 132 | ## Project Ideas 133 | * [Classic unix utilities make great beginner projects! : rust](https://www.reddit.com/r/rust/comments/b0i625/classic_unix_utilities_make_great_beginner/) 134 | 135 | ## General Tinker 136 | * [Understand this assembly output](https://godbolt.org/z/SYMUem) 137 | * [Understand this example code](https://play.rust-lang.org/?version=stable&mode=debug&edition=2018&gist=1ca846311b58545aa1a0c7475360f916) 138 | * [Rust pattern: Iterating an over a Rc>](http://smallcultfollowing.com/babysteps/blog/2018/09/02/rust-pattern-iterating-an-over-a-rc-vec-t/) 139 | * [State Machine Patterns in Rust](https://hoverbear.org/2016/10/12/rust-state-machine-pattern/) 140 | 141 | ## Long form and General Knowledge 142 | * [Scientific computing: a Rust adventure Part 0 - Vectors](https://www.lpalmieri.com/posts/2019-02-23-scientific-computing-a-rust-adventure-part-0-vectors/) 143 | * [Scientific computing: a Rust adventure Part 1 - Zero-cost abstractions](https://www.lpalmieri.com/posts/2019-03-12-scientific-computing-a-rust-adventure-part-1-zero-cost-abstractions/) 144 | * [Test harness - Wikipedia](https://en.wikipedia.org/wiki/Test_harness) 145 | 146 | --- 147 | 148 | ## Async 149 | * [What Are Tokio and Async IO All About?](https://manishearth.github.io/blog/2018/01/10/whats-tokio-and-async-io-all-about/) 150 | * [Async, futures, and tokio - Rust Crash Course lesson 7](https://www.snoyman.com/blog/2018/12/rust-crash-course-07-async-futures-tokio) 151 | * [async/await notation for ergonomic asynchronous IO Pull Request](https://github.com/rust-lang/rfcs/pull/2394/files) 152 | * [asynchronous - What is the purpose of async/await in Rust?](https://stackoverflow.com/questions/52835725/what-is-the-purpose-of-async-await-in-rust) 153 | * [The relationship between async libraries in Rust](https://www.jimmycuadra.com/posts/the-relationship-between-async-libraries-in-rust/) 154 | * [RFC: stabilize `std::task` and `std::future::Future`](https://github.com/aturon/rfcs/blob/e7eaea194994da28bde2c36d78fedf50e79b4bcf/text/2592-futures.md) 155 | 156 | ## Concurrency 157 | * [Green Threads are like Garbage Collection](https://www.fpcomplete.com/blog/2017/01/green-threads-are-like-garbage-collection) 158 | * [Fearless Concurrency - The Rust Programming Language](https://doc.rust-lang.org/1.30.0/book/second-edition/ch16-00-concurrency.html) 159 | * [Sending trait objects between threads - help - The Rust Programming Language Forum](https://users.rust-lang.org/t/sending-trait-objects-between-threads/2374) 160 | * [std::sync::Arc - Rust](https://doc.rust-lang.org/std/sync/struct.Arc.html) 161 | * [Is Send/Sync special cased? - The Rust Programming Language Forum](https://users.rust-lang.org/t/is-send-sync-special-cased/2355/2) 162 | * [What is a Thread?](https://www.geeksforgeeks.org/operarting-system-thread/) 163 | * [Tokio: Tutorial](https://tokio.rs/tokio/tutorial) 164 | 165 | ## Futures 166 | * [Futures in Rust](https://www.youtube.com/watch?v=9_3krAQtD2k) 167 | * [Understanding Futures In Rust — Part 1 | Viget](https://www.viget.com/articles/understanding-futures-in-rust-part-1/) 168 | * [Futures in Rust (and Haskell)](https://slides.com/wraithm/async-io-in-rust-and-haskell/#/) 169 | * [Converting AsyncRead and AsyncWrite to Futures, Sinks and Streams](https://jsdw.me/posts/rust-futures-tokio/) 170 | * [Zero-cost futures in Rust · Aaron Turon](https://aturon.github.io/blog/2016/08/11/futures/) 171 | 172 | ## TCP, epoll, channels 173 | * [TCP in Rust - #1](https://www.youtube.com/watch?v=bzja9fQWzdA&) 174 | * [TCP in Rust - #2](https://www.youtube.com/watch?v=OCpt1I0MWXE) 175 | * [TCP in Rust - #3](https://www.youtube.com/watch?v=8GE6ltLRJA4) 176 | * [Channels in Rust](https://www.youtube.com/watch?v=b4mS5UPHh20) 177 | * [epoll with Rust](https://zupzup.org/epoll-with-rust/) 178 | 179 | ## gRPC 180 | * [Building gRPC APIs with Rust](https://konghq.com/blog/building-grpc-apis-with-rust) 181 | * [gRPC load balancing with Rust](https://truelayer.com/blog/grpc-load-balancing-in-rust/) 182 | 183 | ## Libraries 184 | * Futures: [Zero-cost asynchronous programming in Rust](https://github.com/rust-lang-nursery/futures-rs) 185 | * Tower: [GitHub - tower-rs/tower: fn(Request) -> Future](https://github.com/tower-rs/tower) 186 | * Serde: [GitHub - serde-rs/serde: Serialization framework for Rust](https://github.com/serde-rs/serde) 187 | * Tokio: [Tokio - The asynchronous run-time for the Rust programming language.](https://tokio.rs/) 188 | * Axum: [Axum - Web framework](https://github.com/tokio-rs/axum) 189 | 190 | ## Interesting projects 191 | * [rust-ipfs-api](https://github.com/gkbrk/rust-ipfs-api) 192 | * [Radicle](http://www.radicle.xyz/) 193 | * [ffsend:Share files from the command line](https://github.com/timvisee/ffsend) 194 | * [rust-imap: IMAP client library](https://github.com/jonhoo/rust-imap) 195 | 196 | ## General Web and Async KnowHow 197 | * [Concurrency, Parallelism, Threads, Processes, Async and Sync](https://medium.com/swift-india/concurrency-parallelism-threads-processes-async-and-sync-related-39fd951bc61d) 198 | * [The Illustrated TLS 1.3 Connection: Every Byte Explained](https://tls13.ulfheim.net/) 199 | * [corefx/HttpCorrelationProtocol.md ](https://github.com/dotnet/corefx/blob/master/src/System.Diagnostics.DiagnosticSource/src/HttpCorrelationProtocol.md) 200 | * [Transport Layer Security - Wikipedia](https://en.wikipedia.org/wiki/Transport_Layer_Security) 201 | * [Finite-state machine - Wikipedia](https://en.wikipedia.org/wiki/Finite-state_machine) 202 | * [There is no free lunch](http://www.gotw.ca/publications/concurrency-ddj.htm) 203 | * [Reactor Pattern](https://www.puncsky.com/blog/2015/01/13/understanding-reactor-pattern-for-highly-scalable-i-o-bound-web-server/) 204 | 205 | ## Peer-to-Peer 206 | ### libp2p 207 | * [What is libp2p](https://docs.libp2p.io/concepts/introduction/overview/) 208 | * [Adressing in libp2p](https://github.com/libp2p/specs/blob/master/addressing/README.md) 209 | * [PeerIds and keys](https://github.com/libp2p/specs/blob/master/peer-ids/peer-ids.md) 210 | * [Create a libp2p node](https://curriculum.pl-launchpad.io/curriculum/libp2p/core-concepts/) 211 | * [Distributed hash table](https://docs.libp2p.io/concepts/appendix/glossary/#dht) 212 | * [libp2p swarm](https://docs.rs/libp2p/latest/libp2p/swarm/index.html) 213 | * [Chat example](https://github.com/libp2p/rust-libp2p/blob/master/examples/chat-example/src/main.rs) 214 | * [Ping example](https://github.com/gruberb/libp2p-rs-ping/blob/main/src/main.rs) 215 | * [Tutorial: Build a simple p2p app using Rust](https://morioh.com/p/f1b14f97b537) 216 | --------------------------------------------------------------------------------