1 option
Mastering distributed observability in rust : implement opentelemetry in a real-world, multi-container e-commerce architecture / Manjunath Gangappa, Rajkumar Rangaraj.
- Format:
- Book
- Author/Creator:
- Gangappa, Manjunath, author.
- Rangaraj, Rajkumar, author.
- Language:
- English
- Subjects (All):
- Rust (Computer program language).
- Physical Description:
- 1 online resource
- Place of Publication:
- Birmingham : Packt Publishing, 2026.
- Summary:
- Learn to design, implement, and scale distributed observability in Rust using OpenTelemetry, with practical examples for tracing, logging, and metrics. Key Features Implement end-to-end observability in Rust using OpenTelemetry APIs and Collector Correlate logs, traces, and metrics across async, multithreaded Rust applications Build and deploy an observable Rust microservice with Actix, Redis, and Prometheus Configure dashboards, alerts, and trace views in Grafana using real telemetry data Book Description Gain the skills to build, monitor, and debug distributed systems in Rust with this hands-on guide to observability using OpenTelemetry. As Rust adoption grows in backend services, developers face fragmented documentation and limited tooling for telemetry. This book fills that gap by presenting a unified, end-to-end solution to implement distributed observability in modern Rust systems. You'll explore the foundations of observability and Rust's ownership model before learning how to collect, export, and correlate logs, metrics, and traces. Discover how to instrument applications using OpenTelemetry crates and bridge them with the tracing ecosystem. Learn to deploy the OpenTelemetry Collector, integrate with Prometheus, Grafana, and Jaeger, and tackle challenges like sampling, context propagation, and async tracing. Written by two seasoned engineers with over 35 years of combined experience in large-scale systems and open-source observability leadership, this book balances theory with real-world implementations. From debugging async bottlenecks to configuring cost-effective telemetry pipelines, you'll finish with the confidence to operate reliable, observable Rust systems at scale. What you will learn Understand the three pillars of observability in Rust Apply tracing and logging using the Tokio and OpenTelemetry crates Export telemetry to backends like Prometheus, Jaeger, and Grafana Use the OpenTelemetry Collector to manage telemetry pipelines Correlate metrics, logs, and traces for faster debugging Implement structured logging, redaction, and context propagation Optimize telemetry costs with sampling strategies Build and deploy an observability-first Rust microservice Who this book is for Rust developers building backend systems, DevOps engineers, and SREs deploying Rust in production will benefit from this book. Ideal for readers experienced in Rust development who want to implement end-to-end observability using OpenTelemetry and tools like Grafana, Prometheus, and Jaeger.
- Contents:
- Intro
- Mastering Distributed Observability in Rust
- Implement OpenTelemetry in a real-world, multi-container e-commerce architecture
- Foreword
- Contributors
- About the authors
- About the reviewers
- Table of Contents
- Preface
- Who this book is for
- What this book covers
- To get the most out of this book
- Download the example code files
- Download the color images
- Conventions used
- Get in touch
- Share your thoughts
- Free benefits with your book
- How to Unlock
- Part 1
- Foundation
- 1
- Introduction to Observability
- Introduction
- How This Book Works
- Why Observability Matters in Distributed Systems
- What Each Tool Reveals (and Misses)
- From Guesswork to Understanding
- The Three Pillars of Observability in Action
- Traces: Following the Request's Journey
- Logs: The Narrative of What Happened
- Metrics: The Pulse of the System
- Bringing It Together
- What Is OpenTelemetry?
- Building an Observability Mindset
- Chapter Summary
- Subscribe to Deep Engineering
- 2
- Reading Rust Memory From Traces
- What You'll See in Your Traces
- Allocation Patterns: Stack vs. Heap
- Why Stack Allocations Don't Appear in Memory Profiles
- Heap Allocations: The Observability Hotspots
- Understanding Rust's Memory Model
- Ownership
- Borrowing
- The Golden Rule of Observability
- Clone vs. Move: Performance Impact in Traces
- Lock Contention: Mutex and Arc in Distributed Traces
- How Lock Waits Appear as Span Duration
- Async Runtime Observability
- Task Scheduling: What Tokio Does Behind the Scenes
- Blocking Operations in Async Code (The Silent Killer)
- Task Stalls and Backpressure in Traces
- Send and Sync: Why They Matter for Tracing
- Thread-Safe Span Propagation
- Context Propagation Across Async Boundaries
- Memory Leaks and Reference Cycles
- How Arc Cycles Appear in Memory Profiles
- Detecting Leaks Through Metrics
- Summary
- Get this book's PDF version and more
- 3
- The OpenTel E-Commerce System
- OpenTel E-Commerce: System Architecture
- Domain Modeling: From Database to Rust
- Identities and Types
- Service Boundaries and Responsibilities
- OtelMart Gateway (BFF)
- Products Service
- Inventory Service
- Orders Service
- Navigating the Codebase
- Inter-Service Communication: The Distributed Transaction
- The ""Happy Path
- The ""Unhappy Path
- The Backend Request Journey
- The Canonical Checkout Request (HTTP Entry to Database)
- Mapping Backend Service Hops
- The Current State of Logging
- The ""Black Box"" Problem
- Structured Logging (A Half Step)
- Why Observability is Non-Negotiable
- Part 2
- Instrumentation
- 4
- Instrumenting the Request Journey
- The Transformation: Before and After OpenTelemetry
- Where We Left Off
- Notes:
- OCLC-licensed vendor bibliographic record.
- ISBN:
- 9781806671793
- OCLC:
- 1592133218
- Publisher Number:
- CIPO000383253
The Penn Libraries is committed to describing library materials using current, accurate, and responsible language. If you discover outdated or inaccurate language, please fill out this feedback form to report it and suggest alternative language.