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

AQE plan string should only display one plan when the initial and the current plan are the same

    XMLWordPrintableJSON

    Details

    • Type: Improvement
    • Status: Resolved
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: 3.1.0
    • Fix Version/s: 3.1.0
    • Component/s: SQL
    • Labels:
      None

      Description

      Currently, the AQE plan string displays both the initial plan and the current or the final plan. This can be redundant when the initial plan and the current physical plan are exactly the same. For instance, the `EXPLAIN` command will not actually execute the query, and thus the plan string will never change, but currently, the plan string still shows both the current and the initial plan:

       

      AdaptiveSparkPlan (8)
      +- == Current Plan ==
         Sort (7)
         +- Exchange (6)
            +- HashAggregate (5)
               +- Exchange (4)
                  +- HashAggregate (3)
                     +- Filter (2)
                        +- Scan parquet default.explain_temp1 (1)
      +- == Initial Plan ==
         Sort (7)
         +- Exchange (6)
            +- HashAggregate (5)
               +- Exchange (4)
                  +- HashAggregate (3)
                     +- Filter (2)
                        +- Scan parquet default.explain_temp1 (1)
      

      When the initial and the current plan are the same, there should be only one plan string displayed. For example

      AdaptiveSparkPlan (8)
      +- Sort (7)
         +- Exchange (6)
            +- HashAggregate (5)
               +- Exchange (4)
                  +- HashAggregate (3)
                     +- Filter (2)
                        +- Scan parquet default.explain_temp1 (1)

       

        Attachments

          Activity

            People

            • Assignee:
              allisonwang-db Allison Wang
              Reporter:
              allisonwang-db Allison Wang
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: