DataDriven
LearnPracticeInterviewDiscussDailyJobs

The transactional outbox is the canonical fix for dual writes

A medium Pipeline Design interview practice problem on DataDriven. Write and execute real pipeline design code with instant grading.

Domain
Pipeline Design
Difficulty
medium

Problem

The transactional outbox is the canonical fix for dual writes. The application writes only to the database; the same transaction that writes the business row also inserts an outbox row. A separate publisher drains the outbox to the broker. Either both rows commit or neither does. The section names two publisher implementations: a polling publisher that selects unpublished rows and updates published_at, and a CDC-driven publisher that reads the WAL via Debezium. Build the outbox by adding the outbox table, replacing the dual-write handler with one that writes both rows in one transaction, and adding a publisher whose name states which implementation it uses.

Practice This Problem

Solve this Pipeline Design problem with real code execution. DataDriven runs your solution and grades it automatically.

Related

  • All Practice Problems
  • Mock Interview Mode
  • System Design Interview Questions
  • Data Engineering Interview Prep Guide
  • Daily Challenge
  • Data Engineering Lessons