A company is using Pub/Sub to ingest clickstream events and Dataflow to write to BigQuery. They observe that some events are malformed and cause the pipeline to fail. They need a solution that captures malformed events without blocking the pipeline and allows reprocessing later. Which Dataflow pattern should they implement?
Dead letter sink is the correct pattern: isolate bad records and let the pipeline proceed.
Why this answer
Dead letter sinks (DLQ) are the standard pattern for handling bad records in Dataflow. The pipeline writes malformed records to a separate sink (e.g., Pub/Sub topic or GCS) for later analysis. Side inputs are for enriching data, not error handling.
Reshuffle doesn't apply. Output tags (side outputs) can also be used, but explicit dead letter pattern is more standard.