Apache Spark : Memory management and Graceful degradation
Many of the concepts of Apache Spark are pretty straightforward and easy to understand, however some lucky few can be badly misunderstood. One of the greatest misunderstanding of all is the fact that some still believe that "Spark is only relevant with datasets that can fit into memory, otherwise it will crash".
This is an understanding mistake, Spark being easily associated as a "Hadoop using RAM more efficiently", but it still is a mistake.
Spark is by default doing the best it can to load the datasets it handles in memory. Still when the handled datasets are too large to fit into memory, automatically (or should i say auto-magically) these objects will be spilled to disk. This is one of the main features of Spark coined by the expression "graceful degradation" and it was very well illustrated by these two charts in Matei Zaharia's dissertation : An Architecture for Fast and General Data Processing on Large Clusters :
[caption id="attachment_1211" align="aligncenter" width="660"]
Newsletter
Stay updated with new articles.
Keep reading
Changing Spark's default java serialization to Kryo
Apache Spark's default serialization relies on Java with the default *readObject(...)* and *writeObject(...)* methods for all **Serializable**classes. This is a very fine default behavior as long as y...
Jan 9, 2015
RDDs are the new bytecode of Apache Spark
With the Apache Spark 1.3 release the Dataframe API for Spark SQL got introduced, for those of you who missed the big announcements, I'd recommend to read the article : [Introducing Dataframes in Spar...
May 29, 2015From Pandas to Apache Spark's Dataframe
With the introduction in Spark 1.4 of Window operations, you can finally port pretty much any relevant piece of Pandas' Dataframe computation to Apache Spark parallel computation framework using Spark...
Jul 31, 2015
No comments yet. Be the first to comment!