-
Notifications
You must be signed in to change notification settings - Fork 3.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
release-22.1: sql: improve EXPLAIN (DDL) output #79780
Conversation
b589dbd
to
56a5529
Compare
Thanks for opening a backport. Please check the backport criteria before merging:
If some of the basic criteria cannot be satisfied, ensure that the exceptional criteria are satisfied within.
Add a brief release justification to the body of your PR to justify this backport. Some other things to consider:
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Needs a rewrite for some reason.
We may have forgotten to backport something. Investigating. |
56a5529
to
cafc599
Compare
I think it's because #79294 hasn't been merged yet. |
Ack, rebasing it now |
Err, so are you 😓 |
After #79294 gets merged, I'll rebase this one again before merging. |
For no good reason, scgraph was imported as scgraph2. This commit fixes this. Release note: None
Previously, the EXPLAIN (DDL, STAGES) and EXPLAIN (DDL, DEPS) statements were printing graphviz URLs to help engineers during the development of the declarative schema changer. Now that the declarative schema changer is going live, the audience for EXPLAIN (DDL) changes to become the users. The graphviz URLs were, at any rate, not very useful for schema changes involving many objects, due to limitations in the rendering engine. This commit gets rid of the STAGES and DEPS flags to provide a unified plan which is similar to the data-driven test output in the scplan package. The VERBOSE flag can now be used to render a superset of the information in the default rendering. Touches #77158. Release note (sql change): EXPLAIN (DDL), when invoked on statements supported by the declarative schema changer, prints a plan of what the schema changer will do. This can be useful for the user to anticipate the complexity of a schema change (anything involving Backfill or Validation operations might be slow to run). This can be useful for troubleshooting. EXPLAIN (DDL, VERBOSE) produces a more detailed plan.
cafc599
to
00a868c
Compare
Backport 2/2 commits from #79673 on behalf of @postamar.
/cc @cockroachdb/release
Previously, the EXPLAIN (DDL, STAGES) and EXPLAIN (DDL, DEPS) statements
were printing graphviz URLs to help engineers during the development of
the declarative schema changer.
Now that the declarative schema changer is going live, the audience for
EXPLAIN (DDL) changes to become the users. The graphviz URLs were, at
any rate, not very useful for schema changes involving many objects, due
to limitations in the rendering engine.
This commit gets rid of the STAGES and DEPS flags to provide a unified
plan which is similar to the data-driven test output in the scplan
package. The VERBOSE flag can now be used to render a superset of the
information in the default rendering.
Touches #77158.
Release note (sql change): EXPLAIN (DDL), when invoked on statements
supported by the declarative schema changer, prints a plan of what the
schema changer will do. This can be useful for the user to anticipate
the complexity of a schema change (anything involving Backfill or
Validation operations might be slow to run). This can be useful for
troubleshooting. EXPLAIN (DDL, VERBOSE) produces a more detailed plan.
EXPLAIN (DDL)
Example:EXPLAIN (DDL, VERBOSE)
Example:Release justification: low-risk high-value change pertaining to declarative schema changer