15. • Basic Assumption : Batch jobs have full data-
set
• But, how about edges?
Data Accuracy - with Lambda
Smaller batch size == more edges!
Graph kudos to Stream Processing 101 from Tyler Akidau
(https://www.oreilly.com/ideas/the-world-beyond-batch-streaming-101)
10:00 11:00 12:00 13:00 system time
17. Observation
• Data Accuracy is still very hard with Lambda
–Additional system (e.g. Kafka Audit) has to be
used to safely start the batch jobs
• Duplication in Online/Offline system:
–Development cost
–Operational overhead
–Maintenance overhead
18. Going Lambda-less
• Handle late arrivals and out of order arrivals
• Eventually correct results
– Compute results at end of ‘window’.
– Re-compute when events arrives late
• Influenced by “Google MillWheel”
21. Handling ‘out of order arrival’
1:01pm1:02pm
1:00pm1:02pm
null join result in
window(“1:00pm”, “2min”)
Kafka
Kafka
AdViewEvent
AdClickEvent
AdQuality processor
22. Handling ‘out of order arrival’
1:01pm1:02pm1:00pm1:01pm
1:00pm1:02pm
Re-compute
window(“1:00pm”, “2min”)
Out-of-order arrival
Kafka
Kafka
AdViewEvent
AdClickEvent
AdQuality processor
32. Reprocessing - entire Dataset
Profile
Updates
(Samza) Title-
Standardizer
(Samza) Title-
Standardizer
BootstrapBackup
Machine Learning
model (NEW)
output
Kafka
Databus
Databus
(Samza)
Merge and
Store
Results
33. Reprocessing- Caveats
• Stream processors are fast.. They can DOS the
system if you reprocess
– Control max-concurrency of your job
– Quotas for Kafka, Databases
• Reprocessing a 100 TB source ?
–Capacity ?
–Saturation of NICs, Top of rack switches
34. Reprocessing larger datasets
Profile
Updates
(Samza) Title-
Standardizer
Machine Learning
model
output
Kafka
Databus
(Samza)
Merge and
Store
Results
Database
Dump in
HDFS
(Samza) Title-
Standardizer
ML Model in
HDFS
Hadoop
35. Experimentation
Database
Dump in HDFS
(Samza) Title-
Standardizer
Hadoop
ML Model in
HDFS
Output in HDFS
● Offline experimentation before pushing the logic online
○ Most datasets are already available in Hadoop (at LinkedIn)
○ Fast Iteration with minimum impact to production
36. Conclusion
1.It is possible to avoid code
duplication(hot/cold path) to support
– Accuracy
–Reprocessing
2. Some Lambda related problems still linger
when reprocessing entire datasets
–e.g. merging online/reprocessing results