Commit graph

84684 commits

Author SHA1 Message Date
Julia Rechkunova
250a473e8d
[Discover Tabs] Support renaming tabs via double click (#213540)
- Closes #210509 

## Summary

This PR enables tab label editing by adding double click handling.

![Mar-07-2025
12-01-53](https://github.com/user-attachments/assets/9dc527bd-e7a5-4539-b1be-81a0685e45e1)

## Testing

Two options are possible:

1. start Storybook with `yarn storybook unified_tabs` and navigate to
`http://localhost:9001`.
2. start Kibana with `yarn start --run-examples`. Then navigate to the
Unified Tabs example plugin
`http://localhost:5601/app/unifiedTabsExamples`.


### Checklist

- [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
2025-03-10 14:32:42 +01:00
Robert Stelmach
49ebf9e43e
[Discover] Exclude Elasticsearch metadata fields from Display in Content Column (#213255)
Removed "_" from fields to exclude in the Display and replaced it with
Elasticsearch's metadata fields.
2025-03-10 13:55:35 +01:00
José Luis González
516c9dcc22
[Search] Using plugs EUI icon (#213700)
## Summary

Updating the new EUI plugs icon within the Create a connector button in
the Home page

![CleanShot 2025-03-10 at 11 20
44@2x](https://github.com/user-attachments/assets/87dda36b-356d-4051-9c6f-9c75daaae364)


### 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-03-10 13:50:15 +01:00
Robert Jaszczurek
6a184b4b4b
[ML] Trained Models: Count tests run against trained models (#212927)
Part of: https://github.com/elastic/kibana/issues/200725
This PR adds UI Counters for tests (success and failed) run against
trained models.
2025-03-10 13:42:30 +01:00
Marco Vettorello
d6afbe9675
[TSVB] Remove temporary fix for Borealis in TSVB test (#212050)
## Summary

Fixes a workaround implemented in the TSVB functional tests to cover a
flaky test that wasn't possible to solve locally.
2025-03-10 13:21:34 +01:00
Stratoula Kalafateli
6f831770fd
[ES|QL] Fixes the suggestion problem in where for multiline queries (#213240)
## Summary

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

This is the attempt to fix this bug:

```
FROM kibana_sample_data_logs
| WHERE event.dataset == # cursor on this line
| LIMIT 10
```

In main the suggestions do not trigger. The problem is that the range is
completely wrong. The lineNumber is 3 while it should be 2 and the start
and end columns are also wrong.


This PR attempts to fix it (hopefully).

![meow](https://github.com/user-attachments/assets/2741891e-5186-477b-900f-ef42bb3371da)


### 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-03-10 13:02:21 +01:00
Georgii Gorbachev
da0480bde9
[Security Solution] Test plan for prebuilt rule upgrade notifications (#212817)
**Epic:** https://github.com/elastic/kibana/issues/174168
**Partially addresses:**
https://github.com/elastic/kibana/issues/202078,
https://github.com/elastic/kibana/issues/210358

## Summary

We started to rework and introduce functional changes to our existing
test plans for prebuilt rule customization, upgrade, and export/import
workflows.

Specifically, this PR:

- Creates a new test plan for prebuilt rule upgrade notifications on the
Rule Management, Rule Details, and Rule Editing pages. The filename is
`prebuilt_rule_upgrade_notifications.md`.
- Extracts the existing scenarios for upgrade notifications on the Rule
Management page from `prebuilt_rule_upgrade_without_preview.md` to
`prebuilt_rule_upgrade_notifications.md`. Also, updates them according
to the most recent UI behavior.
- Adds new scenarios for upgrade notifications on the Rule Details page
to `prebuilt_rule_upgrade_notifications.md`.
- Adds new scenarios for upgrade notifications on the Rule Editing page
to `prebuilt_rule_upgrade_notifications.md`.

The new test plan should be in line with the changes discussed in
https://github.com/elastic/kibana/issues/210358.
2025-03-10 11:50:12 +00:00
Carlos Crespo
3bd48eaefd
[APM] Remove Aggregated Critical Path flamegraph view feature (#213270)
closes [#212256](https://github.com/elastic/kibana/issues/212256)

## Summary


Remove the Aggregated Critical Path feature. The necessary data needed
for this feature comes from a query running a `scripted_metric` agg.

`scripted_metric` agg queries will be rewritten in other features.
However, for the Aggregated Critical Path case, running queries with
available aggregations won't achieve the same accuracy in a performant
way. Another solution would be needed for this.

Given that this feature has been in tech preview since 8.6, and the
adoption number is low, we decided to remove this feature


| Before | After |
|--------|------|
|<img width="800" alt="image"
src="https://github.com/user-attachments/assets/fdb83c13-818f-49c7-ab3c-046dff0a53d1"
/>|<img width="800" alt="image"
src="https://github.com/user-attachments/assets/4739cca2-ae19-4041-8b41-e87c8041e2c1"
/>|


with `observability:apmEnableCriticalPath` enabled

| Before | After |
|--------|------|
|<img width="800" alt="image"
src="https://github.com/user-attachments/assets/95d31db9-9e0d-4095-8300-2625f420da5c"
/>|<img width="800" alt="image"
src="https://github.com/user-attachments/assets/7f845d85-7a6e-4d45-910f-a5bcee159760"
/>|

---------

Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
2025-03-10 12:01:38 +01:00
Umberto Pepato
6c281caceb
[ResponseOps][Cases] Fix flaky Cases action Cypress test (#213529)
## Summary

- Fixes the flaky functional test added in #210547 by adding a network
request intercept and clicking on the correct dropdown button
- Unskips the test file

## References

Closes #211959

### Checklist

- [x] [Flaky Test
Runner](https://ci-stats.kibana.dev/trigger_flaky_test_runner/1) was
used on any tests changed
2025-03-10 11:16:02 +01:00
Stratoula Kalafateli
5f9f88a80e
[ES|QL] Small refactoring (#213439)
## Summary

Just a small refactoring here to make the code a bit more readable. Also
functions inside functions didnt make a lot of sense there
2025-03-10 10:58:40 +01:00
Alex Szabo
1e1fc8011e
[CI] remove 8.15 es snapshot build schedule (#213607)
## Summary
Removes schedule that triggers daily builds on
https://buildkite.com/elastic/kibana-elasticsearch-snapshot-build (8.15
won't be released any more)
2025-03-10 10:57:54 +01:00
Alex Szabo
830dbd4ed7
[ci] Trigger VM image rebuild for cache rebuild only (#213497)
## Summary
When VM image rebuild is triggered after ES promotion, only the cache
warmup should be built.

This PR also separates the daily full build to a daily base + cache
build (in case ES promotions are failing for some reason, we should
still have a daily cache refresh).

Requires: https://github.com/elastic/ci-agent-images/pull/1295

With this, we'd run a daily base image build and cache build (~40m +
25m) + cache warmups for every promotion (~4x 25m) instead of a full
build and promotion per build (~4x 55m). Ultimately not that much of a
gain 🤷 (4*55=220m => 40+5x25=165m)
2025-03-10 10:56:15 +01:00
Kibana Machine
97e6a8d974
[ES|QL] Update function metadata (#213672)
This PR updates the function definitions and inline docs based on the
latest metadata from Elasticsearch.
2025-03-10 09:02:32 +01:00
Kibana Machine
2c93a349f3
[api-docs] 2025-03-10 Daily api_docs build (#213673)
Generated by
https://buildkite.com/elastic/kibana-api-docs-daily/builds/1007
2025-03-10 07:11:00 +01:00
Davis McPhee
c398102c79
[Discover] Enable consistent-type-imports eslint rule (#212293)
## Summary

This PR enables the `@typescript-eslint/consistent-type-imports` eslint
rule for the Discover and saved search plugins. The benefits are that it
keeps things a bit cleaner, but more importantly ensures we aren't
accidentally importing more than types when all we need is types, which
can cause side effects.

I've added `backport:prev-major` and `backport:prev-minor` labels to the
PR because I figure backporting this is safe and would reduce merge
conflicts in future backports.

We should consider enabling this for all of our plugins and packages,
although that list might harder to maintain. I'm also curious if anyone
knows of other eslint rules we don't currently use that we'd benefit
from enabling.

### Checklist

- [ ] 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>
2025-03-10 00:09:57 -03:00
Kibana Machine
8388710236
[api-docs] 2025-03-09 Daily api_docs build (#213667)
Generated by
https://buildkite.com/elastic/kibana-api-docs-daily/builds/1006
2025-03-09 08:09:21 +01:00
Zacqary Adam Xeper
fffc18cfc4
[Response Ops] [Rule Form] Remove V1 Rule Form Flyout (#209171)
## Summary

Closes #195211 

Removes all old rule form flyout code, which should no longer be
referenced at all after https://github.com/elastic/kibana/pull/206685/

### 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-03-08 14:26:54 +02:00
Kenneth Kreindler
166efa0c83
[Security Solution] [Attack discovery] Fix mistake in default attack discovery graph state (#213651)
## Summary

Fix mistake instroduced in [this
PR](https://github.com/elastic/kibana/pull/205553/files#diff-7a3a06cc740e97fe6941bb05a878a18561ed194946d3f28fadeb3f2f38dc1013R50).
The default state of continuePrompt was not migrated correctly.

### 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]
[Documentation](https://www.elastic.co/guide/en/kibana/master/development-documentation.html)
was added for features that require explanation or tutorials
- [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] 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)
- [X] 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.
- [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)

### 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-03-08 11:21:37 +01:00
Kibana Machine
bda4c78c53
[api-docs] 2025-03-08 Daily api_docs build (#213647)
Generated by
https://buildkite.com/elastic/kibana-api-docs-daily/builds/1005
2025-03-08 08:19:44 +01:00
Devin W. Hurley
b64be404b0
[Security Solution] [Detections] Support user error tagging for eql rule types (#213470)
## Summary

adds support for tagging user errors in eql rule type and tags missing
data view id as user error
2025-03-08 01:24:05 +01:00
Jen Huang
3f90203406
[UII] Support searchAfter and PIT (point-in-time) parameters for get agents list API (#213486)
## Summary

Resolves https://github.com/elastic/kibana/issues/206924.

This PR adds the following query parameters to the agent list API (`GET
/api/fleet/agents`) in order to enable fetching beyond the first 10,000
hits:
```
    searchAfter?: string;
    openPit?: boolean;
    pitId?: string;
    pitKeepAlive?: string;
```

The list agent API response can now include the following properties
```
    // the PIT ID used
    pit?: string;

    // stringified version of the last agent's `sort` field,
    // can be passed as `searchAfter` in the next request
    nextSearchAfter? string;
```

* `searchAfter` can be used with or without a `pitId`. If using
`searchAfter`, `page` parameter is not accepted.

* `searchAfter` expects a stringified array. (Reviewers: I couldn't get
the Kibana request schema to accept a multi-part query param and convert
it to an array... I think this would be better, please let me know if
you know how to get that to work 🙏)

* `pitKeepAlive` duration (i.e. `30s`, `1m`, etc) must be present when
opening a PIT or retrieving results using a PIT ID.

* These can be used with the existing `sortField` and `sortOrder`
params. They default to `enrolled_at` and `desc` respectively.

### Example using only `searchAfter`:

```
# Retrieve the first 10k hits
curl -X GET 'http://<user>:<pass>@<kibana url>/api/fleet/agents?perPage=10000'

# Grab the `nextSearchAfter` param from the response
# Pass it to the new request to retrieve the next page of 10k hits
curl -X GET 'http://<user>:<pass>@<kibana url>/api/fleet/agents?perPage=10000&searchAfter=<nextSearchAfter>'
```

### Example using `searchAfter` with point-in-time parameters:
```
# Retrieve the first 10k hits and open a PIT
curl -X GET 'http://<user>:<pass>@<kibana url>/api/fleet/agents?perPage=10000&openPit=true&pitKeepAlive=5m'

# Grab the `pit` ID from the response
# Grab the `nextSearchAfter` param from the response
# Pass both to the new request to retrieve the next page of 10k hits
curl -X GET 'http://<user>:<pass>@<kibana url>/api/fleet/agents?perPage=10000&searchAfter=<nextSearchAfter>&pitId=<pit id>&pitKeepAlive=5m'
```

## Testing
I recommend using `scripts/create_agents` to generate bulk agents and
testing the above requests. You can generate new agents between PIT
requests to test that using a PIT ID retains the original state. (An API
functional test was added for this)

Note: you may need to add `&showInactive=true` to all requests if your
fake agents become inactive.

TBD

### Checklist

Check the PR satisfies following conditions. 

Reviewers should verify this PR satisfies this list as well.

- [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: kibanamachine <42973632+kibanamachine@users.noreply.github.com>
2025-03-07 16:01:49 -08:00
Rodney Norris
c9969e798a
[Search] test: remove navigation skip in mki (#213256)
## Summary

The navigation test was skipped in MKI because opening the maps page
caused a modal that then prevented navigating away from maps to continue
the test.

Opening the maps page has previously been removed from the navigation
test suite and therefore this test doesn't need to be skipped in MKI any
longer.

Closes #196823

### Checklist

- [ ] [Flaky Test
Runner](https://ci-stats.kibana.dev/trigger_flaky_test_runner/1) was
used on any tests changed
2025-03-08 00:57:46 +01:00
Lisa Cawley
147ccae730
Add examples for APM source map APIs (#212449) 2025-03-08 00:18:35 +01:00
Nicolas Ruflin
9689c7e05a
Fix installation of EDOT Collector for Mac (#212606)
When running the download script, the following error was printed in the
end:

```
Warning: Got more output options than URLs
```

This fixes the warning by removing the -O option. Removing `--output`
does not work as the file on disk has not the same file name as the own
on the remote server.

As the issue exists for Mac and Linus, both were fixed. I did a quick
manual test on Debian and OS X, both worked as expected.

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

Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
2025-03-07 22:11:26 +01:00
Tiago Costa
bc32269787
skip flaky suite (#213422) 2025-03-07 18:48:03 +00:00
elastic-renovate-prod[bot]
95081f2150
Update docker.elastic.co/wolfi/chainguard-base:latest Docker digest to 10f7cda (main) (#213511)
This PR contains the following updates:

| Package | Update | Change |
|---|---|---|
| docker.elastic.co/wolfi/chainguard-base | digest | `6dcddd8` ->
`10f7cda` |

---

### Configuration

📅 **Schedule**: Branch creation - At any time (no schedule defined),
Automerge - At any time (no schedule defined).

🚦 **Automerge**: Disabled by config. Please merge this manually once you
are satisfied.

♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the
rebase/retry checkbox.

🔕 **Ignore**: Close this PR and you won't be reminded about this update
again.

---

- [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check
this box

---

This PR has been generated by [Renovate
Bot](https://redirect.github.com/renovatebot/renovate).

<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzOS4xMDcuMCIsInVwZGF0ZWRJblZlciI6IjM5LjEwNy4wIiwidGFyZ2V0QnJhbmNoIjoibWFpbiIsImxhYmVscyI6WyJUZWFtOk9wZXJhdGlvbnMiLCJiYWNrcG9ydDpza2lwIiwicmVsZWFzZV9ub3RlOnNraXAiXX0=-->

Co-authored-by: elastic-renovate-prod[bot] <174716857+elastic-renovate-prod[bot]@users.noreply.github.com>
2025-03-07 12:38:46 -06:00
Sergi Massaneda
723a33b7de
[Security Solution][Connectors] Torq connector allow EU hooks hostname (#212563)
## Summary

From: https://github.com/elastic/kibana/issues/212511

Add support for EU domains

---------

Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
2025-03-07 18:43:24 +01:00
Mike Côté
5041031b5d
Wait for Elasticsearch cluster health to be green/yellow on task manager index before starting the poller (#212785)
I've noticed some serverless projects would encounter `503` errors
shortly after "resuming". When this happens, Elasticsearch needs time to
restore indices and their data before it can fulfill requests
successfully. It was recommended to wait for the cluster / index to have
a healthy green (serverless) / yellow (stateful) status before starting
to run background tasks. This way the task manager will not encounter
503 errors as often which reflect into the metrics.

There are a few functional details to the changes I've made:
- Narrows the health call to the task manager index only
- Waits for green on serverless and yellow on stateful
- Has a timeout of 30s
- Will start claiming tasks after the timeout or when an error is
returned by the API call - to prevent a node not claiming tasks at all
(reduce risk, smoother introduction to this new constraint)

## To verify
- Ensure code reflects functional requirements
- Verify unit tests validate the functionality on various code paths
- Ensure Kibana starts claiming tasks on startup once the health API
responds (can also check on serverless and ECH. I spun up one of each
with this PR)

---------

Co-authored-by: Ying Mao <ying.mao@elastic.co>
2025-03-07 18:38:16 +01:00
Marshall Main
a78f9c2efe
[Security Solution] Extract common shared security params into object (#212694)
## Summary

Replaces many long lists of parameters with `sharedParams` - a list of
commonly used inputs from the shared security rule wrapper.
`sharedParams` should be treated as immutable throughout the entire rule
execution to eliminate confusion about which params are specific to
certain code paths and which ones are simply passed through from the
shared wrapper.

More refactoring will follow to further reduce the pass through param
passing. I attempted to limit the scope of changes in this PR by
destructuring `sharedParams` into the expected param format for some
functions. This also sets us up to remove function passing of
`wrapHits`, `bulkCreate`, etc, which would have required passing more of
these individual shared params deep into rule execution logic.

---------

Co-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>
2025-03-07 12:30:35 -05:00
Kibana Machine
e7c71937d5 skip failing test suite (#202564) 2025-03-08 04:23:50 +11:00
Kibana Machine
db7761efc1 skip failing test suite (#207045) 2025-03-08 03:58:01 +11:00
Rodney Norris
a3e4312462
[Search] fix(index_details): reduce sample documents from 50 to 10 (#213297)
## Summary

Reduced the number of documents we show on the index details page from
50 to 10 to reduce the memory footprint of polling with this query.
Additionally I refactored some of the server code to be have less
intermediate variables that were unnecessary.

### Alternative

This is the easier approach, I did consider updating the endpoint to
stream the response instead which could also solve this problem. But
that would require a lot of custom handling for pagination etc. so I
opted for this simpler solution for now if it is acceptable.

### Checklist

- [ ] 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
- [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
2025-03-07 10:41:45 -06:00
Arturo Lidueña
5d0e0f48ad
Fixing - Failing test: Stateful Observability - Deployment-agnostic A… (#213530)
Closes [#213209](https://github.com/elastic/kibana/issues/213209)

### Ordering Issue
- The instruction about `retrieve_elastic_doc` appears before the
`get_dataset_info` instruction.
- The content is the same, but the order of instructions has changed,
causing a failure in an exact string match.
### Minor Formatting Differences
- Even slight variations in spacing, newlines, or indentations can cause
a test failure.

## Solution
use `systemMessageSorted` - order of instructions can vary, so we sort to compare them
2025-03-07 17:10:09 +01:00
Nathan Reese
ea266bcd7e
[dashboard] fix map center change shows unsaved change after clicking reset (#213445)
Closes https://github.com/elastic/kibana/issues/213444

The problem is setting the view with the globe view may not set the view
to the exact value. For example setting zoom to 1.74 may move the map to
zoom 1.77. PR resolves this problem by adding a margin of error for
comparing zoom differences.

---------

Co-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>
Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
2025-03-07 08:15:21 -07:00
Tre
da4ab47ff6
[SKIP ON MKI] .../create_monitor_project_private_location.ts (#213578)
## Summary
see details: https://github.com/elastic/kibana/issues/213576
2025-03-07 16:08:41 +01:00
Mykola Harmash
33f71ae678
[Onboarding] Hide card labels in search results (#213417)
Closes https://github.com/elastic/kibana/issues/200917

Looking at the code in Fleet search results screen, cards would also
have the `Unverified` badges. ([this
check](https://github.com/elastic/kibana/blob/main/x-pack/platform/plugins/shared/fleet/public/applications/integrations/sections/epm/screens/home/card_utils.tsx#L101)
would return `true` because this specific page doesn't provides
`packageVerificationKeyId` to the `isPackageUnverified()` function, this
only happens on the individual integration details page. Fleet search
just [hides the
badges](https://github.com/elastic/kibana/blob/main/x-pack/platform/plugins/shared/fleet/public/applications/integrations/sections/epm/screens/home/available_packages.tsx#L188)
for cards in search results.

This change aligns Onboarding search results with Fleet search results
and hides the card labels which fixes the issue with `Unverified` badge
appearing for installed integrations.

| Before | After |
| --- | --- |
|
![388110694-bd6abaf4-15ac-4d56-b556-fddb11c85ba7](https://github.com/user-attachments/assets/751a6572-192c-45f6-bfa8-82433b73398d)
| ![CleanShot 2025-03-07 at 14 35
53@2x](https://github.com/user-attachments/assets/d1588d7d-eec8-4207-a1e6-9a53272bbddf)
|
2025-03-07 15:40:39 +01:00
jennypavlova
9a3d83415d
[APM] Playwright initial setup (#212970)
Closes https://github.com/elastic/kibana/issues/210178
## Summary

This PR adds the initial setup for playwright APM test (follow up of
[#211430](https://github.com/elastic/kibana/pull/211430), I am keeping
it for reference ). It includes only parallel test setup, which is the
recommended way of testing, and uses a `globalSetup` - currently has
only APM fixture, but it will be extended in the future. This first step
show cases 2 suites running in parallel: service inventory and service
map.

## Testing
- to run the tests refer to the
[README](https://github.com/elastic/kibana/pull/212970/files#diff-2c7f781789afa56f24d630b74f5068e279f8ecbbf3c98ab08ebb135074f7ee9b)

---------

Co-authored-by: Sergi Romeu <sergi.romeu@elastic.co>
Co-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>
2025-03-07 15:32:34 +01:00
jennypavlova
36e930c273
[APM][Errors] Fix: Missing summary data in in error sample (#213430)
Closes #213418 
## Summary

This PR fixes the missing error sample summary by adding the missing
fields

Bug (Before) | Fix (After)
|-----------------------|-----------|
| <img width="1912" alt="image"
src="https://github.com/user-attachments/assets/f7a9b007-529d-422d-b0e2-eac2e06c26b1"
/> |
![image](https://github.com/user-attachments/assets/c31ef1f6-44fd-442f-a12e-d3df0790cdc5)
|

## Testing
- Find a service with errors (using edge oblt data or any data that
includes the field values shown)
- Click on the service and navigate to Errors tab 
- The Error sample should include the summary data 

![image](https://github.com/user-attachments/assets/c86fdc3e-cd88-46b5-a59a-e1b8c7d44bef)
2025-03-07 15:08:39 +01:00
Søren Louv-Jansen
175e9066d0
[Obs AI Assistant] Add test for get_dataset_info (#213231)
- Add API test for `get_dataset_info`
- Add apache synthtrace scenario
- Search local and remote clusters unless otherwise specified
2025-03-07 13:53:10 +01:00
Antonio
2ead636ebd
[ResponseOps][MW] Use date format from settings in MW UI (#211576)
Closes #199315

## Summary

This PR changes the Maintenance Window UI to respect the date format
configured in Kibana's advanced settings.

3 places needed changing:
- Maintenance window list.
- Maintenance window creation page.
- Event popover in the maintenance window list(for recurring MWs).
2025-03-07 13:45:48 +01:00
Sonia Sanz Vivas
521f34511e
Fix bug in Index Management ILM details (#213101)
## Summary
We had a bug in Index Management. When the user clicks Index Management
> Index details > Index lifecycle, the page was unable to load. After
refreshing, the info was displayed correctly.

![image](https://github.com/user-attachments/assets/924e59cc-2912-4e3c-aaf3-8e2cc3adfe33)
 
This error was caused because the hook invariant violation rule was not
being fulfilled: https://react.dev/errors/310?invariant=310.

The lifecycle tab is rendered through the extension service that comes
from the ILM plugin. In [this
PR](https://github.com/elastic/kibana/pull/204449/files#diff-021836407481af0b98d7d91abab452bed569e3197072713bdf57a065f43ef734R43)
we modified the ILM component introducing the `euiTheme` hook, which was
causing the the hook invariant violation error.

With this PR the hook is now rendered in the Index Management plugin and
passed to ILM to avoid the error.

### Demo
<details>
<summary>Video</summary>



https://github.com/user-attachments/assets/2c212d30-b7a9-42de-9869-cc10093f0f33


</details>

---------

Co-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>
2025-03-07 13:43:09 +01:00
Tre
5d565abd02
[SKIP ON MKI] .../_data_view_create_delete.ts (#213533)
## Summary
see details: https://github.com/elastic/kibana/issues/213532
2025-03-07 13:24:18 +01:00
Rickyanto Ang
fb3537cfc9
Move Functions from CSP to Shared packages (#212663)
## Summary

As a part of Expandable Findings flyout, we will need to move some
Constants, Types, Functions, Components into Security Solution plugin or
Shared package

This PR is phase 2 for Findings (Misconfiguration flyout) which include
moving functions into shared package or security solution plugin

---------

Co-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>
2025-03-07 04:17:42 -08:00
Marco Antonio Ghiani
d0c62a20e9
[Streams 🌊] Enrichment state management improvements (#211686)
## 📓 Summary

Closes https://github.com/elastic/streams-program/issues/102
Closes https://github.com/elastic/streams-program/issues/159

This re-work of the enrichment state management introduces XState as
state library to prepare scaling the enrichment part for more processors
and improve performance reducing unnecessary side effects.

## 🤓 Reviewers note

**There is a lot to digest on this PR, I'm open to any suggestion and I
left some notes around to guide the review.
This is also far from perfect as there is margin for other minor DX
improvements for consuming the state machines, but it will all come in
follow-up work after we resolve prioritized work such as integrating the
Schema Editor.**

Most of the changes on this PR are about the state management for the
stream enrichment, but it touches also some other areas to integrate the
event-based flow.

### Stream enrichment machine

This machine handles the complexity around updating/promoting/deleting
processors, and the available simulation states.
It's a root level machine that spawns and manages its children machine,
one for the **simulation** behaviour and one for each **processor**
instantiated.

<img width="950" alt="Screenshot 2025-02-27 at 17 10 03"
src="https://github.com/user-attachments/assets/756a6668-600d-4863-965e-4fc8ccd3a69f"
/>

### Simulation machine

This machine handle the flow around sampling -> simulating, handling
debouncing and determining once a simulation can run or should refresh.
It also spawn a child date range machine to react to the observable time
changes and reloads.
It also derives all the required table configurations (columns, filters,
documents) centralizing the parsing and reducing the cases for
re-computing, since we don't rely anymore on the previous live
processors copy.

<img width="1652" alt="Screenshot 2025-02-27 at 17 33 40"
src="https://github.com/user-attachments/assets/fc1fa089-acb2-4ec5-84bc-f27f81cc6abe"
/>

### Processor machine

A processor can be in different states depending on the changes, not
this tracks each of them independently and send events to the parent
machine to react accordingly. It provide a boost in performance compared
to the previous approach, as we don't have to rerender the whole page
tree since the changes are encapsulated in the machine state.

<img width="1204" alt="Screenshot 2025-03-04 at 11 34 01"
src="https://github.com/user-attachments/assets/0e6b8854-b7c9-4ee8-a721-f4222354d382"
/>

---------

Co-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>
2025-03-07 12:34:30 +01:00
Jared Burgett
cfa2fb4aa8
Fixed entity-store enablement for API key saved object storage (#213516)
When enabling the entity store with a non-superuser with all required
credentials, it returns the following errors:

![Screenshot 2025-03-06 at 11 07
02](https://github.com/user-attachments/assets/01b8fe73-5c7a-44aa-9b04-2c7e16a9d656)

To fix it, we need to disable security for the saved object client.

While this change sounds scary (exclude security??) there are three
reasons I believe this is the appropriate fix:
* [It's what rules management/alerting/detections does for creating
their hidden/encrypted saved objects.
](https://github.com/elastic/kibana/blob/main/x-pack/platform/plugins/shared/alerting/server/rules_client_factory.ts#L140)I
view that as the canonical example for doing this kind of work.
* Even with this change, we actually still require the user to have
Saved Object Management capabilities, both in the UI (as a privilege
check) and in the init/enable routes, upstream of where we create the
saved object. You can try this out yourself, the init route will fail
without that privilege.
* We only use that particular Saved Object client in that particular
spot, not throughout the rest of our Saved Object usages.

### How to reproduce it
* On main branch
* With an empty cluster
* Generate data with doc generator
* Login with 'elastic' user and create a test role and user with
following credentials:
* cluster, all
* indices, all
* Kibana, all spaces, all
* Open an anonymous tab and login with the test user
* Enable the entity store with the test user

Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
2025-03-07 12:25:20 +01:00
Sergi Massaneda
2cdd20c497
[Security Solution][SIEM migrations] Add timeouts and surface execution errors (#212799)
## Summary

Implements controls to have more visibility over the errors, especially
in the initialization phase (populate ELSER indices)

### Changes
- Added timeout to the initialization phase (20 minutes).
- Added concurrency control for initialization tasks, only the first
concurrent migration will trigger it, and the rest will await it.
- Added proper error handling for the ES bulk index operations of
integrations and prebuilt rules ELSER indices.
- Added timeout for individual agent invocations (3 minutes)
- Added `migrationsLastError` server state to store the errors (not
ideal, this should be moved to the migration index when we implement it)
for now it's fine.
- Added the `last_error` in the _/stats_ API response.
- The UI displays the `last_error` if it's defined.

### Screenshots

Onboarding error:

![error_onboarding](https://github.com/user-attachments/assets/268633fe-94b1-40e6-9270-8d0f6b59923e)

Rules page error:

![error_rules_page](https://github.com/user-attachments/assets/e2c2ddc7-2668-4452-bf5c-b40132860e27)

---------

Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
2025-03-07 12:00:57 +01:00
Tomasz Ciecierski
81db1a127a
[AI_SOC] Add tier/add-on configuration (#213425) 2025-03-07 11:46:42 +01:00
Irene Blanco
e62cb6a37a
[Discover][APM] Add icon to transaction name badge in summary column (#213428)
## Summary

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

As part of the Traces in Discover initiative, we’ve added
`transaction.name` and `span.name` badges to the summary column. Some
documents can contain both, making it unclear which one represents the
transaction or the span name, and that's hot helpful for the filtering
experience the badges provide.

This PR addresses that by adding an icon as a prefix to the transaction
name, similar to the one used in the APM trace waterfall.


|Before|After|
|-|-|
|![Screenshot 2025-03-06 at 17 07
50](https://github.com/user-attachments/assets/2cd57f57-d430-418e-a727-7345fd65befc)|![Screenshot
2025-03-06 at 17 07
58](https://github.com/user-attachments/assets/6f618b3a-fcb8-4957-b3ab-93bd937761f7)|

We have two types of icons, the `merge` one by default or the `globe`
for rum agents.

![Screenshot 2025-03-06 at 16 04
45](https://github.com/user-attachments/assets/071050f3-2d86-4b96-b597-01338e5443af)

 ### Boy scouting

While playing around with the cell renderers, I realized that for long
values, the content was floating outside of the popover container.

![Screenshot 2025-03-06 at 14 05
03](https://github.com/user-attachments/assets/302dc6a9-9885-431e-a8f1-04d063ccb061)
So I've decided to add the same behaviour we have for the actions
popover in the flyout.
|Table|Flyout|
|-|-|
|![Screenshot 2025-03-06 at 16 41
04](https://github.com/user-attachments/assets/4a287c6e-6375-4afd-9b51-0e63bff12b27)|![Screenshot
2025-03-06 at 16 16
30](https://github.com/user-attachments/assets/c73d0dd7-a4ac-4d4c-8634-a2bfad771c0e)|

### How to test

Add this to your kibana.dev.yml:

```
discover.experimental.enabledProfiles:
  - traces-data-source-profile
`````

- Go to Discover page
- Select APM data view
- Check your traces data
2025-03-07 11:15:15 +01:00
Kibana Machine
4f2edcef97 skip failing test suite (#204069) 2025-03-07 20:52:38 +11:00
Gonçalo Rica Pais da Silva
4a8a9aceab
[Discover][APM] Show event.outcome badge only on failure outcomes (#213268)
## Summary

Changes the `event.outcome` badge to no longer have an icon, instead
appearing only when the `event.outcome` value is `failure`, and showing
as a `danger` colored badge.

<img alt="Event Outcome Discover Traces Screenshot 2025-03-04 173032"
src="https://github.com/user-attachments/assets/7c5ffc84-e483-4667-abed-d38461362351"
/>

Closes #213207

### How to Test

Ensure the following is added to your kibana.dev.yml:

```yaml
discover.experimental.enabledProfiles:
  - traces-data-source-profile
```

- Go to Discover page, select the APM static data view when on the
oblt-cli cluster.
- On the data grid, all the summary cells for trace data should only
show 3 badges when the `event.outcome` is either `success` or `unknown`.
Only a red badge is shown for traces that have `event.outcome` as
`failure`.
2025-03-07 10:49:41 +01:00