-
Notifications
You must be signed in to change notification settings - Fork 8.1k
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
[state] store actual state value in session storage #8022
[state] store actual state value in session storage #8022
Commits on Sep 6, 2016
-
[state] store url states into session storage
Kibana currently stores it's entire application state in the URL by rison encoding it and sticking it into a query string parameter, _a for AppState and _g for GlobalState. This has functioned fine for a while, but Internet Explorer's short URL length restriction are starting to become a problem for more and more users. To provide these users with a workaround this adds an advanced config option that will store the state in sessionStorage instead of the URL. This is accomplished by hashing the serialized version of the state, storing a short version of the hash in the URL, and storing the whole serialized state in sessionStorage using the hash + state-type as a key. Since sessionStorage is limited in size, we must clean up old stored states after they become unreachable to the application. This is done using the new `LazyLruStore` class, a wrapper around sessionStorage. This wrapper helps us maintain the list of stored states based on the time they are accessed (On each set the access time is updates). It's cleanup style is configured with it's maxItems, idealClearRatio, and maxIdealClearPercent configurations. The defaults for which should be sufficient. `maxItems`: limits the store to n items, removing the oldest item when the list overflows `idealClearRatio+maxIdealClearPercent`: when `store.setItem(key, value)` throws an error we try to clear space equal to `idealClearRatio * (key+value).length`, but no more space than `totalSize * maxIdealClearPercent`
spalger committedSep 6, 2016 Configuration menu - View commit details
-
Copy full SHA for 8f7af7d - Browse repository at this point
Copy the full SHA 8f7af7dView commit details -
Configuration menu - View commit details
-
Copy full SHA for 55a923d - Browse repository at this point
Copy the full SHA 55a923dView commit details -
Configuration menu - View commit details
-
Copy full SHA for df8e5ac - Browse repository at this point
Copy the full SHA df8e5acView commit details -
[share] stop caching unhashUrl() call
spalger committedSep 6, 2016 Configuration menu - View commit details
-
Copy full SHA for ed12206 - Browse repository at this point
Copy the full SHA ed12206View commit details -
Rename HashingStore interface methods for consistency and clarity. Re…
…move unused '#remove' method.
Configuration menu - View commit details
-
Copy full SHA for b51b5cb - Browse repository at this point
Copy the full SHA b51b5cbView commit details -
Simplify HashingStore interface. Extract createHash method into a cre…
…ateStorageHash module.
Configuration menu - View commit details
-
Copy full SHA for df2c116 - Browse repository at this point
Copy the full SHA df2c116View commit details -
Remove LazyLruStore, HashingStore, and createStorageHash.
- Replace with HashedItemStore, createStateHash, and isStateHash. - Refactor stubBrowserStorage.
Configuration menu - View commit details
-
Copy full SHA for 06ed933 - Browse repository at this point
Copy the full SHA 06ed933View commit details -
incorporate feedback from @thomasneirynck
spalger committedSep 6, 2016 Configuration menu - View commit details
-
Copy full SHA for 6f9c708 - Browse repository at this point
Copy the full SHA 6f9c708View commit details -
[state] enable storing the state in session storage by default
spalger committedSep 6, 2016 Configuration menu - View commit details
-
Copy full SHA for 445ceba - Browse repository at this point
Copy the full SHA 445cebaView commit details -
[crypto] add license from sha.js
spalger committedSep 6, 2016 Configuration menu - View commit details
-
Copy full SHA for a26b850 - Browse repository at this point
Copy the full SHA a26b850View commit details -
Merge branch 'master' of github.com:elastic/kibana into implement/sto…
…reStateInLocalstorage
spalger committedSep 6, 2016 Configuration menu - View commit details
-
Copy full SHA for bf35d8a - Browse repository at this point
Copy the full SHA bf35d8aView commit details
Commits on Sep 7, 2016
-
[state] disable saving to sessionStorage by default
Rather than enable a behavior we would rather not keep by default, we'll keep it opt-in and link to it so that users who have issues can find the setting
spalger committedSep 7, 2016 Configuration menu - View commit details
-
Copy full SHA for 458630d - Browse repository at this point
Copy the full SHA 458630dView commit details