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

[Embeddables] Migration System for Unsaved State #164501

Closed
ThomThomson opened this issue Aug 22, 2023 · 3 comments
Closed

[Embeddables] Migration System for Unsaved State #164501

ThomThomson opened this issue Aug 22, 2023 · 3 comments
Labels
Feature:Dashboard Dashboard related features Feature:Embeddables Relating to the Embeddable system impact:high Addressing this issue will have a high level of impact on the quality/strength of our product. loe:large Large Level of Effort project:embeddableRebuild Team:Presentation Presentation Team for Dashboard, Input Controls, and Canvas

Comments

@ThomThomson
Copy link
Contributor

Currently, after #162986 the Dashboard does not run clientside migrations for any state passed in via the URL, or for any unsaved state that was in the session storage.

The function that runs on Dashboard saved object load means that most of the time, when the embeddable create function is called on Dashboards there are no more migrations to be run. If for any reason there are migrations to be run at this point, the embeddable inheritance structure means they get immediately undone because the Container's child input is considered the source of truth. This could happen when:

  • The Dashboard has state in the session storage. If a user has unsaved panels in their session storage, they refresh the Dashboard, and Kibana has updated, the Embeddable create method will detect if any new migrations have been registered and will run them, but the container will pick up the changes and immediately undo them.
  • There are panels from an older version injected via the URL from a snapshot link. Again the migrations will get run, but will immediately get undone.

Implementing this back-propagation on the existing Embeddables framework would require ugly workarounds and changes that would affect the stability of the Embeddable platform. Once we move to a less prescriptive inheritance structure, this will not be a problem.

@ThomThomson ThomThomson added Feature:Dashboard Dashboard related features Team:Presentation Presentation Team for Dashboard, Input Controls, and Canvas loe:large Large Level of Effort impact:high Addressing this issue will have a high level of impact on the quality/strength of our product. Feature:Embeddables Relating to the Embeddable system labels Aug 22, 2023
@elasticmachine
Copy link
Contributor

Pinging @elastic/kibana-presentation (Team:Presentation)

@ThomThomson
Copy link
Contributor Author

This should be solved once #167429 is completed.

@ThomThomson
Copy link
Contributor Author

Closing because this is already solved by the new embeddable system.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Feature:Dashboard Dashboard related features Feature:Embeddables Relating to the Embeddable system impact:high Addressing this issue will have a high level of impact on the quality/strength of our product. loe:large Large Level of Effort project:embeddableRebuild Team:Presentation Presentation Team for Dashboard, Input Controls, and Canvas
Projects
None yet
Development

No branches or pull requests

2 participants