Intro to nom, a parser combinator library for Rust

Subscribers:
985
Published on ● Video Link: https://www.youtube.com/watch?v=t9P_aOAP2s4



Duration: 1:31:29
795 views
36


Dive into the world of parsing with Rust as we showcase NOM, a powerful parser combinator library! In this live stream, we'll dissect the intricacies of parsing Redis protocol commands, unraveling the complexities with NOM's elegant solutions.

🔍 Understanding Parsing: We begin with an overview of parsers and parsing methods, contrasting a naive approach with NOM's sophisticated techniques.

💡 Consuming Parsers: Learn how NOM progressively consumes input and handles exceptions, revolutionizing parsing in Rust.

🛠️ Crafting Parsers with Combinators: Explore NOM's arsenal of combinators like tag, pair, tuple, and delimited, crafting composable and reusable parsing functions for Redis protocol commands.

🚀 Performance Benchmarking: Witness NOM's prowess as we compare its performance with regex, showcasing its superiority in parsing tasks, especially in scenarios like Advent of Code challenges.

🔄 Handling Optional Spaces and Delimiters: Delve into enhancing parser robustness and flexibility, addressing concerns and refining parsing logic for seamless data extraction.

🔧 Future Implementation Plans: Get insights into expanding parser capabilities, refining error handling, and tackling edge cases, ensuring a flexible and robust Redis protocol parser.

Join us as we unravel the art of parsing with Rust and NOM, unlocking the secrets to efficient and reliable data extraction. Whether you're a Rust enthusiast, a parsing aficionado, or simply curious about the NOM library, this live stream promises to enlighten and inspire your coding journey.


Chapters:

00:00:00 Intro
00:00:44 What is a parser
00:01:32 String splitting approach
00:04:11 Consuming parsers
00:08:23 How to install and use the `nom` crate
00:25:05 Useful links to deep dive on `nom`
00:28:55 Building a parse for the Redis Serialization Protocol (RESP) with `nom` (live coding)
01:30:38 Closing


⛓️ Links:

- Slides: https://loige.link/nom-intro
- Our repo (tinyresp): https://github.com/lmammino/tinyresp
- nom documentation: https://docs.rs/nom
- nom combinators cheatsheet: https://github.com/rust-bakery/nom/blob/main/doc/choosing_a_combinator.md
- nom error management cheatsheet: https://github.com/rust-bakery/nom/blob/main/doc/error_management.md
- nom official examples: https://github.com/rust-bakery/nom/tree/main/examples
- examples from this presentation: https://play.rust-lang.org/?
version=stable&mode=debug&edition=2021&gist=f2db795f7b887f9a2257f950863ee1f5
- The Redis Serialization Protocol (RESP) Spec: https://redis.io/docs/reference/protocol-spec/


➡️ Follow us on Twitch for more live streams at https://twitch.tv/loige

#Rust #Parsing #NOM #RedisProtocol #LiveStream #Twitch #LiveCoding




Other Videos By Luciano Mammino (loige)


2024-06-11Building Tinykit: a simple lead generation app on AWS Serverless with Rust - Part 4
2024-06-04Building Tinykit: a simple lead generation app on AWS Serverless with Rust - Part 3
2024-05-27Building Tinykit: a simple lead generation app on AWS Serverless with Rust - Part 2
2024-04-15Building Tinykit: a simple lead generation app on AWS Serverless with Rust - Part 1
2024-04-09Building Lambda functions in Rust - part 3
2024-03-19Building Lambda functions in Rust - part 2
2024-03-12Building Lambda functions in Rust
2024-02-27Parsing the Redis Serialization Protocol (RESP) in Rust with nom (Part 3)
2024-02-20Parsing the Redis Serialization Protocol (RESP) in Rust with nom (Part 2)
2024-02-05Exploring OramaSearch with Michele Riva - Indexing and searching blog posts
2024-01-30Intro to nom, a parser combinator library for Rust
2024-01-15Automating blog post descriptions and SEO metadata with Amazon Bedrock
2023-12-11Solving Advent Of Code 2023 day 11
2023-12-04Solving Advent Of Code 2023 day 1 to 3
2023-11-13Building a Twitch Chat Game in Rust part 5 - Twitch Live Stream
2023-11-06Building a Twitch Chat Game in Rust part 4 - Twitch Live Stream
2023-09-18Building a Twitch Chat Game in Rust part 3 - Twitch Live Stream
2023-09-11Building a Twitch Chat Game in Rust part 2 - Twitch Live Stream
2023-09-04Building a Twitch Chat Game in Rust part 1 - Twitch Live Stream
2023-08-28Fixing Fullstackbulletin.com part 9 - Twitch Live Stream
2023-08-22Luciano Mammino (loige) Live Stream



Tags:
rust
redis
nom
parsing
protocol
live coding
slides
parser combinator
regex
regular expression
string splitting
introduction
tech talk
twitch
live stream
pair programming
pairing
english
italian
twitch live coding