Skip to content

Commit

Permalink
Merge branch '8.x' into backport/8.x/pr-204790
Browse files Browse the repository at this point in the history
  • Loading branch information
neptunian authored Dec 19, 2024
2 parents 04678c0 + 5f539ab commit 1614164
Show file tree
Hide file tree
Showing 426 changed files with 4,694 additions and 3,621 deletions.
18 changes: 18 additions & 0 deletions .buildkite/pipelines/pull_request/scout_ui_tests.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
steps:
- command: .buildkite/scripts/steps/functional/scout_ui_tests.sh
label: 'Scout UI Tests'
agents:
machineType: n2-standard-4
preemptible: true
depends_on:
- build
- quick_checks
- checks
- linting
- linting_with_types
- check_types
timeout_in_minutes: 30
retry:
automatic:
- exit_status: '-1'
limit: 2
12 changes: 11 additions & 1 deletion .buildkite/scripts/pipelines/pull_request/pipeline.ts
Original file line number Diff line number Diff line change
Expand Up @@ -302,7 +302,7 @@ const getPipeline = (filename: string, removeSteps = true) => {
/^packages\/kbn-grouping/,
/^packages\/kbn-resizable-layout/,
/^packages\/kbn-rison/,
/^packages\/kbn-rule-data-utils/,
/^src\/platform\/packages\/shared\/kbn-rule-data-utils/,
/^packages\/kbn-safer-lodash-set/,
/^packages\/kbn-search-types/,
/^packages\/kbn-securitysolution-.*/,
Expand Down Expand Up @@ -386,6 +386,16 @@ const getPipeline = (filename: string, removeSteps = true) => {
);
}

if (
(await doAnyChangesMatch([
/^x-pack\/plugins\/discover_enhanced\/ui_tests/,
/^packages\/kbn-scout/,
])) ||
GITHUB_PR_LABELS.includes('ci:scout-ui-tests')
) {
pipeline.push(getPipeline('.buildkite/pipelines/pull_request/scout_ui_tests.yml'));
}

pipeline.push(getPipeline('.buildkite/pipelines/pull_request/post_build.yml'));

// remove duplicated steps
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ source .buildkite/scripts/common/util.sh
echo --- Security Solution OpenAPI Code Generation

echo -e "\n[Security Solution OpenAPI Code Generation] OpenAPI Common Package\n"
(cd packages/kbn-openapi-common && yarn openapi:generate)
(cd src/platform/packages/shared/kbn-openapi-common && yarn openapi:generate)

echo -e "\n[Security Solution OpenAPI Code Generation] Lists Common Package\n"
(cd x-pack/solutions/security/packages/kbn-securitysolution-lists-common && yarn openapi:generate)
Expand Down
13 changes: 13 additions & 0 deletions .buildkite/scripts/steps/functional/scout_ui_tests.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
#!/usr/bin/env bash

set -euo pipefail

source .buildkite/scripts/steps/functional/common.sh

export JOB=kibana-scout-ui-tests

TEST_CONFIG="x-pack/plugins/discover_enhanced/ui_tests/playwright.config.ts"
KIBANA_DIR="$KIBANA_BUILD_LOCATION"

