-
Notifications
You must be signed in to change notification settings - Fork 3.8k
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
Sentry: alter_table_drop_column.go:581: building declarative schema change targets for ALTER TABLE: failed to drop all of the relevant elements: [× ×] (1) attached stack trace -- stack trace: | ... #105754
Comments
postamar
pushed a commit
to postamar/cockroach
that referenced
this issue
Jul 6, 2023
The declarative schema changer builder contains assertions on the state of elements and their targets and these could sometimes fail because the check which verifies that the corresponding descriptors are not already undergoing a schema change was performed later. This commit fixes this by moving the check earlier so the assertion is never reached in those cases. This commit removes a skipped test which is superseded by a new test in the schemachanger package. Fixes: cockroachdb#45510 Fixes: cockroachdb#102927 Fixes: cockroachdb#105754 Release note (bug fix): fixed a bug which manifested itself in error messages containing "failed to drop all of the relevant elements" when executing DDL statements with the declarative schema changer. What this really means is that there's a concurrent schema change that's ongoing. Instead we now behave as expected and wait for it to finish.
postamar
pushed a commit
to postamar/cockroach
that referenced
this issue
Jul 6, 2023
The declarative schema changer builder contains assertions on the state of elements and their targets and these could sometimes fail because the check which verifies that the corresponding descriptors are not already undergoing a schema change was performed later. This commit fixes this by moving the check earlier so the assertion is never reached in those cases. This commit removes a skipped test which is superseded by a new test in the schemachanger package. Fixes: cockroachdb#45510 Fixes: cockroachdb#102927 Fixes: cockroachdb#105754 Release note (bug fix): fixed a bug which manifested itself in error messages containing "failed to drop all of the relevant elements" when executing DDL statements with the declarative schema changer. What this really means is that there's a concurrent schema change that's ongoing. Instead we now behave as expected and wait for it to finish.
craig bot
pushed a commit
that referenced
this issue
Jul 6, 2023
105795: asim: add exact_bound, upper_bound, lower_bound to CmdArgs r=kvoli a=wenyihu6 **asim: move sim helper functions to helpers_test.go** This patch moves helper functions for scanning and parsing arguments from `datadriven_simulation_test.go` to `helpers_test.go`. Note that this commit does not change any existing functionality. Epic: None Release Note: None --- **asim: add exact_bound, upper_bound, lower_bound to CmdArgs** Previously, the allocator simulator's assertions were limited to accepting only a single threshold value for type=balance, type=steady, and type=stat assertions. This single threshold functioned as an upper limit for balance and steady and as an exact limit for stat. This is less ideal as there are instances where different types of bounds need to be asserted. To improve this, this patch replaces the argument `threshold=` with `exact_bound=, upper_bound=, and lower_bound=`. Note that only one argument should be specified at a time. If multiple are specified, the expected precedence order is exact_bound > upper_bound > lower_bound. Note that this commit does not change any existing functionality. Epic: None Release Note: None 106175: schemachanger,scbuild: fix assertion bug r=postamar a=postamar The declarative schema changer builder contains assertions on the state of elements and their targets and these could sometimes fail because the check which verifies that the corresponding descriptors are not already undergoing a schema change was performed later. This commit fixes this by moving the check earlier so the assertion is never reached in those cases. This commit removes a skipped test which is superseded by a new test in the schemachanger package. Fixes: #45510 Fixes: #102927 Fixes: #105754 Release note (bug fix): fixed a bug which manifested itself in error messages containing "failed to drop all of the relevant elements" when executing DDL statements with the declarative schema changer. What this really means is that there's a concurrent schema change that's ongoing. Instead we now behave as expected and wait for it to finish. Co-authored-by: Wenyi <[email protected]> Co-authored-by: Marius Posta <[email protected]>
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
This issue was auto filed by Sentry. It represents a crash or reported error on a live cluster with telemetry enabled.
Sentry Link: https://cockroach-labs.sentry.io/issues/4281301765/?referrer=webhooks_plugin
Panic Message:
Stacktrace (expand for inline code snippets):
GOROOT/src/runtime/asm_amd64.s#L1593-L1595
https://github.com/cockroachdb/cockroach/blob/d8d427b1574281f7dc16da266867279c13cdbfd6/pkg/sql/pgwire/conn.go#L777-L779
https://github.com/cockroachdb/cockroach/blob/d8d427b1574281f7dc16da266867279c13cdbfd6/pkg/sql/conn_executor.go#L892-L894
https://github.com/cockroachdb/cockroach/blob/d8d427b1574281f7dc16da266867279c13cdbfd6/pkg/sql/conn_executor.go#L2096-L2098
https://github.com/cockroachdb/cockroach/blob/d8d427b1574281f7dc16da266867279c13cdbfd6/pkg/sql/conn_executor.go#L2179-L2181
https://github.com/cockroachdb/cockroach/blob/d8d427b1574281f7dc16da266867279c13cdbfd6/pkg/sql/conn_executor.go#L2174-L2176
https://github.com/cockroachdb/cockroach/blob/d8d427b1574281f7dc16da266867279c13cdbfd6/pkg/sql/conn_executor_exec.go#L140-L142
https://github.com/cockroachdb/cockroach/blob/d8d427b1574281f7dc16da266867279c13cdbfd6/pkg/sql/conn_executor_exec.go#L2985-L2987
https://github.com/cockroachdb/cockroach/blob/d8d427b1574281f7dc16da266867279c13cdbfd6/pkg/sql/conn_executor_exec.go#L141-L143
https://github.com/cockroachdb/cockroach/blob/d8d427b1574281f7dc16da266867279c13cdbfd6/pkg/sql/conn_executor_exec.go#L963-L965
https://github.com/cockroachdb/cockroach/blob/d8d427b1574281f7dc16da266867279c13cdbfd6/pkg/sql/conn_executor_exec.go#L1483-L1485
https://github.com/cockroachdb/cockroach/blob/d8d427b1574281f7dc16da266867279c13cdbfd6/pkg/sql/conn_executor_exec.go#L1977-L1979
https://github.com/cockroachdb/cockroach/blob/d8d427b1574281f7dc16da266867279c13cdbfd6/pkg/sql/plan_opt.go#L237-L239
https://github.com/cockroachdb/cockroach/blob/d8d427b1574281f7dc16da266867279c13cdbfd6/pkg/sql/plan_opt.go#L573-L575
https://github.com/cockroachdb/cockroach/blob/d8d427b1574281f7dc16da266867279c13cdbfd6/pkg/sql/opt/optbuilder/builder.go#L245-L247
https://github.com/cockroachdb/cockroach/blob/d8d427b1574281f7dc16da266867279c13cdbfd6/pkg/sql/opt/optbuilder/builder.go#L271-L273
https://github.com/cockroachdb/cockroach/blob/d8d427b1574281f7dc16da266867279c13cdbfd6/pkg/sql/opt/optbuilder/builder.go#L433-L435
https://github.com/cockroachdb/cockroach/blob/d8d427b1574281f7dc16da266867279c13cdbfd6/pkg/sql/opt/optbuilder/opaque.go#L69-L71
https://github.com/cockroachdb/cockroach/blob/d8d427b1574281f7dc16da266867279c13cdbfd6/pkg/sql/opaque.go#L55-L57
https://github.com/cockroachdb/cockroach/blob/d8d427b1574281f7dc16da266867279c13cdbfd6/pkg/sql/schema_change_plan_node.go#L67-L69
https://github.com/cockroachdb/cockroach/blob/d8d427b1574281f7dc16da266867279c13cdbfd6/pkg/sql/schemachanger/scbuild/build.go#L84-L86
https://github.com/cockroachdb/cockroach/blob/d8d427b1574281f7dc16da266867279c13cdbfd6/pkg/sql/schemachanger/scbuild/internal/scbuildstmt/process.go#L172-L174
GOROOT/src/reflect/value.go#L367-L369
GOROOT/src/reflect/value.go#L583-L585
https://github.com/cockroachdb/cockroach/blob/d8d427b1574281f7dc16da266867279c13cdbfd6/pkg/sql/schemachanger/scbuild/internal/scbuildstmt/alter_table.go#L169-L171
GOROOT/src/reflect/value.go#L367-L369
GOROOT/src/reflect/value.go#L583-L585
https://github.com/cockroachdb/cockroach/blob/d8d427b1574281f7dc16da266867279c13cdbfd6/pkg/sql/schemachanger/scbuild/internal/scbuildstmt/alter_table_drop_column.go#L44-L46
https://github.com/cockroachdb/cockroach/blob/d8d427b1574281f7dc16da266867279c13cdbfd6/pkg/sql/schemachanger/scbuild/internal/scbuildstmt/alter_table_drop_column.go#L314-L316
https://github.com/cockroachdb/cockroach/blob/d8d427b1574281f7dc16da266867279c13cdbfd6/pkg/sql/schemachanger/scbuild/internal/scbuildstmt/alter_table_drop_column.go#L580-L582
GOROOT/src/runtime/panic.go#L883-L885
https://github.com/cockroachdb/cockroach/blob/d8d427b1574281f7dc16da266867279c13cdbfd6/pkg/sql/schemachanger/scerrors/errors.go#L80-L82
GOROOT/src/runtime/asm_amd64.s#L1593-L1595
https://github.com/cockroachdb/cockroach/blob/d8d427b1574281f7dc16da266867279c13cdbfd6/pkg/sql/pgwire/conn.go#L777-L779
https://github.com/cockroachdb/cockroach/blob/d8d427b1574281f7dc16da266867279c13cdbfd6/pkg/sql/conn_executor.go#L892-L894
https://github.com/cockroachdb/cockroach/blob/d8d427b1574281f7dc16da266867279c13cdbfd6/pkg/sql/conn_executor.go#L2096-L2098
https://github.com/cockroachdb/cockroach/blob/d8d427b1574281f7dc16da266867279c13cdbfd6/pkg/sql/conn_executor.go#L2179-L2181
https://github.com/cockroachdb/cockroach/blob/d8d427b1574281f7dc16da266867279c13cdbfd6/pkg/sql/conn_executor.go#L2174-L2176
https://github.com/cockroachdb/cockroach/blob/d8d427b1574281f7dc16da266867279c13cdbfd6/pkg/sql/conn_executor_exec.go#L140-L142
https://github.com/cockroachdb/cockroach/blob/d8d427b1574281f7dc16da266867279c13cdbfd6/pkg/sql/conn_executor_exec.go#L2985-L2987
https://github.com/cockroachdb/cockroach/blob/d8d427b1574281f7dc16da266867279c13cdbfd6/pkg/sql/conn_executor_exec.go#L141-L143
https://github.com/cockroachdb/cockroach/blob/d8d427b1574281f7dc16da266867279c13cdbfd6/pkg/sql/conn_executor_exec.go#L963-L965
https://github.com/cockroachdb/cockroach/blob/d8d427b1574281f7dc16da266867279c13cdbfd6/pkg/sql/conn_executor_exec.go#L1483-L1485
https://github.com/cockroachdb/cockroach/blob/d8d427b1574281f7dc16da266867279c13cdbfd6/pkg/sql/conn_executor_exec.go#L1977-L1979
https://github.com/cockroachdb/cockroach/blob/d8d427b1574281f7dc16da266867279c13cdbfd6/pkg/sql/plan_opt.go#L237-L239
https://github.com/cockroachdb/cockroach/blob/d8d427b1574281f7dc16da266867279c13cdbfd6/pkg/sql/plan_opt.go#L573-L575
https://github.com/cockroachdb/cockroach/blob/d8d427b1574281f7dc16da266867279c13cdbfd6/pkg/sql/opt/optbuilder/builder.go#L245-L247
https://github.com/cockroachdb/cockroach/blob/d8d427b1574281f7dc16da266867279c13cdbfd6/pkg/sql/opt/optbuilder/builder.go#L271-L273
https://github.com/cockroachdb/cockroach/blob/d8d427b1574281f7dc16da266867279c13cdbfd6/pkg/sql/opt/optbuilder/builder.go#L433-L435
https://github.com/cockroachdb/cockroach/blob/d8d427b1574281f7dc16da266867279c13cdbfd6/pkg/sql/opt/optbuilder/opaque.go#L69-L71
https://github.com/cockroachdb/cockroach/blob/d8d427b1574281f7dc16da266867279c13cdbfd6/pkg/sql/opaque.go#L55-L57
https://github.com/cockroachdb/cockroach/blob/d8d427b1574281f7dc16da266867279c13cdbfd6/pkg/sql/schema_change_plan_node.go#L67-L69
https://github.com/cockroachdb/cockroach/blob/d8d427b1574281f7dc16da266867279c13cdbfd6/pkg/sql/schemachanger/scbuild/build.go#L84-L86
https://github.com/cockroachdb/cockroach/blob/d8d427b1574281f7dc16da266867279c13cdbfd6/pkg/sql/schemachanger/scbuild/internal/scbuildstmt/process.go#L172-L174
GOROOT/src/reflect/value.go#L367-L369
GOROOT/src/reflect/value.go#L583-L585
https://github.com/cockroachdb/cockroach/blob/d8d427b1574281f7dc16da266867279c13cdbfd6/pkg/sql/schemachanger/scbuild/internal/scbuildstmt/alter_table.go#L169-L171
GOROOT/src/reflect/value.go#L367-L369
GOROOT/src/reflect/value.go#L583-L585
https://github.com/cockroachdb/cockroach/blob/d8d427b1574281f7dc16da266867279c13cdbfd6/pkg/sql/schemachanger/scbuild/internal/scbuildstmt/alter_table_drop_column.go#L44-L46
https://github.com/cockroachdb/cockroach/blob/d8d427b1574281f7dc16da266867279c13cdbfd6/pkg/sql/schemachanger/scbuild/internal/scbuildstmt/alter_table_drop_column.go#L314-L316
https://github.com/cockroachdb/cockroach/blob/d8d427b1574281f7dc16da266867279c13cdbfd6/pkg/sql/schemachanger/scbuild/internal/scbuildstmt/alter_table_drop_column.go#L580-L582
Tags
Jira issue: CRDB-29175
The text was updated successfully, but these errors were encountered: