All jobs / Data engineer / Data Lakes
Data engineer interview question · 3–5 years
Streaming writes leave a trail of tiny files. What do you schedule?
The strongest answer
A compaction you can bound — after a watermark or on a clock — so reads stay cheap; I do not compact in the write path if that is how we miss the SLA
Why it works
Exactly. Compact as a job with a bound. Magic, blocking every batch, and weekly drops are how you miss or lose.
What a good answer covers
- Schedule bounded compaction.
- Do not block every ingest.
- Lakes do not self-heal files.
- Do not DROP as maintenance.
Answers that fall short
- Close, but not the strongest: Nothing; the lake will sort itself
Lakes do not sort themselves. - Weak: A compaction on every micro-batch, blocking the ingest
Blocking ingest is how the SLA dies. - Red flag: A weekly DROP TABLE
DROP is not compaction.
Who gets asked this
More Data Lakes questions
- Spark, a SQL engine and the BI tool each keep their own idea of which tables exist in the lake, and they…
- After a merger you have two lakes. How do you close it?
- Parquet or Avro — when do you use each in a pipeline?
- What is different about writing a table to S3 or GCS compared with writing to a local filesystem?
- A streaming job wrote 200,000 tiny files for one day. What is the smell?
- Two Parquet datasets hold the same rows. A filter on order_date reads a tenth of one and nearly all of the…
- Time travel is on and storage doubled. What do you set?
- Bronze / silver / gold is on the slide. What makes it real?