Repository navigation
fix: Missing sql_editor_id index - #27392
Conversation
|
@justinpark you'll also have to:
Creating a new index to the |
There was a problem hiding this comment.
Should this index be on the (user_id, sql_editor_id) tuple instead?
There was a problem hiding this comment.
@john-bodley We have agreed to use a single key index rather than these composite keys. Could you please confirm the agreement here?
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## master #27392 +/- ##
==========================================
+ Coverage 67.34% 69.71% +2.37%
==========================================
Files 1909 1909
Lines 74592 74616 +24
Branches 8320 8320
==========================================
+ Hits 50235 52022 +1787
+ Misses 22305 20542 -1763
Partials 2052 2052
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. |
|
From experience that table can get massive and depending on your SQL engine, and creating an index can be a locking operation, which can cascade into deadlock territory on this particular table (I think there's still a pretty crazy amount of polling happening in SQL Lab to look at query state). If you're using MySQL I'd treat this migration very very sensitively. I think there are ways to create index in a non-locking way in MySQL, but have to go out of your way to do it Maybe not a bad time to archive the query table table in your environment ... For most shops I think 90 days worth of query history is enough to go by, not a bad thing to schedule something that deletes 90+ day old queries daily... Note that |
There was a problem hiding this comment.
Given that it's now a index on two columns you'll have to use the Index function.
|
About my earlier comment, the issue may be significant enough that you'd want to write a custom migration for MySQL for your own sake at Airbnb, you can probably go direct DDL |
e249bed to
fcf7a84
Compare
There was a problem hiding this comment.
Could we skip the upgrade if the index already exists?
a6ab95f to
f91ce6d
Compare
5a38b9a to
8a2c84e
Compare
8a2c84e to
0dfc810
Compare
0dfc810 to
1d19118
Compare
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## master #27392 +/- ##
==========================================
+ Coverage 60.48% 69.98% +9.49%
==========================================
Files 1931 1933 +2
Lines 76236 76498 +262
Branches 8568 8566 -2
==========================================
+ Hits 46114 53539 +7425
+ Misses 28017 20855 -7162
+ Partials 2105 2104 -1
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. |
…mporter text, migration warning Three doc corrections to the datasets soft-delete entry, matching the same pass applied to charts in 376a476 and dashboards in 3acc9f7: 1. Rison filter values were wrong: the entry advertised dataset_deleted_state=(deleted|active), but the implementation (BaseDeletedStateFilter.apply in superset/views/filters.py:185-189) only accepts include / only — other values silently no-op. 2. Importer description was stale (described the pre-Option-C raise behavior). Rewrote to reflect the implicit restore-and-update Option C now does: owner gets the dataset back in place (PK + chart back- reference + table_columns + sql_metrics preserved), non-owners and callers without can_write get ImportFailedError. 3. Added a migration-safety note following the precedent set by PR apache#27392 and PR apache#27119. Index creation runs inline (no CONCURRENTLY, per Superset convention) and briefly blocks reads on the tables table during the build on Postgres; MySQL InnoDB builds it online. Production deployments with many thousands of datasets should run during a maintenance window — `tables` is one of the bigger entity tables in Superset. The "no cascade in v1" and FAB-permission side-effect paragraphs are unchanged. Co-Authored-By: Claude Opus 4.7 (1M context) <[email protected]>
…mporter text, migration warning Three doc corrections to the datasets soft-delete entry, matching the same pass applied to charts in 376a476 and dashboards in 3acc9f7: 1. Rison filter values were wrong: the entry advertised dataset_deleted_state=(deleted|active), but the implementation (BaseDeletedStateFilter.apply in superset/views/filters.py:185-189) only accepts include / only — other values silently no-op. 2. Importer description was stale (described the pre-Option-C raise behavior). Rewrote to reflect the implicit restore-and-update Option C now does: owner gets the dataset back in place (PK + chart back- reference + table_columns + sql_metrics preserved), non-owners and callers without can_write get ImportFailedError. 3. Added a migration-safety note following the precedent set by PR apache#27392 and PR apache#27119. Index creation runs inline (no CONCURRENTLY, per Superset convention) and briefly blocks reads on the tables table during the build on Postgres; MySQL InnoDB builds it online. Production deployments with many thousands of datasets should run during a maintenance window — `tables` is one of the bigger entity tables in Superset. The "no cascade in v1" and FAB-permission side-effect paragraphs are unchanged. Co-Authored-By: Claude Opus 4.7 (1M context) <[email protected]>
…orter text, migration warning Three doc-only corrections to the charts soft-delete entry: 1. Rison filter values were wrong: the entry advertised chart_deleted_state=(deleted|active), but the implementation (BaseDeletedStateFilter.apply in superset/views/filters.py:185-189) only accepts include / only — other values silently no-op. 2. Importer description was stale (described the pre-Option-C raise behavior). Rewrote to reflect the implicit restore-and-update Option C now does: owner gets the chart back in place, non-owners and callers without can_write get ImportFailedError. Reflects the permission matrix in the in-tree docstring. 3. Added a migration-safety note following the precedent set by PR apache#27392 ("Adds an index... may cause downtime on large deployments") and PR apache#27119. Index creation runs inline (no CONCURRENTLY, per Superset convention) and briefly blocks reads on the slices table during the build on Postgres; MySQL InnoDB builds it online. Sourced from the SQLAlchemy review on PR apache#40129. Co-Authored-By: Claude Opus 4.7 (1M context) <[email protected]>
…rter + migration notes Three doc corrections to the dashboards soft-delete entry, matching the same pass applied to charts in 376a476: 1. Rison filter values were wrong: the entry advertised dashboard_deleted_state=(deleted|active), but the implementation (BaseDeletedStateFilter.apply in superset/views/filters.py:185-189) only accepts include / only — other values silently no-op. Flagged by the SQLAlchemy review on PR apache#40128. 2. Added the importer-behavior paragraph that was missing here. The dashboard importer adopts the same Option-C / Case-B semantics as charts and datasets: owners get an implicit restore-and-update, non-owners and callers without can_write get ImportFailedError, never a silent reattach. 3. Added a migration-safety note following the precedent set by PR apache#27392 and PR apache#27119. Index creation runs inline (no CONCURRENTLY, per Superset convention) and briefly blocks reads on the dashboards table during the build on Postgres; MySQL InnoDB builds it online. Slug-uniqueness footgun paragraph kept as-is; tracked in sc-107581. Co-Authored-By: Claude Opus 4.7 (1M context) <[email protected]>
…orter text, migration warning Three doc-only corrections to the charts soft-delete entry: 1. Rison filter values were wrong: the entry advertised chart_deleted_state=(deleted|active), but the implementation (BaseDeletedStateFilter.apply in superset/views/filters.py:185-189) only accepts include / only — other values silently no-op. 2. Importer description was stale (described the pre-Option-C raise behavior). Rewrote to reflect the implicit restore-and-update Option C now does: owner gets the chart back in place, non-owners and callers without can_write get ImportFailedError. Reflects the permission matrix in the in-tree docstring. 3. Added a migration-safety note following the precedent set by PR apache#27392 ("Adds an index... may cause downtime on large deployments") and PR apache#27119. Index creation runs inline (no CONCURRENTLY, per Superset convention) and briefly blocks reads on the slices table during the build on Postgres; MySQL InnoDB builds it online. Sourced from the SQLAlchemy review on PR apache#40129. Co-Authored-By: Claude Opus 4.7 (1M context) <[email protected]>
…rter + migration notes Three doc corrections to the dashboards soft-delete entry, matching the same pass applied to charts in 376a476: 1. Rison filter values were wrong: the entry advertised dashboard_deleted_state=(deleted|active), but the implementation (BaseDeletedStateFilter.apply in superset/views/filters.py:185-189) only accepts include / only — other values silently no-op. Flagged by the SQLAlchemy review on PR apache#40128. 2. Added the importer-behavior paragraph that was missing here. The dashboard importer adopts the same Option-C / Case-B semantics as charts and datasets: owners get an implicit restore-and-update, non-owners and callers without can_write get ImportFailedError, never a silent reattach. 3. Added a migration-safety note following the precedent set by PR apache#27392 and PR apache#27119. Index creation runs inline (no CONCURRENTLY, per Superset convention) and briefly blocks reads on the dashboards table during the build on Postgres; MySQL InnoDB builds it online. Slug-uniqueness footgun paragraph kept as-is; tracked in sc-107581. Co-Authored-By: Claude Opus 4.7 (1M context) <[email protected]>
…mporter text, migration warning Three doc corrections to the datasets soft-delete entry, matching the same pass applied to charts in 376a476 and dashboards in 3acc9f7: 1. Rison filter values were wrong: the entry advertised dataset_deleted_state=(deleted|active), but the implementation (BaseDeletedStateFilter.apply in superset/views/filters.py:185-189) only accepts include / only — other values silently no-op. 2. Importer description was stale (described the pre-Option-C raise behavior). Rewrote to reflect the implicit restore-and-update Option C now does: owner gets the dataset back in place (PK + chart back- reference + table_columns + sql_metrics preserved), non-owners and callers without can_write get ImportFailedError. 3. Added a migration-safety note following the precedent set by PR apache#27392 and PR apache#27119. Index creation runs inline (no CONCURRENTLY, per Superset convention) and briefly blocks reads on the tables table during the build on Postgres; MySQL InnoDB builds it online. Production deployments with many thousands of datasets should run during a maintenance window — `tables` is one of the bigger entity tables in Superset. The "no cascade in v1" and FAB-permission side-effect paragraphs are unchanged. Co-Authored-By: Claude Opus 4.7 (1M context) <[email protected]>
…orter text, migration warning Three doc-only corrections to the charts soft-delete entry: 1. Rison filter values were wrong: the entry advertised chart_deleted_state=(deleted|active), but the implementation (BaseDeletedStateFilter.apply in superset/views/filters.py:185-189) only accepts include / only — other values silently no-op. 2. Importer description was stale (described the pre-Option-C raise behavior). Rewrote to reflect the implicit restore-and-update Option C now does: owner gets the chart back in place, non-owners and callers without can_write get ImportFailedError. Reflects the permission matrix in the in-tree docstring. 3. Added a migration-safety note following the precedent set by PR apache#27392 ("Adds an index... may cause downtime on large deployments") and PR apache#27119. Index creation runs inline (no CONCURRENTLY, per Superset convention) and briefly blocks reads on the slices table during the build on Postgres; MySQL InnoDB builds it online. Sourced from the SQLAlchemy review on PR apache#40129. Co-Authored-By: Claude Opus 4.7 (1M context) <[email protected]>
…rter + migration notes Three doc corrections to the dashboards soft-delete entry, matching the same pass applied to charts in 376a476: 1. Rison filter values were wrong: the entry advertised dashboard_deleted_state=(deleted|active), but the implementation (BaseDeletedStateFilter.apply in superset/views/filters.py:185-189) only accepts include / only — other values silently no-op. Flagged by the SQLAlchemy review on PR apache#40128. 2. Added the importer-behavior paragraph that was missing here. The dashboard importer adopts the same Option-C / Case-B semantics as charts and datasets: owners get an implicit restore-and-update, non-owners and callers without can_write get ImportFailedError, never a silent reattach. 3. Added a migration-safety note following the precedent set by PR apache#27392 and PR apache#27119. Index creation runs inline (no CONCURRENTLY, per Superset convention) and briefly blocks reads on the dashboards table during the build on Postgres; MySQL InnoDB builds it online. Slug-uniqueness footgun paragraph kept as-is; tracked in sc-107581. Co-Authored-By: Claude Opus 4.7 (1M context) <[email protected]>
…mporter text, migration warning Three doc corrections to the datasets soft-delete entry, matching the same pass applied to charts in 376a476 and dashboards in 3acc9f7: 1. Rison filter values were wrong: the entry advertised dataset_deleted_state=(deleted|active), but the implementation (BaseDeletedStateFilter.apply in superset/views/filters.py:185-189) only accepts include / only — other values silently no-op. 2. Importer description was stale (described the pre-Option-C raise behavior). Rewrote to reflect the implicit restore-and-update Option C now does: owner gets the dataset back in place (PK + chart back- reference + table_columns + sql_metrics preserved), non-owners and callers without can_write get ImportFailedError. 3. Added a migration-safety note following the precedent set by PR apache#27392 and PR apache#27119. Index creation runs inline (no CONCURRENTLY, per Superset convention) and briefly blocks reads on the tables table during the build on Postgres; MySQL InnoDB builds it online. Production deployments with many thousands of datasets should run during a maintenance window — `tables` is one of the bigger entity tables in Superset. The "no cascade in v1" and FAB-permission side-effect paragraphs are unchanged. Co-Authored-By: Claude Opus 4.7 (1M context) <[email protected]>
…rter + migration notes Three doc corrections to the dashboards soft-delete entry, matching the same pass applied to charts in 376a476: 1. Rison filter values were wrong: the entry advertised dashboard_deleted_state=(deleted|active), but the implementation (BaseDeletedStateFilter.apply in superset/views/filters.py:185-189) only accepts include / only — other values silently no-op. Flagged by the SQLAlchemy review on PR apache#40128. 2. Added the importer-behavior paragraph that was missing here. The dashboard importer adopts the same Option-C / Case-B semantics as charts and datasets: owners get an implicit restore-and-update, non-owners and callers without can_write get ImportFailedError, never a silent reattach. 3. Added a migration-safety note following the precedent set by PR apache#27392 and PR apache#27119. Index creation runs inline (no CONCURRENTLY, per Superset convention) and briefly blocks reads on the dashboards table during the build on Postgres; MySQL InnoDB builds it online. Slug-uniqueness footgun paragraph kept as-is; tracked in sc-107581. Co-Authored-By: Claude Opus 4.7 (1M context) <[email protected]>
…rter + migration notes Three doc corrections to the dashboards soft-delete entry, matching the same pass applied to charts in 376a476: 1. Rison filter values were wrong: the entry advertised dashboard_deleted_state=(deleted|active), but the implementation (BaseDeletedStateFilter.apply in superset/views/filters.py:185-189) only accepts include / only — other values silently no-op. Flagged by the SQLAlchemy review on PR apache#40128. 2. Added the importer-behavior paragraph that was missing here. The dashboard importer adopts the same Option-C / Case-B semantics as charts and datasets: owners get an implicit restore-and-update, non-owners and callers without can_write get ImportFailedError, never a silent reattach. 3. Added a migration-safety note following the precedent set by PR apache#27392 and PR apache#27119. Index creation runs inline (no CONCURRENTLY, per Superset convention) and briefly blocks reads on the dashboards table during the build on Postgres; MySQL InnoDB builds it online. Slug-uniqueness footgun paragraph kept as-is; tracked in sc-107581. Co-Authored-By: Claude Opus 4.7 (1M context) <[email protected]>
…orter text, migration warning Three doc-only corrections to the charts soft-delete entry: 1. Rison filter values were wrong: the entry advertised chart_deleted_state=(deleted|active), but the implementation (BaseDeletedStateFilter.apply in superset/views/filters.py:185-189) only accepts include / only — other values silently no-op. 2. Importer description was stale (described the pre-Option-C raise behavior). Rewrote to reflect the implicit restore-and-update Option C now does: owner gets the chart back in place, non-owners and callers without can_write get ImportFailedError. Reflects the permission matrix in the in-tree docstring. 3. Added a migration-safety note following the precedent set by PR apache#27392 ("Adds an index... may cause downtime on large deployments") and PR apache#27119. Index creation runs inline (no CONCURRENTLY, per Superset convention) and briefly blocks reads on the slices table during the build on Postgres; MySQL InnoDB builds it online. Sourced from the SQLAlchemy review on PR apache#40129. Co-Authored-By: Claude Opus 4.7 (1M context) <[email protected]>
…mporter text, migration warning Three doc corrections to the datasets soft-delete entry, matching the same pass applied to charts in 376a476 and dashboards in 3acc9f7: 1. Rison filter values were wrong: the entry advertised dataset_deleted_state=(deleted|active), but the implementation (BaseDeletedStateFilter.apply in superset/views/filters.py:185-189) only accepts include / only — other values silently no-op. 2. Importer description was stale (described the pre-Option-C raise behavior). Rewrote to reflect the implicit restore-and-update Option C now does: owner gets the dataset back in place (PK + chart back- reference + table_columns + sql_metrics preserved), non-owners and callers without can_write get ImportFailedError. 3. Added a migration-safety note following the precedent set by PR apache#27392 and PR apache#27119. Index creation runs inline (no CONCURRENTLY, per Superset convention) and briefly blocks reads on the tables table during the build on Postgres; MySQL InnoDB builds it online. Production deployments with many thousands of datasets should run during a maintenance window — `tables` is one of the bigger entity tables in Superset. The "no cascade in v1" and FAB-permission side-effect paragraphs are unchanged. Co-Authored-By: Claude Opus 4.7 (1M context) <[email protected]>
…rter + migration notes Three doc corrections to the dashboards soft-delete entry, matching the same pass applied to charts in 376a476: 1. Rison filter values were wrong: the entry advertised dashboard_deleted_state=(deleted|active), but the implementation (BaseDeletedStateFilter.apply in superset/views/filters.py:185-189) only accepts include / only — other values silently no-op. Flagged by the SQLAlchemy review on PR apache#40128. 2. Added the importer-behavior paragraph that was missing here. The dashboard importer adopts the same Option-C / Case-B semantics as charts and datasets: owners get an implicit restore-and-update, non-owners and callers without can_write get ImportFailedError, never a silent reattach. 3. Added a migration-safety note following the precedent set by PR apache#27392 and PR apache#27119. Index creation runs inline (no CONCURRENTLY, per Superset convention) and briefly blocks reads on the dashboards table during the build on Postgres; MySQL InnoDB builds it online. Slug-uniqueness footgun paragraph kept as-is; tracked in sc-107581. Co-Authored-By: Claude Opus 4.7 (1M context) <[email protected]>
…orter text, migration warning Three doc-only corrections to the charts soft-delete entry: 1. Rison filter values were wrong: the entry advertised chart_deleted_state=(deleted|active), but the implementation (BaseDeletedStateFilter.apply in superset/views/filters.py:185-189) only accepts include / only — other values silently no-op. 2. Importer description was stale (described the pre-Option-C raise behavior). Rewrote to reflect the implicit restore-and-update Option C now does: owner gets the chart back in place, non-owners and callers without can_write get ImportFailedError. Reflects the permission matrix in the in-tree docstring. 3. Added a migration-safety note following the precedent set by PR apache#27392 ("Adds an index... may cause downtime on large deployments") and PR apache#27119. Index creation runs inline (no CONCURRENTLY, per Superset convention) and briefly blocks reads on the slices table during the build on Postgres; MySQL InnoDB builds it online. Sourced from the SQLAlchemy review on PR apache#40129. Co-Authored-By: Claude Opus 4.7 (1M context) <[email protected]>
…mporter text, migration warning Three doc corrections to the datasets soft-delete entry, matching the same pass applied to charts in 376a476 and dashboards in 3acc9f7: 1. Rison filter values were wrong: the entry advertised dataset_deleted_state=(deleted|active), but the implementation (BaseDeletedStateFilter.apply in superset/views/filters.py:185-189) only accepts include / only — other values silently no-op. 2. Importer description was stale (described the pre-Option-C raise behavior). Rewrote to reflect the implicit restore-and-update Option C now does: owner gets the dataset back in place (PK + chart back- reference + table_columns + sql_metrics preserved), non-owners and callers without can_write get ImportFailedError. 3. Added a migration-safety note following the precedent set by PR apache#27392 and PR apache#27119. Index creation runs inline (no CONCURRENTLY, per Superset convention) and briefly blocks reads on the tables table during the build on Postgres; MySQL InnoDB builds it online. Production deployments with many thousands of datasets should run during a maintenance window — `tables` is one of the bigger entity tables in Superset. The "no cascade in v1" and FAB-permission side-effect paragraphs are unchanged. Co-Authored-By: Claude Opus 4.7 (1M context) <[email protected]>
…rter + migration notes Three doc corrections to the dashboards soft-delete entry, matching the same pass applied to charts in 376a476: 1. Rison filter values were wrong: the entry advertised dashboard_deleted_state=(deleted|active), but the implementation (BaseDeletedStateFilter.apply in superset/views/filters.py:185-189) only accepts include / only — other values silently no-op. Flagged by the SQLAlchemy review on PR apache#40128. 2. Added the importer-behavior paragraph that was missing here. The dashboard importer adopts the same Option-C / Case-B semantics as charts and datasets: owners get an implicit restore-and-update, non-owners and callers without can_write get ImportFailedError, never a silent reattach. 3. Added a migration-safety note following the precedent set by PR apache#27392 and PR apache#27119. Index creation runs inline (no CONCURRENTLY, per Superset convention) and briefly blocks reads on the dashboards table during the build on Postgres; MySQL InnoDB builds it online. Slug-uniqueness footgun paragraph kept as-is; tracked in sc-107581. Co-Authored-By: Claude Opus 4.7 (1M context) <[email protected]>
…orter text, migration warning Three doc-only corrections to the charts soft-delete entry: 1. Rison filter values were wrong: the entry advertised chart_deleted_state=(deleted|active), but the implementation (BaseDeletedStateFilter.apply in superset/views/filters.py:185-189) only accepts include / only — other values silently no-op. 2. Importer description was stale (described the pre-Option-C raise behavior). Rewrote to reflect the implicit restore-and-update Option C now does: owner gets the chart back in place, non-owners and callers without can_write get ImportFailedError. Reflects the permission matrix in the in-tree docstring. 3. Added a migration-safety note following the precedent set by PR apache#27392 ("Adds an index... may cause downtime on large deployments") and PR apache#27119. Index creation runs inline (no CONCURRENTLY, per Superset convention) and briefly blocks reads on the slices table during the build on Postgres; MySQL InnoDB builds it online. Sourced from the SQLAlchemy review on PR apache#40129. Co-Authored-By: Claude Opus 4.7 (1M context) <[email protected]>
…mporter text, migration warning Three doc corrections to the datasets soft-delete entry, matching the same pass applied to charts in 376a476 and dashboards in 3acc9f7: 1. Rison filter values were wrong: the entry advertised dataset_deleted_state=(deleted|active), but the implementation (BaseDeletedStateFilter.apply in superset/views/filters.py:185-189) only accepts include / only — other values silently no-op. 2. Importer description was stale (described the pre-Option-C raise behavior). Rewrote to reflect the implicit restore-and-update Option C now does: owner gets the dataset back in place (PK + chart back- reference + table_columns + sql_metrics preserved), non-owners and callers without can_write get ImportFailedError. 3. Added a migration-safety note following the precedent set by PR apache#27392 and PR apache#27119. Index creation runs inline (no CONCURRENTLY, per Superset convention) and briefly blocks reads on the tables table during the build on Postgres; MySQL InnoDB builds it online. Production deployments with many thousands of datasets should run during a maintenance window — `tables` is one of the bigger entity tables in Superset. The "no cascade in v1" and FAB-permission side-effect paragraphs are unchanged. Co-Authored-By: Claude Opus 4.7 (1M context) <[email protected]>
…orter text, migration warning Three doc-only corrections to the charts soft-delete entry: 1. Rison filter values were wrong: the entry advertised chart_deleted_state=(deleted|active), but the implementation (BaseDeletedStateFilter.apply in superset/views/filters.py:185-189) only accepts include / only — other values silently no-op. 2. Importer description was stale (described the pre-Option-C raise behavior). Rewrote to reflect the implicit restore-and-update Option C now does: owner gets the chart back in place, non-owners and callers without can_write get ImportFailedError. Reflects the permission matrix in the in-tree docstring. 3. Added a migration-safety note following the precedent set by PR apache#27392 ("Adds an index... may cause downtime on large deployments") and PR apache#27119. Index creation runs inline (no CONCURRENTLY, per Superset convention) and briefly blocks reads on the slices table during the build on Postgres; MySQL InnoDB builds it online. Sourced from the SQLAlchemy review on PR apache#40129. Co-Authored-By: Claude Opus 4.7 (1M context) <[email protected]>
…rter + migration notes Three doc corrections to the dashboards soft-delete entry, matching the same pass applied to charts in 376a476: 1. Rison filter values were wrong: the entry advertised dashboard_deleted_state=(deleted|active), but the implementation (BaseDeletedStateFilter.apply in superset/views/filters.py:185-189) only accepts include / only — other values silently no-op. Flagged by the SQLAlchemy review on PR apache#40128. 2. Added the importer-behavior paragraph that was missing here. The dashboard importer adopts the same Option-C / Case-B semantics as charts and datasets: owners get an implicit restore-and-update, non-owners and callers without can_write get ImportFailedError, never a silent reattach. 3. Added a migration-safety note following the precedent set by PR apache#27392 and PR apache#27119. Index creation runs inline (no CONCURRENTLY, per Superset convention) and briefly blocks reads on the dashboards table during the build on Postgres; MySQL InnoDB builds it online. Slug-uniqueness footgun paragraph kept as-is; tracked in sc-107581. Co-Authored-By: Claude Opus 4.7 (1M context) <[email protected]>
…mporter text, migration warning Three doc corrections to the datasets soft-delete entry, matching the same pass applied to charts in 376a476 and dashboards in 3acc9f7: 1. Rison filter values were wrong: the entry advertised dataset_deleted_state=(deleted|active), but the implementation (BaseDeletedStateFilter.apply in superset/views/filters.py:185-189) only accepts include / only — other values silently no-op. 2. Importer description was stale (described the pre-Option-C raise behavior). Rewrote to reflect the implicit restore-and-update Option C now does: owner gets the dataset back in place (PK + chart back- reference + table_columns + sql_metrics preserved), non-owners and callers without can_write get ImportFailedError. 3. Added a migration-safety note following the precedent set by PR apache#27392 and PR apache#27119. Index creation runs inline (no CONCURRENTLY, per Superset convention) and briefly blocks reads on the tables table during the build on Postgres; MySQL InnoDB builds it online. Production deployments with many thousands of datasets should run during a maintenance window — `tables` is one of the bigger entity tables in Superset. The "no cascade in v1" and FAB-permission side-effect paragraphs are unchanged. Co-Authored-By: Claude Opus 4.7 (1M context) <[email protected]>
…mporter text, migration warning Three doc corrections to the datasets soft-delete entry, matching the same pass applied to charts in 376a476 and dashboards in 3acc9f7: 1. Rison filter values were wrong: the entry advertised dataset_deleted_state=(deleted|active), but the implementation (BaseDeletedStateFilter.apply in superset/views/filters.py:185-189) only accepts include / only — other values silently no-op. 2. Importer description was stale (described the pre-Option-C raise behavior). Rewrote to reflect the implicit restore-and-update Option C now does: owner gets the dataset back in place (PK + chart back- reference + table_columns + sql_metrics preserved), non-owners and callers without can_write get ImportFailedError. 3. Added a migration-safety note following the precedent set by PR apache#27392 and PR apache#27119. Index creation runs inline (no CONCURRENTLY, per Superset convention) and briefly blocks reads on the tables table during the build on Postgres; MySQL InnoDB builds it online. Production deployments with many thousands of datasets should run during a maintenance window — `tables` is one of the bigger entity tables in Superset. The "no cascade in v1" and FAB-permission side-effect paragraphs are unchanged. Co-Authored-By: Claude Opus 4.7 (1M context) <[email protected]>
…orter text, migration warning Three doc-only corrections to the charts soft-delete entry: 1. Rison filter values were wrong: the entry advertised chart_deleted_state=(deleted|active), but the implementation (BaseDeletedStateFilter.apply in superset/views/filters.py:185-189) only accepts include / only — other values silently no-op. 2. Importer description was stale (described the pre-Option-C raise behavior). Rewrote to reflect the implicit restore-and-update Option C now does: owner gets the chart back in place, non-owners and callers without can_write get ImportFailedError. Reflects the permission matrix in the in-tree docstring. 3. Added a migration-safety note following the precedent set by PR apache#27392 ("Adds an index... may cause downtime on large deployments") and PR apache#27119. Index creation runs inline (no CONCURRENTLY, per Superset convention) and briefly blocks reads on the slices table during the build on Postgres; MySQL InnoDB builds it online. Sourced from the SQLAlchemy review on PR apache#40129. Co-Authored-By: Claude Opus 4.7 (1M context) <[email protected]>
…rter + migration notes Three doc corrections to the dashboards soft-delete entry, matching the same pass applied to charts in 376a476: 1. Rison filter values were wrong: the entry advertised dashboard_deleted_state=(deleted|active), but the implementation (BaseDeletedStateFilter.apply in superset/views/filters.py:185-189) only accepts include / only — other values silently no-op. Flagged by the SQLAlchemy review on PR apache#40128. 2. Added the importer-behavior paragraph that was missing here. The dashboard importer adopts the same Option-C / Case-B semantics as charts and datasets: owners get an implicit restore-and-update, non-owners and callers without can_write get ImportFailedError, never a silent reattach. 3. Added a migration-safety note following the precedent set by PR apache#27392 and PR apache#27119. Index creation runs inline (no CONCURRENTLY, per Superset convention) and briefly blocks reads on the dashboards table during the build on Postgres; MySQL InnoDB builds it online. Slug-uniqueness footgun paragraph kept as-is; tracked in sc-107581. Co-Authored-By: Claude Opus 4.7 (1M context) <[email protected]>
…mporter text, migration warning Three doc corrections to the datasets soft-delete entry, matching the same pass applied to charts in 376a476 and dashboards in 3acc9f7: 1. Rison filter values were wrong: the entry advertised dataset_deleted_state=(deleted|active), but the implementation (BaseDeletedStateFilter.apply in superset/views/filters.py:185-189) only accepts include / only — other values silently no-op. 2. Importer description was stale (described the pre-Option-C raise behavior). Rewrote to reflect the implicit restore-and-update Option C now does: owner gets the dataset back in place (PK + chart back- reference + table_columns + sql_metrics preserved), non-owners and callers without can_write get ImportFailedError. 3. Added a migration-safety note following the precedent set by PR apache#27392 and PR apache#27119. Index creation runs inline (no CONCURRENTLY, per Superset convention) and briefly blocks reads on the tables table during the build on Postgres; MySQL InnoDB builds it online. Production deployments with many thousands of datasets should run during a maintenance window — `tables` is one of the bigger entity tables in Superset. The "no cascade in v1" and FAB-permission side-effect paragraphs are unchanged. Co-Authored-By: Claude Opus 4.7 (1M context) <[email protected]>
…orter text, migration warning Three doc-only corrections to the charts soft-delete entry: 1. Rison filter values were wrong: the entry advertised chart_deleted_state=(deleted|active), but the implementation (BaseDeletedStateFilter.apply in superset/views/filters.py:185-189) only accepts include / only — other values silently no-op. 2. Importer description was stale (described the pre-Option-C raise behavior). Rewrote to reflect the implicit restore-and-update Option C now does: owner gets the chart back in place, non-owners and callers without can_write get ImportFailedError. Reflects the permission matrix in the in-tree docstring. 3. Added a migration-safety note following the precedent set by PR apache#27392 ("Adds an index... may cause downtime on large deployments") and PR apache#27119. Index creation runs inline (no CONCURRENTLY, per Superset convention) and briefly blocks reads on the slices table during the build on Postgres; MySQL InnoDB builds it online. Sourced from the SQLAlchemy review on PR apache#40129. Co-Authored-By: Claude Opus 4.7 (1M context) <[email protected]>
…rter + migration notes Three doc corrections to the dashboards soft-delete entry, matching the same pass applied to charts in 376a476: 1. Rison filter values were wrong: the entry advertised dashboard_deleted_state=(deleted|active), but the implementation (BaseDeletedStateFilter.apply in superset/views/filters.py:185-189) only accepts include / only — other values silently no-op. Flagged by the SQLAlchemy review on PR apache#40128. 2. Added the importer-behavior paragraph that was missing here. The dashboard importer adopts the same Option-C / Case-B semantics as charts and datasets: owners get an implicit restore-and-update, non-owners and callers without can_write get ImportFailedError, never a silent reattach. 3. Added a migration-safety note following the precedent set by PR apache#27392 and PR apache#27119. Index creation runs inline (no CONCURRENTLY, per Superset convention) and briefly blocks reads on the dashboards table during the build on Postgres; MySQL InnoDB builds it online. Slug-uniqueness footgun paragraph kept as-is; tracked in sc-107581. Co-Authored-By: Claude Opus 4.7 (1M context) <[email protected]>
…mporter text, migration warning Three doc corrections to the datasets soft-delete entry, matching the same pass applied to charts in 376a476 and dashboards in 3acc9f7: 1. Rison filter values were wrong: the entry advertised dataset_deleted_state=(deleted|active), but the implementation (BaseDeletedStateFilter.apply in superset/views/filters.py:185-189) only accepts include / only — other values silently no-op. 2. Importer description was stale (described the pre-Option-C raise behavior). Rewrote to reflect the implicit restore-and-update Option C now does: owner gets the dataset back in place (PK + chart back- reference + table_columns + sql_metrics preserved), non-owners and callers without can_write get ImportFailedError. 3. Added a migration-safety note following the precedent set by PR apache#27392 and PR apache#27119. Index creation runs inline (no CONCURRENTLY, per Superset convention) and briefly blocks reads on the tables table during the build on Postgres; MySQL InnoDB builds it online. Production deployments with many thousands of datasets should run during a maintenance window — `tables` is one of the bigger entity tables in Superset. The "no cascade in v1" and FAB-permission side-effect paragraphs are unchanged. Co-Authored-By: Claude Opus 4.7 (1M context) <[email protected]>
SUMMARY
As titled, it adds the index for
sql_editor_idin query table which seems to have caused a slowdown in the sqllab_bootstrap query.TESTING INSTRUCTIONS
locally test
superset db upgradeADDITIONAL INFORMATION