echo "--- Stateful: 'discover_enhanced' plugin UI Tests"
node scripts/scout run-tests --stateful --config "$TEST_CONFIG" --kibana-install-dir "$KIBANA_DIR"
6 changes: 3 additions & 3 deletions .github/CODEOWNERS
Original file line number Diff line number Diff line change
Expand Up @@ -683,7 +683,7 @@ x-pack/packages/observability/observability_utils/observability_utils_server @el
x-pack/test/security_api_integration/plugins/oidc_provider @elastic/kibana-security
test/common/plugins/otel_metrics @elastic/obs-ux-infra_services-team
packages/kbn-openapi-bundler @elastic/security-detection-rule-management
packages/kbn-openapi-common @elastic/security-detection-rule-management
src/platform/packages/shared/kbn-openapi-common @elastic/security-detection-rule-management
packages/kbn-openapi-generator @elastic/security-detection-rule-management
packages/kbn-optimizer @elastic/kibana-operations
packages/kbn-optimizer-webpack-helpers @elastic/kibana-operations
Expand Down Expand Up @@ -758,7 +758,7 @@ packages/kbn-router-to-openapispec @elastic/kibana-core
packages/kbn-router-utils @elastic/obs-ux-logs-team
examples/routing_example @elastic/kibana-core
packages/kbn-rrule @elastic/response-ops
packages/kbn-rule-data-utils @elastic/security-detections-response @elastic/response-ops @elastic/obs-ux-management-team
src/platform/packages/shared/kbn-rule-data-utils @elastic/security-detections-response @elastic/response-ops @elastic/obs-ux-management-team
x-pack/plugins/rule_registry @elastic/response-ops @elastic/obs-ux-management-team
x-pack/platform/plugins/private/runtime_fields @elastic/kibana-management
packages/kbn-safer-lodash-set @elastic/kibana-security
Expand Down Expand Up @@ -1039,7 +1039,7 @@ packages/kbn-whereis-pkg-cli @elastic/kibana-operations
packages/kbn-xstate-utils @elastic/obs-ux-logs-team
packages/kbn-yarn-lock-validator @elastic/kibana-operations
packages/kbn-zod @elastic/kibana-core
packages/kbn-zod-helpers @elastic/security-detection-rule-management
src/platform/packages/shared/kbn-zod-helpers @elastic/security-detection-rule-management
####
## Everything below this line overrides the default assignments for each package.
## Items lower in the file have higher precedence:
Expand Down
2 changes: 1 addition & 1 deletion dev_docs/key_concepts/building_blocks.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ and <DocLink id="kibBuildingBlocks" section="index-patterns" text="Index Pattern
### Dashboard Embeddable

Add a Dashboard Embeddable directly inside your application to provide users with a set of visualizations and graphs that work seamlessly
with the <DocLink id="kibBuildingBlocks" section="query-bar" text="Query Bar"/>. Every feature that is added to a registered <DocLink id="kibBuildingBlocks" section="embeddables" text="Embeddable" /> (Lens, Maps, Saved Searches and more) will be available automatically, as well as any <DocLink id="kibBuildingBlocks" section="ui-actions--triggers" text="UI Actions" /> that are added to the Embeddable context menu panel (for example, drilldowns, custom panel time ranges, and "share to" features).
with the <DocLink id="kibBuildingBlocks" section="query-bar" text="Query Bar"/>. Every feature that is added to a registered <DocLink id="kibBuildingBlocks" section="embeddables" text="Embeddable" /> (Lens, Maps, Discover sessions and more) will be available automatically, as well as any <DocLink id="kibBuildingBlocks" section="ui-actions--triggers" text="UI Actions" /> that are added to the Embeddable context menu panel (for example, drilldowns, custom panel time ranges, and "share to" features).

The Dashboard Embeddable is one of the highest-level UI components you can add to your application.

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -298,7 +298,7 @@ This event will be indexed with the following structure:

The meta field supports telemetry on time ranges, providing calculated metrics for enhanced context. This includes:

- **Query range in ceconds:**
- **Query range in seconds:**

- Calculated as the time difference in seconds between `rangeFrom` and `rangeTo`.

Expand Down
2 changes: 1 addition & 1 deletion docs/concepts/data-views.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -166,7 +166,7 @@ clusters or indicies from cross-cluster search].
When you delete a {data-source}, you cannot recover the associated field formatters, runtime fields, source filters,
and field popularity data. Deleting a {data-source} does not remove any indices or data documents from {es}.

WARNING: Deleting a {data-source} breaks all visualizations, saved searches, and other saved objects that reference the data view.
WARNING: Deleting a {data-source} breaks all visualizations, saved Discover sessions, and other saved objects that reference the data view.

. Go to the **Data Views** management page using the navigation menu or the <<kibana-navigation-search,global search field>>.

