Fault tolerance
In a streaming application there are typically three types of guarantees available, as follows:
Figure 5.11: Typical guarantees offered by a streaming application
In a streaming application, which generally comprises of data receivers, transformers, and components, producing different output failures can happen.
Figure 5.12: Components of a streaming application
Worker failure impact on receivers
When a Spark worker fails, it can impact the receiver that might be in the midst of reading data from a source.
Suppose you are working with a source that can be either a reliable filesystem or a messaging system such as Kafka/Flume, and the worker running the receiver responsible for getting the data from the system and replicating it within the cluster dies. Spark has the ability to recover from failed receivers, but its ability depends on the type of data source and can range from at least once to exactly once semantics.
If the data is being received from fault-tolerant systems such...