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

[discuss] Deprecate state:storeInSessionStorage? #67454

Closed
Dosant opened this issue May 27, 2020 · 6 comments
Closed

[discuss] Deprecate state:storeInSessionStorage? #67454

Dosant opened this issue May 27, 2020 · 6 comments
Labels
discuss Feature:StateManagement Team:Core Core services & architecture: plugins, logging, config, saved objects, http, ES client, i18n, etc Team:Visualizations Visualization editors, elastic-charts and infrastructure

Comments

@Dosant
Copy link
Contributor

Dosant commented May 27, 2020

Shall we consider deprecating and removing state:storeInSessionStorage advanced setting?
My understanding is that it was primarily needed to workaround IE url limit?
Please let me know if this is not the only use case and there are still benefits for keeping this around past IE support.

From the description:

The URL can sometimes grow to be too large for some browsers to handle.
To counter-act this we are testing if storing parts of the URL in session storage could help. 
Please let us know how it goes!

Please note:

  • This option is disabled by default.
  • Not sure if we have insight into usage?
  • Only kibana apps use it. Other apps doesn't implement this setting.
  • Initially this was brought up as part of the discussion around uiSettings ownership [uiSettings]: Migrate items owned by app arch to new platform #66040 (comment). Most of the code that implements hashing is in kibana_utils, but seemed weird that an advanced setting would belong to utils plugin.

If we remove this we could get rid of pretty complex codepaths and increase tests code coverage:

Questions

  1. This was needed only to workaround IE url limitation? Is this correct?
  2. If yes, should we consider deprecating it in post IE era?
  3. If yes, do we have to wait for 8.0 to remove it?
@Dosant Dosant added discuss Team:Core Core services & architecture: plugins, logging, config, saved objects, http, ES client, i18n, etc Team:Visualizations Visualization editors, elastic-charts and infrastructure Team:AppArch Feature:StateManagement labels May 27, 2020
@elasticmachine
Copy link
Contributor

Pinging @elastic/kibana-app (Team:KibanaApp)

@elasticmachine
Copy link
Contributor

Pinging @elastic/kibana-platform (Team:Platform)

@elasticmachine
Copy link
Contributor

Pinging @elastic/kibana-app-arch (Team:AppArch)

@timroes
Copy link
Contributor

timroes commented May 27, 2020

This was needed only to workaround IE url limitation? Is this correct?

And the answer here is: No. And thus unfortunately solve all the other questions already. In general it's used to handle too long URLs. This is not an IE11 problem, IE just have a significant lower limit, so you can run way easier into that. But since we store the full state inside the URL you can run into rather long URLs. One example where this might happen (also in other browser) more regularily, is if you try to use Vega and writing long Specifications, which we'll then store fully in the URL. So you might need to use that setting for writing Vega. Ideally we would have a good way, not to store thus kind of long state in the URL, and always store it separately, but I think that'll require quiet some changes to the visualize editor, to have "back" still working as expected, etc. (see also #17603).

@Dosant
Copy link
Contributor Author

Dosant commented May 27, 2020

Got it, @timroes, thanks for detailed explanation!

@Dosant Dosant closed this as completed May 27, 2020
@LeeDr
Copy link

LeeDr commented Aug 17, 2020

The other case I ran into where state:storeInSessionStorage was required was when I had a very large scripted field and tried to use that value (in a filter control) on a dashboard. The entire scripted field was in the URL.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
discuss Feature:StateManagement Team:Core Core services & architecture: plugins, logging, config, saved objects, http, ES client, i18n, etc Team:Visualizations Visualization editors, elastic-charts and infrastructure
Projects
None yet
Development

No branches or pull requests

4 participants