You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@spark.apache.org by Amit Sela <am...@gmail.com> on 2016/11/22 20:49:15 UTC

Fault-tolerant Accumulators in stateful operators.

Hi all,

To recover (functionally) Accumulators from Driver failure in a streaming
application, we wrap them in a "getOrCreate" Singleton as shown here
<https://github.com/apache/spark/blob/master/examples/src/main/scala/org/apache/spark/examples/streaming/RecoverableNetworkWordCount.scala#L123>
.
I was wondering how that works if I use the Accumulators inside a
mapWithState/updateStateByKey operator ? Has anyone used Accumulators in
one of the stateful operators ?

Thanks,
Amit