Skip to content

[Dashboard][Controls] Do not recommend adhoc dataviews#225705

Merged
ThomThomson merged 5 commits intoelastic:mainfrom
ThomThomson:dashboard/fitlerOutAdhocDataviews
Jul 2, 2025
Merged

[Dashboard][Controls] Do not recommend adhoc dataviews#225705
ThomThomson merged 5 commits intoelastic:mainfrom
ThomThomson:dashboard/fitlerOutAdhocDataviews

Conversation

@ThomThomson
Copy link
Contributor

@ThomThomson ThomThomson commented Jun 27, 2025

Fixes #225357

Overview

This PR stops the Dashboard from placing adhoc data views into its published data views list. This fixes a bug where Dashboard would recommend an adhoc data view as the most relevant data view when creating a control, causing the above bug.

@ThomThomson ThomThomson added bug Fixes for quality problems that affect the customer experience release_note:fix Team:Presentation Presentation Team for Dashboard, Input Controls, and Canvas t// loe:small Small Level of Effort impact:critical This issue should be addressed immediately due to a critical level of impact on the product. backport:version Backport to applied version labels v9.1.0 v8.19.0 v9.0.0 v9.0.4 and removed v9.0.0 labels Jun 27, 2025
@ThomThomson
Copy link
Contributor Author

/ci

@ThomThomson
Copy link
Contributor Author

@elasticmachine merge upstream

@ThomThomson
Copy link
Contributor Author

/ci

@ThomThomson
Copy link
Contributor Author

@elasticmachine merge upstream

@ThomThomson
Copy link
Contributor Author

/ci

@ThomThomson ThomThomson marked this pull request as ready for review July 2, 2025 16:51
@ThomThomson ThomThomson requested review from a team as code owners July 2, 2025 16:51
@elasticmachine
Copy link
Contributor

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

Copy link
Member

@kertal kertal left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Codeowner review, it's just a comment, that makes sense, thx!

Copy link
Contributor

@nreese nreese left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

kibana-presentation changes LGTM. One recommendation is to document that dataViews$ should not contain adhoc data views in src/platform/packages/shared/presentation/presentation_publishing/interfaces/publishes_data_views.ts.
code review only

@elasticmachine
Copy link
Contributor

💚 Build Succeeded

Metrics [docs]

Public APIs missing comments

Total count of every public API that lacks a comment. Target amount is 0. Run node scripts/build_api_docs --plugin [yourplugin] --stats comments for more detailed information.

id before after diff
@kbn/presentation-publishing 222 221 -1
dataViews 451 450 -1
total -2

Async chunks

Total size of all lazy-loaded chunks that will be downloaded as the user navigates the app

id before after diff
controls 477.7KB 477.9KB +164.0B
dashboard 616.9KB 617.0KB +29.0B
total +193.0B

History

@ThomThomson ThomThomson merged commit f48e814 into elastic:main Jul 2, 2025
10 checks passed
kibanamachine pushed a commit to kibanamachine/kibana that referenced this pull request Jul 2, 2025
Stops the Dashboard from placing adhoc data views into its published data views list. This fixes a bug where Dashboard would recommend an adhoc data view as the most relevant data view when creating a control.

(cherry picked from commit f48e814)
@kibanamachine
Copy link
Contributor

💔 Some backports could not be created

Status Branch Result
8.19
9.0 Backport failed because of merge conflicts
9.1 An unhandled error occurred. Please see the logs for details

Note: Successful backport PRs will be merged automatically after passing CI.

Manual backport

To create the backport manually run:

node scripts/backport --pr 225705

Questions ?

Please refer to the Backport tool documentation

kibanamachine pushed a commit to kibanamachine/kibana that referenced this pull request Jul 2, 2025
Stops the Dashboard from placing adhoc data views into its published data views list. This fixes a bug where Dashboard would recommend an adhoc data view as the most relevant data view when creating a control.

(cherry picked from commit f48e814)
@kibanamachine
Copy link
Contributor

💔 Some backports could not be created

Status Branch Result
8.19
9.0 Backport failed because of merge conflicts
9.1

Note: Successful backport PRs will be merged automatically after passing CI.

Manual backport

To create the backport manually run:

node scripts/backport --pr 225705

Questions ?

Please refer to the Backport tool documentation

kibanamachine added a commit that referenced this pull request Jul 2, 2025
#226297)

# Backport

