Uploaded image for project: 'Spark'
  1. Spark
  2. SPARK-4094

checkpoint should still be available after rdd actions

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Resolved
    • Major
    • Resolution: Won't Fix
    • 1.1.0
    • None
    • Spark Core
    • None

    Description

      rdd.checkpoint() must be called before any actions on this rdd, if there is any other actions before, checkpoint would never succeed. For the following code as example:

      rdd = sc.makeRDD(...)
      rdd.collect()
      rdd.checkpoint()
      rdd.count()

      This rdd would never be checkpointed. For algorithms that have many iterations would have some problem. Such as graph algorithm, there will have many iterations which will cause the RDD lineage very long. So RDD may need checkpoint after a certain iteration number. And if there is also any action within the iteration loop, the checkpoint() operation will never work for the later iterations after the iteration which calls the action operation.

      But this would not happen for RDD cache. RDD cache would always make successfully before rdd actions no matter whether there is any actions before cache().
      So rdd.checkpoint() should also be with the same behavior with rdd.cache().

      Attachments

        Issue Links

          Activity

            People

              liyezhang556520 Zhang, Liye
              liyezhang556520 Zhang, Liye
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: