internalsGet Pro

Module 10 · Lesson 12 of 13Pro

Case: Razorpay’s fraud checks in 200 ms with Flink

Level
Advanced
Topic
Stream processing with Flink
Reading time
18 min

When you finish this page you can

  1. Trace an event through Razorpay’s Mitra engine, from its two Kafka streams to a prediction, and name what each part does.
  2. Explain with numbers why Razorpay keeps features in Flink’s keyed state instead of looking them up per payment.
  3. Write a pattern over a card’s payment attempts with Flink SQL’s MATCH_RECOGNIZE, and say what waiting for the watermark costs it.
  4. Decide which of Razorpay’s choices Kartly’s fraud-signals job needs now, and which can wait.

Builds on 4 lessons

Start with lesson 317 min
  1. Windows: tumbling, sliding and session17 min
  2. Watermarks: deciding when late events stop counting17 min
  3. Stateful stream processing and state backends18 min
  4. Flink SQL: streaming with SQL17 min

A ₹150 screen guard, then two ₹22,000 phones

is an online store in India. At this stage its checkout service sees about 600,000 payment attempts a day, up to about 300 a second in a festival sale. Each attempt goes to topic kartly.payment-attempts in Kafka. Meera, a data engineer, has been asked to build fraud-signals, a Flink job that turns those attempts into signals the checkout’s risk check can read within its 200 ms budget.

Our biggest sale ever · Black Friday

Flat 50% Off

Pro

Continue reading

Unlock every course, now and later

  • System Design, live
  • AI Engineering, live
  • Data Engineering, live
  • Machine Learning Engineering, live
  • Inference Engineering, coming soon
  • AI Research, coming soon
  • Performance Engineering, coming soon
  • Agent & Harness Engineering, coming soon
  • LLM Fine-tuning, coming soon
  • LLM Pre-training & Post-training, coming soon
  • Reinforcement Learning, coming soon
  • AI Infrastructure & Platform Engineering, coming soon
  • AI Evaluation & Safety, coming soon
  • Forward Deployed Engineering, coming soon
  • Cloud Computing, coming soon
  • DevOps, coming soon

50% off · Annual and Lifetime

BLACKFRIDAY50Applied at checkout

Choose a plan