Dataford
Interview QuestionsInterview GuidesExperiencesCoaching
New
Pricing
Get started
Dataford
Popular roles
Software EngineerData AnalystData ScientistData EngineerBusiness AnalystAI EngineerMachine Learning EngineerProduct Manager
Browse
Browse All RolesEvery role hub, from analyst to MLBrowse All CompaniesCompany-specific interview loopsAll Interview GuidesThe full guide library
Top questions by role
Software EngineerData AnalystData ScientistData EngineerBusiness AnalystAI EngineerMachine Learning EngineerProduct Manager
Top questions by skill
SQLPythonStatisticsMachine LearningA/B TestingSystem DesignGenerative AIProduct SenseMetricsBehavioral
Browse all questions →Try a mock interview
Experiences
Practice
Mock InterviewsTimed interview simulations with feedbackCoaching1:1 coaching with people at your target companiesSuccess PathYour 6-week structured planModulesCurated lessons by topicWebinarsTalks from ex-Big Tech data leadsPlaygroundA free-form scratch editor
Learn
BlogInterview strategy and career adviceTech Job Market ReportHiring trends across data and AI rolesFor UniversitiesDataford for career centersAbout DatafordWho we are and how we build
Pricing
Build my plan

Fraud Detection Batch vs Streaming

MediumPipelines00:00
Practice interviewer
In session
5 left
00:00

Your question is Fraud Detection Batch vs Streaming. Take a moment with it on the right.

Talk me through your thinking if you like. When you're confident, submit your answer and I'll grade it like a real screen (7/10 or better passes).

You need to log in / sign up to chat or submit.

Problem

Context

PayWave, a digital payments platform processing card-not-present transactions, currently runs hourly batch fraud scoring with Apache Spark on S3-backed transaction logs. Fraud analysts want sub-second blocking for high-risk payments, but the finance team still needs complete, reconciled datasets for investigations, chargebacks, and model retraining.

You need to design a fraud data pipeline and explain the trade-offs between batch and stream processing, including whether to use one approach or a hybrid architecture.

Scale Requirements

  • Transaction volume: 120K transactions/second peak, 25K average
  • Event size: ~1.5 KB JSON per authorization event
  • Daily data volume: ~8 TB raw transaction + device + merchant events
  • Decision latency: P95 < 300 ms for online fraud decisions
  • Batch SLA: Reconciled fraud fact tables available within 30 minutes of hour close
  • Retention: 13 months hot storage, 7 years archived for compliance

Requirements

  1. Design ingestion for real-time transaction, device fingerprint, and merchant risk events.
  2. Support online fraud scoring for payment authorization decisions with low latency.
  3. Build batch reconciliation to correct late, duplicated, or out-of-order events and produce investigation-ready tables.
  4. Define how features such as card velocity, merchant anomaly counts, and device reuse are computed in streaming vs batch.
  5. Ensure idempotent processing, replay capability, and auditable lineage from raw event to fraud decision.
  6. Describe orchestration, monitoring, and failure recovery for both real-time and batch paths.
  7. Explain the trade-offs in accuracy, latency, cost, operational complexity, and recovery when choosing batch, streaming, or hybrid.

Constraints

  • Existing stack is AWS-first: MSK, S3, EMR, Airflow, Snowflake
  • Incremental budget is capped at $40K/month
  • PCI and SOC 2 controls apply; PII must be encrypted in transit and at rest
  • Team has strong Spark/Airflow experience but limited expertise operating low-latency stateful streaming at scale