Expand Down
2 changes: 1 addition & 1 deletion docs/concepts/esql.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ disabled using the `enableESQL` setting from the
{kibana-ref}/advanced-options.html[Advanced Settings].
This will hide the {esql} user interface from various applications.
However, users will be able to access existing {esql} artifacts like saved searches and visualizations.
However, users will be able to access existing {esql} artifacts like saved Discover sessions and visualizations.
====

[float]
Expand Down
4 changes: 2 additions & 2 deletions docs/concepts/save-query.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -11,10 +11,10 @@ Save this query, and you can embed the search results in dashboards,
use them as a foundation for building a visualization,
and share them in a link or CVS form.

Saved queries are different than <<save-open-search,saved searches>>,
Saved queries are different than <<save-open-search,saved Discover sessions>>,
which include the *Discover* configuration&mdash;selected columns in the document table, sort order, and
{data-source}&mdash;in addition to the query.
Saved searches are primarily used for adding search results to a dashboard.
Discover sessions are primarily used for adding search results to a dashboard.

[role="xpack"]
==== Read-only access
Expand Down
1 change: 1 addition & 0 deletions docs/developer/plugin-list.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -309,6 +309,7 @@ oss plugins.
|{kib-repo}blob/{branch}/src/plugins/saved_search/README.md[savedSearch]
|Contains the saved search saved object definition and helpers.
This object is created when a user saves their current session in the Discover app.
|{kib-repo}blob/{branch}/src/plugins/screenshot_mode/README.md[screenshotMode]
Expand Down
2 changes: 1 addition & 1 deletion docs/discover/document-explorer.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ In the pop-up, drag the column names to their new order.

* To resize a column, drag the right edge of the column header until the column is the width that you want.
+
Column widths are stored with a saved search. When you visualize saved searches on dashboards, the saved search appears the same as in **Discover**.
Column widths are stored with a Discover session. When you add a Discover session as a dashboard panel, it appears the same as in **Discover**.

[float]
[[document-explorer-density]]
Expand Down
12 changes: 6 additions & 6 deletions docs/discover/get-started-discover.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -293,24 +293,24 @@ Learn more about how to use ES|QL queries in <<try-esql, Using ES|QL>>.

[float]
[[save-discover-search]]
==== Save your search for later use
==== Save your Discover session for later use

Save your search so you can use it later, generate a CSV report, or use it to create visualizations, dashboards, and Canvas workpads.
Saving a search saves the query text, filters,
Save your Discover session so you can use it later, generate a CSV report, or use it to create visualizations, dashboards, and Canvas workpads.
Saving a Discover session saves the query text, filters,
and current view of *Discover*, including the columns selected in
the document table, the sort order, and the {data-source}.

. In the application menu bar, click **Save**.

. Give your search a title and a description.
. Give your session a title and a description.

. Optionally store <<managing-tags,tags>> and the time range with the search.
. Optionally store <<managing-tags,tags>> and the time range with the session.

. Click **Save**.

[float]
[[share-your-findings]]
==== Share your search
==== Share your Discover session

To share your search and **Discover** view with a larger audience, click *Share* in the application menu bar.
For detailed information about the sharing options, refer to <<reporting-getting-started,Reporting>>.
Expand Down
36 changes: 18 additions & 18 deletions docs/discover/save-search.asciidoc
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
[[save-open-search]]
== Save a search for reuse
== Save a Discover session for reuse

A saved search is a convenient way to reuse a search
A saved Discover session is a convenient way to reuse a search
that you've created in *Discover*.
Saved searches are good for adding search results to a dashboard,
Discover sessions are good for saving a configured view of Discover to use later or adding search results to a dashboard,
and can also serve as a foundation for building visualizations.

[role="xpack"]
Expand All @@ -16,27 +16,27 @@ displayed and the *Save* button is not visible. For more information, refer to <
[role="screenshot"]
image::discover/images/read-only-badge.png[Example of Discover's read only access indicator in Kibana's header]
[float]
=== Save a search
=== Save a Discover session

