Loading video player...
Advertisement/Werbung: Try Sevalla now and receive $50 of free credits: https://sevalla.com/?utm_source=flowoelki&utm_medium=Referral&utm_campaign=youtube In this video, we'll talk about implementing a web server in Axum and Rust. If you're interested in learning about Closures in Rust, feel free to check out this video: https://youtu.be/nqFk2twicdA š Description In this video, we will explore building web servers in Rust using the Axum framework and demonstrate how to create clean, ergonomic APIs through practical examples, focusing on error handling and routing patterns. We'll build a simple REST API that showcases why Axum is excellent for creating modular web services with type-safe extractors. You will learn the following things: ⢠What Axum is and how to set up a basic web server with async handlers ⢠How to implement centralized API error handling using enums and the IntoResponse trait ⢠Understanding Axum's extractors (Path, Json) ⢠How to define multiple routes and handle dynamic URL parameters ⢠How to write tests for your API endpoints using Tower's ServiceExt trait without network overhead ā³ Timestamps: 00:00 - Introduction 00:26 - Creating the Router? 04:53 - API error handling 11:06 - health_check 12:02 - list_users 13:16 - get_user 14:49 - Testing 20:49 - Outro š Hey there! If you are new to this channel: Hey š my name is Flo and I am a professional software engineer with a passion for coding in Golang, TypeScript, JavaScript, and Rust. This channel is where I share that passion and dive into the exciting world of software engineering. šØ Support and Connect! Become a member. https://www.youtube.com/@FloWoelki/membership Discord: https://discord.gg/TnA7drJ X / Twitter: https://x.com/FlorianWoelki LinkedIn: https://www.linkedin.com/in/florian-woelki/ GitHub: https://github.com/FlorianWoelki #rust #axum #webserver