Skip to content
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

sql/schemachanger: add automated collection of corpus information into nightlies #86381

Closed
fqazi opened this issue Aug 18, 2022 · 1 comment
Closed
Assignees
Labels
C-bug Code not up to spec/doc, specs & docs deemed correct. Solution expected to change code/behavior.

Comments

@fqazi
Copy link
Collaborator

fqazi commented Aug 18, 2022

To be able to test mixed version / backwards compatibility with the declarative schema changer we need to be able to validate with a corpus of declarative states from previous releases. Recently, we added support for collecting such a corpus from both end-to-end testing and logic test in a manual fashion. We need to further extend it by adding support for automated collection:

  1. Add a new CI step for running logical test and end to end tests with --declarative-corpus= option to generate a corpus into a temporary directory
  2. Add a new CI step for running mixed version logic test with the --declarative-corpus= option to generate a mixed corpus into a temporary directory (not needed on 22.1)
  3. Add a step to validate and replay the corpuses on the same release, if this fails then we already have compatibility issues on the same version TestValidateCorpuses was added for this reason and takes a path option
  4. Upload to GCS the generated corpus file, tagged with a fixed name "corpus-" and "corpus-.mixed" (this is only run on nightlies so only the latest one needs to be kept)

Separately we are going to create a roachtest that will pull the corpus from the previous release, and the mixed version from the current release, then validate both with our new declarative-corpus-validate command. This will be done as a separate issue

Jira issue: CRDB-18730

@fqazi fqazi added the C-bug Code not up to spec/doc, specs & docs deemed correct. Solution expected to change code/behavior. label Aug 18, 2022
@fqazi fqazi self-assigned this Aug 18, 2022
@fqazi fqazi changed the title sql/schemachanger: add automated collection of corpus information sql/schemachanger: add automated collection of corpus information into nightlies Aug 18, 2022
fqazi added a commit to fqazi/cockroach that referenced this issue Sep 13, 2022
Informs: cockroachdb#86381

Previously, the command for validating the mixed
version corpus was invalid. This patch fixes the validation
command to address this, so the mixed version corpus is
automatically uploaded.

Release note: None
craig bot pushed a commit that referenced this issue Sep 20, 2022
86334: *: add restriction to running DDL with internal executors r=ajwerner,rafiss a=ZhouXing19

The current internal executor has its lifecycle, which makes it erroneous
when being used to execute DDL statements if under an outer txn. 

In this commit, we 
1. Migrated the existing DDLs with internal executor with not-nil txn to either 
`descs.CollectionFactory.TxnWithExecutor()` or `planner.WithInternalExecutor()`.
Only internal executors inited via these 2 interfaces are bounded with txn-related
metadata, and hence are allowed to run DDLs in a transactional manner.
2. Added a restriction for running DDLs with internal executor only if it's bound with
txn-related metadata.

fixes #87281

Release justification: bug fix for the internal executor
Release note: none

87304: roachtest: refactor github issue posting and expose actual vm args for reporting r=renatolabs a=smg260

The change is split into 2 commits. 
1. More strictly addresses [81846](#81846).  Also addresses [this](https://github.com/cockroachdb/cockroach/pull/87304/files#diff-1e3ec1fc5bade2df4b8681c44959be2a390f703839f30a979da98f963769c9fcR1046) existing TODO
2. Refactors functions related to posting an issue to github into a separate source file and adds tests.

These commits can be squashed but are separate at the moment for convenience. 

Resolves: #81846

Release justification: test-only change
Release note: none

87896: ci: fix validation for mixed version schema change corpus r=fqazi a=fqazi

Informs: #86381

Previously, the command for validating the mixed
version corpus was invalid. This patch fixes the validation 
command to address this, so the mixed version corpus is 
automatically uploaded.

Release note: None

88138: server: return all completed stmt diag requests r=xinhaoz a=xinhaoz

Fixes #80104

Previously, we only return statement diagnostics requests that have not yet expired. Since we use the results of this request to populate completed statement diagnostics bundles in addition to outstanding requests, completed statement diag bundles would disappear from the UI after the request expired.

This commit ensures that `StatementDiagnosticsRequests` returns all completed stmt diag requests so that we can display the complete history of completed bundles in the UI.

Release note (bug fix): completed stmt diagnostics bundles now persist in the UI in stmt diag bundle pages

88159: ui/cluster-ui: fix jobs page polling r=xinhaoz a=xinhaoz

Fixes #68109

Previously, the jobs page would not poll for new data until a re-render was triggered. This commit updates the jobs page polling to every 10s regardless of
whether or not the rest of the page has changed.

Release note (bug fix): jobs page refreshes page data at an interval of 10s

88165: sql: version gate idx recommendations in insert-stmt-stats r=ericharmeling a=ericharmeling

This commit version gates index recommendation insert in insert-stmt-stats.

Fixes #88140.

Release note: None

88168: api: increase timeout of sql api r=maryliag a=maryliag

Previously, some request using the sql-over-http
api were hitting a timeout, with the default value of 5s. This commit increases to 300s (5min) on the calls made from SQL Activity and Insights pages.

Fixes #88094

Release note: None

88173: cli/sql: put a limit on history size r=DrewKimball a=knz

Fixes #54679.

Previously, there was no limit. Some users managed to make their history run into megabyte-size, despite de-duplication, which was causing slowness.

This patch fixes it by adding a limit of 1000 entries. Sufficiently large to not be inconvenient, but sufficiently small that it prevents the history file from growing abnormally large.

Release note (cli change): The interactive SQL shell now retains a maximum of 1000 entries. There was no limit previously.

88193: kv: hoist log.ExpensiveLogEnabled outside loop in appendRefreshSpans r=arulajmani a=nvanbenschoten

This commit hoists the call to `log.ExpensiveLogEnabled` outside of the per-span loop in `txnSpanRefresher.appendRefreshSpans`. The function is too expensive to call once per span.

Release justification: low risk change that may close perf gap.

Release note: None.

Co-authored-by: Jane Xing <[email protected]>
Co-authored-by: Miral Gadani <[email protected]>
Co-authored-by: Faizan Qazi <[email protected]>
Co-authored-by: Xin Hao Zhang <[email protected]>
Co-authored-by: Eric Harmeling <[email protected]>
Co-authored-by: Marylia Gutierrez <[email protected]>
Co-authored-by: Raphael 'kena' Poss <[email protected]>
Co-authored-by: Nathan VanBenschoten <[email protected]>
blathers-crl bot pushed a commit that referenced this issue Sep 20, 2022
Informs: #86381

Previously, the command for validating the mixed
version corpus was invalid. This patch fixes the validation
command to address this, so the mixed version corpus is
automatically uploaded.

Release note: None
@fqazi
Copy link
Collaborator Author

fqazi commented Sep 23, 2022

Finished, and uploaded to GCS automatically

@fqazi fqazi closed this as completed Sep 23, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
C-bug Code not up to spec/doc, specs & docs deemed correct. Solution expected to change code/behavior.
Projects
None yet
Development

No branches or pull requests

1 participant