Code the Future, Now
summary
Demonstrates replacing nightly batch jobs by encoding time into live code: build a saga (NServiceBus) that keeps a single-row week total per customer, updates it atomically and request a time out to remove an order after 7 days, and uses optimistic concurrency plus outbox/distributed-transaction tricks so one concurrent handler succeeds and the other retries. Shows practical delayed-delivery hacks for SQS (900s chunks) and RabbitMQ (TTL + binary-queue trick up to ~8.5 years) and reports that this eliminates slow nightly reports and triggers real-time actions (e.g., lock account after 3 risky transactions).
AI-written summary · about
chapters (16)
- 0:00Introduction and context
- 3:03Real-world order discount problem
- 8:14Batch jobs and their limitations
- 13:06Rethinking time in business logic
- 17:45Introducing the Saga pattern
- 20:13Saga implementation walkthrough
- 27:24Solving the discount use case with Saga
- 31:59Timeout handling in messaging systems
- 35:09Advanced timeout simulation in RabbitMQ
- 38:01Concurrency and transactional guarantees
- 41:30Eliminating batch jobs with real-time processing
- 42:36Fraud detection with Sagas and real-time intelligence
- 45:50Business value of real-time systems
- 46:12Resources and further learning
- 47:16Key takeaways and TDD with Sagas
- 49:03Talking to business about real requirements
related talks
53mMaking tomorrow's code look like today's
36mRise of the Machines [B]
01h 01mThe Unsung Hero of Modern Software: Asynchronous Messaging
39mBuilding next-gen applications with event-driven architecture
01h 29mMonolithic Delivery
24mShaping Tomorrow's Technology: Navigating Cloud-Native, Serverless, and Polyglot Programming
47mPatterns for Building Event-driven Web & Mobile App Backends
37mBuild next-gen applications with event-driven architectures