By default, a saved search stores the query text, filters, and
By default, a Discover session stores the query text, filters, and
current view of *Discover*, including the columns and sort order in the document table, and the {data-source}.

. Once you've created a search worth saving, click *Save* in the toolbar.
. Enter a name for the search.
. Optionally store <<managing-tags,tags>> and the time range with the search.
. Once you've created a view worth saving, click *Save* in the toolbar.
. Enter a name for the session.
. Optionally store <<managing-tags,tags>> and the time range with the session.
. Click *Save*.
. To reload your search results in *Discover*, click *Open* in the toolbar, and select the saved search.
. To reload your search results in *Discover*, click *Open* in the toolbar, and select the saved Discover session.
+
If the saved search is associated with a different {data-source} than is currently
selected, opening the saved search changes the selected {data-source}. The query language
used for the saved search is also automatically selected.
If the saved Discover session is associated with a different {data-source} than is currently
selected, opening the saved Discover session changes the selected {data-source}. The query language
used for the saved Discover session is also automatically selected.

[float]
=== Duplicate a search
. In **Discover**, open the search that you want to duplicate.
=== Duplicate a Discover session
. In **Discover**, open the Discover session that you want to duplicate.
. In the toolbar, click *Save*.
. Give the search a new name.
. Turn on **Save as new search**.
. Give the session a new name.
. Turn on **Save as new Discover session**.
. Click *Save*.


