-
Notifications
You must be signed in to change notification settings - Fork 8.3k
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
[Lens] Datasource dimensions are not cleared properly #160116
Comments
Pinging @elastic/kibana-visualizations @elastic/kibana-visualizations-external (Team:Visualizations) |
I think the problem is in this update:
It adds new properties and doesn't remove the old ones. I think the properties must be explicitly set to The old code worked because it used kibana/x-pack/plugins/lens/public/persistence/saved_object_store.ts Lines 60 to 68 in 93256a7
Interesting that, for example, dashboard so won't have the same problem because panels are stored as a json string. |
Adds #160116 known issue to 8.9 release notes.
…166371) Adds elastic#160116 known issue to 8.9 release notes. (cherry picked from commit 7010742)
…166371) Adds elastic#160116 known issue to 8.9 release notes. (cherry picked from commit 7010742)
…#166452) # Backport This will backport the following commits from `main` to `8.10`: - [[DOCS] Adds #160116 known issue to 8.9 release notes (#166371)](#166371) <!--- Backport version: 8.9.7 --> ### Questions ? Please refer to the [Backport tool documentation](https://github.com/sqren/backport) <!--BACKPORT [{"author":{"name":"Kaarina Tungseth","email":"[email protected]"},"sourceCommit":{"committedDate":"2023-09-14T12:42:05Z","message":"[DOCS] Adds #160116 known issue to 8.9 release notes (#166371)\n\nAdds #160116 known issue to 8.9 release notes.","sha":"7010742461a3e974f918d10bc181c4737aa08edd","branchLabelMapping":{"^v8.11.0$":"main","^v(\\d+).(\\d+).\\d+$":"$1.$2"}},"sourcePullRequest":{"labels":["Team:Docs","release_note:skip","v8.9.0","v8.11.0","v8.10.1"],"number":166371,"url":"https://github.com/elastic/kibana/pull/166371","mergeCommit":{"message":"[DOCS] Adds #160116 known issue to 8.9 release notes (#166371)\n\nAdds #160116 known issue to 8.9 release notes.","sha":"7010742461a3e974f918d10bc181c4737aa08edd"}},"sourceBranch":"main","suggestedTargetBranches":["8.9","8.10"],"targetPullRequestStates":[{"branch":"8.9","label":"v8.9.0","labelRegex":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"},{"branch":"main","label":"v8.11.0","labelRegex":"^v8.11.0$","isSourceBranch":true,"state":"MERGED","url":"https://github.com/elastic/kibana/pull/166371","number":166371,"mergeCommit":{"message":"[DOCS] Adds #160116 known issue to 8.9 release notes (#166371)\n\nAdds #160116 known issue to 8.9 release notes.","sha":"7010742461a3e974f918d10bc181c4737aa08edd"}},{"branch":"8.10","label":"v8.10.1","labelRegex":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"}]}] BACKPORT--> Co-authored-by: Kaarina Tungseth <[email protected]>
…166453) # Backport This will backport the following commits from `main` to `8.9`: - [[DOCS] Adds #160116 known issue to 8.9 release notes (#166371)](#166371) <!--- Backport version: 8.9.7 --> ### Questions ? Please refer to the [Backport tool documentation](https://github.com/sqren/backport) <!--BACKPORT [{"author":{"name":"Kaarina Tungseth","email":"[email protected]"},"sourceCommit":{"committedDate":"2023-09-14T12:42:05Z","message":"[DOCS] Adds #160116 known issue to 8.9 release notes (#166371)\n\nAdds #160116 known issue to 8.9 release notes.","sha":"7010742461a3e974f918d10bc181c4737aa08edd","branchLabelMapping":{"^v8.11.0$":"main","^v(\\d+).(\\d+).\\d+$":"$1.$2"}},"sourcePullRequest":{"labels":["Team:Docs","release_note:skip","v8.9.0","v8.11.0","v8.10.1"],"number":166371,"url":"https://github.com/elastic/kibana/pull/166371","mergeCommit":{"message":"[DOCS] Adds #160116 known issue to 8.9 release notes (#166371)\n\nAdds #160116 known issue to 8.9 release notes.","sha":"7010742461a3e974f918d10bc181c4737aa08edd"}},"sourceBranch":"main","suggestedTargetBranches":["8.9","8.10"],"targetPullRequestStates":[{"branch":"8.9","label":"v8.9.0","labelRegex":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"},{"branch":"main","label":"v8.11.0","labelRegex":"^v8.11.0$","isSourceBranch":true,"state":"MERGED","url":"https://github.com/elastic/kibana/pull/166371","number":166371,"mergeCommit":{"message":"[DOCS] Adds #160116 known issue to 8.9 release notes (#166371)\n\nAdds #160116 known issue to 8.9 release notes.","sha":"7010742461a3e974f918d10bc181c4737aa08edd"}},{"branch":"8.10","label":"v8.10.1","labelRegex":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"}]}] BACKPORT--> Co-authored-by: Kaarina Tungseth <[email protected]>
Kibana version:
main, only 8.9 caused by [2c491b5] [CM] - lens (#155700)
When updated, the Lens object is being deep-merged so all the properties ever set stay in the saved object even if they were removed. What is odd is that the
save
call gets the proper response from the backend and Lens app works on correct saved object (removed properties are cleared) but after refreshing we can see that saved object from the DB keeps everything unless it was overwritten.Here's the flow to reproduce for datasource columns:
Remove two bucket dimensions and save
Go to /app/management/kibana/objects and inspect your saved object.
The dimensions are still there:
I've put impact medium, but it's imo potentially high as it can create incorrect saved objects that will be difficult to clean up and cause errors we cannot predict. @stratoula feel free to change.
The side effects include for example:
The text was updated successfully, but these errors were encountered: