- Resilient distributed dataset (RDD)
- A read-only collection of objects partitioned across a set of machines that can be rebuilt if a partition is lost. Its elements need not exist in physical storage; the handle carries enough information to compute the dataset from data in reliable storage.
- Lineage
- The chain of dataset objects recording, for each RDD, a pointer to its parent and how the parent was transformed. Spark replays this chain to recompute just a lost partition, instead of checkpointing and rolling back.
- Working set
- A body of data that an application reuses across multiple parallel operations, as in iterative machine learning or repeated interactive queries. It is the workload class that acyclic data flow systems handle badly and that Spark is designed for.
- Parallel operation
- An action that triggers computation on an RDD by shipping a closure to workers: reduce, which combines elements with an associative function and returns to the driver, collect, which sends all elements to the driver, and foreach, which runs a function for its side effects.
- Driver program
- The user's main program, which implements the application's high-level control flow, defines RDDs and shared variables, and launches parallel operations on the cluster. All reduce and collect results return to it.
- Broadcast variable
- A wrapper around a large read-only value that ensures the value is copied to each worker only once instead of being packaged with every closure. Its serialized form is just a path to a file in a shared file system, and it is reusable across parallel operations.
- Accumulator
- A shared variable that workers can only add to using an associative operation and that only the driver can read, defined for any type with an add operation and a zero value. Its add-only semantics make it easy to make fault tolerant, and the driver applies each partition's updates only once.
- cache action
- A persistence change that leaves an RDD lazy but hints that its partitions should be kept in memory after first computation. It is only a hint: if cluster memory is insufficient, Spark recomputes the partitions when they are used.
- Preferred locations
- The per-partition placement hints returned by getPreferredLocations and used by delay scheduling to send each task where its data lives. For a cached dataset they start as the parent's locations and are updated once a partition is cached on a node.