-
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
[Discover] Fix loading data views in ES|QL mode #199099
[Discover] Fix loading data views in ES|QL mode #199099
Conversation
/ci |
src/plugins/discover/public/application/main/discover_main_route.tsx
Outdated
Show resolved
Hide resolved
…te.tsx Co-authored-by: Julia Rechkunova <[email protected]>
Pinging @elastic/kibana-data-discovery (Team:DataDiscovery) |
💛 Build succeeded, but was flaky
Failed CI StepsTest Failures
Metrics [docs]Async chunks
History
cc @kertal |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Seems to be fixing the issue. Looks good from my side!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM too, thanks for fixing it!
Starting backport for target branches: 8.16, 8.x |
- Closes elastic#199065 ## Summary This PR makes sure that data views are loaded so user can view them after switching from ES|QL mode to data view mode. Looks like it was introduced in elastic#195670 ### Testing On your local instance having `kibana_sample_data_logs` installed * Open a link to an ES|QL query [link](http://localhost:5601/xot/app/discover#/?_g=(filters:!(),refreshInterval:(pause:!t,value:60000),time:(from:now-15m,to:now))&_a=(columns:!(),dataSource:(dataViewId:e3465e67bdeced2befff9f9dca7ecf9c48504cad68a10efd881f4c7dd5ade28a,type:dataView),filters:!(),interval:auto,query:(language:kuery,query:''),sort:!(!(timestamp,desc)))) * Switch to classic * Open the DataView Picker, to see a list of DataViews, before this fix there were none ### Checklist - [x] [Unit or functional tests](https://www.elastic.co/guide/en/kibana/master/development-tests.html) were updated or added to match the most common scenarios --------- Co-authored-by: Julia Rechkunova <[email protected]> Co-authored-by: Julia Rechkunova <[email protected]> (cherry picked from commit 08b83c5)
- Closes elastic#199065 ## Summary This PR makes sure that data views are loaded so user can view them after switching from ES|QL mode to data view mode. Looks like it was introduced in elastic#195670 ### Testing On your local instance having `kibana_sample_data_logs` installed * Open a link to an ES|QL query [link](http://localhost:5601/xot/app/discover#/?_g=(filters:!(),refreshInterval:(pause:!t,value:60000),time:(from:now-15m,to:now))&_a=(columns:!(),dataSource:(dataViewId:e3465e67bdeced2befff9f9dca7ecf9c48504cad68a10efd881f4c7dd5ade28a,type:dataView),filters:!(),interval:auto,query:(language:kuery,query:''),sort:!(!(timestamp,desc)))) * Switch to classic * Open the DataView Picker, to see a list of DataViews, before this fix there were none ### Checklist - [x] [Unit or functional tests](https://www.elastic.co/guide/en/kibana/master/development-tests.html) were updated or added to match the most common scenarios --------- Co-authored-by: Julia Rechkunova <[email protected]> Co-authored-by: Julia Rechkunova <[email protected]> (cherry picked from commit 08b83c5)
💚 All backports created successfully
Note: Successful backport PRs will be merged automatically after passing CI. Questions ?Please refer to the Backport tool documentation |
) # Backport This will backport the following commits from `main` to `8.x`: - [[Discover] Fix loading data views in ES|QL mode (#199099)](#199099) <!--- Backport version: 9.4.3 --> ### Questions ? Please refer to the [Backport tool documentation](https://github.com/sqren/backport) <!--BACKPORT [{"author":{"name":"Matthias Wilhelm","email":"[email protected]"},"sourceCommit":{"committedDate":"2024-11-06T18:13:33Z","message":"[Discover] Fix loading data views in ES|QL mode (#199099)\n\n- Closes https://github.com/elastic/kibana/issues/199065\r\n\r\n## Summary\r\n\r\nThis PR makes sure that data views are loaded so user can view them\r\nafter switching from ES|QL mode to data view mode.\r\n\r\nLooks like it was introduced in\r\nhttps://github.com//pull/195670\r\n\r\n### Testing\r\n\r\nOn your local instance having `kibana_sample_data_logs` installed\r\n\r\n* Open a link to an ES|QL query\r\n[link](http://localhost:5601/xot/app/discover#/?_g=(filters:!(),refreshInterval:(pause:!t,value:60000),time:(from:now-15m,to:now))&_a=(columns:!(),dataSource:(dataViewId:e3465e67bdeced2befff9f9dca7ecf9c48504cad68a10efd881f4c7dd5ade28a,type:dataView),filters:!(),interval:auto,query:(language:kuery,query:''),sort:!(!(timestamp,desc))))\r\n* Switch to classic\r\n* Open the DataView Picker, to see a list of DataViews, before this fix\r\nthere were none\r\n\r\n### Checklist\r\n\r\n- [x] [Unit or functional\r\ntests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)\r\nwere updated or added to match the most common scenarios\r\n\r\n---------\r\n\r\nCo-authored-by: Julia Rechkunova <[email protected]>\r\nCo-authored-by: Julia Rechkunova <[email protected]>","sha":"08b83c55f64bc250a4b6d5909cfc2e46003e9751","branchLabelMapping":{"^v9.0.0$":"main","^v8.17.0$":"8.x","^v(\\d+).(\\d+).\\d+$":"$1.$2"}},"sourcePullRequest":{"labels":["Feature:Discover","release_note:skip","v9.0.0","Team:DataDiscovery","v8.16.0","backport:version","v8.17.0"],"title":"[Discover] Fix loading data views in ES|QL mode","number":199099,"url":"https://github.com/elastic/kibana/pull/199099","mergeCommit":{"message":"[Discover] Fix loading data views in ES|QL mode (#199099)\n\n- Closes https://github.com/elastic/kibana/issues/199065\r\n\r\n## Summary\r\n\r\nThis PR makes sure that data views are loaded so user can view them\r\nafter switching from ES|QL mode to data view mode.\r\n\r\nLooks like it was introduced in\r\nhttps://github.com//pull/195670\r\n\r\n### Testing\r\n\r\nOn your local instance having `kibana_sample_data_logs` installed\r\n\r\n* Open a link to an ES|QL query\r\n[link](http://localhost:5601/xot/app/discover#/?_g=(filters:!(),refreshInterval:(pause:!t,value:60000),time:(from:now-15m,to:now))&_a=(columns:!(),dataSource:(dataViewId:e3465e67bdeced2befff9f9dca7ecf9c48504cad68a10efd881f4c7dd5ade28a,type:dataView),filters:!(),interval:auto,query:(language:kuery,query:''),sort:!(!(timestamp,desc))))\r\n* Switch to classic\r\n* Open the DataView Picker, to see a list of DataViews, before this fix\r\nthere were none\r\n\r\n### Checklist\r\n\r\n- [x] [Unit or functional\r\ntests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)\r\nwere updated or added to match the most common scenarios\r\n\r\n---------\r\n\r\nCo-authored-by: Julia Rechkunova <[email protected]>\r\nCo-authored-by: Julia Rechkunova <[email protected]>","sha":"08b83c55f64bc250a4b6d5909cfc2e46003e9751"}},"sourceBranch":"main","suggestedTargetBranches":["8.16","8.x"],"targetPullRequestStates":[{"branch":"main","label":"v9.0.0","branchLabelMappingKey":"^v9.0.0$","isSourceBranch":true,"state":"MERGED","url":"https://github.com/elastic/kibana/pull/199099","number":199099,"mergeCommit":{"message":"[Discover] Fix loading data views in ES|QL mode (#199099)\n\n- Closes https://github.com/elastic/kibana/issues/199065\r\n\r\n## Summary\r\n\r\nThis PR makes sure that data views are loaded so user can view them\r\nafter switching from ES|QL mode to data view mode.\r\n\r\nLooks like it was introduced in\r\nhttps://github.com//pull/195670\r\n\r\n### Testing\r\n\r\nOn your local instance having `kibana_sample_data_logs` installed\r\n\r\n* Open a link to an ES|QL query\r\n[link](http://localhost:5601/xot/app/discover#/?_g=(filters:!(),refreshInterval:(pause:!t,value:60000),time:(from:now-15m,to:now))&_a=(columns:!(),dataSource:(dataViewId:e3465e67bdeced2befff9f9dca7ecf9c48504cad68a10efd881f4c7dd5ade28a,type:dataView),filters:!(),interval:auto,query:(language:kuery,query:''),sort:!(!(timestamp,desc))))\r\n* Switch to classic\r\n* Open the DataView Picker, to see a list of DataViews, before this fix\r\nthere were none\r\n\r\n### Checklist\r\n\r\n- [x] [Unit or functional\r\ntests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)\r\nwere updated or added to match the most common scenarios\r\n\r\n---------\r\n\r\nCo-authored-by: Julia Rechkunova <[email protected]>\r\nCo-authored-by: Julia Rechkunova <[email protected]>","sha":"08b83c55f64bc250a4b6d5909cfc2e46003e9751"}},{"branch":"8.16","label":"v8.16.0","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"},{"branch":"8.x","label":"v8.17.0","branchLabelMappingKey":"^v8.17.0$","isSourceBranch":false,"state":"NOT_CREATED"}]}] BACKPORT--> Co-authored-by: Matthias Wilhelm <[email protected]>
…9206) # Backport This will backport the following commits from `main` to `8.16`: - [[Discover] Fix loading data views in ES|QL mode (#199099)](#199099) <!--- Backport version: 9.4.3 --> ### Questions ? Please refer to the [Backport tool documentation](https://github.com/sqren/backport) <!--BACKPORT [{"author":{"name":"Matthias Wilhelm","email":"[email protected]"},"sourceCommit":{"committedDate":"2024-11-06T18:13:33Z","message":"[Discover] Fix loading data views in ES|QL mode (#199099)\n\n- Closes https://github.com/elastic/kibana/issues/199065\r\n\r\n## Summary\r\n\r\nThis PR makes sure that data views are loaded so user can view them\r\nafter switching from ES|QL mode to data view mode.\r\n\r\nLooks like it was introduced in\r\nhttps://github.com//pull/195670\r\n\r\n### Testing\r\n\r\nOn your local instance having `kibana_sample_data_logs` installed\r\n\r\n* Open a link to an ES|QL query\r\n[link](http://localhost:5601/xot/app/discover#/?_g=(filters:!(),refreshInterval:(pause:!t,value:60000),time:(from:now-15m,to:now))&_a=(columns:!(),dataSource:(dataViewId:e3465e67bdeced2befff9f9dca7ecf9c48504cad68a10efd881f4c7dd5ade28a,type:dataView),filters:!(),interval:auto,query:(language:kuery,query:''),sort:!(!(timestamp,desc))))\r\n* Switch to classic\r\n* Open the DataView Picker, to see a list of DataViews, before this fix\r\nthere were none\r\n\r\n### Checklist\r\n\r\n- [x] [Unit or functional\r\ntests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)\r\nwere updated or added to match the most common scenarios\r\n\r\n---------\r\n\r\nCo-authored-by: Julia Rechkunova <[email protected]>\r\nCo-authored-by: Julia Rechkunova <[email protected]>","sha":"08b83c55f64bc250a4b6d5909cfc2e46003e9751","branchLabelMapping":{"^v9.0.0$":"main","^v8.17.0$":"8.x","^v(\\d+).(\\d+).\\d+$":"$1.$2"}},"sourcePullRequest":{"labels":["Feature:Discover","release_note:skip","v9.0.0","Team:DataDiscovery","v8.16.0","backport:version","v8.17.0"],"title":"[Discover] Fix loading data views in ES|QL mode","number":199099,"url":"https://github.com/elastic/kibana/pull/199099","mergeCommit":{"message":"[Discover] Fix loading data views in ES|QL mode (#199099)\n\n- Closes https://github.com/elastic/kibana/issues/199065\r\n\r\n## Summary\r\n\r\nThis PR makes sure that data views are loaded so user can view them\r\nafter switching from ES|QL mode to data view mode.\r\n\r\nLooks like it was introduced in\r\nhttps://github.com//pull/195670\r\n\r\n### Testing\r\n\r\nOn your local instance having `kibana_sample_data_logs` installed\r\n\r\n* Open a link to an ES|QL query\r\n[link](http://localhost:5601/xot/app/discover#/?_g=(filters:!(),refreshInterval:(pause:!t,value:60000),time:(from:now-15m,to:now))&_a=(columns:!(),dataSource:(dataViewId:e3465e67bdeced2befff9f9dca7ecf9c48504cad68a10efd881f4c7dd5ade28a,type:dataView),filters:!(),interval:auto,query:(language:kuery,query:''),sort:!(!(timestamp,desc))))\r\n* Switch to classic\r\n* Open the DataView Picker, to see a list of DataViews, before this fix\r\nthere were none\r\n\r\n### Checklist\r\n\r\n- [x] [Unit or functional\r\ntests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)\r\nwere updated or added to match the most common scenarios\r\n\r\n---------\r\n\r\nCo-authored-by: Julia Rechkunova <[email protected]>\r\nCo-authored-by: Julia Rechkunova <[email protected]>","sha":"08b83c55f64bc250a4b6d5909cfc2e46003e9751"}},"sourceBranch":"main","suggestedTargetBranches":["8.16","8.x"],"targetPullRequestStates":[{"branch":"main","label":"v9.0.0","branchLabelMappingKey":"^v9.0.0$","isSourceBranch":true,"state":"MERGED","url":"https://github.com/elastic/kibana/pull/199099","number":199099,"mergeCommit":{"message":"[Discover] Fix loading data views in ES|QL mode (#199099)\n\n- Closes https://github.com/elastic/kibana/issues/199065\r\n\r\n## Summary\r\n\r\nThis PR makes sure that data views are loaded so user can view them\r\nafter switching from ES|QL mode to data view mode.\r\n\r\nLooks like it was introduced in\r\nhttps://github.com//pull/195670\r\n\r\n### Testing\r\n\r\nOn your local instance having `kibana_sample_data_logs` installed\r\n\r\n* Open a link to an ES|QL query\r\n[link](http://localhost:5601/xot/app/discover#/?_g=(filters:!(),refreshInterval:(pause:!t,value:60000),time:(from:now-15m,to:now))&_a=(columns:!(),dataSource:(dataViewId:e3465e67bdeced2befff9f9dca7ecf9c48504cad68a10efd881f4c7dd5ade28a,type:dataView),filters:!(),interval:auto,query:(language:kuery,query:''),sort:!(!(timestamp,desc))))\r\n* Switch to classic\r\n* Open the DataView Picker, to see a list of DataViews, before this fix\r\nthere were none\r\n\r\n### Checklist\r\n\r\n- [x] [Unit or functional\r\ntests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)\r\nwere updated or added to match the most common scenarios\r\n\r\n---------\r\n\r\nCo-authored-by: Julia Rechkunova <[email protected]>\r\nCo-authored-by: Julia Rechkunova <[email protected]>","sha":"08b83c55f64bc250a4b6d5909cfc2e46003e9751"}},{"branch":"8.16","label":"v8.16.0","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"},{"branch":"8.x","label":"v8.17.0","branchLabelMappingKey":"^v8.17.0$","isSourceBranch":false,"state":"NOT_CREATED"}]}] BACKPORT--> Co-authored-by: Matthias Wilhelm <[email protected]>
- Closes elastic#199065 ## Summary This PR makes sure that data views are loaded so user can view them after switching from ES|QL mode to data view mode. Looks like it was introduced in elastic#195670 ### Testing On your local instance having `kibana_sample_data_logs` installed * Open a link to an ES|QL query [link](http://localhost:5601/xot/app/discover#/?_g=(filters:!(),refreshInterval:(pause:!t,value:60000),time:(from:now-15m,to:now))&_a=(columns:!(),dataSource:(dataViewId:e3465e67bdeced2befff9f9dca7ecf9c48504cad68a10efd881f4c7dd5ade28a,type:dataView),filters:!(),interval:auto,query:(language:kuery,query:''),sort:!(!(timestamp,desc)))) * Switch to classic * Open the DataView Picker, to see a list of DataViews, before this fix there were none ### Checklist - [x] [Unit or functional tests](https://www.elastic.co/guide/en/kibana/master/development-tests.html) were updated or added to match the most common scenarios --------- Co-authored-by: Julia Rechkunova <[email protected]> Co-authored-by: Julia Rechkunova <[email protected]>
Summary
This PR makes sure that data views are loaded so user can view them after switching from ES|QL mode to data view mode.
Looks like it was introduced in #195670
Testing
On your local instance having
kibana_sample_data_logs
installedChecklist