A set of asynchronous RDD actions available through an implicit conversion.
:: DeveloperApi :: An RDD that cogroups its parents.
:: DeveloperApi :: An RDD that cogroups its parents. For each key k in parent RDDs, the resulting RDD contains a tuple with the list of values for that key.
This is an internal API. We recommend users use RDD.cogroup(...) instead of instantiating this directly.
Extra functions available on RDDs of Doubles through an implicit conversion.
:: DeveloperApi ::
An RDD that provides core functionality for reading data stored in Hadoop (e.g., files in HDFS,
sources in HBase, or S3), using the older MapReduce API (org.apache.hadoop.mapred
).
:: DeveloperApi ::
An RDD that provides core functionality for reading data stored in Hadoop (e.g., files in HDFS,
sources in HBase, or S3), using the older MapReduce API (org.apache.hadoop.mapred
).
Instantiating this class directly is not recommended, please use
org.apache.spark.SparkContext.hadoopRDD()
An RDD that executes a SQL query on a JDBC connection and reads results.
An RDD that executes a SQL query on a JDBC connection and reads results. For usage example, see test case JdbcRDDSuite.
:: DeveloperApi ::
An RDD that provides core functionality for reading data stored in Hadoop (e.g., files in HDFS,
sources in HBase, or S3), using the new MapReduce API (org.apache.hadoop.mapreduce
).
:: DeveloperApi ::
An RDD that provides core functionality for reading data stored in Hadoop (e.g., files in HDFS,
sources in HBase, or S3), using the new MapReduce API (org.apache.hadoop.mapreduce
).
Instantiating this class directly is not recommended, please use
org.apache.spark.SparkContext.newAPIHadoopRDD()
Extra functions available on RDDs of (key, value) pairs where the key is sortable through an implicit conversion.
Extra functions available on RDDs of (key, value) pairs where the key is sortable through
an implicit conversion. They will work with any key type K
that has an implicit Ordering[K]
in scope. Ordering objects already exist for all of the standard primitive types. Users can also
define their own orderings for custom types, or to override the default ordering. The implicit
ordering that is in the closest scope will be used.
import org.apache.spark.SparkContext._ val rdd: RDD[(String, Int)] = ... implicit val caseInsensitiveOrdering = new Ordering[String] { override def compare(a: String, b: String) = a.toLowerCase.compare(b.toLowerCase) } // Sort by key, using the above case insensitive ordering. rdd.sortByKey()
Extra functions available on RDDs of (key, value) pairs through an implicit conversion.
::DeveloperApi:: A PartitionCoalescer defines how to coalesce the partitions of a given RDD.
::DeveloperApi:: A PartitionCoalescer defines how to coalesce the partitions of a given RDD.
::DeveloperApi::
A group of Partition
s
::DeveloperApi::
A group of Partition
s
:: DeveloperApi :: An RDD used to prune RDD partitions/partitions so we can avoid launching tasks on all partitions.
:: DeveloperApi :: An RDD used to prune RDD partitions/partitions so we can avoid launching tasks on all partitions. An example use case: If we know the RDD is partitioned by range, and the execution DAG has a filter on the key, we can avoid launching tasks on partitions that don't have the range covering the key.
A Resilient Distributed Dataset (RDD), the basic abstraction in Spark.
A Resilient Distributed Dataset (RDD), the basic abstraction in Spark. Represents an immutable,
partitioned collection of elements that can be operated on in parallel. This class contains the
basic operations available on all RDDs, such as map
, filter
, and persist
. In addition,
org.apache.spark.rdd.PairRDDFunctions contains operations available only on RDDs of key-value
pairs, such as groupByKey
and join
;
org.apache.spark.rdd.DoubleRDDFunctions contains operations available only on RDDs of
Doubles; and
org.apache.spark.rdd.SequenceFileRDDFunctions contains operations available on RDDs that
can be saved as SequenceFiles.
All operations are automatically available on any RDD of the right type (e.g. RDD[(Int, Int)])
through implicit.
Internally, each RDD is characterized by five main properties:
All of the scheduling and execution in Spark is done based on these methods, allowing each RDD to implement its own way of computing itself. Indeed, users can implement custom RDDs (e.g. for reading data from a new storage system) by overriding these functions. Please refer to the Spark paper for more details on RDD internals.
Extra functions available on RDDs of (key, value) pairs to create a Hadoop SequenceFile, through an implicit conversion.
Extra functions available on RDDs of (key, value) pairs to create a Hadoop SequenceFile, through an implicit conversion.
This can't be part of PairRDDFunctions because we need more implicit parameters to convert our keys and values to Writable.
:: DeveloperApi :: The resulting RDD from a shuffle (e.g.
:: DeveloperApi :: The resulting RDD from a shuffle (e.g. repartitioning of data).
the key class.
the value class.
the combiner class.
Defines implicit functions that provide extra functionalities on RDDs of specific types.
Defines implicit functions that provide extra functionalities on RDDs of specific types.
For example, RDD.rddToPairRDDFunctions converts an RDD into a PairRDDFunctions for
key-value-pair RDDs, and enabling extra functionalities such as PairRDDFunctions.reduceByKey
.
Provides several RDD implementations. See org.apache.spark.rdd.RDD.