[Index Management] Improve error messages when editing index settings#119144
Merged
sabarasaba merged 12 commits intoelastic:mainfrom Nov 30, 2021
Merged
[Index Management] Improve error messages when editing index settings#119144sabarasaba merged 12 commits intoelastic:mainfrom
sabarasaba merged 12 commits intoelastic:mainfrom
Conversation
sabarasaba
commented
Nov 19, 2021
x-pack/plugins/index_management/__jest__/client_integration/home/indices_tab.test.ts
Show resolved
Hide resolved
Member
Author
|
@elasticmachine merge upstream |
Contributor
|
Pinging @elastic/kibana-stack-management (Team:Stack Management) |
Member
Author
|
@elasticmachine merge upstream |
Member
Author
|
@elasticmachine merge upstream |
sebelga
approved these changes
Nov 25, 2021
Contributor
sebelga
left a comment
There was a problem hiding this comment.
Tested locally and works great. Great improvement @sabarasaba ! Thanks for enhancing this.
I left a few non blocker comments.
x-pack/plugins/index_management/__jest__/client_integration/home/indices_tab.test.ts
Show resolved
Hide resolved
x-pack/plugins/index_management/public/application/services/api.ts
Outdated
Show resolved
Hide resolved
Member
Author
💚 Build Succeeded
Metrics [docs]Async chunks
History
To update your PR or re-run it, just comment with: cc @sabarasaba |
sebelga
approved these changes
Nov 30, 2021
Contributor
sebelga
left a comment
There was a problem hiding this comment.
LGTM! Thanks for making the changes 👍
Contributor
|
@sabarasaba Howdy. I think we need this to be backported to to 7.17 and 8.0 since all of the other tests being backported include changes made in this PR. |
This was referenced Dec 21, 2021
sabarasaba
added a commit
to sabarasaba/kibana
that referenced
this pull request
Dec 21, 2021
…elastic#119144) * Improve error message and start writting tests * Refactor tests * Fix tests * commit using @elastic.co * Refactor test * Add documentation * Fix ts types * Address CR changes Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
sabarasaba
added a commit
to sabarasaba/kibana
that referenced
this pull request
Dec 21, 2021
…elastic#119144) * Improve error message and start writting tests * Refactor tests * Fix tests * commit using @elastic.co * Refactor test * Add documentation * Fix ts types * Address CR changes Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com> # Conflicts: # x-pack/plugins/index_management/__jest__/client_integration/helpers/test_subjects.ts # x-pack/plugins/index_management/public/application/sections/home/index_list/detail_panel/edit_settings_json/edit_settings_json.js
sabarasaba
added a commit
that referenced
this pull request
Dec 21, 2021
…#119144) (#121723) * Improve error message and start writting tests * Refactor tests * Fix tests * commit using @elastic.co * Refactor test * Add documentation * Fix ts types * Address CR changes Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com> Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
sabarasaba
added a commit
that referenced
this pull request
Dec 21, 2021
…ettings (#119144) (#121724) * [Index Management] Improve error messages when editing index settings (#119144) * Improve error message and start writting tests * Refactor tests * Fix tests * commit using @elastic.co * Refactor test * Add documentation * Fix ts types * Address CR changes Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com> # Conflicts: # x-pack/plugins/index_management/__jest__/client_integration/helpers/test_subjects.ts # x-pack/plugins/index_management/public/application/sections/home/index_list/detail_panel/edit_settings_json/edit_settings_json.js * Fix import path
TinLe
pushed a commit
to TinLe/kibana
that referenced
this pull request
Dec 22, 2021
…elastic#119144) * Improve error message and start writting tests * Refactor tests * Fix tests * commit using @elastic.co * Refactor test * Add documentation * Fix ts types * Address CR changes Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes #118026
Summary
Currently when there's an error while saving index settings a very non informative error is shown to the user below the JSON editor. Which makes it harder for users to find if the viewport of their screen is narrow. This PR improves this error message by wrapping it in an error callout above the JSON editor and showing the actual error message returned by Elasticsearch instead of just a
Bad Requestlabel.How to test
yarn es snapshot --license=trialyarn startStack Management->Index Management-> open the flyout of any index and go to theEdit settingstabindex.routing.allocation.include._tier_preferenceto"[data_content]"Screenshots
before/after
// Old version

// Improved error handling