Expand All @@ -46,5 +46,5 @@ used for the saved search is also automatically selected.
. Go to *Dashboards*.
. Open or create the dashboard, then click *Edit*.
. Click *Add from library*.
. From the *Types* dropdown, select *Saved search*.
. Select the saved search that you want to visualize, then click *X* to close the list.
. From the *Types* dropdown, select *Discover session*.
. Select the Discover session that you want to add, then click *X* to close the list.
2 changes: 1 addition & 1 deletion docs/discover/search-sessions.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ image::images/search-session-awhile.png[Search Session indicator displaying the
Once you save a search session, you can start a new search,
navigate to a different application, or close the browser.

. To view your saved searches, go to the
. To view your saved search sessions, go to the
*Search Sessions* management page using the navigation menu or the <<kibana-navigation-search,global search field>>.
For a saved or completed session, you can also open this view from the search sessions popup.

Expand Down
28 changes: 14 additions & 14 deletions docs/discover/search.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -92,10 +92,10 @@ status:[400 TO 499] AND (extension:php OR extension:html)


[[save-open-search]]
=== Save a search
A saved search persists your current view of Discover for later retrieval and reuse. You can reload a saved search into Discover, add it to a dashboard, and use it as the basis for a visualization.
=== Save a Discover session
A saved Discover session persists your current view of Discover for later retrieval and reuse. You can reload a saved session into Discover, add it to a dashboard, and use it as the basis for a visualization.

A saved search includes the query text, filters, and optionally, the time filter. A saved search also includes the selected columns in the document table, the sort order, and the current index pattern.
A Discover session includes the query text, filters, and optionally, the time filter. A Discover session also includes the selected columns in the document table, the sort order, and the current {data-source}.

[role="xpack"]
[[discover-read-only-access]]
Expand All @@ -107,23 +107,23 @@ Kibana see <<xpack-security-authorization>>.
[role="screenshot"]
image::discover/images/read-only-badge.png[Example of Discover's read only access indicator in Kibana's header]

==== Save a search
To save the current search:
==== Save a Discover session
To save the current session:

. Click *Save* in the toolbar.
. Enter a name for the search and click *Save*.
. Enter a name for the session and click *Save*.

To import, export, and delete saved searches, go to the *Saved Objects* management page using the navigation menu or the <<kibana-navigation-search,global search field>>.
To import, export, and delete saved Discover sessions, go to the *Saved Objects* management page using the navigation menu or the <<kibana-navigation-search,global search field>>.

==== Open a saved search
To load a saved search into Discover:
==== Open a saved Discover session
To load a saved session into Discover:

. Click *Open* in the toolbar.
. Select the search you want to open.
. Select the session you want to open.

If the saved search is associated with a different index pattern than is currently
selected, opening the saved search changes the selected index pattern. The query language
used for the saved search will also be automatically selected.
If the saved Discover session is associated with a different {data-source} than is currently
selected, opening the saved Discover session changes the selected {data-source}. The query language
used for the saved Discover session will also be automatically selected.

[[save-load-delete-query]]
=== Save a query
Expand All @@ -133,7 +133,7 @@ A saved query is a portable collection of query text and filters that you can re
* View the results of the same query in multiple apps
* Share your query

Saved queries don't include information specific to Discover, such as the currently selected columns in the document table, the sort order, and the index pattern. If you want to save your current view of Discover for later retrieval and reuse, create a <<save-open-search, saved search>> instead.
Saved queries don't include information specific to Discover, such as the currently selected columns in the document table, the sort order, and the {data-source}. If you want to save your current view of Discover for later retrieval and reuse, create a <<save-open-search, Discover session>> instead.

[role="xpack"]
==== Read-only access
Expand Down
4 changes: 2 additions & 2 deletions docs/fleet/fleet.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ It is recommended for advanced users only.
[role="screenshot"]
image::fleet/images/fleet-start.png[{fleet} app in {kib}]

Most integration content installed by {fleet} isn’t editable. This content is tagged with a **Managed** badge in the {kib} UI. Managed content itself cannot be edited or deleted, however managed visualizations, dashboards, and saved searches can be cloned.
Most integration content installed by {fleet} isn’t editable. This content is tagged with a **Managed** badge in the {kib} UI. Managed content itself cannot be edited or deleted, however managed visualizations, dashboards, and Discover sessions can be cloned.

[role="screenshot"]
image::fleet/images/system-managed.png[An image of the new managed badge.]
Expand All @@ -37,7 +37,7 @@ To clone a dashboard:
. Click *Save and return* after editing the dashboard.
. Click *Save*.

To clone managed content relating to specific visualization editors, such as Lens, TSVB, and Maps, view the visualization in the editor then begin to make edits. Unlike cloning dashboards, and dashboard panels, the cloned content retains the original configurations. Once finished you are prompted to save the edits as a new visualization. The same applies for altering any saved searches in a managed visualization.
To clone managed content relating to specific visualization editors, such as Lens, TSVB, and Maps, view the visualization in the editor then begin to make edits. Unlike cloning dashboards, and dashboard panels, the cloned content retains the original configurations. Once finished you are prompted to save the edits as a new visualization. The same applies for altering any linked Discover sessions in a managed visualization.

[float]
== Get started
Expand Down
6 changes: 3 additions & 3 deletions docs/management/advanced-options.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -321,7 +321,7 @@ When disabled, *Discover* loads fields using the {es} search API's

[[discover-searchonpageload]]`discover:searchOnPageLoad`::
Controls whether a search is executed when *Discover* first loads. This setting
does not have an effect when loading a saved search.
does not have an effect when loading a saved Discover session.

[[discover:showFieldStatistics]]`discover:showFieldStatistics`::
beta[] Enables the Field statistics view. Examine details such as
Expand All @@ -334,10 +334,10 @@ Controls the display of multi-fields in the expanded document view.
The default sort direction for time-based data views.

[[doctable-hidetimecolumn]]`doc_table:hideTimeColumn`::
Hides the "Time" column in *Discover* and in all saved searches on dashboards.
Hides the "Time" column in *Discover* and in all Discover session panels on dashboards.

[[doctable-highlight]]`doc_table:highlight`::
Highlights results in *Discover* and saved searches on dashboards. Highlighting
Highlights search results in *Discover* and Discover session panels on dashboards. Highlighting
slows requests when working on big documents.

[[doctable-legacy]]`doc_table:legacy`::
Expand Down
Loading

0 comments on commit 1614164

Please sign in to comment.