Uploaded image for project: 'Couchbase Server'
  1. Couchbase Server
  2. MB-55308

[CX] Graphical explain plan broken

    XMLWordPrintable

Details

    • Untriaged
    • 0
    • Unknown
    • Analytics CBO Sprint 13

    Description

      As a result of MB-54096, we add cardinality and cost information to the JSON explain plan as shown below:

      Specifically, we add the following to the EXPLAIN plan.

      estimated per-operator cardinality
      estimated per-operator cost
      estimated total cost for the plan up to the current operator
      estimated cardinality for the whole plan
      estimated total cost for the whole plan

      Example snippet of query plan:

      "requestID": "01af0e04-c950-4f6d-878b-05cd4c43c5a0",
      "signature":

      { "*": "*" }

      ,
      "results": [ {
      *"cardinality" : 15.0,
      "cost" : 5021.1,
      "plan" : {*
      "operator" : "distribute-result",
      "expressions" : [
      "$$36"
      ],
      "operatorId" : "1.1",
      "runtime-id" : "ODID:1",
      "physical-operator" : "DISTRIBUTE_RESULT",
      "execution-mode" : "UNPARTITIONED",
      "optimizer-estimates" :

      { "cardinality" : 15.0, "op-cost" : 0.0, "total-cost" : 5021.1 }

      ,
      "inputs" : [
      {
      "operator" : "exchange",
      "operatorId" : "1.2",
      "runtime-id" : "CDID:3",
      "physical-operator" : "ONE_TO_ONE_EXCHANGE",
      "execution-mode" : "UNPARTITIONED",
      "optimizer-estimates" :

      { "cardinality" : 15.0, "op-cost" : 0.0, "total-cost" : 5021.1 }

      ,

      As a result, the plan is now embedded inside the results.plan field, which the GUI is not expecting and we do not get a graphical explain plan.

      Attachments

        Issue Links

          For Gerrit Dashboard: MB-55308
          # Subject Branch Project Status CR V

          Activity

            People

              vijay.sarathy Vijay Sarathy
              vijay.sarathy Vijay Sarathy
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Gerrit Reviews

                  There are no open Gerrit changes

                  PagerDuty