This will backport the following commits from `main` to `9.1`:
- [[Dashboard][Controls] Do not recommend adhoc dataviews
(#225705)](#225705)

<!--- Backport version: 9.6.6 -->

### Questions ?
Please refer to the [Backport tool
documentation](https://github.com/sorenlouv/backport)

<!--BACKPORT [{"author":{"name":"Devon
Thomson","email":"devon.thomson@elastic.co"},"sourceCommit":{"committedDate":"2025-07-02T19:45:45Z","message":"[Dashboard][Controls]
Do not recommend adhoc dataviews (#225705)\n\nStops the Dashboard from
placing adhoc data views into its published data views list. This fixes
a bug where Dashboard would recommend an adhoc data view as the most
relevant data view when creating a
control.","sha":"f48e8142750669651933711e87f57ff26bb8210b","branchLabelMapping":{"^v9.2.0$":"main","^v(\\d+).(\\d+).\\d+$":"$1.$2"}},"sourcePullRequest":{"labels":["bug","release_note:fix","Team:Presentation","loe:small","impact:critical","backport:version","v9.1.0","v8.19.0","v9.2.0","v9.0.4"],"title":"[Dashboard][Controls]
Do not recommend adhoc
dataviews","number":225705,"url":"https://github.com/elastic/kibana/pull/225705","mergeCommit":{"message":"[Dashboard][Controls]
Do not recommend adhoc dataviews (#225705)\n\nStops the Dashboard from
placing adhoc data views into its published data views list. This fixes
a bug where Dashboard would recommend an adhoc data view as the most
relevant data view when creating a
control.","sha":"f48e8142750669651933711e87f57ff26bb8210b"}},"sourceBranch":"main","suggestedTargetBranches":["9.1","8.19","9.0"],"targetPullRequestStates":[{"branch":"9.1","label":"v9.1.0","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"},{"branch":"8.19","label":"v8.19.0","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"},{"branch":"main","label":"v9.2.0","branchLabelMappingKey":"^v9.2.0$","isSourceBranch":true,"state":"MERGED","url":"https://github.com/elastic/kibana/pull/225705","number":225705,"mergeCommit":{"message":"[Dashboard][Controls]
Do not recommend adhoc dataviews (#225705)\n\nStops the Dashboard from
placing adhoc data views into its published data views list. This fixes
a bug where Dashboard would recommend an adhoc data view as the most
relevant data view when creating a
control.","sha":"f48e8142750669651933711e87f57ff26bb8210b"}},{"branch":"9.0","label":"v9.0.4","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"}]}]
BACKPORT-->

Co-authored-by: Devon Thomson <devon.thomson@elastic.co>
kibanamachine added a commit that referenced this pull request Jul 2, 2025
… (#226296)

# Backport

This will backport the following commits from `main` to `8.19`:
- [[Dashboard][Controls] Do not recommend adhoc dataviews
(#225705)](#225705)

<!--- Backport version: 9.6.6 -->

### Questions ?
Please refer to the [Backport tool
documentation](https://github.com/sorenlouv/backport)

<!--BACKPORT [{"author":{"name":"Devon
Thomson","email":"devon.thomson@elastic.co"},"sourceCommit":{"committedDate":"2025-07-02T19:45:45Z","message":"[Dashboard][Controls]
Do not recommend adhoc dataviews (#225705)\n\nStops the Dashboard from
placing adhoc data views into its published data views list. This fixes
a bug where Dashboard would recommend an adhoc data view as the most
relevant data view when creating a
control.","sha":"f48e8142750669651933711e87f57ff26bb8210b","branchLabelMapping":{"^v9.2.0$":"main","^v(\\d+).(\\d+).\\d+$":"$1.$2"}},"sourcePullRequest":{"labels":["bug","release_note:fix","Team:Presentation","loe:small","impact:critical","backport:version","v9.1.0","v8.19.0","v9.2.0","v9.0.4"],"title":"[Dashboard][Controls]
Do not recommend adhoc
dataviews","number":225705,"url":"https://github.com/elastic/kibana/pull/225705","mergeCommit":{"message":"[Dashboard][Controls]
Do not recommend adhoc dataviews (#225705)\n\nStops the Dashboard from
placing adhoc data views into its published data views list. This fixes
a bug where Dashboard would recommend an adhoc data view as the most
relevant data view when creating a
control.","sha":"f48e8142750669651933711e87f57ff26bb8210b"}},"sourceBranch":"main","suggestedTargetBranches":["9.1","8.19","9.0"],"targetPullRequestStates":[{"branch":"9.1","label":"v9.1.0","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"},{"branch":"8.19","label":"v8.19.0","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"},{"branch":"main","label":"v9.2.0","branchLabelMappingKey":"^v9.2.0$","isSourceBranch":true,"state":"MERGED","url":"https://github.com/elastic/kibana/pull/225705","number":225705,"mergeCommit":{"message":"[Dashboard][Controls]
Do not recommend adhoc dataviews (#225705)\n\nStops the Dashboard from
placing adhoc data views into its published data views list. This fixes
a bug where Dashboard would recommend an adhoc data view as the most
relevant data view when creating a
control.","sha":"f48e8142750669651933711e87f57ff26bb8210b"}},{"branch":"9.0","label":"v9.0.4","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"}]}]
BACKPORT-->

Co-authored-by: Devon Thomson <devon.thomson@elastic.co>
@ThomThomson
Copy link
Contributor Author

💚 All backports created successfully

Status Branch Result
9.0

Note: Successful backport PRs will be merged automatically after passing CI.

Questions ?

Please refer to the Backport tool documentation

ThomThomson added a commit to ThomThomson/kibana that referenced this pull request Jul 3, 2025
Stops the Dashboard from placing adhoc data views into its published data views list. This fixes a bug where Dashboard would recommend an adhoc data view as the most relevant data view when creating a control.

(cherry picked from commit f48e814)

# Conflicts:
#	src/platform/plugins/shared/controls/public/controls/data_controls/options_list_control/get_options_list_control_factory.tsx
ThomThomson added a commit that referenced this pull request Jul 3, 2025
#226422)

# Backport

This will backport the following commits from `main` to `9.0`:
- [[Dashboard][Controls] Do not recommend adhoc dataviews
(#225705)](#225705)

<!--- Backport version: 10.0.1 -->

### Questions ?
Please refer to the [Backport tool
documentation](https://github.com/sorenlouv/backport)

<!--BACKPORT [{"author":{"name":"Devon
Thomson","email":"devon.thomson@elastic.co"},"sourceCommit":{"committedDate":"2025-07-02T19:45:45Z","message":"[Dashboard][Controls]
Do not recommend adhoc dataviews (#225705)\n\nStops the Dashboard from
placing adhoc data views into its published data views list. This fixes
a bug where Dashboard would recommend an adhoc data view as the most
relevant data view when creating a
control.","sha":"f48e8142750669651933711e87f57ff26bb8210b","branchLabelMapping":{"^v9.2.0$":"main","^v(\\d+).(\\d+).\\d+$":"$1.$2"}},"sourcePullRequest":{"labels":["bug","release_note:fix","Team:Presentation","loe:small","impact:critical","backport:version","v9.1.0","v8.19.0","v9.2.0","v9.0.4"],"title":"[Dashboard][Controls]
Do not recommend adhoc
dataviews","number":225705,"url":"https://github.com/elastic/kibana/pull/225705","mergeCommit":{"message":"[Dashboard][Controls]
Do not recommend adhoc dataviews (#225705)\n\nStops the Dashboard from
placing adhoc data views into its published data views list. This fixes
a bug where Dashboard would recommend an adhoc data view as the most
relevant data view when creating a
control.","sha":"f48e8142750669651933711e87f57ff26bb8210b"}},"sourceBranch":"main","suggestedTargetBranches":["9.0"],"targetPullRequestStates":[{"branch":"9.1","label":"v9.1.0","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"url":"https://github.com/elastic/kibana/pull/226297","number":226297,"state":"MERGED","mergeCommit":{"sha":"88593381d369a55eff0620015fb75d844e558188","message":"[9.1]
[Dashboard][Controls] Do not recommend adhoc dataviews (#225705)
(#226297)\n\n# Backport\n\nThis will backport the following commits from
`main` to `9.1`:\n- [[Dashboard][Controls] Do not recommend adhoc
dataviews\n(#225705)](https://github.com/elastic/kibana/pull/225705)\n\n\n\n###
Questions ?\nPlease refer to the [Backport
tool\ndocumentation](https://github.com/sorenlouv/backport)\n\n\n\nCo-authored-by:
Devon Thomson
<devon.thomson@elastic.co>"}},{"branch":"8.19","label":"v8.19.0","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"url":"https://github.com/elastic/kibana/pull/226296","number":226296,"state":"MERGED","mergeCommit":{"sha":"7a30084256088d181e483760178d9d2cbc3ab65a","message":"[8.19]
[Dashboard][Controls] Do not recommend adhoc dataviews (#225705)
(#226296)\n\n# Backport\n\nThis will backport the following commits from
`main` to `8.19`:\n- [[Dashboard][Controls] Do not recommend adhoc
dataviews\n(#225705)](https://github.com/elastic/kibana/pull/225705)\n\n\n\n###
Questions ?\nPlease refer to the [Backport
tool\ndocumentation](https://github.com/sorenlouv/backport)\n\n\n\nCo-authored-by:
Devon Thomson
<devon.thomson@elastic.co>"}},{"branch":"main","label":"v9.2.0","branchLabelMappingKey":"^v9.2.0$","isSourceBranch":true,"state":"MERGED","url":"https://github.com/elastic/kibana/pull/225705","number":225705,"mergeCommit":{"message":"[Dashboard][Controls]
Do not recommend adhoc dataviews (#225705)\n\nStops the Dashboard from
placing adhoc data views into its published data views list. This fixes
a bug where Dashboard would recommend an adhoc data view as the most
relevant data view when creating a
control.","sha":"f48e8142750669651933711e87f57ff26bb8210b"}},{"branch":"9.0","label":"v9.0.4","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"}]}]
BACKPORT-->
kertal pushed a commit to kertal/kibana that referenced this pull request Jul 25, 2025
Stops the Dashboard from placing adhoc data views into its published data views list. This fixes a bug where Dashboard would recommend an adhoc data view as the most relevant data view when creating a control.
nreese added a commit that referenced this pull request Oct 14, 2025
…out in the KQL search bar (#238731)

Closes #236288

### Background
#225705 fixed an issue where
controls where getting created with adhoc data views. This fix cause
regression #236288. Instead of
filtering out adhoc data views from dashboard.dataViews$, the fix should
occur in the control group level and ignore adhoc data views when
suggesting the data view when creating a control.

### Test instructions
* install sample web logs and wait until its install - web logs is
expected to be default data view
* install sample flights data set
* create new dashboard
* add ESQL panel with statement `FROM kibana_sample_data_flights | LIMIT
10`
* click into unified search query bar. Verify typeahead is populated
from `flights` data view.
* Add new control to dashboard. Ensure suggested data view is `Kibana
Sample Data Logs` - meaning the control suggested the default data view
and not the adhoc flights data view from the lens panel.
kibanamachine pushed a commit to kibanamachine/kibana that referenced this pull request Oct 14, 2025
…out in the KQL search bar (elastic#238731)

Closes elastic#236288

### Background
elastic#225705 fixed an issue where
controls where getting created with adhoc data views. This fix cause
regression elastic#236288. Instead of
filtering out adhoc data views from dashboard.dataViews$, the fix should
occur in the control group level and ignore adhoc data views when
suggesting the data view when creating a control.

### Test instructions
* install sample web logs and wait until its install - web logs is
expected to be default data view
* install sample flights data set
* create new dashboard
* add ESQL panel with statement `FROM kibana_sample_data_flights | LIMIT
10`
* click into unified search query bar. Verify typeahead is populated
from `flights` data view.
* Add new control to dashboard. Ensure suggested data view is `Kibana
Sample Data Logs` - meaning the control suggested the default data view
and not the adhoc flights data view from the lens panel.

(cherry picked from commit 01e67c3)
kibanamachine pushed a commit to kibanamachine/kibana that referenced this pull request Oct 14, 2025
…out in the KQL search bar (elastic#238731)

Closes elastic#236288

### Background
elastic#225705 fixed an issue where
controls where getting created with adhoc data views. This fix cause
regression elastic#236288. Instead of
filtering out adhoc data views from dashboard.dataViews$, the fix should
occur in the control group level and ignore adhoc data views when
suggesting the data view when creating a control.

### Test instructions
* install sample web logs and wait until its install - web logs is
expected to be default data view
* install sample flights data set
* create new dashboard
* add ESQL panel with statement `FROM kibana_sample_data_flights | LIMIT
10`
* click into unified search query bar. Verify typeahead is populated
from `flights` data view.
* Add new control to dashboard. Ensure suggested data view is `Kibana
Sample Data Logs` - meaning the control suggested the default data view
and not the adhoc flights data view from the lens panel.

(cherry picked from commit 01e67c3)
kibanamachine pushed a commit to kibanamachine/kibana that referenced this pull request Oct 14, 2025
…out in the KQL search bar (elastic#238731)

Closes elastic#236288

### Background
elastic#225705 fixed an issue where
controls where getting created with adhoc data views. This fix cause
regression elastic#236288. Instead of
filtering out adhoc data views from dashboard.dataViews$, the fix should
occur in the control group level and ignore adhoc data views when
suggesting the data view when creating a control.

### Test instructions
* install sample web logs and wait until its install - web logs is
expected to be default data view
* install sample flights data set
* create new dashboard
* add ESQL panel with statement `FROM kibana_sample_data_flights | LIMIT
10`
* click into unified search query bar. Verify typeahead is populated
from `flights` data view.
* Add new control to dashboard. Ensure suggested data view is `Kibana
Sample Data Logs` - meaning the control suggested the default data view
and not the adhoc flights data view from the lens panel.

(cherry picked from commit 01e67c3)
kibanamachine pushed a commit to kibanamachine/kibana that referenced this pull request Oct 14, 2025
…out in the KQL search bar (elastic#238731)

Closes elastic#236288

### Background
elastic#225705 fixed an issue where
controls where getting created with adhoc data views. This fix cause
regression elastic#236288. Instead of
filtering out adhoc data views from dashboard.dataViews$, the fix should
occur in the control group level and ignore adhoc data views when
suggesting the data view when creating a control.

### Test instructions
* install sample web logs and wait until its install - web logs is
expected to be default data view
* install sample flights data set
* create new dashboard
* add ESQL panel with statement `FROM kibana_sample_data_flights | LIMIT
10`
* click into unified search query bar. Verify typeahead is populated
from `flights` data view.
* Add new control to dashboard. Ensure suggested data view is `Kibana
Sample Data Logs` - meaning the control suggested the default data view
and not the adhoc flights data view from the lens panel.

(cherry picked from commit 01e67c3)
kibanamachine added a commit that referenced this pull request Oct 14, 2025
…tered out in the KQL search bar (#238731) (#238990)

# Backport

This will backport the following commits from `main` to `9.1`:
- [[dashboard] fix Adhoc dataviews from ES|QL charts are being filtered
out in the KQL search bar
(#238731)](#238731)

<!--- Backport version: 9.6.6 -->

### Questions ?
Please refer to the [Backport tool
documentation](https://github.com/sorenlouv/backport)

<!--BACKPORT [{"author":{"name":"Nathan
Reese","email":"reese.nathan@elastic.co"},"sourceCommit":{"committedDate":"2025-10-14T17:50:51Z","message":"[dashboard]
fix Adhoc dataviews from ES|QL charts are being filtered out in the KQL
search bar (#238731)\n\nCloses
https://github.com/elastic/kibana/issues/236288\n\n###
Background\nhttps://github.com//pull/225705 fixed an issue
where\ncontrols where getting created with adhoc data views. This fix
cause\nregression #236288.
Instead of\nfiltering out adhoc data views from dashboard.dataViews$,
the fix should\noccur in the control group level and ignore adhoc data
views when\nsuggesting the data view when creating a control.\n\n###
Test instructions\n* install sample web logs and wait until its install
- web logs is\nexpected to be default data view\n* install sample
flights data set\n* create new dashboard\n* add ESQL panel with
statement `FROM kibana_sample_data_flights | LIMIT\n10`\n* click into
unified search query bar. Verify typeahead is populated\nfrom `flights`
data view.\n* Add new control to dashboard. Ensure suggested data view
is `Kibana\nSample Data Logs` - meaning the control suggested the
default data view\nand not the adhoc flights data view from the lens
panel.","sha":"01e67c3b061e8115c793569b7a8923fcecce9295","branchLabelMapping":{"^v9.3.0$":"main","^v(\\d+).(\\d+).\\d+$":"$1.$2"}},"sourcePullRequest":{"labels":["release_note:fix","Team:Presentation","backport:version","v9.2.0","v9.0.6","v9.3.0","v9.1.6","v8.19.6"],"title":"[dashboard]
fix Adhoc dataviews from ES|QL charts are being filtered out in the KQL
search
bar","number":238731,"url":"https://github.com/elastic/kibana/pull/238731","mergeCommit":{"message":"[dashboard]
fix Adhoc dataviews from ES|QL charts are being filtered out in the KQL
search bar (#238731)\n\nCloses
https://github.com/elastic/kibana/issues/236288\n\n###
Background\nhttps://github.com//pull/225705 fixed an issue
where\ncontrols where getting created with adhoc data views. This fix
cause\nregression #236288.
Instead of\nfiltering out adhoc data views from dashboard.dataViews$,
the fix should\noccur in the control group level and ignore adhoc data
views when\nsuggesting the data view when creating a control.\n\n###
Test instructions\n* install sample web logs and wait until its install
- web logs is\nexpected to be default data view\n* install sample
flights data set\n* create new dashboard\n* add ESQL panel with
statement `FROM kibana_sample_data_flights | LIMIT\n10`\n* click into
unified search query bar. Verify typeahead is populated\nfrom `flights`
data view.\n* Add new control to dashboard. Ensure suggested data view
is `Kibana\nSample Data Logs` - meaning the control suggested the
default data view\nand not the adhoc flights data view from the lens
panel.","sha":"01e67c3b061e8115c793569b7a8923fcecce9295"}},"sourceBranch":"main","suggestedTargetBranches":["9.2","9.0","9.1","8.19"],"targetPullRequestStates":[{"branch":"9.2","label":"v9.2.0","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"},{"branch":"9.0","label":"v9.0.6","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"},{"branch":"main","label":"v9.3.0","branchLabelMappingKey":"^v9.3.0$","isSourceBranch":true,"state":"MERGED","url":"https://github.com/elastic/kibana/pull/238731","number":238731,"mergeCommit":{"message":"[dashboard]
fix Adhoc dataviews from ES|QL charts are being filtered out in the KQL
search bar (#238731)\n\nCloses
https://github.com/elastic/kibana/issues/236288\n\n###
Background\nhttps://github.com//pull/225705 fixed an issue
where\ncontrols where getting created with adhoc data views. This fix
cause\nregression #236288.
Instead of\nfiltering out adhoc data views from dashboard.dataViews$,
the fix should\noccur in the control group level and ignore adhoc data
views when\nsuggesting the data view when creating a control.\n\n###
Test instructions\n* install sample web logs and wait until its install
- web logs is\nexpected to be default data view\n* install sample
flights data set\n* create new dashboard\n* add ESQL panel with
statement `FROM kibana_sample_data_flights | LIMIT\n10`\n* click into
unified search query bar. Verify typeahead is populated\nfrom `flights`
data view.\n* Add new control to dashboard. Ensure suggested data view
is `Kibana\nSample Data Logs` - meaning the control suggested the
default data view\nand not the adhoc flights data view from the lens
panel.","sha":"01e67c3b061e8115c793569b7a8923fcecce9295"}},{"branch":"9.1","label":"v9.1.6","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"},{"branch":"8.19","label":"v8.19.6","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"}]}]
BACKPORT-->

Co-authored-by: Nathan Reese <reese.nathan@elastic.co>
kibanamachine added a commit that referenced this pull request Oct 14, 2025
…tered out in the KQL search bar (#238731) (#238991)

# Backport

This will backport the following commits from `main` to `9.2`:
- [[dashboard] fix Adhoc dataviews from ES|QL charts are being filtered
out in the KQL search bar
(#238731)](#238731)

<!--- Backport version: 9.6.6 -->

### Questions ?
Please refer to the [Backport tool
documentation](https://github.com/sorenlouv/backport)

<!--BACKPORT [{"author":{"name":"Nathan
Reese","email":"reese.nathan@elastic.co"},"sourceCommit":{"committedDate":"2025-10-14T17:50:51Z","message":"[dashboard]
fix Adhoc dataviews from ES|QL charts are being filtered out in the KQL
search bar (#238731)\n\nCloses
https://github.com/elastic/kibana/issues/236288\n\n###
Background\nhttps://github.com//pull/225705 fixed an issue
where\ncontrols where getting created with adhoc data views. This fix
cause\nregression #236288.
Instead of\nfiltering out adhoc data views from dashboard.dataViews$,
the fix should\noccur in the control group level and ignore adhoc data
views when\nsuggesting the data view when creating a control.\n\n###
Test instructions\n* install sample web logs and wait until its install
- web logs is\nexpected to be default data view\n* install sample
flights data set\n* create new dashboard\n* add ESQL panel with
statement `FROM kibana_sample_data_flights | LIMIT\n10`\n* click into
unified search query bar. Verify typeahead is populated\nfrom `flights`
data view.\n* Add new control to dashboard. Ensure suggested data view
is `Kibana\nSample Data Logs` - meaning the control suggested the
default data view\nand not the adhoc flights data view from the lens
panel.","sha":"01e67c3b061e8115c793569b7a8923fcecce9295","branchLabelMapping":{"^v9.3.0$":"main","^v(\\d+).(\\d+).\\d+$":"$1.$2"}},"sourcePullRequest":{"labels":["release_note:fix","Team:Presentation","backport:version","v9.2.0","v9.0.6","v9.3.0","v9.1.6","v8.19.6"],"title":"[dashboard]
fix Adhoc dataviews from ES|QL charts are being filtered out in the KQL
search
bar","number":238731,"url":"https://github.com/elastic/kibana/pull/238731","mergeCommit":{"message":"[dashboard]
fix Adhoc dataviews from ES|QL charts are being filtered out in the KQL
search bar (#238731)\n\nCloses
https://github.com/elastic/kibana/issues/236288\n\n###
Background\nhttps://github.com//pull/225705 fixed an issue
where\ncontrols where getting created with adhoc data views. This fix
cause\nregression #236288.
Instead of\nfiltering out adhoc data views from dashboard.dataViews$,
the fix should\noccur in the control group level and ignore adhoc data
views when\nsuggesting the data view when creating a control.\n\n###
Test instructions\n* install sample web logs and wait until its install
- web logs is\nexpected to be default data view\n* install sample
flights data set\n* create new dashboard\n* add ESQL panel with
statement `FROM kibana_sample_data_flights | LIMIT\n10`\n* click into
unified search query bar. Verify typeahead is populated\nfrom `flights`
data view.\n* Add new control to dashboard. Ensure suggested data view
is `Kibana\nSample Data Logs` - meaning the control suggested the
default data view\nand not the adhoc flights data view from the lens
panel.","sha":"01e67c3b061e8115c793569b7a8923fcecce9295"}},"sourceBranch":"main","suggestedTargetBranches":["9.2","9.0","9.1","8.19"],"targetPullRequestStates":[{"branch":"9.2","label":"v9.2.0","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"},{"branch":"9.0","label":"v9.0.6","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"},{"branch":"main","label":"v9.3.0","branchLabelMappingKey":"^v9.3.0$","isSourceBranch":true,"state":"MERGED","url":"https://github.com/elastic/kibana/pull/238731","number":238731,"mergeCommit":{"message":"[dashboard]
fix Adhoc dataviews from ES|QL charts are being filtered out in the KQL
search bar (#238731)\n\nCloses
https://github.com/elastic/kibana/issues/236288\n\n###
Background\nhttps://github.com//pull/225705 fixed an issue
where\ncontrols where getting created with adhoc data views. This fix
cause\nregression #236288.
Instead of\nfiltering out adhoc data views from dashboard.dataViews$,
the fix should\noccur in the control group level and ignore adhoc data
views when\nsuggesting the data view when creating a control.\n\n###
Test instructions\n* install sample web logs and wait until its install
- web logs is\nexpected to be default data view\n* install sample
flights data set\n* create new dashboard\n* add ESQL panel with
statement `FROM kibana_sample_data_flights | LIMIT\n10`\n* click into
unified search query bar. Verify typeahead is populated\nfrom `flights`
data view.\n* Add new control to dashboard. Ensure suggested data view
is `Kibana\nSample Data Logs` - meaning the control suggested the
default data view\nand not the adhoc flights data view from the lens
panel.","sha":"01e67c3b061e8115c793569b7a8923fcecce9295"}},{"branch":"9.1","label":"v9.1.6","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"},{"branch":"8.19","label":"v8.19.6","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"}]}]
BACKPORT-->

Co-authored-by: Nathan Reese <reese.nathan@elastic.co>
kibanamachine added a commit that referenced this pull request Oct 14, 2025
…ltered out in the KQL search bar (#238731) (#238988)

# Backport

This will backport the following commits from `main` to `8.19`:
- [[dashboard] fix Adhoc dataviews from ES|QL charts are being filtered
out in the KQL search bar
(#238731)](#238731)

<!--- Backport version: 9.6.6 -->

### Questions ?
Please refer to the [Backport tool
documentation](https://github.com/sorenlouv/backport)

<!--BACKPORT [{"author":{"name":"Nathan
Reese","email":"reese.nathan@elastic.co"},"sourceCommit":{"committedDate":"2025-10-14T17:50:51Z","message":"[dashboard]
fix Adhoc dataviews from ES|QL charts are being filtered out in the KQL
search bar (#238731)\n\nCloses
https://github.com/elastic/kibana/issues/236288\n\n###
Background\nhttps://github.com//pull/225705 fixed an issue
where\ncontrols where getting created with adhoc data views. This fix
cause\nregression #236288.
Instead of\nfiltering out adhoc data views from dashboard.dataViews$,
the fix should\noccur in the control group level and ignore adhoc data
views when\nsuggesting the data view when creating a control.\n\n###
Test instructions\n* install sample web logs and wait until its install
- web logs is\nexpected to be default data view\n* install sample
flights data set\n* create new dashboard\n* add ESQL panel with
statement `FROM kibana_sample_data_flights | LIMIT\n10`\n* click into
unified search query bar. Verify typeahead is populated\nfrom `flights`
data view.\n* Add new control to dashboard. Ensure suggested data view
is `Kibana\nSample Data Logs` - meaning the control suggested the
default data view\nand not the adhoc flights data view from the lens
panel.","sha":"01e67c3b061e8115c793569b7a8923fcecce9295","branchLabelMapping":{"^v9.3.0$":"main","^v(\\d+).(\\d+).\\d+$":"$1.$2"}},"sourcePullRequest":{"labels":["release_note:fix","Team:Presentation","backport:version","v9.2.0","v9.0.6","v9.3.0","v9.1.6","v8.19.6"],"title":"[dashboard]
fix Adhoc dataviews from ES|QL charts are being filtered out in the KQL
search
bar","number":238731,"url":"https://github.com/elastic/kibana/pull/238731","mergeCommit":{"message":"[dashboard]
fix Adhoc dataviews from ES|QL charts are being filtered out in the KQL
search bar (#238731)\n\nCloses
https://github.com/elastic/kibana/issues/236288\n\n###
Background\nhttps://github.com//pull/225705 fixed an issue
where\ncontrols where getting created with adhoc data views. This fix
cause\nregression #236288.
Instead of\nfiltering out adhoc data views from dashboard.dataViews$,
the fix should\noccur in the control group level and ignore adhoc data
views when\nsuggesting the data view when creating a control.\n\n###
Test instructions\n* install sample web logs and wait until its install
- web logs is\nexpected to be default data view\n* install sample
flights data set\n* create new dashboard\n* add ESQL panel with
statement `FROM kibana_sample_data_flights | LIMIT\n10`\n* click into
unified search query bar. Verify typeahead is populated\nfrom `flights`
data view.\n* Add new control to dashboard. Ensure suggested data view
is `Kibana\nSample Data Logs` - meaning the control suggested the
default data view\nand not the adhoc flights data view from the lens
panel.","sha":"01e67c3b061e8115c793569b7a8923fcecce9295"}},"sourceBranch":"main","suggestedTargetBranches":["9.2","9.0","9.1","8.19"],"targetPullRequestStates":[{"branch":"9.2","label":"v9.2.0","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"},{"branch":"9.0","label":"v9.0.6","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"},{"branch":"main","label":"v9.3.0","branchLabelMappingKey":"^v9.3.0$","isSourceBranch":true,"state":"MERGED","url":"https://github.com/elastic/kibana/pull/238731","number":238731,"mergeCommit":{"message":"[dashboard]
fix Adhoc dataviews from ES|QL charts are being filtered out in the KQL
search bar (#238731)\n\nCloses
https://github.com/elastic/kibana/issues/236288\n\n###
Background\nhttps://github.com//pull/225705 fixed an issue
where\ncontrols where getting created with adhoc data views. This fix
cause\nregression #236288.
Instead of\nfiltering out adhoc data views from dashboard.dataViews$,
the fix should\noccur in the control group level and ignore adhoc data
views when\nsuggesting the data view when creating a control.\n\n###
Test instructions\n* install sample web logs and wait until its install
- web logs is\nexpected to be default data view\n* install sample
flights data set\n* create new dashboard\n* add ESQL panel with
statement `FROM kibana_sample_data_flights | LIMIT\n10`\n* click into
unified search query bar. Verify typeahead is populated\nfrom `flights`
data view.\n* Add new control to dashboard. Ensure suggested data view
is `Kibana\nSample Data Logs` - meaning the control suggested the
default data view\nand not the adhoc flights data view from the lens
panel.","sha":"01e67c3b061e8115c793569b7a8923fcecce9295"}},{"branch":"9.1","label":"v9.1.6","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"},{"branch":"8.19","label":"v8.19.6","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"}]}]
BACKPORT-->

Co-authored-by: Nathan Reese <reese.nathan@elastic.co>
ersin-erdal pushed a commit to ersin-erdal/kibana that referenced this pull request Oct 15, 2025
…out in the KQL search bar (elastic#238731)

Closes elastic#236288

### Background
elastic#225705 fixed an issue where
controls where getting created with adhoc data views. This fix cause
regression elastic#236288. Instead of
filtering out adhoc data views from dashboard.dataViews$, the fix should
occur in the control group level and ignore adhoc data views when
suggesting the data view when creating a control.

### Test instructions
* install sample web logs and wait until its install - web logs is
expected to be default data view
* install sample flights data set
* create new dashboard
* add ESQL panel with statement `FROM kibana_sample_data_flights | LIMIT
10`
* click into unified search query bar. Verify typeahead is populated
from `flights` data view.
* Add new control to dashboard. Ensure suggested data view is `Kibana
Sample Data Logs` - meaning the control suggested the default data view
and not the adhoc flights data view from the lens panel.
mgadewoll pushed a commit to tkajtoch/kibana that referenced this pull request Oct 17, 2025
…out in the KQL search bar (elastic#238731)

Closes elastic#236288

### Background
elastic#225705 fixed an issue where
controls where getting created with adhoc data views. This fix cause
regression elastic#236288. Instead of
filtering out adhoc data views from dashboard.dataViews$, the fix should
occur in the control group level and ignore adhoc data views when
suggesting the data view when creating a control.

### Test instructions
* install sample web logs and wait until its install - web logs is
expected to be default data view
* install sample flights data set
* create new dashboard
* add ESQL panel with statement `FROM kibana_sample_data_flights | LIMIT
10`
* click into unified search query bar. Verify typeahead is populated
from `flights` data view.
* Add new control to dashboard. Ensure suggested data view is `Kibana
Sample Data Logs` - meaning the control suggested the default data view
and not the adhoc flights data view from the lens panel.
rylnd pushed a commit to rylnd/kibana that referenced this pull request Oct 17, 2025
…out in the KQL search bar (elastic#238731)

Closes elastic#236288

### Background
elastic#225705 fixed an issue where
controls where getting created with adhoc data views. This fix cause
regression elastic#236288. Instead of
filtering out adhoc data views from dashboard.dataViews$, the fix should
occur in the control group level and ignore adhoc data views when
suggesting the data view when creating a control.

### Test instructions
* install sample web logs and wait until its install - web logs is
expected to be default data view
* install sample flights data set
* create new dashboard
* add ESQL panel with statement `FROM kibana_sample_data_flights | LIMIT
10`
* click into unified search query bar. Verify typeahead is populated
from `flights` data view.
* Add new control to dashboard. Ensure suggested data view is `Kibana
Sample Data Logs` - meaning the control suggested the default data view
and not the adhoc flights data view from the lens panel.
nickpeihl pushed a commit to nickpeihl/kibana that referenced this pull request Oct 23, 2025
…out in the KQL search bar (elastic#238731)

Closes elastic#236288

### Background
elastic#225705 fixed an issue where
controls where getting created with adhoc data views. This fix cause
regression elastic#236288. Instead of
filtering out adhoc data views from dashboard.dataViews$, the fix should
occur in the control group level and ignore adhoc data views when
suggesting the data view when creating a control.

### Test instructions
* install sample web logs and wait until its install - web logs is
expected to be default data view
* install sample flights data set
* create new dashboard
* add ESQL panel with statement `FROM kibana_sample_data_flights | LIMIT
10`
* click into unified search query bar. Verify typeahead is populated
from `flights` data view.
* Add new control to dashboard. Ensure suggested data view is `Kibana
Sample Data Logs` - meaning the control suggested the default data view
and not the adhoc flights data view from the lens panel.
NicholasPeretti pushed a commit to NicholasPeretti/kibana that referenced this pull request Oct 27, 2025
…out in the KQL search bar (elastic#238731)

Closes elastic#236288

### Background
elastic#225705 fixed an issue where
controls where getting created with adhoc data views. This fix cause
regression elastic#236288. Instead of
filtering out adhoc data views from dashboard.dataViews$, the fix should
occur in the control group level and ignore adhoc data views when
suggesting the data view when creating a control.

### Test instructions
* install sample web logs and wait until its install - web logs is
expected to be default data view
* install sample flights data set
* create new dashboard
* add ESQL panel with statement `FROM kibana_sample_data_flights | LIMIT
10`
* click into unified search query bar. Verify typeahead is populated
from `flights` data view.
* Add new control to dashboard. Ensure suggested data view is `Kibana
Sample Data Logs` - meaning the control suggested the default data view
and not the adhoc flights data view from the lens panel.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

backport:version Backport to applied version labels bug Fixes for quality problems that affect the customer experience impact:critical This issue should be addressed immediately due to a critical level of impact on the product. loe:small Small Level of Effort release_note:fix Team:Presentation Presentation Team for Dashboard, Input Controls, and Canvas t// v8.19.0 v9.0.4 v9.1.0 v9.2.0

5 participants