File tree Expand file tree Collapse file tree 2 files changed +4
-2
lines changed
sql/core/src/main/scala/org/apache/spark/sql Expand file tree Collapse file tree 2 files changed +4
-2
lines changed Original file line number Diff line number Diff line change @@ -22,6 +22,7 @@ import java.util.Properties
2222import scala .collection .JavaConverters ._
2323
2424object SQLConf {
25+ val COMPRESS_CACHED = " spark.sql.inMemoryColumnarStorage.compressed"
2526 val AUTO_BROADCASTJOIN_THRESHOLD = " spark.sql.autoBroadcastJoinThreshold"
2627 val SHUFFLE_PARTITIONS = " spark.sql.shuffle.partitions"
2728 val DEFAULT_SIZE_IN_BYTES = " spark.sql.defaultSizeInBytes"
@@ -49,6 +50,9 @@ trait SQLConf {
4950 /** ************************ Spark SQL Params/Hints ******************* */
5051 // TODO: refactor so that these hints accessors don't pollute the name space of SQLContext?
5152
53+ /** When true tables cached using the in-memory columnar caching will be compressed. */
54+ private [spark] def useCompression : Boolean = get(COMPRESS_CACHED , " false" ).toBoolean
55+
5256 /** Number of partitions to use for shuffle operators. */
5357 private [spark] def numShufflePartitions : Int = get(SHUFFLE_PARTITIONS , " 200" ).toInt
5458
Original file line number Diff line number Diff line change @@ -192,8 +192,6 @@ class SQLContext(@transient val sparkContext: SparkContext)
192192 currentTable.logicalPlan
193193
194194 case _ =>
195- val useCompression =
196- sparkContext.conf.getBoolean(" spark.sql.inMemoryColumnarStorage.compressed" , false )
197195 InMemoryRelation (useCompression, executePlan(currentTable).executedPlan)
198196 }
199197
You can’t perform that action at this time.
0 commit comments