Sanjaay Gowda T S
Mastercard Incorporated practice

ORIGINAL COMPANY-CONTEXT PRACTICE

Accept a clearing batch without silently losing records

System designHardConcept

Original practice scenario: A hypothetical payment-processing service receives numbered clearing files from a partner. Files can be retransmitted, arrive out of order or contain malformed records. Design acceptance and reconciliation.

Written for independent practice using company context; this is not a verified question from a company interview.

A REASONED APPROACH

Model answer.

Separate transport receipt, file validation and business acceptance. A successful upload must not imply that every clearing record was accepted or that an expected file actually arrived.

Work through it

  1. Identify the partner, business date, file sequence and content fingerprint; distinguish identical retries from conflicting content under the same identity.
  2. Validate the complete envelope and declared record controls, staging records before an atomic acceptance decision or an explicit record-level exception policy.
  3. Track expected versus received file sequences and reconcile accepted counts and amounts, returning durable receipts that support replay and operator investigation.

Tradeoffs to discuss

  • File-level atomicity simplifies reconciliation but rejects valid records alongside a defect; partial acceptance requires detailed receipts and careful retry semantics.

Common pitfalls

  • A missing sequence is different from an empty valid file.
  • Never repair control totals by dropping unmatched records or assuming retransmitted content is necessarily identical.

KEEP PRACTISING

Related questions.

Keep learning beyond the interview.

Explore the Learning Hub