The Fifth Elephant 2019

Gathering of 1000+ practitioners from the data ecosystem

Real-time fraud detection with Kafka Streams

Submitted by Navinder Pal Singh Brar (@navinder) on Jun 5, 2019

Session type: Short talk of 20 mins Status: Rejected


One of the major use cases for stream processing is real-time fraud detection. Walmart just launched a new subscription package where it provides free delivery for users who are enrolled with a monthly subscription, which can be misused sometimes. Since the fraud detection model runs on each transaction and comes with very tight SLAs, we had to increase availability in our Kafka streams cluster and reduce latency. I will be discussing this architecture along with problems we faced, such as frequent rebalancing, high latency, invariably large assignment size, and excessive data movement after every deployment. The below features will be discussed in detail:
•Smart Client: A client library to query the precise machine and get data for a customer to reduce interactive queries
•Read from replicas: During bulk ingestion of events, CPU usage is at the peak in the machines which leads to high latency, so we had to support read from replicas to counter that
•Read while rebalancing: During rebalancing, Streams cluster doesn’t serve queries, but since availability is of foremost importance we enabled reads during rebalancing
•Reading from a store of specific partition: Currently, Kafka streams iterates over each partition of a store via composite stores to find the key, we enabled direct read into the partition where the key is present
•Backup and Restore feature: Developed backup and restore feature for all the data stored in RocksDB, if the state gets corrupted due to some bug or any other reasons
Key Takeaways:
•Lessons learned from using Kafka streams as data as a service
•Modifying Kafka Streams to fit availability-first use cases


Key Takeaways:
•Lessons learned from using Kafka streams as data as a service
•Modifying Kafka Streams to fit availability-first use cases


Basic understanding of Kafka Streams

Speaker bio

Navinder is working as a data engineer in Walmart Labs where he has been working with Kafka ecosystem for the last couple of years, especially Kafka Streams and created a new platform on top of it to suit their needs to process billions of events per day in real time and trigger models on each event. He has been active in contributing back to Kafka Streams and has patented few features as well. He is interested in solving complex problems and distributed systems and likes to spend time in gym and boxing ring in his spare time.


  • Abhishek Balaji (@booleanbalaji) a year ago

    Hi Navinder,

    Thank you for submitting a proposal. We need to see detailed slides and a preview video to evaluate your proposal. Your slides must cover the following:

    • Problem statement/context, which the audience can relate to and understand. The problem statement has to be a problem (based on this context) that can be generalized for all.
    • What were the tools/frameworks available in the market to solve this problem? How did you evaluate these, and what metrics did you use for the evaluation? Why did you pick the option that you did?
    • Explain how the situation was before the solution you picked/built and how it changed after implementing the solution you picked and built? Show before-after scenario comparisons & metrics.
    • What compromises/trade-offs did you have to make in this process?
    • What is the one takeaway that you want participants to go back with at the end of this talk? What is it that participants should learn/be cautious about when solving similar problems?

    We need your updated slides and preview video by Jun 17, 2019 to evaluate your proposal. If we do not receive an update, we’d be moving your proposal for evaluation under a future event.

  • Abhishek Balaji (@booleanbalaji) a year ago

    Marked as rejected since proposer hasnt responded to comments/updated content before deadline. Will be considered for a future event if content is updated.

Login to leave a comment