Procedural Programming vs Data Flow
summary
Argument: Flink is a parallel dataflow engine where datasets are lazy datasets not values and cannot be nested; common procedural patterns must be reworked into scalable primitives. Concrete examples: mean computed by mapping each element to (value,1), reducing to (sum,count) and dividing; centering done by cross or by sending the one-element mean as a broadcast dataset (accessed in RichMap.open as a Java collection); least-squares done by mapping points to outer-product matrices, reducing their sum, then solving the small linear system locally. Uses Apache Flink Scala API, Flink ML (Breeze-backed vectors).
AI-written summary · about
