Free Online Certification Courses – Learn Today. Lead Tomorrow. › Forums › Apache Spark › what is action, how it process data in apache spark
- This topic has 2 replies, 1 voice, and was last updated 5 years, 7 months ago by DataFlair Team.
-
AuthorPosts
-
-
September 20, 2018 at 4:27 pm #5856DataFlair TeamSpectator
Explain briefly what is Action in Apache Spark, how action is used to generate final results ?
Provide some examples of actions. -
September 20, 2018 at 4:27 pm #5859DataFlair TeamSpectator
Actions return final result of RDD computations/operation.It triggers execution using lineage graph to load the data into original RDD, and carries out all intermediate transformations and returns final result to Driver program or write it out to file system.
For example: First, take, reduce, collect, count, aggregate are some of the actions in spark.
Action produces a value back to the Apache Spark driver program. It may trigger a previously constructed, lazy RDD to be evaluated. It is an RDD operations that produce non-RDD values. Action function materializes a value in a Spark program. So basically an action is RDD operation that returns a value of any type but RDD[T] is an action. Actions are one of two ways to send data from executors to the driver (the other being accumulators).
For detail study of Action refer Transformation and Action in Apache Spark.
-
September 20, 2018 at 4:27 pm #5861DataFlair TeamSpectator
Actions are RDD operations that give non-RDD values. Actions return final results of RDDcomputations.
All the execution the pending transformation are performed once Action is triggered mentioned in lineage graph and return final results to Driver program or write it out to file system.Example of actions are:
take,count,min,max,sumFor detailed study of RDD operation refer RDD-Transformation and Action.
-
-
AuthorPosts
- You must be logged in to reply to this topic.