A Sense of Place: What ReaderT Can Do in a Purely Functional World
summary
Claims a concrete pattern: use ReaderT to carry a composable "place" environment so log lines, exceptions and simple profilers show high‑level context instead of raw stack frames. Shows a Scala benchmark runner for quasar (built at slam data), converts two‑argument loggers into an RT-based logger, composes logger stages, and attaches domain traces to exceptions. Demonstrates this in a couple of production Scala programs and explains how logical areas compose for scoped timing and filtering. stack traces are useless is the motivating diagnosis.
AI-written summary · about
chapters (7)
- 0:00Introduction and context
- 3:52Benchmark design as functions
- 8:52The problem of logging
- 15:19Logger implementation
- 25:44Contextual logging with places
- 30:26Plumbing context with Reader T
- 42:57Abstraction and final thoughts
related talks
44mTelling the Truth with Types
50mSimple code for a type safe world
16mWhat's in the Box: Ergonomic and Expressive Capture Tracking over Generic Data(…)
42mFunction Passing Style: Typed, Distributed Functional Programming
42mLet the Compiler Help You: How to Make the Most of Scala's Type System
40mFunction-Passing, A New Model for Typed, Asynchronous and Distributed Programming
27mTake a rest from REST
15mTypestate via Revocable Capabilities
