You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@spark.apache.org by "Xiao Li (JIRA)" <ji...@apache.org> on 2018/09/09 04:04:00 UTC

[jira] [Updated] (SPARK-23880) table cache should be lazy and don't trigger any job

     [ https://issues.apache.org/jira/browse/SPARK-23880?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Xiao Li updated SPARK-23880:
----------------------------
    Summary: table cache should be lazy and don't trigger any job  (was: table cache should be lazy and don't trigger any jobs.)

> table cache should be lazy and don't trigger any job
> ----------------------------------------------------
>
>                 Key: SPARK-23880
>                 URL: https://issues.apache.org/jira/browse/SPARK-23880
>             Project: Spark
>          Issue Type: Improvement
>          Components: SQL
>    Affects Versions: 2.3.0
>            Reporter: Wenchen Fan
>            Assignee: Takeshi Yamamuro
>            Priority: Major
>             Fix For: 2.4.0
>
>
> {code}
> val df = spark.range(10000000000L)
>   .filter('id > 1000)
>   .orderBy('id.desc)
>   .cache()
> {code}
> This triggers a job while the cache should be lazy. The problem is that, when creating `InMemoryRelation`, we build the RDD, which calls `SparkPlan.execute` and may trigger jobs, like sampling job for range partitioner, or broadcast job.
> We should create the RDD at physical phase.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

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