All jobs / Backend developer / Architecture
Backend developer interview question · 5+ years
The interviewer asks: “Two years of events, consumers you don't own. How do you evolve the schema?” Strongest answer?
The strongest answer
Compatibility windows: additive fields, dual-publish old and new types if I break, a registry that blocks incompatible producers, and a documented retirement. I don't rewrite history in the log.
Why it works
Exactly. You don't own the consumers; the log is an API. Dual-run and a registry are how platforms survive year three.
What a good answer covers
- The log is a public API.
- Additive or dual-publish; registry gates.
- Don't rewrite history casually.
- Schemaless isn't a strategy.
Answers that fall short
- Close, but not the strongest: Compact the topic and republish a clean schema.
Compacting away history may be allowed technically and still break a replay consumer or an auditor. Treat it as a product change. - Weak: Tell other teams to deploy the same day.
Lockstep day is a fantasy once you have more than one team. Compatibility is the feature. - Red flag: Put a protobuf Any in every message so I can change anything.
Any / schemaless just postpones the fight to runtime. You still need a contract.
Who gets asked this
More Architecture questions
- The interviewer asks: “Auth, TLS, and WAF — in every service or at the gateway?” Strongest answer?
- An interviewer says: “Design a URL shortener.” What do you do first?
- What does a load balancer do, and what does it not do?
- What is the difference between scaling up and scaling out?
- Why do interviewers keep asking whether a service is stateless?
- When does adding a cache help, and when does it not?
- In a design, why do you say which columns are indexed?
- What is a read replica for?