Commit graph

86271 commits

Author SHA1 Message Date
Alejandro Fernández Haro
10d46e5f5e
chore(fullstory): serve the snippet as an asset (#220368) 2025-05-07 23:06:24 +02:00
Nathan Reese
e269d04ee0
[embeddable] cleanup usages of useBatchedOptionalPublishingSubjects (#216714)
`useBatchedOptionalPublishingSubjects` should only be used when `api` is
not available until after rendering. This PR replaces usages of
`useBatchedOptionalPublishingSubjects` with
`useBatchedPublishingSubjects` where possible.

---------

Co-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>
Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
2025-05-07 13:32:33 -06:00
Nathan Reese
670ff4ee06
[dashboard] fix invalid dashboard displayed as 404 instead of showing validation error (#211661)
Closes https://github.com/elastic/kibana/issues/211659

PR updates `loadDashboardState` to throw content management error when
status is not a 404. PR does not attempt to clean-up DashboardRenderer's
display of the error.

<img width="500" alt="Screenshot 2025-05-07 at 8 20 02 AM"
src="https://github.com/user-attachments/assets/39883951-d4df-46fa-9950-bb8103898b6b"
/>


### test instructions
1) use saved object import to import dashboard with schema errors -
https://github.com/elastic/kibana/blob/main/x-pack/test/functional/apps/dashboard/group2/migration_smoke_tests/exports/lens_dashboard_migration_test_7_12_1.ndjson.
2) open dashboard, verify schema validation error is displayed.

---------

Co-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>
Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
2025-05-07 13:32:04 -06:00
Rodney Norris
c2c356567d
search: functional test migration for ska (#220382)
## Summary

Migrate functional tests for stateful search solution to new config.
Part of https://github.com/elastic/kibana-team/issues/1503

### 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
- [ ] [Flaky Test
Runner](https://ci-stats.kibana.dev/trigger_flaky_test_runner/1) was
used on any tests changed
2025-05-07 13:37:55 -05:00
Rickyanto Ang
26ed87dc75
[Cloud Security] Fix for Redirect Issue from Vuln contextual flyout (#219822)
## Summary

This PR addresses the issue where if user tried to renavigate to
Findings page (with filter on) from Vulnerability Contextual Flyout by
clicking on the popup icon in the Vulnerability Details table the filter
on Findings page won't get formed properly IF some of the fields value
contains special character such as "+", this happen when user gets
redirected to Findings page

in the case of "+", this malformed filter is caused because in the URL
"+" gets encoded into "%20" which is space instead of "%2b" which is "+"



https://github.com/user-attachments/assets/ce4007a1-b0ad-4ce4-b389-53c44a43aa9b
2025-05-07 11:10:12 -07:00
Bena Kansara
23683e59c0
[Observability] [Rules] Add telemetry for linked dashboards and investigation guide (#217502)
Part of https://github.com/elastic/kibana/issues/216491

Adds telemetry for linked dashboards and investigation guide fields that
are coming soon: https://github.com/elastic/kibana/issues/214522,
https://github.com/elastic/kibana/issues/213024

- Number of rules with linked dashboards
- Number of rules with non-empty investigation guide

To test, you can use the following API call. The result should include
two new fields: `count_rules_with_linked_dashboards` and
`count_rules_with_investigation_guide`

```
POST kbn:/internal/telemetry/clusters/_stats?apiVersion=2
{
  "unencrypted": true,
  "refreshCache": true
}
```

### Note
I have added a comment to update one test file
(`x-pack/test/alerting_api_integration/common/lib/get_test_rule_data.ts`)
once `artifacts` field is available in schema.

---------

Co-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>
2025-05-07 14:09:11 -04:00
Eyo O. Eyo
e11c4b3a81
Adjustments to trigger chromium build Github action (#220332)
## Summary

Removes concurrency check that would causes checks to cancel without
triggering a build, also remove listener on closed issues since we were
handling them anyways.

<!--

### 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-07 19:37:39 +02:00
Dzmitry Lemechko
a2c9cbfaab
[ska][x-pack] relocate platform tests [4] (#219691)
## Summary

Part of https://github.com/elastic/kibana-team/issues/1503

This PR is mostly about moving tests from `x-pack/test` to
`x-pack/platform/test`

Before:

```
x-pack/test/
     | - api_integration/apis/management/
     | - api_integration/apis/monitoring/
     | - api_integration/apis/osquery/
     | - automatic_import_api_integration
     | - monitoring_api_integration/
     | - saved_object_api_integration/
```

After: 
```
x-pack/platform/test/
     | - api_integration/apis/management/
     | - api_integration/apis/monitoring/
     | - api_integration/apis/osquery/
     | - automatic_import_api_integration
     | - monitoring_api_integration/
     | - saved_object_api_integration/
```

Additional:

- `x-pack/test/api_integration/apis/osquery/config.ts` was move to
platform stateful manifest to match `osquery` plugin (shared, platform)
- `automatic_import_api_integration` config files were moved to platform
stateful manifest to match `automatic_import` plugin (shared, platform)
- `x-pack/test/common/lib/test_data_loader.ts` is required by SO api
tests and was copied to `x-pack/platform/test/common`

---------

Co-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>
2025-05-07 19:13:04 +02:00
florent-leborgne
2671acc695
[Docs] Add known issue about Obs AI Assistant KB to 9.0 docs (#220401)
^^ 

Counterpart of https://github.com/elastic/kibana/pull/220397 for 9.0
docs
2025-05-07 16:53:02 +00:00
jennypavlova
c9776687e2
[Infra] Fix processes query (#220381)
Closes #220289 and
https://github.com/elastic/opentelemetry-lib/issues/168
## Summary

This PR fixes an issue with the processes query in case the document is
missing some of the required fields for the aggregation (like user.name,
process.pid, system.process.cpu.total.pct, etc.). This PR adds a filter
to the query to ensure that all the required fields exist

| Before | After |
| ------ | ------ |
|
![image](https://github.com/user-attachments/assets/2dd94bb6-d7b9-453a-a741-dbba734a0b1a)
|
![image](https://github.com/user-attachments/assets/bb6a14db-88c2-4bca-beca-577465e1b06e)
|

## Testing 
> [!NOTE]  
> With the oblt lite cluster, the issue is reproducible as in the
screenshot (one of the hosts using the hostsmetrics receiver),
I also tested with metricbeat for regressions and the host Otel
Onboarding steps locally (the processes are not available there, just
the summary)

- Go to the asset details page and open the processes tab
- There shouldn't be an error shown when loading the processes
2025-05-07 18:36:00 +02:00
Lisa Cawley
2ae840624e
Update Elasticsearch URLs in doc link service (#219656)
Co-authored-by: Jean-Louis Leysens <jeanlouis.leysens@elastic.co>
2025-05-07 17:57:18 +02:00
elastic-renovate-prod[bot]
c6ccb8d8a1
Update dependency elasticsearch-8.x to v8.18.2 (main) (#219314)
Co-authored-by: elastic-renovate-prod[bot] <174716857+elastic-renovate-prod[bot]@users.noreply.github.com>
Co-authored-by: Alejandro Fernández Haro <alejandro.haro@elastic.co>
2025-05-07 17:03:44 +02:00
Abdul Wahab Zahid
cf2091d5dc
Audit Logs Levels - Obs Ux Logs Team (#218413)
The PR audits and fixes the log levels for Dataset Quality plugin based on [guidelines](https://docs.elastic.dev/kibana-dev-docs/services/logging#log-level).
2025-05-07 16:48:54 +02:00
Paul Tavares
ae5a93811b
[Security Solution][Endpoint] Change where agent diagnostic files saved on test failures for cypress suites (#220272)
## Summary

- Changes the location of any captured Elastic agent diagnostics files
during a cypress tests failure to `target/agent_diagnostics` from
`target/test_failures`
2025-05-07 16:32:32 +02:00
Alexey Antonov
208d7b5d38
fix: [Security:Assets:Fleet page]Fields missing name from announcement (#220351)
Closes: #204915
Closes: #209325

## Summary
Collapsed/Expanded buttons have to be correctly announced for users
using assistive technology.

## Changes made: 
1. Added required 'aria' attributes

## Screen 

<img width="1017" alt="image"
src="https://github.com/user-attachments/assets/e442c3c6-a3ad-47cd-9bdb-b6e3ed514366"
/>
2025-05-07 17:25:55 +03:00
Alexi Doak
d72c62c4c0
[ResponseOps] Update ES|QL ES query rule for context.grouping action variable (#220302)
Follow on from this PR that was merged,
https://github.com/elastic/kibana/pull/213550
## Summary

This PR updates the ES|QL grouping processing to work with the
`context.grouping` action variable.


### 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


### To verify
1. Create an ES|QL rule with grouping.
2. In "active" and "recovered" action message, use `context.grouping`
variable
3. Verify that both "active" and "recovered" alert notifications contain
correct information

Example if grouping on `host.name` and `container.id`:

```
{
  "grouping": "{{context.grouping}}",
  "host.name": "{{context.grouping.host.name}}",
  "container.id": "{{context.grouping.container.id}}"
}
```
2025-05-07 07:25:41 -07:00
Pablo Machado
a30c888216
[SecuritySolution] Privileged user monitoring page + Risk levels panel (#219834)
This pull request introduces enhancements and bug fixes across multiple
components in the security solution plugin. Key updates include
improvements to the DonutChart component, support for ESQL queries in
the Inspect Modal, and the addition of new hooks and components for
privileged user monitoring. The changes also include minor refactoring
and optimizations.

### DonutChart Enhancements and Refactoring:
* Updated `max-width` in the `donutTextWrapper` style to use a
percentage for better responsiveness. (`donutchart.tsx`,
[x-pack/solutions/security/plugins/security_solution/public/common/components/charts/donutchart.tsxL81-R81](diffhunk://#diff-56039022d9e7cfcdda9c26e0566e5cd5f23dbb8e6c4806c6b2e39bdcee605cd2L81-R81))
* Replaced the `style` prop with the `css` prop for better integration
with Emotion styling. (`donutchart.tsx`,
[x-pack/solutions/security/plugins/security_solution/public/common/components/charts/donutchart.tsxL142-R142](diffhunk://#diff-56039022d9e7cfcdda9c26e0566e5cd5f23dbb8e6c4806c6b2e39bdcee605cd2L142-R142))
* Simplified the `onPartitionClick` logic by removing the
`.toLowerCase()` transformation. (`donutchart.tsx`,
[x-pack/solutions/security/plugins/security_solution/public/common/components/charts/donutchart.tsxL181-R181](diffhunk://#diff-56039022d9e7cfcdda9c26e0566e5cd5f23dbb8e6c4806c6b2e39bdcee605cd2L181-R181))

### ESQL Query Support in Inspect Modal:
* Added `lodash/fp`'s `isString` utility to handle conditional logic for
ESQL vs. JSON formatting. (`modal.tsx`,
[x-pack/solutions/security/plugins/security_solution/public/common/components/inspect/modal.tsxR28](diffhunk://#diff-e7bd02a3f01d8b88dea1df92d5f27d7d9c13bc8e59ae0c1ff4396f1eb139e340R28))
* Dynamically set the `language` attribute in `EuiCodeBlock` based on
the request body type. (`modal.tsx`,
[x-pack/solutions/security/plugins/security_solution/public/common/components/inspect/modal.tsxL251-R252](diffhunk://#diff-e7bd02a3f01d8b88dea1df92d5f27d7d9c13bc8e59ae0c1ff4396f1eb139e340L251-R252))
* Enhanced the rendering of the request body to support both raw and
stringified formats. (`modal.tsx`,
[x-pack/solutions/security/plugins/security_solution/public/common/components/inspect/modal.tsxL260-R263](diffhunk://#diff-e7bd02a3f01d8b88dea1df92d5f27d7d9c13bc8e59ae0c1ff4396f1eb139e340L260-R263))

### Privileged User Monitoring:
* Introduced a new `RiskLevelsPrivilegedUsersPanel` component with a
DonutChart and table for visualizing privileged user risk levels.
(`risk_level_panel/index.tsx`,
[x-pack/solutions/security/plugins/security_solution/public/entity_analytics/components/privileged_user_monitoring/components/risk_level_panel/index.tsxR1-R150](diffhunk://#diff-db56c23ac70dfb3daed48e12703939a97b342e66ef37a2fb37b12443b872393dR1-R150))
* Added supporting hooks (`useRiskLevelsPrivilegedUserQuery`,
`useRiskLevelsTableColumns`) and constants for privileged user
monitoring. (`risk_level_panel/hooks.tsx`,
[[1]](diffhunk://#diff-43a65c138415c204a947839568ba745f55b03e137dddc6081b551b116530f672R1-R124);
`risk_level_panel/constants.ts`,
[[2]](diffhunk://#diff-3d45970aca50b5e25ee79b7399245b08225060a91e63436eeb67721f9332276dR1-R22)
* Created a wrapper component `PrivilegedUserMonitoring` to organize
different panels related to privileged user insights. (`index.tsx`,
[x-pack/solutions/security/plugins/security_solution/public/entity_analytics/components/privileged_user_monitoring/index.tsxR1-R44](diffhunk://#diff-273ad32c97dcf15c6c6054fd7c5516d587132674578d25986b235cd174c75789R1-R44))

### New Hooks for Query Management:
* Added `useEsqlQueryWithGlobalFilters` to facilitate ESQL query
construction with global filters.
(`use_esql_query_with_global_filter.ts`,
[x-pack/solutions/security/plugins/security_solution/public/common/hooks/esql/use_esql_query_with_global_filter.tsR1-R28](diffhunk://#diff-a6205e70128171bfa6f6aa85e3b4090c18740033696f41667fe5f7140b309036R1-R28))
* Introduced `useAddFilter` for dynamically adding filters to the Kibana
filter manager. (`use_add_filter.ts`,
[x-pack/solutions/security/plugins/security_solution/public/common/hooks/use_add_filter.tsR1-R33](diffhunk://#diff-eb285a6a89e7f3641339b8c3b1823add89ccd1e721d5820030691998a8dd35f1R1-R33))

### Minor Refactoring:
* Removed unused parameters from `useGetDefaultRiskIndex` calls to
simplify API usage. (`use_risk_score.tsx`,
[[1]](diffhunk://#diff-cd4a1ef2e228a140ee7b2d6408f70759864d3e10074094a56f33e32950d2f67aL76-R76);
`use_risk_score_kpi.tsx`,
[[2]](diffhunk://#diff-a717e9611a5489f1b092575c183229d98af1abbdddf78a2fa1a6d95f00969843L48-R48)
Summary

### How to test it?
1. Check out Mark's privmon document generator branch
https://github.com/elastic/security-documents-generator/pull/104
2. Run `yarn start privmon`
3. Start Kibana with the flag `privilegeMonitoringEnabled` enabled
4. Go to privmon page using the many and click in the top link
5. Play with the brand new visualisation

### 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] 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-07 15:44:55 +02:00
Jon
dc8b4b6a6f
Upgrade caniuse-lite (#219987)
Fixes

```
[bazel] Browserslist: browsers data (caniuse-lite) is 6 months old. Please run:
[bazel]   npx update-browserslist-db@latest
```

---------

Co-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>
2025-05-07 08:02:35 -05:00
Nicolas Chaulet
f759f3ed7b
[Fleet] Opt-in new cluster into space awareness (#220290) 2025-05-07 08:48:30 -04:00
Marco Liberati
78e74353aa
[Lens] "Compare to" badge for Metric chart (#214811)
## Summary

Fixes #184907

This PR introduces the Trend badge feature into the Secondary Metric
chart type.
<img width="1318" alt="Screenshot 2025-04-30 at 13 04 36"
src="https://github.com/user-attachments/assets/6b3c599e-304f-4bc0-8ff2-094ed54ea248"
/>
<img width="1503" alt="Screenshot 2025-04-30 at 13 04 03"
src="https://github.com/user-attachments/assets/cb203156-a7a8-4f61-bf30-57f7d1484fed"
/>
<img width="1339" alt="Screenshot 2025-04-30 at 13 03 21"
src="https://github.com/user-attachments/assets/8896af7f-9193-41b5-a4b5-970907b084c5"
/>
<img width="1319" alt="Screenshot 2025-04-30 at 13 05 34"
src="https://github.com/user-attachments/assets/12aa556e-8743-4167-9902-14fa9ef2e85d"
/>


Here's a short list of tasks handled by this PR:

* [x] New Color by value option: `None` | `Static` | `Dynamic`
  * Default `None` option is the default (legacy preserved)
  * [x] `Static` option enables the badge with the picked color
* [x] this is also enforced when the Primary metric is not number based
(or when primary transition from number to text)
  * [x] `Dynamic` option enables both the badge coloring and the icon
* [x] When disabled a tooltip with the explanation of the issue appears
    * [x] Trend palette is enabled by default on enable
* [x] Added other 3 extra palettes (`Reversed`, `Temperature`,
`Complementary`)
* [x] Each palette has been implemented using both EUI tokens AND Vis
tokens
          * [x] Revisited this decision ♻️ 
        * [x] Remove redundant palettes
          * ~~keep only Vis palettes & hardcode `green` value for now.~~
* ~~Once EUI exposes the green token integrate in a follow up.~~
* Use the `@kbn/palettes` service with the new `compare_to` palette with
hardcoded values
      * [x] Exposes display options: `Icon` | `Value` | `Both`
        * [x] `Both` is the default
* [x] `Icon` or `Both` will show up 3 possible icon options: arrow up,
arrow down and equal sign from unicode
          * [x]  Make sure both text and icon respect breakpoint sizes
* [x] Remove hack for breakpoints ( Lens Embeddable + Secondary metric)
once new Charts upgrade is merged:
https://github.com/elastic/elastic-charts/pull/2627
* [x] Remove `theme` and contrast color computation once the Elastic
Charts PR above is merged
          * [x] Make sure badge is always accessible
        * [x] Exposes Trend options: `Static value` | `Primary metric` 
* [x] `Static value` will show up a new `Baseline` control (debounced)
* [x] `Primary metric` is enabled only for numeric primary values
            * [x]  When disabled a tooltip shows up explaining the issue
* [x] Added description text to explain difference with the other
compare mode
            * [x] Show only delta value when in Primary 
 * [x] Migrated existing `metric_vis` tests from Enzyme to RTL
 * [x] New tests for the new Secondary metric component in RTL
* [x] Added new smoketest + panel mode caching testing for the metric
feature in FTR


Few aspects of this feature have been discussed and deferred to a follow
up issue: https://github.com/elastic/kibana/issues/217992

### 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>
Co-authored-by: Nick Partridge <nick.ryan.partridge@gmail.com>
2025-05-07 14:44:27 +02:00
Ersin Erdal
0878a095a5
Support rrule for task scheduling (#217728)
Resolves: https://github.com/elastic/kibana/issues/216308

This PR adds rrule notation support to the task scheduling.

Currently we use a simple interval string (such as `1h` or `45m`) to
calculate the next `runAt` that we use to decide if the task should be
picked up or not. With this PR, we will be able to use rrule as well.

We set the `runAt` field in 3 places:
- At task creation: when the task is created for the first time, this is
always `now` if a specific runAt is not provided.
- At task update. We update runAt on task update as well but only when
it is provided. We don't update it when the schedule config changes.
- After task run: to decide when the next run will be after a task is
run.

This PR modifies:
- At task creation: It still uses the `runAt` when it is provided but
calculates a runAt by using rrule if the config has a fixed time (like
every day at 13:00) config. Becausethe task should not run immediately
when there is a fixed time to run.
- After task run: It calculates the next `runAt` with rrule when it is
provided.

This PR doesn't apply any change on `At task update` as it requires a
further investigation and consideration. We will handle it with a
follow-on issue.

## To verify:
You can use the test task `sampleRecurringTask` to test the feature.
Just create a task with rrule in the schedule config.
Then check the runAt field in the task SO to see if it is the expected
datetime.
Then run the task one more time and check the new `runAt`

I also used the usage reporting task in the actions plugin to test the
feature.

---------

Co-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>
2025-05-07 14:39:11 +02:00
Sergi Romeu
eb6a159317
[Infra] Remove enableInfrastructureAssetCustomDashboards setting (#220210)
## Summary

Part of #218501

This PR removes the advanced setting
`observability:enableInfrastructureAssetCustomDashboards` but keeps the
saved object, to be removed in a [follow-up
issue](https://github.com/elastic/kibana/issues/220340).

---------

Co-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>
2025-05-07 14:21:08 +02:00
Ania Kowalska
cb67765b5e
[Discover] add per tab loading indicator (#219059)
## Summary

Closes #217331

Each tab shows loading indicator if the query is running.


https://github.com/user-attachments/assets/3c7bea34-c365-4038-ad42-636985e5a3db

~~I used the preview data here, as we already have the functionality of
observing changing status, I didn't want to replicate this logic. I'm
open to suggestions though, if for any reason `getPreviewData` shouldn't
be invoked here or be invoked only here and passed down to preview
component.~~
Edit: after syncing with @davismcphee, I lifted the `getPreviewData`
call up, so it's called once


### 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)
- [ ] ...

---------

Signed-off-by: Florian Lehner <florian.lehner@elastic.co>
Co-authored-by: Julia Rechkunova <julia.rechkunova@gmail.com>
Co-authored-by: Joe Reuter <johannes.reuter@elastic.co>
Co-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>
Co-authored-by: jennypavlova <dzheni.pavlova@elastic.co>
Co-authored-by: Dzmitry Lemechko <dzmitry.lemechko@elastic.co>
Co-authored-by: Aleh Zasypkin <aleh.zasypkin@gmail.com>
Co-authored-by: Nikita Indik <nikita.indik@elastic.co>
Co-authored-by: Patrick Mueller <patrick.mueller@elastic.co>
Co-authored-by: Søren Louv-Jansen <soren.louv@elastic.co>
Co-authored-by: Elena Shostak <165678770+elena-shostak@users.noreply.github.com>
Co-authored-by: Brad White <Ikuni17@users.noreply.github.com>
Co-authored-by: Robert Jaszczurek <92210485+rbrtj@users.noreply.github.com>
Co-authored-by: Kevin Delemme <kevin.delemme@elastic.co>
Co-authored-by: Charis Kalpakis <39087493+fake-haris@users.noreply.github.com>
Co-authored-by: Steph Milovic <stephanie.milovic@elastic.co>
Co-authored-by: Jesus Wahrman <41008968+jesuswr@users.noreply.github.com>
Co-authored-by: Sergi Massaneda <sergi.massaneda@elastic.co>
Co-authored-by: Paulo Silva <paulo.henrique@elastic.co>
Co-authored-by: Kylie Meli <kylie.geller@elastic.co>
Co-authored-by: Anton Dosov <anton.dosov@elastic.co>
Co-authored-by: Saarika Bhasi <55930906+saarikabhasi@users.noreply.github.com>
Co-authored-by: Stratoula Kalafateli <efstratia.kalafateli@elastic.co>
Co-authored-by: elastic-renovate-prod[bot] <174716857+elastic-renovate-prod[bot]@users.noreply.github.com>
Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
Co-authored-by: Alexi Doak <109488926+doakalexi@users.noreply.github.com>
Co-authored-by: Lisa Cawley <lcawley@elastic.co>
Co-authored-by: Alejandro Fernández Haro <alejandro.haro@elastic.co>
Co-authored-by: Viduni Wickramarachchi <viduni.ushanka@gmail.com>
Co-authored-by: Mason Herron <46727170+Supplementing@users.noreply.github.com>
Co-authored-by: Khristinin Nikita <nikita.khristinin@elastic.co>
Co-authored-by: Julia Rechkunova <julia.rechkunova@elastic.co>
Co-authored-by: Eyo O. Eyo <7893459+eokoneyo@users.noreply.github.com>
Co-authored-by: Michel Losier <michel.losier@elastic.co>
Co-authored-by: Nicolas Chaulet <nicolas.chaulet@elastic.co>
Co-authored-by: Krzysztof Kowalczyk <krzysztof.kowalczyk@elastic.co>
Co-authored-by: Ryland Herrick <ryalnd@gmail.com>
Co-authored-by: Devin W. Hurley <devin.hurley@elastic.co>
Co-authored-by: Panagiota Mitsopoulou <panagiota.mitsopoulou@elastic.co>
Co-authored-by: Christos Nasikas <xristosnasikas@gmail.com>
Co-authored-by: Nathan Reese <reese.nathan@elastic.co>
Co-authored-by: Tim Sullivan <tsullivan@users.noreply.github.com>
Co-authored-by: Christiane (Tina) Heiligers <christiane.heiligers@elastic.co>
Co-authored-by: Florian Lehner <florianl@users.noreply.github.com>
Co-authored-by: Paulina Shakirova <paulina.shakirova@elastic.co>
Co-authored-by: Milosz Marcinkowski <38698566+miloszmarcinkowski@users.noreply.github.com>
Co-authored-by: Sergi Romeu <sergi.romeu@elastic.co>
2025-05-07 14:18:22 +02:00
Tiago Vila Verde
7059a8a1c7
[Entity Analytics][Privilege User Monitoring] Add Privileged User CRUD API (#218098)
## Summary

This PR introduces basic CRUD routes for handling Privileged Users in
Entity Analytics.


The following routes are available:

* CREATE: `POST /api/entity_analytics/monitoring/users`
* GET:    `GET /api/entity_analytics/monitoring/users/{id}`
* LIST:   `GET /api/entity_analytics/monitoring/users/list`
* UPDATE: `PUT /api/entity_analytics/monitoring/users/{id}`
* DELETE: `DELETE /api/entity_analytics/monitoring/users/{id}`


For CREATE and UPDATE, the request body should be of type:
```
{ "user_name": string, is_monitored: boolean }
```

The reason for snake_case is to align better with the upcoming csv and
json upload work.
This PR already introduces boilerplate code (registering the endpoints
and handlers) for those routes). We might want to change this.

## How to test


1. Start a fresh Kibana instance
2. Enable the `EntityAnalyticsPrivilegeMonitoring` Feature Flag.
3. Initialise the privmon engine with `POST
kbn:/api/entity_analytics/monitoring/engine/init`
4. Test any of the endpoints above
* Make sure to either note down the returned `id`s or simply query the
underlying index: `.entity_analytics.monitoring.users-<your namespace>`

---------

Co-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>
2025-05-07 14:17:33 +02:00
Viduni Wickramarachchi
1971ff261c
[Obs AI Assistant] Show Inspect button when no ML nodes are available (#220173) 2025-05-07 08:14:41 -04:00
Vadim Kibana
1d1d650769
[ES|QL] Bump Monaco highlighting library (#220345)
## Summary

- [x] Fixes highlighting at the beginning and mid of keywords

<img width="704" alt="image"
src="https://github.com/user-attachments/assets/9f9f5b97-9602-4e1a-b3af-9033c9371793"
/>
2025-05-07 13:52:01 +02:00
Luke Gmys
1c9a9d72c6
[Security Solution][Sourcerer] replace use get scoped data view (#220196)
## Summary

This PR adds data view retrieval from the new data view manager / picker
wherever we are using `useGetScopedSourcererDataView` now, with the
intention of removing the latter eventually (when new picker is
stabilized).

Related issue: https://github.com/elastic/security-team/issues/12569
Parent epic: https://github.com/elastic/security-team/issues/11959

### Testing

Add the following flag to your config

```
xpack.securitySolution.enableExperimental: ['newDataViewPickerEnabled']
```

- With the feature flag off, the app should not break.
- When the flag is on, data view information should be retrieved based
on the selection / active data view obtained from the new data view
manager.

### 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
2025-05-07 13:33:05 +02:00
Gonçalo Rica Pais da Silva
5babf0383b
[Discover][APM] Add field action popover to span/transaction title (#220246)
## Summary

As the Span/Transaction name and id were moved to be the Title/Subtitle
of the Span/Transaction document overview, they initially lost the field
actions popover they had before. This PR adds the popover back.

Closes #220066

![Screenshot 2025-05-06
153849](https://github.com/user-attachments/assets/6075e836-b665-454a-8199-18edf747f4b2)

### How to test

* Add this to your `kibana.dev.yml` file:
```yaml
discover.experimental.enabledProfiles:
  - observability-traces-data-source-profile
  - observability-traces-transaction-document-profile
  - observability-traces-span-document-profile
```
* Enable the Observability mode for the current space, then navigate to
Discover
* Create/use a data-view or use an ES|QL query that targets a `traces-*`
index.
* Open the overview for a resulting Span/Transaction and hover over the
title/name. A popover should appear.
2025-05-07 13:02:39 +02:00
Tomasz Ciecierski
0a5120b9a4
[AI4DSOC] Hide security solution pages (#219081)
## Summary

This PR implements a mechanism to control visibility and access to
Security Solution pages based on user access and PLIs.
It replaces direct usage of the `SecurityRoutePageWrapper` component
with the `withSecurityRoutePageWrapper` higher-order component across
multiple route files in the Security Solution plugin.

## Changes

- Added `cloudSecurityPosture` entry to the `SecurityPageName` enum in
`deep_links.ts`
- Replaced direct usage of `SecurityRoutePageWrapper` with
`withSecurityRoutePageWrapper` HOC in:


| Route | Complete | AiSoc | Comments |

|-------------------------|----------|--------------------------------|----------------------|
| Asset Inventory routes | OK | Redirected to /get_started | |
| Assets routes | OK | OK | Should we hide this one? |
| Cloud Security Posture | Redirected to /get_started | Redirected to
/get_started | Redirected if there's no 'Cloud' Addon (even on Complete)
|
| Dashboards routes | OK | Redirected to /get_started | |
| Exceptions routes | OK | Upselling | Upselling has priority over
redirection |
| Explore routes | OK | Redirected to /get_started | |
| Investigations routes | OK | Redirected to /get_started | |
| Notes routes | OK | Not Working | Should be redirected to get_started
- TBC... |
| Overview routes | OK | Redirected to /get_started | |
| Timelines routes | OK | Redirected to /get_started | |


## Question: 
<img width="1227" alt="Screenshot 2025-04-24 at 15 20 52"
src="https://github.com/user-attachments/assets/a57936b9-e954-43d8-a6d0-caf31508461c"
/>
Without `Cloud` Add-on - should we hide the cloud cards ? Eg. in
`Complete` tier?


## Technical Details

The `withSecurityRoutePageWrapper` HOC provides a consistent way to
handle authorization, redirects, and page visibility across the Security
Solution.
This approach allows for more granular control over which pages are
accessible based on user permissions and subscription tier, particularly
important for the **AI for SOC** functionality.

## Testing

- Verified that all Security Solution pages properly respect user
permissions
- Confirmed that unauthorized users are redirected appropriately

Closes: https://github.com/elastic/security-team/issues/12401

---------

Co-authored-by: Ash <1849116+ashokaditya@users.noreply.github.com>
Co-authored-by: Ashokaditya <ashokaditya@elastic.co>
2025-05-07 11:56:43 +02:00
Dario Gieselaar
2387e3b88c
[Inference] Instrument inference with OpenTelemetry (#218694)
Instrument the inference chatComplete API with OpenTelemetry, and export
helper functions to create spans w/ the right semconv attributes.
Additionally, optionally export to Langfuse or Phoenix.

## Centralizes OpenTelemetry setup

As this is the first instance of OpenTelemetry based _tracing_ (we
already have metrics in the MonitoringCollection plugin), some
bootstrapping code is necessary to centrally configure OpenTelemetry. To
this end, I've added the following config settings:

- `telemetry.tracing.enabled`: whether OpenTelemetry tracing is enabled
(defaults to undefined, if undefined, falls back to `telemetry.enabled`)
- `telemetry.tracing.sample_rate` (defaults to 1)

The naming of these configuration settings is mostly in-line with [the
Elasticsearch tracing
settings](https://github.com/elastic/elasticsearch/blob/main/TRACING.md).

The following packages (containing bootstrapping logic, utility
functions, types and config schemas) were added:
- `@kbn/telemetry`
- `@kbn/telemetry-config` 
- `@kbn/tracing`

The OpenTelemetry bootstrapping depends on @kbn/apm-config-loader, as it
has the same constraints - it needs to run before any other code, and it
needs to read the raw config.

Additionally, a root `telemetry` logger was added that captures
OpenTelemetry logs.

Note that there is no default exporter for spans, which means that
although spans are being recorded, they do not get exported.

## Instrument chatComplete calls

Calls to `chatComplete` now create OpenTelemetry spans, roughly
following semantic conventions (which for GenAI are very much in flux).
Some helper functions were added to create other inference spans. These
helper functions use baggage to determine whether the created inference
span is the "root" of an inference trace. This allows us to export these
spans as if it were root spans - something that is needed to be able to
easily visualize these in other tools.

Leveraging these inference spans, two exporters are added. One for
[Phoenix](https://github.com/Arize-ai/phoenix) and one for
[Langfuse](https://github.com/langfuse/langfuse/tree/main): two
open-source LLM Observability suites. This allows engineers that use the
Inference plugin to be able to inspect and improve their LLM-based
workflows with much less effort.

For both Phoenix and Langfuse, two service scripts were added. Run `node
scripts/phoenix` or `node scripts/langfuse` to get started. Both scripts
work with zero-config - they will log generated Kibana config to stdout.

---------

Co-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>
Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
2025-05-07 11:44:29 +02:00
Sergi Romeu
89c91350cc
[APM] Remove apmTraceExplorerTab setting and feature (#219063)
## Summary

Part of #218501

This PR removes the advanced setting `observability:apmTraceExplorerTab`
and the feature.
2025-05-07 10:46:56 +02:00
Milosz Marcinkowski
475eef75f7
[APM] Prevent undefined error in transaction flyout (#220224)
## Summary

Handle missing `trace` and `transaction` properties. Despite, we require
`trace.id` and `transaction.id` fields in ES query, there might be
circumstances where those fields are missing (based on stack-telemetry
errors). The issue is related with #219512.

Before (error message might be different depending on the browser):


https://github.com/user-attachments/assets/53fa8c5b-a17d-4e9d-a907-a849a835502e

After:


https://github.com/user-attachments/assets/eea596de-8f89-4812-9b7f-65adaac20255
2025-05-07 10:28:38 +02:00
Mykola Harmash
57890caae4
Add flow id to copy button (#220094)
This change adds onboarding ID to the "Copy To Clipboard" button in Auto
Detect flow. This ID is needed to correctly connect BI events during the
flow.

**Note about backports**
I'm going to add backport labels for 8.18 and 9.0 after 8.18.1 and 9.0.1
have been released (May 6th).

![CleanShot 2025-05-05 at 16 05
24@2x](https://github.com/user-attachments/assets/49c0f4a9-29e1-47f8-89ef-2d03016d747c)
2025-05-07 09:20:46 +02:00
Stratoula Kalafateli
b6df628c8d
[ES|QL] Fixes types failure in adding a control after a conflict merge (#220325)
## Summary

Fixes main after merge of https://github.com/elastic/kibana/pull/219495.
Apparently the api changed in another PR and I didnt know.
2025-05-07 08:23:15 +02:00
Stratoula Kalafateli
6accad891d
[ES|QL] Adds an ES|QL control option on the dashboard controls dropdown (#219495)
## Summary

Closes https://github.com/elastic/kibana/issues/213154
Closes https://github.com/elastic/kibana/issues/209826

Allows the creation of the ES|QL control from the dashboard dropdown


![meow](https://github.com/user-attachments/assets/8b48adf5-d01a-497a-8062-1271eb213660)

### 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

---------

Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
2025-05-07 07:35:13 +02:00
Tiago Costa
25ed5a9750
chore(NA): update versions after v9.0.2 bump (#220254)
This PR is a simple update of our versions file after the recent bumps.
2025-05-07 03:23:40 +01:00
Tiago Costa
629b7dc02b
chore(NA): update versions after v8.18.2 bump (#220251)
This PR is a simple update of our versions file after the recent bumps.
2025-05-07 03:09:06 +01:00
Brad White
40e0361bb1
Add secondary chromedriver rule (#220307)
## Summary

There is a bit of strange behavior with how Renovate parses some rules
because everything is disabled at first. Eng-Prod dug into this and this
was the recommended solution - having a rule just to enable
`chromedriver` and a second rule with our config. See
[Slack](https://elastic.slack.com/archives/C07AMD4CNUR/p1746479094816819)
for full context.
2025-05-06 18:47:39 -05:00
Meghan Murphy
a218f6aed3
[WorkChat] Have UI use Tools instead of integrations (#220165)
## Summary

This PR changes the user-facing 'Integrations' to 'Tools' 

<img width="1706" alt="Screenshot 2025-05-05 at 9 55 41 PM"
src="https://github.com/user-attachments/assets/8aefce06-ccf2-42f1-a5c6-1acb12a71937"
/>

<img width="1697" alt="Screenshot 2025-05-05 at 5 54 52 PM"
src="https://github.com/user-attachments/assets/bf79781c-0029-409f-8dc6-74feda974ddb"
/>
<img width="1722" alt="Screenshot 2025-05-05 at 5 55 03 PM"
src="https://github.com/user-attachments/assets/d79ca8d4-6d6f-4a2b-ba5d-905d59694be6"
/>

<img width="1720" alt="Screenshot 2025-05-05 at 5 55 16 PM"
src="https://github.com/user-attachments/assets/6805a34e-9e22-483d-bc81-4c0f27f73321"
/>



### 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>
Co-authored-by: Jedr Blaszyk <jedrazb@gmail.com>
2025-05-07 01:14:27 +02:00
Lisa Cawley
9635e5f28b
[DOCS] Fix URLs in Kibana API documentation (#215989) 2025-05-06 16:01:09 -07:00
Tiago Costa
2a2b10e15a
chore(NA): update versions after v8.17.7 bump (#220258)
This PR is a simple update of our versions file after the recent bumps.
2025-05-06 23:50:31 +01:00
Devon Thomson
3e882d8cd9
[Embeddables] Serialized State Only (#215947)
Closes https://github.com/elastic/kibana/issues/205531
Closes #219877.
Closes https://github.com/elastic/kibana/issues/213153
Closes https://github.com/elastic/kibana/issues/150920
Closes https://github.com/elastic/kibana/issues/203130
 
### Overview
The embeddable framework has two types of state: `SerializedState` and
`RuntimeState`.

`SerializedState` is the form of the state when saved into a Dashboard
saved object. I.e. the References are extracted, and state saved
externally (by reference) is removed. In contrast `RuntimeState` is an
exact snapshot of the state used by the embeddable to render.

<b>Exposing SerializedState and RuntimeState was a mistake</b> that
caused numerous regressions and architectural complexities.

This PR simplifies the embeddable framework by only exposing
`SerializedState`. `RuntimeState` stays localized to the embeddable
implementation and is never leaked to the embeddable framework.

### Whats changed
* `ReactEmbeddableFactory<SerializedState, RuntimeState, Api>` =>
`EmbeddableFactory<SerializedState, Api>`
* `deserializeState` removed from embeddable factory. Instead,
`SerializedState` is passed directly into `buildEmbeddable`.
* `buildEmbeddable` parameter `buildApi` replaced with `finalizeApi`.
`buildApi({ api, comparators })` => `finalizeApi(api)`.
* The embeddable framework previously used its knowledge of
`RuntimeState` to setup and monitor unsaved changes. Now, unsaved
changes setup is pushed down to the embeddable implementation since the
embeddable framework no longer has knowledge of embeddable RuntimeState.

### Reviewer instructions
<b>Please prioritize reviews.</b> This is a large effort from our team
and is blocking many other initiatives. Getting this merged is a top
priority.

This is a large change that would best be reviewed by manually testing
the changes
* adding/editing your embeddable types
* Ensuring dashboard shows unsaved changes as expected
* Ensuring dashboard resets unsaved changes as expected
* Ensuring dashboard does not show unsaved changes after save and reset
* Returning to a dashboard with unsaved changes renders embeddables with
those unsaved changes

---------

Co-authored-by: Hannah Mudge <Heenawter@users.noreply.github.com>
Co-authored-by: Nathan Reese <reese.nathan@elastic.co>
Co-authored-by: Nick Peihl <nick.peihl@elastic.co>
Co-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>
Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
Co-authored-by: Catherine Liu <catherine.liu@elastic.co>
Co-authored-by: Ola Pawlus <98127445+olapawlus@users.noreply.github.com>
2025-05-06 15:08:34 -06:00
Eyo O. Eyo
2fd65fba64
[On-Week] Automate chromium linux builds for reporting in Kibana (#212674)
## Summary

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

This PR ~attempts to take a stab at automating~ automates the process
for building the linux headless chromium used for reporting within
Kibana.

The Idea here is that one would simply only need create an issue within
the Kibana project that will then trigger the build for chromium, we'll
be leveraging GitHub actions for this, the Github workflow defined only
kicks in when an issue is created with the label
`trigger-chromium-build`, when such an issue is created, the body of the
issue is analysed; there's an expectation that the body would contain a
fenced codeblock of type json that specifies the property
`puppeteer_version`, if this is found this value is read and, we then
trigger a build on buildkite passing along this value, in the case where
there are multiple fenced code blocks specifying the expected property
`puppeteer_version` we leave a message that the issue body be modified,
also if the expected label was added but the expected property is not
found we also leave a message prompting that the expected property be
provided.

Once the build has commenced a message containing the link to the build
would be provided as initial feedback to the user, also on completion
another message is provided to the user, that provides a link to the PR
containing all the required changes to update puppeteer to the version
specified.

~It's also worth pointing out that this PR also, modifies the source for
`win`, `mac` chromium binaries to leverage the [JSON API
endpoint](https://github.com/GoogleChromeLabs/chrome-for-testing#json-api-endpoints)
provided by Google to get the required binaries for chromium headless in
a deterministic way, which in turns is part of what makes this
automation possible.~

## How to test this

- If you'd love to test the Github action too without the PR being
merging in just yet, you should consider setting up
[act](https://github.com/nektos/act), alongside it's companion [vscode
extension](https://sanjulaganepola.github.io/github-local-actions-docs/)
, we'll then want to create a payload file providing similar data that
github would return for our workflow trigger, more info about setting
this up
[here](https://sanjulaganepola.github.io/github-local-actions-docs/usage/settings/#payloads).
The payload file we'd want would be something along the following lines;

```json
{
    "action": "labeled",
    "label":{
        "name": "trigger-chromium-build"
    },
    "issue": {
        "number": 1,
        "title": "Issue 1",
        "author_association": "MEMBER",
        "labels": [
            {
                "name": "trigger-chromium-build"
            }
        ],
        "body": "\n## Random text \n\n ~~~json\n{\n  \"puppeteer_version\": \"24.6.1\" \n}\n~~~\n~~~json\n{\n  \"some_random_value\": \"23.0.1\" \n}\n~~~"
    }
}
```

- To test the actual build process it can be initiated through this
specific pipeline
https://buildkite.com/elastic/kibana-migration-pipeline-staging by
creating a custom build on `pull/212674/head` (this pull request) with
the env variable similar to this

```
TESTED_PIPELINE_PATH=.buildkite/pipelines/chromium_linux_build/build_chromium.yml
PUPPETEER_VERSION=24.6.1
GITHUB_ISSUE_NUMBER=212732
GITHUB_ISSUE_BASE_OWNER=elastic
GITHUB_ISSUE_BASE_REPO=kibana
GITHUB_ISSUE_TRIGGER_USER=eokoneyo
```

PS: Issue #212732 is an issue that's been created to test providing
feedback to the user about the build process, re-triggering a build on
an existing issue updates the comments in place.

<!-- ### Where to go from here?

- Ideas and thoughts welcome
-->
<!--
### 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-06 22:04:08 +02:00
Tim Sullivan
0acd88e3b9
[Breadcrumbs] Hide "deployment" in breadcrumb when on-prem (#220110)
## Summary

Closes #219869

**Before**

![image](https://github.com/user-attachments/assets/59f0f6fc-2113-44ee-8e36-69c4eb718fad)


**After**
<img width="1320" alt="image"
src="https://github.com/user-attachments/assets/85ad1117-4aab-4a8d-807c-4fa90cd8b917"
/>


### 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
2025-05-06 12:43:47 -07:00
Tiago Costa
0712aa6ab8
skip flaky suite (#220081) 2025-05-06 20:19:30 +01:00
Nicolas Chaulet
162d3abc53
[Fleet] Fix updating agentless settings for managed policies (#220244) 2025-05-06 14:13:32 -04:00
jennypavlova
9348f9b930
[APM][OTel] Test details and waterfall (#220241)
Closes #219487
Closes #219486 

## Summary

This PR adds more tests to the e2e OTel / Edot suite
2025-05-06 19:48:21 +02:00
Irene Blanco
d193a92a3e
[Discover][APM] Add latency chart to duration section in new overview tab in flyout (#217975)
## Summary

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

As part of the Traces in Discover feature we want to add latency
duration chart to the already existing duration section.

### Details

- Created `latencyOverallSpanDistributionRoute` based on
`latencyOverallTransactionDistributionRoute` to gather the data needed
for rendering the span chart.
- We may reconsider whether this should remain in APM or be moved to a
shared package for better typing, easier exposure, and easier
maintenance. There's an
[issue](https://github.com/elastic/kibana/issues/216959) to address
this.
- Split `TraceDocumentOverview` into `TransactionDocumentOverview` and
`SpanDocumentOverview`, and also split `getTraceDocumentOverview` into
`getTransactionDocumentOverview` and `getSpanDocumentOverview`.
- Created `DurationDistributionChart` in `kbn-apm-ui-shared` based on
the `DurationDistributionChart` in APM.
- Keep in mind that it's an exact clone of the component and its
dependencies, excepting a couple of booleans I added as props, so I
don't expect any of it to be reviewed as part of this PR
- We'll be removing the APM version in favor of this one as part of this
[issue](https://github.com/elastic/kibana/issues/211781), so it only
exists in one place.
- Removed the telemetry TODOs since the issue was closed, and no
additional work is needed for tracking click links.

Both spans and transactions will now have the latency duration chart:

|Details||
|-|-|
|Transaction|![Screenshot 2025-04-11 at 11 09
00](https://github.com/user-attachments/assets/7320bb82-66d2-4c29-ac90-916c25398e79)|
|Span|![Screenshot 2025-04-11 at 11 08
33](https://github.com/user-attachments/assets/3ccde990-6870-442e-854e-778fadc244ef)|
|Loading|![Screen Recording 2025-04-11 at 11 09
16](https://github.com/user-attachments/assets/c336cc3d-2b34-43ea-8168-4c9dbf60fe08)|
|Dark mode|![Screenshot 2025-04-11 at 12 44
01](https://github.com/user-attachments/assets/a1d10c8d-8fae-4ff4-9758-6cc9295d6b30)|


## How to test

- Enable the discover profiles by adding this to the` kibana.yml `file:
```
discover.experimental.enabledProfiles:
  - observability-traces-data-source-profile
  - observability-traces-transaction-document-profile
  - observability-traces-span-document-profile
```
- Make sure your space has Observability as Solution View.
- Open Discover and select or create a data view that includes any APM
traces index (`traces-*`), or query them using ES|QL.
- Apply a filter for `data_stream.type:"traces"` to ensure only trace
documents are retrieved.
- Open the flyout.

---------

Co-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>
Co-authored-by: Carlos Crespo <crespocarlos@users.noreply.github.com>
2025-05-06 18:54:04 +02:00
Tre
3e794de2ee
[SKIP ON MKI] 6 tests in 2 test files failing (#220260)
## Summary

see details: https://github.com/elastic/kibana/issues/220248
2025-05-06 18:11:05 +02:00
Alexi Doak
8b470ffdfc
[ResponseOps][Reporting] Schema changes to send email attachments for reporting (#219164)
Part of https://github.com/elastic/kibana/issues/216316

## Summary

This PR adds schema changes and validation for sending attachments with
the email connector. The connector email services uses the execute API
that bypasses task manager and just passes the attachments.


### 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

---------

Co-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>
2025-05-06 08:58:48 -07:00