I'm new to Spark, and I'm trying to understand what are the benefit of using broadcast var on using singleton wrapper. I am aware that Spark also attempts to distribute broadcast variables using efficient broadcast algorithms to reduce communication cost- yet let's assume this happens once on a long living application, hence is not an overhead.
is each task will hold a copy of the singelton or only the executor itself?
I'm trying to understand how it works with singleton and compare it to broadcast.
If this question repeat itself, please let me know, since I didn't find once that were answered.