Code AnalysisHard 60s
Projection Rebuild Requirement
class OrderProjection:
def on(self, evt):
if evt.type == 'OrderPlaced':
self.total += evt.amount
elif evt.type == 'OrderCancelled':
self.total -= evt.amount
# new rule needed: discounts never counted before
A new discount rule must apply retroactively to history. What is the correct event-sourcing response?
Think you can answer under pressure?
Get matched and answer live questions in 3-minute 1v1 battles. Elo ranking, badge tiers and bragging rights on the line.