You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@spark.apache.org by GitBox <gi...@apache.org> on 2019/05/17 12:00:28 UTC

[GitHub] [spark] ScrapCodes commented on a change in pull request #24585: [Spark-27664][SQL] Performance issue while listing large number of files on an object store.

ScrapCodes commented on a change in pull request #24585: [Spark-27664][SQL] Performance issue while listing large number of files on an object store.
URL: https://github.com/apache/spark/pull/24585#discussion_r285095299
 
 

 ##########
 File path: sql/catalyst/src/main/scala/org/apache/spark/sql/internal/SQLConf.scala
 ##########
 @@ -585,6 +585,17 @@ object SQLConf {
       .longConf
       .createWithDefault(250 * 1024 * 1024)
 
+  val HIVE_FILESOURCE_FILE_CACHE_CONCURRENCY_LEVEL =
+    buildConf("spark.sql.hive.filesourceFileCacheConcurrencyLevel")
+      .doc("Provide concurrency level for underlying guava cache. The default is 1." +
+        " Higher value may give better performance, when the number of " +
 
 Review comment:
   A large concurrency value has the following effect.
   Size of each entry is limited by the value `totalCacheCapacity/concurrencyLevel` in guava cache. So if the value of `concurrencyLevel` is for example 4, then the maximum size of a single entry in the cache cannot be greater than 250MB/4 i.e. 62.5MB. 
   Unless a user creates a HIVE table and setup partitions by specifying in the create table format, the entire cache is just a single entry. So, when listing content in a large directory, the requirement of cache is also large. This effect becomes evident, when listing a large directory of greater 100K items. See my other comment for how to reproduce. 

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org