Courses / Course 08
Streaming and Change Data Capture
Data that arrives every second, and changes that must be captured as they happen.
- AdvancedLevel
- about 1.5 hoursTo complete
- 5 lessonsWith checked exercises
- FreeNo account needed
What you will learn
- Read CDC events: operations, log positions and timestamps
- Rebuild current state from a stream
- Handle out-of-order and late events
- Count events in time windows
- Build a full history table from CDC
Syllabus
- 1Events, not tables12 min
Change data capture turns every insert, update and delete in a database into an event.
- 2Rebuilding the current state16 min
Turn a stream of changes back into a table: the latest event per key wins, and deletes remove the row.
- 3Out-of-order and late events16 min
Events do not always arrive in the order they happened. Plan for it.
- 4Windows and live metrics14 min
Count events in time windows, and measure how long things take.
- 5Mini project: full order history from CDC18 min
Turn the stream into a history table, then find orders that got stuck.
The data you will use
Nordic Shop raw feeds
The same Nordic Shop, but before anyone cleaned the data. Every night a job loads the day's orders from the shop system, the payment provider sends its own file, and the customer system keeps a log of every change to a customer.
Tables: raw_orders_feed, payments, customer_history, order_events, customer_contacts, deletion_requests
The lesson Events, not tables walks you through every table and column. Under every code box you can also open a list of the tables and what each column means.
Learn in public on GitHub
Do the exercises in the browser, or in the public course repo so your work shows on your GitHub profile.
Fork the course repo
One click on GitHub gives you your own copy with every exercise and dataset.
Solve and open a pull request
Put your answers in your own folder and open a pull request. A bot checks them and comments with ✅ or ❌.
Join the graduates
Finished a course? Add your name to GRADUATES.md. Your work stays on your GitHub profile for recruiters to see.
What you will build
Rebuild the shop's orders and their full status history from a change stream.
Based on a real project: E-commerce CDC Pipeline