Commit graph

86706 commits

Author SHA1 Message Date
Krzysztof Kowalczyk
017c2e53f5
[Task Manager] Remove spaces plugin dependency in task manager plugin (#221596)
## Summary

This PR removes spaces plugin dependency from task manager plugin and
replaces `spacesService.getActiveSpace` with `getSpaceIdFromPath` from
`@kbn/spaces-utils` package. This prevents a circular dependency from
happening in https://github.com/elastic/kibana/pull/220138

> [!NOTE]  
> I'm changing the test case to use `test-space` id instead of
`testSpace` as this was an invalid space id and it shouldn't have been
used in the mock.

---------

Co-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>
2025-05-28 09:28:16 +02:00
José Luis González
661b96f719
[Search][Query Rules UI] Test in console and delete ruleset from details page (#221350)
## Summary

Adding Test in Console and Delete from the Ruleset details page:



https://github.com/user-attachments/assets/e9db3752-a2e9-4a28-adac-0716809884d6


Test in Console example populating data from the ruleset selected:

![CleanShot 2025-05-23 at 12 18
35@2x](https://github.com/user-attachments/assets/fc94c0e0-f412-4193-9662-9a23703fbfcd)



### Checklist

Check the PR satisfies following conditions. 

Reviewers should verify this PR satisfies this list as well.

- [ ] Any text added follows [EUI's writing
guidelines](https://elastic.github.io/eui/#/guidelines/writing), uses
sentence case text and includes [i18n
support](https://github.com/elastic/kibana/blob/main/src/platform/packages/shared/kbn-i18n/README.md)
- [ ]
[Documentation](https://www.elastic.co/guide/en/kibana/master/development-documentation.html)
was added for features that require explanation or tutorials
- [ ] [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
- [ ] If a plugin configuration key changed, check if it needs to be
allowlisted in the cloud and added to the [docker
list](https://github.com/elastic/kibana/blob/main/src/dev/build/tasks/os_packages/docker_generator/resources/base/bin/kibana-docker)
- [ ] This was checked for breaking HTTP API changes, and any breaking
changes have been approved by the breaking-change committee. The
`release_note:breaking` label should be applied in these situations.
- [ ] [Flaky Test
Runner](https://ci-stats.kibana.dev/trigger_flaky_test_runner/1) was
used on any tests changed
- [ ] The PR description includes the appropriate Release Notes section,
and the correct `release_note:*` label is applied per the
[guidelines](https://www.elastic.co/guide/en/kibana/master/contributing.html#kibana-release-notes-process)

### Identify risks

Does this PR introduce any risks? For example, consider risks like hard
to test bugs, performance regression, potential of data loss.

Describe the risk, its severity, and mitigation for each identified
risk. Invite stakeholders and evaluate how to proceed before merging.

- [ ] [See some risk
examples](https://github.com/elastic/kibana/blob/main/RISK_MATRIX.mdx)
- [ ] ...

---------

Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
Co-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>
2025-05-28 09:20:31 +02:00
Søren Louv-Jansen
b4767bb108
[Obs AI Assistant] Remove semantic_text migration (#220886)
## Background
The semantic text migration was added in 8.17 along with the move to
semantic_text field (https://github.com/elastic/kibana/pull/186499).

## Suggestion

We should remove the semantic_text migration starting in 9.1. Reasons:

- The migration has recently caused severe disruption on a number of
clusters (https://github.com/elastic/kibana/pull/220255).
- The migration may no longer be needed. Users are required to upgrade
Elasticsearch to 8.18 in order to update to 9.0, or 8.19 to upgrade to
9.1. This could mean that users are guaranteed to have run the migration
previously, when upgrading Kibana to 9.1 (needs to be double checked
with Kibana folks)

---------

Co-authored-by: Viduni Wickramarachchi <viduni.ushanka@gmail.com>
Co-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>
2025-05-28 09:29:26 +03:00
Kibana Machine
e6c0491ccc
[api-docs] 2025-05-28 Daily api_docs build (#221722)
Generated by
https://buildkite.com/elastic/kibana-api-docs-daily/builds/1086
2025-05-28 09:20:06 +03:00
Paulina Shakirova
641ee87cc1
[a11y] Fix Title announcement, image flyout dashboards (#220027)
## Summary

This PR resolves [[Platform:Dashboards:DashboardEditMode] Add image
panel is announced
incorrectly](https://github.com/elastic/kibana/issues/215483) issue.
Tested in Safari (Chrome still doesn't pronounce it correctly, which is
a known issue confirmed by Eui team.)

<img width="915" alt="Screenshot 2025-05-04 at 14 06 37"
src="https://github.com/user-attachments/assets/1c2fc8ae-1efc-49b7-ad0b-57eea4cf416c"
/>
2025-05-27 21:21:01 -07:00
Tiago Costa
ce815297b2
skip flaky suite (#217198) 2025-05-28 01:28:09 +01:00
Tiago Costa
b1fe2412df
skip flaky suite (#221030) 2025-05-28 01:23:45 +01:00
Kibana Machine
439f6b8e78 skip failing test suite (#191707) 2025-05-28 02:21:35 +02:00
Kibana Machine
7305bdcb3b skip failing test suite (#221290) 2025-05-28 02:20:47 +02:00
Nathan Reese
33985735fd
[Alerts] fix Duplicated filters are shown (#221678)
Fixes https://github.com/elastic/kibana/issues/221545

### Background
https://github.com/elastic/kibana/pull/215947 refactored
[ControlGroupRenderer](https://github.com/elastic/kibana/blob/main/src/platform/plugins/shared/controls/public/control_group/control_group_renderer/control_group_renderer.tsx)

The regression is caused by this line changing `await
getCreationOptions?.(getDefaultControlGroupRuntimeState(),
controlGroupStateBuilder)` to `getCreationOptions(defaultRuntimeState,
controlGroupStateBuilder)`.

Opening the SLO view caused
https://github.com/elastic/kibana/blob/main/x-pack/solutions/observability/plugins/slo/public/pages/slos/components/common/quick_filters.tsx#L72
to mutate `defaultRuntimeState`, and populate `initialChildControlState`
with `slo-status-filter` and `slo-tags-filter`. Then when returning to
Alerts view, `defaultRuntimeState.initialChildControlState` contained
the controls from SLO page.

### Fix
This PR resolves the issue by passing a new object to
`getCreationOptions` so that `defaultRuntimeState` can not be polluted
by consumers.

### Test steps
* Start kibana with `yarn start`
* Go license page and install 30 day trial license
* In seperate window, run
    ```
    node x-pack/scripts/data_forge.js \
	--events-per-cycle 100 \
	--lookback now-7d  \
	--dataset fake_stack \
	--install-kibana-assets \
	--kibana-url http://localhost:5601/<basePath>
    ```
* In SLO, create an SLO with the following ([more
details](https://github.com/elastic/kibana/blob/main/x-pack/solutions/observability/plugins/slo/dev_docs/slo.md))
    * Type: Custom Query
    * Index: Admin Console
    * Good (query): http.response.status_code < 500
    * Total (query): http.response.status_code : *
* toggle between SLO and alerts page and verify controls in alerts page
do not grow after each visit to SLO page
2025-05-27 18:06:11 -06:00
Meghan Murphy
bcaa3ce28c
[WorkChat] Add Discover and Dashboards to side nav (#221201)
## Summary

This PR adds Discover and Dashboards to Side Navigation for Workchat. 

<img width="247" alt="Screenshot 2025-05-21 at 5 05 54 PM"
src="https://github.com/user-attachments/assets/1e0d55f7-ac66-4588-84e0-aa5e305e450f"
/>
<img width="1903" alt="Screenshot 2025-05-22 at 4 52 11 PM"
src="https://github.com/user-attachments/assets/e19f1680-eb62-4682-9c27-a73a39e62087"
/>

### Checklist

Check the PR satisfies following conditions. 

Reviewers should verify this PR satisfies this list as well.

- [ ] Any text added follows [EUI's writing
guidelines](https://elastic.github.io/eui/#/guidelines/writing), uses
sentence case text and includes [i18n
support](https://github.com/elastic/kibana/blob/main/src/platform/packages/shared/kbn-i18n/README.md)
- [ ]
[Documentation](https://www.elastic.co/guide/en/kibana/master/development-documentation.html)
was added for features that require explanation or tutorials
- [ ] [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
- [ ] If a plugin configuration key changed, check if it needs to be
allowlisted in the cloud and added to the [docker
list](https://github.com/elastic/kibana/blob/main/src/dev/build/tasks/os_packages/docker_generator/resources/base/bin/kibana-docker)
- [ ] This was checked for breaking HTTP API changes, and any breaking
changes have been approved by the breaking-change committee. The
`release_note:breaking` label should be applied in these situations.
- [ ] [Flaky Test
Runner](https://ci-stats.kibana.dev/trigger_flaky_test_runner/1) was
used on any tests changed
- [ ] The PR description includes the appropriate Release Notes section,
and the correct `release_note:*` label is applied per the
[guidelines](https://www.elastic.co/guide/en/kibana/master/contributing.html#kibana-release-notes-process)

### Identify risks

Does this PR introduce any risks? For example, consider risks like hard
to test bugs, performance regression, potential of data loss.

Describe the risk, its severity, and mitigation for each identified
risk. Invite stakeholders and evaluate how to proceed before merging.

- [ ] [See some risk
examples](https://github.com/elastic/kibana/blob/main/RISK_MATRIX.mdx)
- [ ] ...

Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
2025-05-28 01:50:27 +03:00
Antonio Piazza
da537a5506
OpenAI (Other) Connector PKI schema (#215624) 2025-05-27 16:27:57 -06:00
Pierre Gayvallet
f3b4975c8c
[onechat] Introduce plugin and tool registry (#220889)
## Summary

Implements the onechat tool registry RFC.

Fix https://github.com/elastic/search-team/issues/9938
Fix https://github.com/elastic/search-team/issues/10019

This PR introduces the following artifacts:

**plugins:**
- `onechat`

**packages:**
- `@kbn/onechat-common`
- `@kbn/onechat-server`
- `@kbn/onechat-browser`

## Tool APIs overview

### Registering a tool

```ts
class MyPlugin {
  setup(core: CoreSetup, { onechat }: { onechat: OnechatPluginSetup }) {
    onechat.tools.register({
      id: 'my_tool',
      name: 'My Tool',
      description: 'My very first tool',
      meta: {
        tags: ['foo', 'bar'],
      },
      schema: z.object({
        someNumber: z.number().describe('Some random number'),
      }),
      handler: ({ someNumber }, context) => {
        return 42 + someNumber;
      },
    });
  }
}
```

### Executing a tool

Using the `execute` API:

```ts
const { result } = await onechat.tools.execute({
  toolId: 'my_tool',
  toolParams: { someNumber: 9000 },
  request,
});
```

Using a tool descriptor:

```ts
const tool = await onechat.tools.registry.get({ toolId: 'my_tool', request });
const { result } = await tool.execute({ toolParams: { someNumber: 9000 } });
```

With error handling:

```ts
import { isToolNotFoundError } from '@kbn/onechat-common';

try {
  const { result } = await onechat.tools.execute({
    toolId: 'my_tool',
    toolParams: { someNumber: 9000 },
    request,
  });
} catch (e) {
  if (isToolNotFoundError(e)) {
    throw new Error(`run ${e.meta.runId} failed because tool was not found`);
  }
}
```

### Listing tools

```ts
const tools = await onechat.tools.registry.list({ request });
```

*More details and example in the plugin's readme.*

### What is **not** included in this PR:

- tool access control / authorization - we have a dedicated RFC
- dynamic tool registration / permissions checks part/of depends on the
authorization RFC
- feature / capabilities - will come with browser-side and HTTP APIs
- fully defining tool meta - hard to do now
- filter parameters for the tool list API - depends on the meta being
defined

*Those will be follow-ups*. Everything else from the RFC should be
there.

---------

Co-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>
2025-05-28 00:45:01 +03:00
Viduni Wickramarachchi
6d5acfca0d
[Obs AI Assistant] Delete user instruction if text is empty (#221560)
Closes https://github.com/elastic/kibana/issues/220342

## Summary

As of today, when the user clears the user instruction, the entry is not
deleted. Instead the text is cleared from the entry. This has caused
problems in the past.

This PR implements the change where, if a user clears the user
instruction, the entry will be deleted.

Note: Entry deletion via functional tests appears to be flaky due to
issues with clearing the instruction from the editor. Therefore, to
avoid introducing a flaky test, this was covered via a unit test. Added
functional tests to cover scenarios such as creating an instruction,
editing an instruction.

### Screen recording


https://github.com/user-attachments/assets/35a530ca-5a96-4a17-a4b8-d0e4002c1120


### Checklist

Check the PR satisfies following conditions. 

Reviewers should verify this PR satisfies this list as well.

- [x] Any text added follows [EUI's writing
guidelines](https://elastic.github.io/eui/#/guidelines/writing), uses
sentence case text and includes [i18n
support](https://github.com/elastic/kibana/blob/main/src/platform/packages/shared/kbn-i18n/README.md)
- [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
- [x] [Flaky Test
Runner](https://ci-stats.kibana.dev/trigger_flaky_test_runner/1) was
used on any tests changed
- [x] The PR description includes the appropriate Release Notes section,
and the correct `release_note:*` label is applied per the
[guidelines](https://www.elastic.co/guide/en/kibana/master/contributing.html#kibana-release-notes-process)

---------

Co-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>
2025-05-27 17:12:39 -04:00
Julia Rechkunova
c348586e58
[Discover] Persist tabs in local storage and sync selected tab ID with URL (#217706)
- Closes https://github.com/elastic/kibana/issues/216549
- Closes https://github.com/elastic/kibana/issues/216071

## Summary

This PR allows to restore the following state for the previously opened
tabs:
- the selected data view
- classic or ES|QL mode
- query and filters
- time range and refresh interval
- and other properties of the app state
bcba741abc/src/platform/plugins/shared/discover/public/application/main/state_management/discover_app_state_container.ts (L92)

## Changes
- [x] Sync selected tab id to URL => after refresh the initial tab would
be the last selected one
- [x] Restore tabs after refresh 
- [x] Restore appState and globalState after reopening closed tabs
- [x] Clear tabs if Discover was opened from another Kibana app  
- [x] Store tabs in LocalStorage
- [x] Fix "New" action and clear all tabs
- [x] Populate "Recently closed tabs" with data from LocalStorage
- [x] If selected tab id changes in URL externally => update the state  
- [x] Reset the stored state when userId or space Id changes
- [x] Fix all tests

### Testing
- Test that the existing functionality is not affected
- Enable tabs feature in
bcba741abc/src/platform/plugins/shared/discover/public/constants.ts (L15)
and test that tabs are being persisted and can be restored manually too.


### 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
- [x] The PR description includes the appropriate Release Notes section,
and the correct `release_note:*` label is applied per the
[guidelines](https://www.elastic.co/guide/en/kibana/master/contributing.html#kibana-release-notes-process)

---------

Co-authored-by: Davis McPhee <davismcphee@hotmail.com>
Co-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>
2025-05-27 23:32:56 +03:00
Nathan Reese
9d94d8facc
[dashboard] developer console logging to view dashboard unsaved changes (#221027)
Closes https://github.com/elastic/kibana/issues/220118

<img width="600" alt="Screenshot 2025-05-21 at 11 41 42 AM"
src="https://github.com/user-attachments/assets/de35409a-05ea-4509-8eeb-45d4cbd982b0"
/>

### Test instructions
* install sample web logs
* in browser console, enter `window.ELASTIC_PRESENTATION_LOGGER = true`
* Open web logs dashboard
* Change stuff, notice how unsaved changes are logged in console.

---------

Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
2025-05-27 14:15:40 -06:00
Davis Plumlee
892b84cef4
[Security Solution] Fixes rule upgrade Threat Match mapping components overflowing on small screens (#218628)
## Summary

Fixes https://github.com/elastic/kibana/issues/205722

Removes the hard coded width settings for the ThreatMatch components
used in rule editing and prebuilt rule upgrading to make the UI more
reactive and useable on small screens.

### Screenshots

#### Before

**Rule upgrade flyout**
![Screenshot 2025-04-17 at 5 05
12 PM](https://github.com/user-attachments/assets/c78bd2af-f9e6-44f0-b23e-2755e4cf8818)

**Rule editing page**

![before_rule_edit](https://github.com/user-attachments/assets/33facd6a-da20-4479-b1c1-e5f6c952502c)

----

#### After

**Rule upgrade flyout (narrow screen)**
![Screenshot 2025-04-17 at 4 55
21 PM](https://github.com/user-attachments/assets/5f642a19-057f-4086-bd7e-d5997ebe5765)


**Rule upgrade flyout (wide screen)**
![Screenshot 2025-04-17 at 4 55
04 PM](https://github.com/user-attachments/assets/e6def34f-7d97-4421-b0bc-8e77ac602db8)

**Rule editing page**
![Screenshot 2025-04-17 at 4 59
48 PM](https://github.com/user-attachments/assets/4bc3cf9c-df80-4d04-be53-5c819a1b78d3)

**With tooltip** 
![Screenshot 2025-04-23 at 10 18
34 AM](https://github.com/user-attachments/assets/ea66ee6b-cc45-46f8-9d77-683ddaf7e08a)
2025-05-27 14:58:04 -04:00
Jon
db885c5ab7
[build] Add /etc/{default,sysconfig}/kibana to conffile (#221276)
```
[jon@mbpkbn1]~/Downloads% sudo rpm -Uvh kibana-9.1.0-SNAPSHOT-aarch64.rpm
Verifying...                          ################################# [100%]
Preparing...                          ################################# [100%]
Updating / installing...
   1:kibana-9.1.0_SNAPSHOT-1          ################################# [ 50%]
Stopping kibana service... OK
Cleaning up / removing...
   2:kibana-9.0.1-1                   ################################# [100%]
[jon@mbpkbn1]~/Downloads% sudo cat /etc/sysconfig/kibana
user="kibana"
group="kibana"

KBN_PATH_CONF="/etc/kibana"
RESTART_ON_UPGRADE="true"

NODE_OPTIONS_HEAPSNAPSHOT_DEFAULT="--heapsnapshot-signal=SIGUSR2 --diagnostic-dir=/var/lib/kibana"


test upgrade change
```

# Release note
Fixes an issue where `/etc/default/kibana` on deb packages and
`/etc/sysconfig/kibana` on rpm packages would be overwritten on upgrade.
2025-05-27 13:37:32 -05:00
Saarika Bhasi
adda013667
[Search] Index management adds clear filter option to the mappings field type drop down (#221050)
## Summary

Currently, when filtering by fields by field type in index management
mappings tab, user cannot clear the selected filter. In this PR, added
clear button to clear all selected filters.




https://github.com/user-attachments/assets/b4ee4364-5fd3-4081-8433-65c4834d1f52



### Checklist

Check the PR satisfies following conditions. 

Reviewers should verify this PR satisfies this list as well.

- [x] Any text added follows [EUI's writing
guidelines](https://elastic.github.io/eui/#/guidelines/writing), uses
sentence case text and includes [i18n
support](https://github.com/elastic/kibana/blob/main/src/platform/packages/shared/kbn-i18n/README.md)
2025-05-27 21:10:40 +03:00
Tiago Costa
b4e95097db
skip flaky suite (#207704) 2025-05-27 18:55:37 +01:00
Ying Mao
81cafe980e
[Response Ops][Connectors] Updating functional test for executing unsecured actions from non-default space (#221288)
Resolves https://github.com/elastic/kibana/issues/219975

## Summary

Updated functional test for executing unsecured actions from non-default
space to use a created connector, not a pre-configured connector. Using
a pre-configured connector bypasses space issues so the test never
tested the space-specific functionality.

Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
2025-05-27 13:53:39 -04:00
Steph Milovic
7dbfa556c9
[Security Assistant] Fix model bedrock on preconfigured connectors (#221411) 2025-05-27 11:47:03 -06:00
James Gowdy
6562c14a1f
[ML] File upload: Only auto deploy elastic models (#221357)
When adding a `semantic_text` field to the mappings during upload, it
will always try to call inference to auto-deploy the model, even if the
inference endpoint selected isn't an internal elastic one.

To test, add a new endpoint, something like:
```
PUT _inference/text_embedding/openai_embeddings
{
    "service": "openai",
    "service_settings": {
        "api_key": "<key>",
        "model_id": "text-embedding-ada-002"
    }
}
```

In the file upload page, select a PDF file and add an additional
semantic text field

![image](https://github.com/user-attachments/assets/d7ea6483-54ea-4e8d-b85b-f09de116f07e)


During import, there should be no `Initializing model deployment` step.
2025-05-27 20:22:36 +03:00
David Kilfoyle
4c03ca41c2
[Docs] Remove outdated settings yaml file (#221630)
This outdated settings file could cause some confusion so let's remove
it.

The newer `kibana-alert-action-settings.yml` will be used to generated
settings docs.
2025-05-27 13:17:45 -04:00
Yngrid Coello
1a5ba16483
[Deployment Agnostic] Adding registryUrl configuration for DA tests (#221628)
When introducing package registry configuration in
https://github.com/elastic/kibana/pull/193144 I missed the set up of
`xpack.fleet.registryUrl` which has resulted in flaky tests whenever the
test uses fleet underneath.
2025-05-27 19:14:24 +02:00
Sandra G
68992a5405
[Obs AI Assistant] Update reploy text (#221626)
Changes re-deploy to redeploy with the latter being used in other text
in the codebase and docs and the more generally used in the industry.
2025-05-27 12:04:38 -04:00
Maria Iriarte
8c76b93d19
[Lens] Remove transparentize color function (#217344)
## Summary

Removes Lens usage of color functions in favor of color tokens as
requested in
https://github.com/elastic/kibana/issues/199715#custom-colors.

The
[guidelines](https://docs.google.com/document/d/1IAKbasq1nDfqd2IU3KdP8cwD3uCCAwkIekKRq7zgyWg/edit?tab=t.0#heading=h.5rebxirnvgy5)
recommend using opaque colors when possible.

## Screenshots

### After

#### Chart option 

<img width="1005" alt="Screenshot 2025-04-07 at 16 10 56"
src="https://github.com/user-attachments/assets/6b5bf880-9e9e-48b1-8f8a-b047e23e76db"
/>

#### Suggestion panel

<img width="1728" alt="Screenshot 2025-05-26 at 11 09 57"
src="https://github.com/user-attachments/assets/5eeadb53-ec93-4b53-a675-561bfa4df4cb"
/>

#### Drag and drop image

<img width="1728" alt="Screenshot 2025-05-26 at 11 15 49"
src="https://github.com/user-attachments/assets/206197aa-019a-4b1e-84ba-23b719827368"
/>


## Checklist

- [ ] The PR description includes the appropriate Release Notes section,
and the correct `release_note:*` label is applied per the
[guidelines](https://www.elastic.co/guide/en/kibana/master/contributing.html#kibana-release-notes-process)
2025-05-27 18:49:43 +03:00
Rickyanto Ang
ce77052d5e
[Cloud Security] Fix for Preview link issue in Contextual flyout (#221567)
## Summary

This PR address the issue where clicking on Preview accordion option
(Alerts, Misconfiguration, Vulnerability) didn't change the tab in the
left panel


https://github.com/user-attachments/assets/84458570-e1da-4eee-9c57-b83263c5539c
2025-05-27 08:48:41 -07:00
Julia Bardi
6d9f9b4ea1
[Fleet] Fix querying installed packages (#221624)
## Summary

Closes https://github.com/elastic/kibana/issues/220814

Bug introduced in https://github.com/elastic/kibana/pull/156413 where
the filter on `installed_es` was introduced. It doesn't return installed
packages where `installed_es` is empty.

After the fix, packages like APM are returned:
<img width="2538" alt="image"
src="https://github.com/user-attachments/assets/2c3f0832-fc8c-46b1-ad3a-de6d6a9962b8"
/>

This also fixes the remote sync status to show the missing packages:
<img width="719" alt="image"
src="https://github.com/user-attachments/assets/79606fec-cb3d-4f35-a83b-85933fd1d7d2"
/>

 

### Checklist

- [ ] [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
2025-05-27 18:30:31 +03:00
Bena Kansara
776790759c
[Observability] [Alert details page] Remove beta badge from "Related alerts" tab (#221572)
Removes beta badge from "Related alerts" tab in alert detail pages
2025-05-27 17:24:01 +02:00
elastic-vault-github-plugin-prod[bot]
2010066c9e
[main] Sync bundled packages with Package Storage (#221619)
Automated by
https://buildkite.com/elastic/package-storage-infra-kibana-discover-release-branches/builds/2828

Co-authored-by: elasticmachine <elasticmachine@elastic.co>
2025-05-27 18:08:49 +03:00
Kevin Lacabane
2e78b00114
[streams][content pack] check decompressed file size (#220486)
## Summary

Verifies that the uncompressed size of a single object included in the
content pack do not exceed 1MB as a safety measure. The 1MB limit is
based on MAX(`elastic/integrations` dashboard size) * 2.

The change also includes a constraint on the archive internal structure
and expects a single root directory as entry.
Example:
```
content_pack-1.0.0/manifest.yml
content_pack-1.0.0/kibana/dashboard/123-..json
content_pack-1.0.0/kibana/index-pattern/123-..json
...
```

---------

Co-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>
2025-05-27 17:06:47 +02:00
Eyo O. Eyo
f635e2a3b0
[MVP] Product Intercept Dialog (#209571)
## Summary

This PR aims to answer questions about the implementation details for
https://github.com/elastic/kibana-team/issues/1328

We'd like to trigger an intercept dialog to users at specific time
intervals that vary and depend on different parameters, see the PRD
linked in the aforementioned issue.

This MVP takes an approach such that the constraints listed below are
resolved;
- Have the intercept be specific to a single user
- Define a strategy to configure triggers that can vary for the
intercept that's not dependent on the client

How does this work?
- A generic plugin has been created which when declared as dependency
can be used to register and schedule an intercept that should be
presented to the user, this plugin is what's been used for the product
intercept dialog.
- To handle rendering the UI component that gets displayed to the users,
in this PR we hook into core's existing notification system, through the
notification coordinator system that's been created so that we don't
have a situation where an intercept is being displayed whilst a user
might have a toast being rendered to them, if there's an intercept to be
displayed said intercept would not be displayed till the user is
completely done interacting with the toast. [See it's implementation
details
here](src/core/packages/notifications/browser-internal/src/notification_coordinator.ts)
and
[here](x-pack/platform/plugins/private/intercepts/public/prompter/service/intercept_dialog_service.tsx)
for how it's integrated.
- The plugin provides some bootstrap data through an endpoint that every
user calls on page load, ideally this would need to happen just the once
on page load, we then compute when a user should see a trigger
leveraging the bootstrap data provided for the particular registered
trigger in question, the returned data returns the following data as
seen below;

<img width="476" alt="Screenshot 2025-03-27 at 18 01 12"
src="https://github.com/user-attachments/assets/c747b6c8-70d0-4305-b555-ec9998b180c1"
/>


Given we have this data we might then have a flow for triggering the
intercept on the client based of the bootstrap data like so;

	```mermaid
	flowchart TD
	 A[State Bootstrap] --> B{Has data?}
	 B -->|No| C(Do Nothing)
B -->|Yes| D{Does computed runs since trigger registration match stored
user trigger run feedback value?}
	 D -->|No| E[setup timer to display an intercept in that time]
E -->|on completion| G[setup interval to display intercept in the
future]
	 D -->|Yes| G
	 G -->|repeat| G
    ```
	reloading the page restarts the entire process.

## Telemetry

The intercept component provided by defaults records telemetry for
intercept registration, acknowledgement (differentiated into dismissal
and completion), alongside registration overload.


## Visuals


<!--
https://github.com/user-attachments/assets/b39a506c-a119-40e8-9152-258d78691f28
-->

<!--
https://github.com/user-attachments/assets/f564b4bc-9ad9-4e19-8158-6e154ef52fc2
-->

<img width="738" alt="Screenshot 2025-05-07 at 19 41 23"
src="https://github.com/user-attachments/assets/902c6d0b-9299-44bd-8808-4ad97227d0da"
/>

## Testing this PR

- Pull this branch to your machine
- Add the following to your `kibana.dev.yml`, to enable the intercept to
run and be visible

```yml
xpack.intercepts.enabled: true
xpack.product_intercept.enabled: true
xpack.product_intercept.interval: '30s'
```

<!--

### Checklist

Check the PR satisfies following conditions. 

Reviewers should verify this PR satisfies this list as well.

- [ ] Any text added follows [EUI's writing
guidelines](https://elastic.github.io/eui/#/guidelines/writing), uses
sentence case text and includes [i18n
support](https://github.com/elastic/kibana/blob/main/src/platform/packages/shared/kbn-i18n/README.md)
- [ ]
[Documentation](https://www.elastic.co/guide/en/kibana/master/development-documentation.html)
was added for features that require explanation or tutorials
- [ ] [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
- [ ] If a plugin configuration key changed, check if it needs to be
allowlisted in the cloud and added to the [docker
list](https://github.com/elastic/kibana/blob/main/src/dev/build/tasks/os_packages/docker_generator/resources/base/bin/kibana-docker)
- [ ] This was checked for breaking HTTP API changes, and any breaking
changes have been approved by the breaking-change committee. The
`release_note:breaking` label should be applied in these situations.
- [ ] [Flaky Test
Runner](https://ci-stats.kibana.dev/trigger_flaky_test_runner/1) was
used on any tests changed
- [ ] The PR description includes the appropriate Release Notes section,
and the correct `release_note:*` label is applied per the
[guidelines](https://www.elastic.co/guide/en/kibana/master/contributing.html#kibana-release-notes-process)

### Identify risks

Does this PR introduce any risks? For example, consider risks like hard
to test bugs, performance regression, potential of data loss.

Describe the risk, its severity, and mitigation for each identified
risk. Invite stakeholders and evaluate how to proceed before merging.

- [ ] [See some risk
examples](https://github.com/elastic/kibana/blob/main/RISK_MATRIX.mdx)
- [ ] ...

-->

---------

Co-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>
2025-05-27 16:57:58 +02:00
Marco Liberati
b6d71ea7e5
[chore] Remove unused color libraries from renovate (#221603)
## Summary

Remove libraries from `renovate.json` as asked in
https://github.com/elastic/kibana/pull/220221#discussion_r2108741950
2025-05-27 16:36:45 +02:00
Viduni Wickramarachchi
ba6949ae04
[Obs AI Assistant] Update Knowledge Base model via settings (#221319)
Closes https://github.com/elastic/obs-ai-assistant-team/issues/231

## Summary

This PR enables users to change the Knowledge Base model post
installation via AI Assistant Settings.

## How it works


https://github.com/user-attachments/assets/240979ee-56fc-48e4-bd76-de07d03a7c48

### Screenshots


![image](https://github.com/user-attachments/assets/08e4f949-70a4-416e-96d5-0709a54a9f72)


![image](https://github.com/user-attachments/assets/f8da4e76-e679-4a47-8391-a09e5c8ea13c)


![image](https://github.com/user-attachments/assets/07ccfbca-491d-4029-8392-d49315fc1e61)


![image](https://github.com/user-attachments/assets/47fa17f5-ea40-488a-8e5a-436f812ffde0)


### Checklist

Check the PR satisfies following conditions. 

Reviewers should verify this PR satisfies this list as well.

- [x] Any text added follows [EUI's writing
guidelines](https://elastic.github.io/eui/#/guidelines/writing), uses
sentence case text and includes [i18n
support](https://github.com/elastic/kibana/blob/main/src/platform/packages/shared/kbn-i18n/README.md)
- [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
- [ ] [Flaky Test
Runner](https://ci-stats.kibana.dev/trigger_flaky_test_runner/1) was
used on any tests changed
- [x] The PR description includes the appropriate Release Notes section,
and the correct `release_note:*` label is applied per the
[guidelines](https://www.elastic.co/guide/en/kibana/master/contributing.html#kibana-release-notes-process)
2025-05-27 10:09:06 -04:00
Nicolas Chaulet
ea5296a226
[Fleet] Fix bundled package upgrade (#221532) 2025-05-27 10:00:18 -04:00
Ola Pawlus
e713dc6c2f
[Maps] mapColorGradient styles migration to emotion (#221517)
Part of https://github.com/elastic/kibana/issues/207852
2025-05-27 06:30:26 -07:00
Søren Louv-Jansen
3da1f3ea0a
[Obs AI Assistant] Add skipCloud tag to upgrade tests (#221597)
The upgrade tests are flaky in ECH and serverless environments. They
should therefore be skipped for now. Hopefully we can enable them again
in the near future.
2025-05-27 16:25:58 +03:00
Matthias Wilhelm
62bd0b9739
[UnifiedFieldList] Change icon of field list when mapping changes from unmapped to mapped (#221308)
When a field changes from unmapped to mapped the field list is updated, before this change it wasn't
2025-05-27 15:23:25 +02:00
Robert Stelmach
9605a98dee
[Observability:Logs Anomalies page] Replace anomaly table with eui components based table to improve acessibility (#217172) 2025-05-27 14:32:41 +02:00
Joe Reuter
f9b79b3132
Dataset quality: Make sure non-aggregatable message is not shown if no data matches (#221599)
On the dataset quality page, a callout is shown if there are indices
which don't have the `_ignored` field set as aggregatable. This can
happen when some data streams existed from before the cluster got
upgraded.

However, the endpoint to check this also returns `aggregatable: false`
if there are no indices at all in the given time range and filter. While
this might be technically correct, this triggers the display of a
warning callout in the UI which is confusing for users because there
isn't actually a problem.

This PR fixes this.
2025-05-27 14:17:14 +02:00
Marco Liberati
b6c788655a
[chore] Unify all color libraries to chroma.js (#220221)
## Summary

This PR is an updated version of
https://github.com/elastic/kibana/pull/160934 .
All color manipulation libraries now converged to `chroma.js`.

---------

Co-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>
2025-05-27 12:42:53 +02:00
Krzysztof Kowalczyk
7ac80fa5a6
[Spaces] Move getSpaceIdFromPath to a separate package (#221485)
## Summary

This PR creates a separate package with `getSpaceIdFromPath` exported to
avoid creating a circular dependency in
https://github.com/elastic/kibana/pull/220138

---------

Co-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>
2025-05-27 11:57:30 +02:00
Jean-Louis Leysens
feb0e96623
[OAS] Update x-state behaviour to include availability.since (#221137)
## Summary

Updated the behaviour of `setXState` per
https://github.com/elastic/kibana/issues/221056.

Partially addresses that issue. In future we need to migrate existing
routes to add that information, this covers the Core provided
capability.


### 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: kibanamachine <42973632+kibanamachine@users.noreply.github.com>
2025-05-27 11:47:08 +02:00
Arturo Lidueña
85efa38773
Stateful Deployment-Agnostic FTR Config for AI Assistant (#221469)
Closes [#221468](https://github.com/elastic/kibana/issues/221468)

## Summary

Create a Dedicated Stateful Deployment-Agnostic FTR Config for AI
Assistant
2025-05-27 11:39:10 +02:00
Miriam
a5b4d31683
[ObsUX][A11y] Add and improve labels for Legend Options flyout (#221497)
Closes https://github.com/elastic/kibana/issues/212747

#### Summary

Labels has been added or improved to the interactive elements on the
Legend Options flyout in infra inventory

Steps to reproduce

1. Navigate to Configure legend button.
2. Press Enter.
3. Navigate through all elements in Legend Options.
4. Navigate to Return link.
5. Observe screen reader.

tested with VoiceOver

<img width="1150" alt="Screenshot 2025-05-26 at 11 42 26"
src="https://github.com/user-attachments/assets/f367d359-edcd-4420-8fe9-c373f84a86ac"
/>
<img width="1150" alt="Screenshot 2025-05-26 at 11 42 42"
src="https://github.com/user-attachments/assets/781a8c89-61ad-48b5-a73d-009fff6cbf60"
/>
<img width="1150" alt="Screenshot 2025-05-26 at 11 42 56"
src="https://github.com/user-attachments/assets/55cdf8f4-5006-4102-991d-887994b07e1e"
/>
<img width="1150" alt="Screenshot 2025-05-26 at 11 43 13"
src="https://github.com/user-attachments/assets/251ef9bd-d770-4ad1-95ad-4412ee98f51d"
/>

> [!NOTE]  
> Maximum and Minimum are not interactive buttons anymore and a proper
label was added in a previous fix

<img width="1150" alt="Screenshot 2025-05-26 at 11 48 43"
src="https://github.com/user-attachments/assets/412417d1-32e7-4058-9779-f555b7a0f7b9"
/>
2025-05-27 10:04:17 +01:00
Arturo Lidueña
0952e0a6be
retrieve_elastic_doc api test to use local product docs (#218725)
Closes [#217718](https://github.com/elastic/kibana/issues/217718)
Closes [#218819](https://github.com/elastic/kibana/issues/218819)
Closes [#218820](https://github.com/elastic/kibana/issues/218820)

### Summary

Use loca product docs on the retrieve_elastic_doc API test .By
referencing a local product documentation artifact (file:// protocol in
the xpack.productDocBase.artifactRepositoryUrl setting), the test
becomes more reliable, faster, and independent of external changes.

#### Motivation
- Enhanced Reliability: Eliminates dependencies on external HTTP(S)
resources, reducing test flakiness due to network issues or upstream
changes.
- Improved Performance: Utilizes a smaller, trimmed-down version of the
documentation, speeding up test execution.
- Environment Flexibility: Facilitates testing in airgapped or CI
environments without external network access.
- Controlled Testing: Allows precise control over the artifact content,
ensuring consistent and predictable test results. 

#### Implementation Details
- Created a minimal local version of the product documentation artifact,
containing only the necessary components for testing.
- Configured xpack.productDocBase.artifactRepositoryUrl to point to the
local artifact using a file:// path.
- Updated the retrieve_elastic_doc test to validate against specific,
predictable content from the local artifact.


### Checklist

Check the PR satisfies following conditions. 

Reviewers should verify this PR satisfies this list as well.

- [ ] Any text added follows [EUI's writing
guidelines](https://elastic.github.io/eui/#/guidelines/writing), uses
sentence case text and includes [i18n
support](https://github.com/elastic/kibana/blob/main/src/platform/packages/shared/kbn-i18n/README.md)
- [ ]
[Documentation](https://www.elastic.co/guide/en/kibana/master/development-documentation.html)
was added for features that require explanation or tutorials
- [ ] [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
- [ ] If a plugin configuration key changed, check if it needs to be
allowlisted in the cloud and added to the [docker
list](https://github.com/elastic/kibana/blob/main/src/dev/build/tasks/os_packages/docker_generator/resources/base/bin/kibana-docker)
- [ ] This was checked for breaking HTTP API changes, and any breaking
changes have been approved by the breaking-change committee. The
`release_note:breaking` label should be applied in these situations.
- [ ] [Flaky Test
Runner](https://ci-stats.kibana.dev/trigger_flaky_test_runner/1) was
used on any tests changed
- [ ] The PR description includes the appropriate Release Notes section,
and the correct `release_note:*` label is applied per the
[guidelines](https://www.elastic.co/guide/en/kibana/master/contributing.html#kibana-release-notes-process)

---------

Co-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>
Co-authored-by: Viduni Wickramarachchi <viduni.ushanka@gmail.com>
2025-05-27 10:54:26 +02:00
Alejandro García Parrondo
a109d29144
[Discover] Remove not needed tabindex from svg inside button (#117708) (#221265)
## Summary

Closes https://github.com/elastic/kibana/issues/117708

Just removing a tabindex that wasn't needed


### Checklist

Check the PR satisfies following conditions. 

Reviewers should verify this PR satisfies this list as well.

- [ ] Any text added follows [EUI's writing
guidelines](https://elastic.github.io/eui/#/guidelines/writing), uses
sentence case text and includes [i18n
support](https://github.com/elastic/kibana/blob/main/src/platform/packages/shared/kbn-i18n/README.md)
- [ ]
[Documentation](https://www.elastic.co/guide/en/kibana/master/development-documentation.html)
was added for features that require explanation or tutorials
- [ ] [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
- [ ] If a plugin configuration key changed, check if it needs to be
allowlisted in the cloud and added to the [docker
list](https://github.com/elastic/kibana/blob/main/src/dev/build/tasks/os_packages/docker_generator/resources/base/bin/kibana-docker)
- [ ] This was checked for breaking HTTP API changes, and any breaking
changes have been approved by the breaking-change committee. The
`release_note:breaking` label should be applied in these situations.
- [ ] [Flaky Test
Runner](https://ci-stats.kibana.dev/trigger_flaky_test_runner/1) was
used on any tests changed
- [ ] The PR description includes the appropriate Release Notes section,
and the correct `release_note:*` label is applied per the
[guidelines](https://www.elastic.co/guide/en/kibana/master/contributing.html#kibana-release-notes-process)

### Identify risks

Does this PR introduce any risks? For example, consider risks like hard
to test bugs, performance regression, potential of data loss.

Describe the risk, its severity, and mitigation for each identified
risk. Invite stakeholders and evaluate how to proceed before merging.

- [ ] [See some risk
examples](https://github.com/elastic/kibana/blob/main/RISK_MATRIX.mdx)
- [ ] ...
2025-05-27 10:39:36 +02:00
Alejandro García Parrondo
66f2bcb005
[Discover] Update aria-label for field type filter (#217541) (#221090)
## Summary

Closes https://github.com/elastic/kibana/issues/217541

In the `Filter by field type` menu the screen reader announcements were
using duplicated information because it was obtained from the children.
Now the groups have aria tags to better identify the content.

| Before | After |
|--------|------|
| <img width="398" alt="image"
src="https://github.com/user-attachments/assets/5cf408eb-8864-4d1c-9ec6-a597d273c102"
/> | <img width="453" alt="image"
src="https://github.com/user-attachments/assets/de978114-f3fd-44d0-91bb-457de52949b2"
/> |
| <img width="406" alt="image"
src="https://github.com/user-attachments/assets/ace576dc-8790-452c-a92f-4e131b3dcf8b"
/> | <img width="648" alt="image"
src="https://github.com/user-attachments/assets/491ff275-a1a9-4411-9791-04cdc8b472af"
/> |


### Checklist

Check the PR satisfies following conditions. 

Reviewers should verify this PR satisfies this list as well.

- [ ] Any text added follows [EUI's writing
guidelines](https://elastic.github.io/eui/#/guidelines/writing), uses
sentence case text and includes [i18n
support](https://github.com/elastic/kibana/blob/main/src/platform/packages/shared/kbn-i18n/README.md)
- [ ]
[Documentation](https://www.elastic.co/guide/en/kibana/master/development-documentation.html)
was added for features that require explanation or tutorials
- [ ] [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
- [ ] If a plugin configuration key changed, check if it needs to be
allowlisted in the cloud and added to the [docker
list](https://github.com/elastic/kibana/blob/main/src/dev/build/tasks/os_packages/docker_generator/resources/base/bin/kibana-docker)
- [ ] This was checked for breaking HTTP API changes, and any breaking
changes have been approved by the breaking-change committee. The
`release_note:breaking` label should be applied in these situations.
- [ ] [Flaky Test
Runner](https://ci-stats.kibana.dev/trigger_flaky_test_runner/1) was
used on any tests changed
- [ ] The PR description includes the appropriate Release Notes section,
and the correct `release_note:*` label is applied per the
[guidelines](https://www.elastic.co/guide/en/kibana/master/contributing.html#kibana-release-notes-process)

### Identify risks

Does this PR introduce any risks? For example, consider risks like hard
to test bugs, performance regression, potential of data loss.

Describe the risk, its severity, and mitigation for each identified
risk. Invite stakeholders and evaluate how to proceed before merging.

- [ ] [See some risk
examples](https://github.com/elastic/kibana/blob/main/RISK_MATRIX.mdx)
- [ ] ...
2025-05-27 10:39:04 +02:00
elastic-vault-github-plugin-prod[bot]
d5be333973
[main] Sync bundled packages with Package Storage (#220108)
Automated by
https://buildkite.com/elastic/package-storage-infra-kibana-discover-release-branches/builds/2718

Co-authored-by: elasticmachine <elasticmachine@elastic.co>
Co-authored-by: Julia Bardi <90178898+juliaElastic@users.noreply.github.com>
2025-05-27 10:12:23 +02:00