Zero To Production In Rust

An opinionated introduction to backend development

The book takes you on a journey to discover the world of backend development in Rust.
You will learn by doing: we will start from scratch and build together, step by step, a fully functional email newsletter backend API.

You'll learn how to:

  • Navigate and leverage Rust's crates ecosystem
  • Structure your application to make it modular and extensible
  • Write tests, from single units to full-blown integration tests
  • Model your domain and leverage the type system to enforce invariants
  • Collect logs, traces and metrics to observe the state of your application
  • Set up a robust continuous integration and continuous deployment pipeline for your Rust projects

All code comes attached to the book, tests included.

Buy early access £35 Download sample

Early Access

Zero To Production In Rust is not complete yet.

You will get immediate access to the first four chapters (96 pages) in PDF, ePUB, MOBI.

All the source code is attached.

A new chapter is released every two/three weeks. The book should be complete by February 2021.

You will be notified and be able to download new chapters as soon as they are ready!

Reddit avatar

Gilgw on Reddit

“One of the best introductions to Rust for web devs”

This has the workings of being one of the best introductions to Rust for web devs: the explanations are really clear and almost of all my questions get immediately answered in the very next paragraph, as if the author was secretly a mind reader.

Released Chapter Overviews

Foreword

Chapter Zero

Setting the stage: what is this book about? Who is this book for? A brief overview of the principles behind Cloud-native applications.

Getting started

Chapter One

We'll start building our Rust toolkit: compilation, linting, security audit, formatting. We'll have a solid CI pipeline in place by the end of the chapter.

Our project

Chapter Two

We want to build an email newsletter API: what does it look like? We'll focus on working in iterations and introduce the concept of user stories.

Bootstrapping the application

Chapter Three

Things get serious: we'll boostrap an actix-web application from scratch, build a POST endpoint to enroll new subscribers, interface with a database to store their details with sqlx. We will follow a TDD-style approach, including integration testing.

Telemetry

Chapter Four

An in-depth exploration of what it means to build an observable API as well as the tools to properly instrument our code (log and tracing crate).

Coming soon

Table of Contents

You can see the full list of planned chapters in the book sample. A new chapter is published every two/three weeks. The next one will be out on Monday 28th September.

author image

About the author

My name is Luca Palmieri and I’m a Lead Engineer at TrueLayer.
I am a co-organiser of the Rust London User Group, an OpenSource contributor and a public speaker.

I have been developing in Rust for almost three years, previously in my free time, now professionally on a daily basis.

I have been fairly active in the OpenSource community.
I am the author of a few crates - ndarray-stats, wiremock and linfa.
I also wrote some test-driven workshops to get people started with Rust - build-your-own-jira-with-rust and ndarray-koans.

I have been speaking regularly at meetups and conferences. You can find the recordings of my past talks here.

You can follow me on Twitter, on GitHub or on my blog.