Companies blueprint · E-Commerce
Flipkart: Big Billion Days, and how Flipkart ships
An end-to-end flash-sale path for The Big Billion Days, from edge admission and a virtual queue through inventory reservation, UPI/EMI/COD checkout, fulfilment-centre allocation and Ekart delivery, plus the months of readiness work behind it. It must never oversell stock, charge a customer twice, or lose a paid order.
- Steps
- 9
- Subjective questions
- 33
- Objective questions
- 33
The problem and the outcome
Problem: During a flash sale, demand for limited-stock deals arrives within seconds and can exceed normal traffic many times over. Without control, stock gets oversold, payments time out, and fulfilment gets swamped.
Outcome: Traffic is admitted at a rate the backend has been load-tested for, and every unit sold maps to one reserved unit and one confirmed payment or COD order. Orders flow asynchronously to the right fulfilment centre and Ekart route, while a war room watches and degrades features if needed.
Architecture
How it works, step by step
- Months before the sale, teams forecast demand, plan capacity, and run repeated production-like load tests and failure drills; a feature freeze is publicly described as locking down changes in the run-up so the sale runs on tested code.
- At sale start, the CDN serves static assets and cached pages while edge rules rate-limit, filter bots and shed excess load before it reaches origin services.
- A virtual queue (waiting room) admits shoppers to hot deals at the rate the backend was tested for, giving fair ordering and a clear wait message instead of errors.
- Catalogue, deal and price data are pre-warmed into in-memory caches so browsing barely touches primary databases; price is re-verified at checkout so a stale cache never sets the charge.
- The inventory service reserves a unit with an atomic conditional decrement (only if stock is greater than zero) and attaches a time-limited hold, so stock can never go negative.
- Checkout uses an idempotency key per order and hands off to payment for UPI, cards or EMI; failed or abandoned payments release the hold, and COD orders skip online payment after eligibility checks.
- Confirmed orders are written as events to a durable log, and an allocation service picks a fulfilment centre based on stock location, delivery promise and capacity.
- The fulfilment centre picks, packs and hands over to Ekart, which routes to the shopper and collects cash or digital payment for COD orders, reconciling it back to the order.
- During the sale, a war room of engineering, product and operations teams watches dashboards and business metrics, and uses feature flags to degrade non-critical features or roll back fast.
Tech stack
- CDN with edge rate limiting and bot management
- Virtual waiting-room / token admission service
- Java microservices on containers with autoscaling
- In-memory key-value cache for catalogue and price
- Transactional relational store for inventory and orders
- Apache Kafka for order and inventory events
- UPI, card and EMI rails via payment gateways
- Metrics, tracing and feature-flag platform for the war room
Key design decisions
- Reserve inventory at buy-now with a short TTL rather than at add-to-cart, so carts do not lock stock and abandoned holds return quickly.
- Use a virtual queue instead of pure autoscaling, because databases and payment partners cannot scale instantly and the queue keeps load within tested limits.
- Serve catalogue and price from cache but treat the database price as authoritative at checkout, trading a small read cost for never charging a stale price.
- Make order allocation asynchronous through an event log so checkout stays fast and allocation can retry or rebalance across fulfilment centres.
- Freeze features and rehearse failure modes before the sale, accepting slower delivery of new work in exchange for a predictable launch.
Common mistakes
- Read-then-write stock checks under concurrency oversell; the decrement must be a single atomic conditional operation.
- Retrying payments or order creation without idempotency keys creates duplicate charges or duplicate orders.
- UPI callbacks can arrive late or out of order; orders need a pending state and reconciliation instead of failing on timeout.
- A cold cache at sale start sends a thundering herd to the database; pre-warm caches and use request coalescing.
- Load tests that skip third parties such as payment and SMS miss the real bottleneck; test end to end with partners.
What to measure
- Oversell count and inventory reconciliation mismatches (target zero)
- Checkout and payment success rate by method (UPI, card, EMI, COD)
- Virtual queue wait time and admission rate versus tested capacity
- p99 latency and error rate for inventory and checkout services
- Order-to-allocation lag and on-time delivery against promise date
Most-asked interview questions
Subjective questions 33
1How would you design inventory reservation for a flash sale so you never oversell?Asked almost every time
I keep one authoritative stock count per SKU and warehouse, and reserve with a single atomic conditional update: decrement only where available is greater than zero, and treat zero affected rows as sold out. That removes the read-then-write race. Each reservation gets an ID and a short TTL; if payment fails or the shopper abandons, a sweeper or event releases the unit. For very hot SKUs I can pre-split stock into buckets across shards to avoid one hot row, then rebalance leftovers. Checkout carries an idempotency key so retries never reserve twice. Finally, I reconcile reservations, orders and payments continuously, because the business promise is zero oversell even when parts fail.
2One deal SKU gets so many concurrent reservation attempts that its single stock row becomes a hotspot. How would you relieve that contention without risking oversell?Asked almost every time
I would split the SKU's sellable stock into several buckets, each holding part of the units, stored as separate keys or rows. A reservation picks a bucket at random or by hash and runs the same atomic conditional decrement on it. If that bucket is empty, it tries a few others before returning sold out. Each bucket still can never go below zero, so the total cannot oversell. The cost is a little stranded stock: one bucket may be empty while another holds units. A background rebalancer or a final sweep fixes that. I would also put the virtual queue in front, so the attempt rate stays near what the store was tested for. That way bucketing handles peaks rather than unbounded load.
3A customer's payment succeeds, but their inventory hold expired a few seconds earlier and the unit went to someone else. What do you do?Asked almost every time
First, design to make this rare. The hold should outlive the payment timeout plus a margin, and you should not release a hold while a payment attempt is still in flight. Release only on a confirmed failure, an abandon, or a timeout after a status check. If it still happens, the payment is real money, so the order must not be silently dropped. Try to re-reserve from any bucket or fulfilment centre with stock. If that works, confirm normally. If it does not, record the order as paid-unfulfillable, start an automatic refund through the payment service using the same idempotency key, and tell the customer clearly. Track this count in the war room, because a rising number means the hold or timeout settings are wrong.
4How would you design the idempotency key for checkout so a customer is never charged twice?Asked almost every time
The client creates a unique key when the shopper first presses Pay and reuses it on every retry, including network retries and double taps. The server stores that key together with a hash of the request: user, cart, amount and reservation IDs. It does this with a unique constraint before calling the payment gateway. If the same key arrives again, the server returns the stored result or the in-progress status, and it does not create a new payment. If the same key arrives with a different payload, it is rejected. The same key, or a key derived from it, goes to the gateway as the merchant order reference, so the gateway also deduplicates. Keys live at least as long as the payment reconciliation window.
5How do you guarantee that a paid order is never lost between the payment confirmation and the order event log?Asked almost every time
I would use the transactional outbox pattern. When payment success is recorded, the same database transaction updates the order to PAID and inserts an outbox row. A relay process reads the outbox and publishes to the durable log, with replication and acknowledgement from multiple brokers. It marks rows as sent only after the publish succeeds. If the relay crashes, it republishes, so consumers must be idempotent by order ID. Separately, a reconciliation job compares gateway settlement reports and payment records with orders. Any payment without a matching confirmed order raises an alert and is repaired or refunded. A dual write straight from the service to both database and broker is what loses orders, so I avoid it.
6Why use a virtual queue if you can autoscale the services?Very often asked
Autoscaling helps stateless services, but it lags a sudden spike, and the real limits are stateful: databases, hot inventory rows, and payment partners whose capacity we do not control. A virtual queue converts an unbounded spike into a controlled admission rate matching what we load-tested. It is also fairer, since shoppers get a position and a wait estimate instead of random errors, and it blocks bots that would grab stock. I would issue signed admission tokens at the edge, validate them at checkout, and tune the rate live from the war room based on error rates and latency. Autoscaling still runs behind it; the queue just ensures we never exceed proven capacity.
7How does a company prepare engineering-wise for a sale like The Big Billion Days?Very often asked
Publicly described practice is that preparation starts months ahead. Teams forecast traffic, plan capacity for compute, databases and partners, and run repeated load tests on production-like setups, fixing bottlenecks each round. Failure drills test what happens when a dependency slows or dies, and every service gets degradation plans and feature flags. Closer to the sale, a feature freeze limits changes to reduce risk. Caches are pre-warmed and payment and logistics partners are aligned on expected volume. During the sale a war room watches technical and business dashboards together, with clear owners and runbooks so decisions like turning off recommendations or slowing queue admission take minutes. Afterwards a review feeds the next year's plan.
8Pre-warmed caches still expire. How do you prevent a cache stampede on deal pages at sale start?Very often asked
There are several layers. Warm caches before the sale and give deal data long or no expiry during the event, with explicit invalidation when a price or deal changes. Add jitter to any TTLs so keys do not expire together. Use request coalescing, also called single-flight: on a miss, only one request rebuilds the key while the others wait or get the slightly stale value. Serve stale-while-revalidate for browse data, because checkout re-verifies price anyway. Keep a local in-process cache in front of the distributed cache for the hottest keys. Protect the database with connection limits and a circuit breaker, so a miss storm degrades into stale pages, not a database outage.
9Why re-verify price at checkout, and what should happen if it differs from what the shopper saw?Very often asked
Browsing reads cached price data that can be seconds or minutes stale. That staleness is acceptable for display but not for charging money. At checkout, the order service reads the authoritative price and deal eligibility, including per-user limits, bank offers and the deal window, from the source of truth. It then signs or locks that amount for this checkout. If the price went up or the deal ended, show the new amount and ask the shopper to confirm explicitly. Never charge more silently. If the price went down, charge the lower price. The amount sent to the payment gateway must come only from this verified server-side calculation, never from the client, which also blocks tampering.
10How would you design the virtual queue so it is fair and cannot be bypassed?Very often asked
When a shopper enters a hot deal, the queue service gives them a position based on arrival time and a signed, short-lived token tied to the user or session. A controller admits positions at a configured rate, matched to the tested backend capacity, and adjusts it from live health signals. Once admitted, the shopper gets a signed admission token. The edge or API gateway checks this token on every protected call, so hitting the origin URLs directly does not work. Tokens expire, are single-use per deal, and are tied to the account, which limits sharing. The waiting page polls cheaply from the edge and shows position or an estimated wait. Anti-bot checks run before a position is issued, not after.
11How would you estimate capacity for the sale-hour checkout path in an interview?Very often asked
I would state assumptions out loud rather than claim real numbers. Start from expected peak concurrent users and the share who reach checkout in the busiest minute. Convert that to orders per second, then multiply by the fan-out per order: calls to the reservation store, price service, payment and writes. That gives requests per second per dependency. Add headroom for retries and spikes, then size each tier from per-node throughput measured in load tests, not vendor claims. For example, if I assume N checkouts per second, each needing about three inventory operations, the inventory store must handle roughly 3N operations at the target latency. Finally, I set the queue admission rate below the weakest tier's tested limit.
12What should the war room watch, and how does it decide to degrade a feature?Very often asked
Watch both business and technical signals. Business signals include orders per minute, checkout conversion, payment success rate split by method and bank, reservation success versus sold-out rate, and queue length and wait time. Technical signals include p99 latency and error rates per service, cache hit ratio, database and broker lag, and saturation such as CPU, connections and thread pools. A sudden drop in payment success for one bank or the UPI path is often the first sign of a partner problem. Decisions should follow pre-agreed runbooks with thresholds and named owners. For example, if checkout latency crosses a limit, turn off recommendations and reviews, or reduce the queue admission rate, using feature flags tested during the drills.
13How would you model the order lifecycle as a state machine?Very often asked
The states are CREATED, then RESERVED, then PAYMENT_PENDING, then PAID or COD_CONFIRMED, then ALLOCATED, PACKED, SHIPPED, DELIVERED, with branches for PAYMENT_FAILED, EXPIRED, CANCELLED, RTO and REFUNDED. Each transition is allowed only from specific states. It is applied with a conditional update, such as setting the status to PAID only where the order ID matches and the status is still PAYMENT_PENDING, often guarded by a version number. This makes duplicate callbacks and racing workers harmless, because the second update matches nothing. Every transition also emits an event through the outbox. This makes the order history auditable and lets support, refunds and analytics rebuild the timeline, which matters for disputes.
14Should inventory be reserved at add-to-cart or at checkout during a flash sale?Very often asked
For a flash sale, I would reserve when the shopper commits to buy, at checkout or on a buy-now action, with a short hold. Reserving at add-to-cart lets many shoppers lock stock they never buy. Scarce deal units then look sold out while sitting in idle carts, which feels unfair and hurts conversion. Holds at checkout are short and tied to an active payment attempt. The cart only shows availability, which is a soft check. For limited deals, you can also enforce per-user quantity limits at reservation time. The trade-off is that a shopper may add an item to the cart and then find it sold out at checkout, so the UI must say clearly that the cart does not hold stock.
15Payment providers deliver callbacks at least once and sometimes out of order. How do you process them safely?Very often asked
Verify every callback's signature first and ignore anything unsigned or for an unknown order. Deduplicate by the gateway's transaction ID and our merchant order reference. Then apply it through the order state machine with conditional updates, so a late FAILED callback cannot overwrite an earlier SUCCESS. Finality rules depend on the gateway, and I treat a success confirmed by a status-check API as authoritative. Do not trust the client redirect alone, because the browser can lie or drop. Return a success acknowledgement to the gateway only after the result is durably stored, so it retries if we crash. Callbacks that arrive after a timeout go to reconciliation.
16How does the allocation service choose a fulfilment centre, and what trade-offs does it make?Often asked
It takes the confirmed order, finds the centres that hold the reserved units, and scores them. Factors include whether the centre can meet the promised delivery date to the shopper's pincode, its current pick and pack capacity and backlog, shipping cost and distance, and whether the order can ship complete from one centre instead of being split. The trade-off is between speed, cost and load balance. The nearest centre may be overloaded during the sale, so a farther one with spare capacity may meet the promise better. Ideally the reservation is already tied to a centre's stock, so allocation does not have to compete for units again. If capacity is exhausted, it should requeue with backoff.
17How do you get effectively exactly-once processing from an at-least-once event log?Often asked
True exactly-once across services is impractical, so you aim for at-least-once delivery with idempotent consumers. Each event carries a unique ID and the order ID. A consumer records processed event IDs, or uses a conditional state transition, in the same transaction as its side effect. A replayed event then does nothing. Commit the consumer offset only after the side effect is durable. Partition events by order ID so all events for one order are processed in sequence. For external side effects such as SMS or courier booking, pass an idempotency key to the downstream system too. Poison messages go to a dead-letter queue with alerts, instead of blocking the partition.
18What runs in a production-like load test before a big sale, and what makes it trustworthy?Often asked
It replays realistic traffic shapes: a sharp spike at sale start, hot-SKU skew, a realistic mix of browse and checkout, and a mix of payment methods. The traffic runs against production or a production-scale environment, with mocked or sandboxed payment partners and test accounts marked so that orders, inventory and metrics can be filtered out. To be trustworthy, it must use real data volumes and cache states, including cold-cache starts, and the same configurations and versions planned for sale day. Run it repeatedly as code changes, find the first bottleneck, fix it, and run it again. Record the safe throughput for each service, because that number sets the queue admission rate.
19What failure drills would you run before the sale?Often asked
Run game days that inject the failures we expect. Kill cache nodes and database replicas. Take down a whole zone. Add latency to a payment gateway or a single bank. Make a downstream service such as recommendations slow rather than dead, because slow is often worse. Pause the event broker to build consumer lag. Also practise operational steps: flipping degradation flags, lowering queue admission, rolling back a release and failing over a database. Each drill checks that alerts fire, dashboards show the issue, runbooks are correct, and people know who decides. Fix the gaps and repeat. The goal is that sale-day incidents feel like rehearsals.
20A feature freeze slows delivery. How would you justify it, and what exceptions would you allow?Often asked
Most outages come from changes, so freezing changes in the run-up means the sale runs on code and configuration that were load-tested and drilled. The capacity numbers stay valid, and the war room knows what is running. The cost is a backlog of features and slower iteration, so the freeze window should be clear and announced early. Exceptions should go through a tight approval path: security fixes, critical bug fixes found in tests, and pre-planned sale-day configuration such as deal setup and flag flips. Even exceptions need testing, a canary rollout and a rollback plan. Changes to configuration and data, like prices and deals, also need review, because those break sales too.
21How would you decide whether an order is eligible for cash on delivery?Often asked
Run a set of checks at checkout. Is COD supported at the destination pincode by the logistics network? Is the order value within allowed limits, and is the item category allowed? Does the account have a history of refusals or returns-to-origin? Are there signals of fraud or bulk reselling, such as many orders to one address? Are any deal-specific restrictions in place, since hot deals may limit COD? COD orders skip online payment, but they still go through reservation and idempotent order creation. Because COD ties up stock and logistics capacity without upfront money, refusals are costly, so the risk rules matter more during a sale.
22How is COD cash collected by Ekart reconciled back to orders?Often asked
At delivery, the agent's device records the outcome against the shipment ID: cash collected, digital payment collected, or refused. That event flows to the logistics and order systems and moves the order to DELIVERED with a payment-collected state. The cash the agent holds is deposited by the hub at the end of the day, and digital collections settle through the payment provider. Reconciliation jobs match expected amounts per shipment against deposits and settlements per agent and hub, and they flag mismatches for investigation. Shipments refused at the door become RTO and return to stock. All of this must be idempotent, because delivery devices may sync late or more than once on poor networks.
23What data store properties do you need for the inventory reservation path?Often asked
You need linearizable, atomic single-key updates, so a conditional decrement is correct under concurrency. You need durability, or at least a durable record of reservations, so a node crash does not resurrect sold units. You need low and predictable latency at high write rates on a few hot keys. That could be a strongly consistent database with conditional updates, or an in-memory store running atomic scripts, backed by a durable ledger and reconciliation. Eventually consistent multi-leader stores are risky here, because two regions could each sell the last unit. Keep each SKU's stock owned by one primary location, and accept that availability for that key depends on its primary.
24How do you prevent retry storms from turning a slowdown into an outage?Often asked
Clients and services should retry with exponential backoff and jitter, under a retry budget, and only on errors that are safe to retry. Every retried write must be idempotent. Put timeouts on every call, shorter than the caller's own deadline, and pass deadlines down the call chain. Use circuit breakers so a failing dependency gets fast failures and time to recover. Apply bulkheads by giving each dependency its own separate pool, so one slow partner cannot exhaust shared threads. At the top, the virtual queue and edge load shedding reduce incoming traffic when health drops. The app should show a friendly retry-later message, not let users hammer a refresh button.
25Which non-critical features would you degrade first, and how do you make degradation safe?Often asked
Rank features by how much they matter to buying. Recommendations, personalised widgets, reviews, Q&A, rich search facets and some analytics calls can go first. Search, the product page, cart, checkout, payment and order confirmation must stay. Each degradable feature sits behind a feature flag with a tested fallback, such as a static list, a cached value or hiding the module. Clients must handle a missing response gracefully. Flags should take effect quickly without a deploy, be changed by authorised people only, be audited, and have been flipped during drills. Degrade in steps and watch conversion and latency after each flip.
26How do you roll back fast during a sale if a change misbehaves?Often asked
Prefer changes that can be undone without a deploy. Ship new code behind flags that default off, and roll out gradually with canaries watched against error and latency limits. Keep the previous build ready, so rollback is a quick traffic switch or redeploy of a known artifact. Make database schema changes backward compatible using the expand-and-contract approach, so the old code still works on the new schema. Version configuration and deal data, with a one-step revert. In the war room, a named owner can roll back without debate when a threshold is crossed, and the team investigates afterwards. Rollback steps are practised before the sale.
27How would you protect customer and payment data in this flow?Often asked
Card data should not touch our servers in raw form. Use the payment gateway's hosted fields or SDK, and use network or issuer tokens for saved cards, as RBI's card-on-file tokenisation rules require. That keeps most systems out of PCI DSS scope. UPI and EMI flows exchange references, not credentials. Encrypt personal data such as addresses and phone numbers in transit and at rest. Restrict access by role, and mask data in logs and support tools. For delivery, share only what the agent needs, and consider masked calling. Follow India's DPDP Act on purpose limitation and retention. Verify webhook signatures, and keep payment amounts server-side only.
28How should EMI checkout differ from a plain card or UPI payment?Often asked
EMI adds eligibility and offer logic. It depends on the issuer or lender, card type, tenure, minimum order value and whether a no-cost EMI deal applies, where the interest is offset by discounts. These rules should be calculated server-side at checkout, alongside price re-verification, so the shopper sees the exact total, EMI amount and any fees before paying. The payment itself still uses the same idempotency key, hold and callback handling, but authorisation may take longer or need extra steps. The hold timeout must cover that. Card-less or pay-later EMI depends on a lender's approval, so it adds an external dependency that needs its own timeout, circuit breaker and fallback.
29What does the data model for reservations look like?Sometimes asked
The inventory table has one row per SKU, per fulfilment centre, per bucket, holding available and reserved counts and a version number. A reservation record holds the reservation ID, SKU, centre, quantity, user, order ID, status (HELD, CONSUMED or RELEASED) and an expiry time. The order record holds its ID, user, line items with locked prices, total, payment method, idempotency key with a unique constraint, state and version. A payment record holds the attempt ID, order ID, gateway reference, amount, status and timestamps. An outbox table stores events waiting to publish. Reserving inserts the hold and decrements available stock atomically. Consuming or releasing moves the hold's status once, guarded by a conditional update.
30How are expired holds released reliably at scale?Sometimes asked
Each hold has an expiry time. A sweeper scans for holds still in HELD status past their expiry, indexed by expiry time and sharded across workers. For each one, it runs a conditional update from HELD to RELEASED, and only if that succeeds does it add the unit back to stock. This makes double release impossible. Before releasing a hold whose payment is pending, it asks the payment service for status, so a payment that just succeeded is not undone. Delayed-queue messages or store-level TTL events can trigger releases sooner, but the sweeper remains the safety net. Releasing too slowly hides real stock, while releasing too eagerly creates paid-but-no-stock cases.
31How do edge rules tell real shoppers apart from bots at sale start?Sometimes asked
Combine several signals rather than relying on one. Use rate limits per IP, device and account. Check reputation lists, and use device and browser fingerprinting and app attestation where available. Look at behaviour such as inhuman speed, scripted paths or direct calls to checkout APIs without page loads. Use challenges such as a CAPTCHA only for suspicious traffic, so normal users are not slowed. Account-level controls matter for deals: verified accounts, per-user purchase limits and signed queue tokens. Watch for false positives, because mobile carriers in India often share IPs across many users through carrier-grade NAT, so strict per-IP limits can block real shoppers.
32How would you think about multi-zone or multi-datacentre resilience for the checkout path?Sometimes asked
Stateless services run across zones behind load balancers, so losing a zone means losing capacity, not function. Capacity planning should keep enough headroom to absorb that loss at peak. Stateful pieces are harder. Databases use synchronous replication within a region for failover without data loss. Inventory keys keep a single primary at a time to avoid split-brain oversell, and failover is fenced, so the old primary cannot accept writes. Cross-region active-active for stock is risky. The event log replicates across zones with acknowledgements from several brokers. All of this needs to be drilled, because untested failover often fails exactly when it is needed.
33While a payment is still pending, what should the shopper see, and why does it matter technically?Sometimes asked
Show a clear pending state: the order is being confirmed, do not pay again, and we will notify you. Also show a way to check status. Keep the shopper on a status page that polls our server, not the gateway. This matters technically because confused users retry. They pay again with a new method, open another tab or call support, which creates duplicate payment attempts and load. The idempotency key and a rule allowing one active payment per order or reservation limit the damage. A final notification by app push, SMS or email once the status resolves, and an automatic refund of any duplicate charge, keep trust high.
Objective questions 33
1Which approach most reliably prevents overselling when thousands of buyers hit one SKU at once?Asked almost every time
Why: An atomic conditional update makes the check and write one operation, so concurrent requests cannot both pass the check. Read-then-write has a race window.
2Which property must the checkout idempotency key have to prevent duplicate charges on retries?Asked almost every time
Why: Deduplication only works if every retry carries the same key. A fresh key per request makes each retry look like a new payment.
3Which pattern best ensures a paid order is published to the event log even if the service crashes right after the database commit?Asked almost every time
Why: The outbox row commits atomically with the order state, and the relay republishes until it succeeds. That removes the dual-write gap.
4A single hot SKU's stock row is the bottleneck. Which change keeps oversell impossible while improving throughput?Asked almost every time
Why: Each bucket still enforces stock greater than zero atomically, so the total cannot go negative, and writes spread across keys.
5A UPI payment callback has not arrived within the checkout timeout. What is the safest handling?Very often asked
Why: UPI confirmations can be delayed, so a pending state with status reconciliation avoids both lost paid orders and double charges.
6Duplicate payment callbacks arrive for the same order. What makes processing them safe?Very often asked
Why: Conditional transitions make repeats do nothing, and deduplication by gateway transaction ID stops double processing.
7Why is the price re-verified at checkout even though browse pages show a price?Very often asked
Why: Cached display data may lag behind price changes, so only a server-side verified price should set the amount charged.
8What is the main purpose of the virtual queue's admission rate?Very often asked
Why: Admitting at a tested rate keeps downstream services inside safe limits and gives orderly waiting instead of errors.
9How should a protected sale API confirm that a request was admitted by the virtual queue?Very often asked
Why: A signed, short-lived token bound to the account cannot be forged or easily shared, so the queue cannot be bypassed.
10Event consumers in the allocation pipeline receive the same event twice. What is the standard approach?Very often asked
Why: At-least-once delivery plus idempotent consumers is the practical way to get the effect of exactly-once processing.
11Why is order allocation to fulfilment centres usually done asynchronously via an event log?Often asked
Why: Decoupling via a durable log means checkout only has to record the order, while allocation can scale, retry and optimise separately.
12When should a hold be released if its payment attempt is still in progress?Often asked
Why: Releasing during an in-flight payment can create a paid order with no stock, so check payment status first.
13Which approach avoids a cache stampede when a hot key expires?Often asked
Why: Only one request rebuilds the key while others get a stale value or wait, so the database is not flooded.
14Why add random jitter to cache TTLs?Often asked
Why: Spreading expiry times avoids synchronised misses that would hit the origin all at once.
15Per-IP rate limits are tuned very aggressively for the sale in India. What is a likely side effect?Often asked
Why: Many mobile users share public IPs through carrier NAT, so strict per-IP limits cause false positives.
16Which change is most acceptable during a pre-sale feature freeze?Often asked
Why: Freezes allow tightly controlled exceptions such as critical fixes. Large untested changes are what freezes exist to stop.
17How should the order service guard state transitions against racing workers?Often asked
Why: Optimistic conditional updates let only one valid transition succeed, without heavy locks.
18What is the safest source of the amount sent to the payment gateway?Often asked
Why: Server-computed totals stop tampering and stale-cache charges.
19Under RBI rules, how should saved cards be handled for repeat checkouts?Often asked
Why: RBI's card-on-file tokenisation rules stop merchants from storing actual card data, so tokens are used.
20A slow, not dead, recommendations service is exhausting the shared threads of the product page. What is the best fix?Often asked
Why: Isolation and fast failure stop a slow dependency from taking down critical paths.
21Which retry policy is right for clients during a sale-time slowdown?Often asked
Why: Backoff with jitter and budgets prevents retry storms that make an overload worse.
22What does the allocation service primarily balance when choosing a fulfilment centre?Often asked
Why: Allocation weighs where stock is, whether the promise can be met, and current pick and pack capacity.
23Why is reserving stock at add-to-cart usually a poor choice for flash-sale deals?Often asked
Why: Many cart adds never convert, so early holds strand limited stock away from real buyers.
24Which store property is most important for the stock decrement?Sometimes asked
Why: Atomic conditional updates on one authoritative copy are what make oversell impossible.
25Why is active-active multi-region writing of the same SKU's stock risky?Sometimes asked
Why: Without a single owner or consensus, concurrent writes in each region can oversell.
26What is the main reason to deduplicate callbacks by gateway transaction ID?Sometimes asked
Why: Webhooks are typically at-least-once, so repeats must be recognised and ignored.
27A COD order is refused at the doorstep. What should happen to the order and stock?Sometimes asked
Why: Refusals become RTO shipments, and the unit returns to sellable stock after receipt.
28What makes a pre-sale load test trustworthy?Sometimes asked
Why: Results only predict sale-day behaviour if the environment and load mirror reality and are re-run as code changes.
29Which is the best first lever when checkout latency crosses its threshold during the sale?Sometimes asked
Why: Pre-tested flags and admission control reduce load quickly and safely, without risky changes.
30Why should schema changes be backward compatible before a sale?Sometimes asked
Why: Expand-and-contract changes let old and new code run on the same schema, which keeps fast rollback possible.
31How should the hold timeout relate to the payment timeout?Sometimes asked
Why: If holds expire before payments resolve, successful payments can lose their stock.
32Why partition order events by order ID in the log?Rarely asked
Why: A partition preserves order, so keying by order ID processes that order's events sequentially.
33Which reconciliation catches a payment captured by the gateway with no matching confirmed order?Rarely asked
Why: Matching settlements to orders finds orphaned payments, which are then repaired or refunded.
Track your progress through every blueprint in your dashboard.
Start learning