Real-Time Payment Alerting with Apache Flink Event-Time Windows versus Spark Micro-Batches
How soon does a streaming engine raise a payment alert, and does it get the alert right when payments arrive out of order? A seeded generator produces 300,293 card payments with injected fraud patterns and a known delay for every payment; the stream is sent into Apache Kafka at its arrival times, once for each arm. The same three rules on 30-second event-time windows per card - defined once as SQL - run in Apache Flink (PyFlink and Flink SQL, standalone cluster) and in Spark Structured Streaming (micro-batches), each with watermarks of 2 s and 10 s, plus a 5-second Spark trigger and a processing-time Flink ablation.
NOTE: Synthetic payment stream from a seeded generator (no personal data) with known out-of-order and late payments; the same three window rules in Apache Flink and Spark Structured Streaming, each fed the same stream through Kafka one arm at a time; every engine ran locally on a standard laptop.
Category: Big Data
Big Data Project BD02 from ProTechSC Academy, with graphical abstract, video demonstration and project guidance.