Commit graph

62541 commits

Author SHA1 Message Date
adcoelho
b87ee2d518 Close FilePreview with Escape key.
Tests.
2023-04-24 10:33:02 +02:00
Navarone Feekery
03464e79c2
[Enterprise Search] Clean up rich configurable fields UI (#155282)
- Add spacing between `EuiRow` and `EuiPanel` for
`ConnectorConfigurationField`.
- Hide fields that have any `ui_restrictions`
- Fix labelling for sensitive textareas
- Other misc cleanup tasks
2023-04-24 10:17:00 +02:00
Ido Cohen
67927e12b2
[Cloud Security] update cloud security telemetry interface 2023-04-24 10:26:39 +03:00
Kibana Machine
743325dc85
[api-docs] 2023-04-24 Daily api_docs build (#155584)
Generated by
https://buildkite.com/elastic/kibana-api-docs-daily/builds/317
2023-04-24 01:02:05 -04:00
Kevin Delemme
50bb555e7a
feat(slo): add feedback button (#155468) 2023-04-23 19:04:12 +02:00
Kevin Delemme
9c3111e57f
chore(slo): change no rule badge style (#155546) 2023-04-23 19:02:46 +02:00
Kevin Delemme
158ea85468
feat(slo): Synchronize cursor on SLO charts (#155560) 2023-04-23 19:01:19 +02:00
Ievgen Sorokopud
68719bdb07
[RAM][SECURITYSOLUTION][ALERTS] - Integrate Alert summary inside of security solution rule page (#154990)
## Summary

[Main ticket](https://github.com/elastic/kibana/issues/151916)
This PR dependant on [these
changes](https://github.com/elastic/kibana/pull/153101)

These changes cover next two tickets:
- [RAM][SECURITYSOLUTION][ALERTS] - Integrate per-action frequency field
in security solution APIs #154532
- [RAM][SECURITYSOLUTION][ALERTS] - Integrate per-action frequency UI in
security solution #154534

With this PR we will integrate per-action `frequency` field which
already works within alert framework and will update security solution
UI to incorporate the possibility to select "summary" vs "for each
alert" type of actions.



![](https://user-images.githubusercontent.com/616158/227377473-f34a330e-81ce-42b4-af1b-e6e302c6319d.png)


## NOTES:
- There will be no more "Perform no actions" option which mutes all the
actions of the rule. For back compatibility, we need to show that rule
is muted in the UI cc @peluja1012 @ARWNightingale
- The ability to generate per-alert action will be done as part of
https://github.com/elastic/kibana/issues/153611


## Technical Notes:
Here are the overview of the conversions and transformations that we are
going to do as part of these changes for devs who are going to review.

On rule **create**/**read**/**update**/**patch**:
- We always gonna set rule level `throttle` to `undefined` from now on
- If each action has `frequency` attribute set, then we just use those
values
- If actions do not have `frequency` attribute set (or for some reason
there is a mix of actions with some of them having `frequency` attribute
and some not), then we transform rule level `throttle` into `frequency`
and set it for each action in the rule

On rule **bulk editing**:
- We always gonna set rule level `throttle` to `undefined`
- If each action has `frequency` attribute set, then we just use those
values
- If actions do not have `frequency` attribute set, then we transform
rule level `throttle` into `frequency` and set it for each action in the
rule
- If user passed only `throttle` attribute with empty actions (`actions
= []`), this will only remove all actions from the rule

This will bring breaking changes which we agreed on with the Advanced
Correlation Group
cc @XavierM @vitaliidm @peluja1012 


### Checklist

Delete any items that are not applicable to this PR.

- [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/packages/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

---------

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
Co-authored-by: Maxim Palenov <maxim.palenov@elastic.co>
2023-04-23 10:53:48 +02:00
Jordan
118daf778b
[Cloud Posture] Dashboard initial FTR (#155163) 2023-04-23 11:51:44 +03:00
Walter Rafelsberger
d6d933a2af
[ML] Moves shared code to @kbn/ml-error-utils. (#155372)
- Moves code from `x-pack/plugins/ml/common/util/errors` that was shared
via `x-pack/plugins/ml/public/shared.ts` to `@kbn/ml-error-utils`.
- `data_visualizer` and `aiops` plugins now use that package instead of
code duplication.
2023-04-22 09:25:37 +02:00
Julia Rechkunova
1bbaa5a62f
[TSDB][Discover] Exclude counter fields from Breakdown options (#155532)
Closes https://github.com/elastic/kibana/issues/155143

## Summary

This PR excludes time series counter fields (like `bytes_counter`) from
"Break down by" options in the histogram.
2023-04-22 07:34:33 +02:00
Nathan Reese
a108b8c9c6
[maps] metrics mask (#154983)
Fixes https://github.com/elastic/kibana/issues/55520

PR adds ability to set mask configuration for metric fields to hide
features client side that are outside the range of the mask.

<img width="600" alt="Screen Shot 2023-04-19 at 3 45 15 PM"
src="https://user-images.githubusercontent.com/373691/233207269-854695dd-ea51-45cd-b092-3360092846bb.png">

<img width="600" alt="Screen Shot 2023-04-19 at 3 44 45 PM"
src="https://user-images.githubusercontent.com/373691/233207329-e0c7f20c-e789-446c-8994-87bcdf8e4bbe.png">

For vector layer, I could not use easier solution of filter expression
since filter expressions do not support feature-state. Instead,
implementation sets opacity paint property to 0.

---------

Co-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>
2023-04-21 18:46:57 -06:00
Garrett Spong
ef64acf405
[RAM] Adds revision to event-log (#153716)
## Summary

Follow on from https://github.com/elastic/kibana/pull/151388 &
https://github.com/elastic/kibana/pull/147398, which includes the rule's
current `revision` when writing to the kibana event-log.

Note: Added as `kibana.alert.rule.revision` instead of as ECS field
`rule.version` as the [ECS
docs](https://www.elastic.co/guide/en/ecs/current/ecs-rule.html#field-rule-version)
conflate `version` & `revision` and figured it was best to be explicit.
If we do indeed want to use `rule.version` I'll make the change.


<p align="center">
<img width="500"
src="https://user-images.githubusercontent.com/2946766/233216775-f371f412-dcf6-4ef7-a396-84ec853eebbb.png"
/>
</p> 



### Checklist

Delete any items that are not applicable to this PR.

- [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
2023-04-21 17:20:26 -07:00
Nathan Reese
d4f2639377
[Maps] fix maps listing page 'Cannot update a component while rendering a different component' (#155545)
To view problem
1) Install sample data set
2) Open maps listing page. Notice the following console warning
<img width="400" alt="Screen Shot 2023-04-21 at 9 19 16 AM"
src="https://user-images.githubusercontent.com/373691/233705813-75efc248-d0e4-40da-bc26-aa01b2e21b00.png">

PR removes side effect during `MapsListViewComp` render that caused
[ScreenReaderRouteAnnouncements](0cd7973e1f/packages/core/chrome/core-chrome-browser-internal/src/ui/header/screen_reader_a11y.tsx)
to update state.

PR also refactors LoadListAndRender into a functional component with
hooks. That change is not needed but was done to isolate the issue.
Figured its worth keeping.

---------

Co-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>
2023-04-21 18:14:57 -06:00
Devon Thomson
085686fceb
[Dashboard] Removes Reload on Clone / Replace Panel (#155561)
Removes the page reload on clone and replace panel to make them feel snappier.
2023-04-21 19:26:18 -04:00
Zacqary Adam Xeper
350bd3eb6d
[RAM] Add query conditional action filter to Security Solution UI (#154680)
## Summary

Closes #152611 

<img width="788" alt="Screenshot 2023-04-10 at 2 09 29 PM"
src="https://user-images.githubusercontent.com/1445834/230977273-9d00aa3d-af2c-4dff-80ef-3034213df90d.png">


### Checklist

Delete any items that are not applicable to this PR.

- [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/packages/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] Any UI touched in this PR is usable by keyboard only (learn more
about [keyboard accessibility](https://webaim.org/techniques/keyboard/))
- [x] Any UI touched in this PR does not create any new axe failures
(run axe in browser:
[FF](https://addons.mozilla.org/en-US/firefox/addon/axe-devtools/),
[Chrome](https://chrome.google.com/webstore/detail/axe-web-accessibility-tes/lhdoppojpmngadmnindnejefpokejbdd?hl=en-US))
2023-04-21 17:14:06 -06:00
Yara Tercero
11155329cc
[Security Solution][Exceptions] - Add exception list duplication options with and without expired items (#154991)
## Summary

Adds the following:

- Add the option to duplicate from the shared exception list management
actions dropdowns
  - User can select to include exception items with expired TTL
  - User can select to not include exception items with expired TTL 
  - Cypress tests added for both options
2023-04-21 16:01:43 -07:00
Matthew Kime
fdc23f570e
[data view field editor] Move preview response and value formatter to controller (#153799)
## Summary

This is a refactor that moves logic from hooks to a controller class for
the data view field editor preview. Functionality is unaffected.
2023-04-21 16:15:25 -05:00
Jiawei Wu
9bb127f26c
[RAM] Add window maintenance column to rule logs and rule tables (#155333)
## Summary
Resolves: https://github.com/elastic/kibana/issues/153775

This PR adds the `maintenance_window_id` column to the following tables:

## O11Y/Security solutions Alerts table

![o11y-alerts-table](https://user-images.githubusercontent.com/74562234/233227165-03c105d9-3890-4462-91ec-cd7c6ad26d7b.png)

## Rule details alerts table

![rule_details_maintenance_window_ids](https://user-images.githubusercontent.com/74562234/233226920-6f903ddf-401f-49e7-bb9c-9a36334fc7ce.png)

## Rule run event log

![rule_event_log_maintenance_window](https://user-images.githubusercontent.com/74562234/233226784-c6e804e6-eabe-4500-b51a-aae7aafbcff1.png)

## To test:
1. Set `ENABLE_MAINTENANCE_WINDOWS` to true in
`x-pack/plugins/alerting/public/plugin.ts`
2. Create 1 or more active maintenance windows in stack management
3. Create a rule, trigger some alerts
4. Go to the rule details page alerts table, assert the `maintenance
window` column is there, and renders the maintenance window ids
5. Go to the rule details page event log table, assert the `maintenance
window` column can enabled, and renders the maintenance window ids
6. Create a O11Y rule, trigger some alerts
7. Go to the O11Y alerts table, assert that the `maintenance_window_id`
field can be enabled, and renders the maintenance window ids
### 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: Lisa Cawley <lcawley@elastic.co>
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2023-04-21 14:01:19 -07:00
Philippe Oberti
9b6c6bcd9c
[Security Solution] expandable flyout small cleanup (#155515) 2023-04-21 15:59:20 -05:00
Devon Thomson
8039fec178
[Embeddable] Always send value input from edit panel action (#155283)
ensures that the by value input is passed into the editors regardless of whether the panel is by value or by reference.
2023-04-21 16:53:25 -04:00
Nathan Reese
f0106b1817
[dashboard][maps] fix 'by value' map does not fill dashboard panel on initial page load (#155554)
Fixes https://github.com/elastic/kibana/issues/155553

Following steps in issue now renders map as expected
<img width="600" alt="Screen Shot 2023-04-21 at 1 18 54 PM"
src="https://user-images.githubusercontent.com/373691/233717520-7e25b4a9-1639-4b5e-9dfc-3816f4f35153.png">
2023-04-21 14:51:12 -06:00
Philippe Oberti
4eeec1865f
[Security Solution] add threat intelligence overview to expandable flyout (#155328) 2023-04-21 15:45:55 -05:00
Luke
8a3f5ebbea
[Security Solution] Store expandable flyout state in the url (#154703) 2023-04-21 15:45:37 -05:00
Steph Milovic
22b8e5b0a6
[Security Solution] Add Timeline Hover Action to Security Dashboard Calculated Metrics (#154299)
Brings back the Add to timeline action on alert counts via Cell Actions

Areas implemented include:
- D&R Dashboard
  - Open alerts by rule
  - Hosts by alert severity
  - Users by alert severity
- Entity Analytics Dashboard
  - Host Risk Scores
  - User Risk Scores


![123](https://user-images.githubusercontent.com/6935300/231568732-2263ac45-ba50-4aab-b3a6-224182fbf92c.jpg)

---------
Crafted with friendship by

Co-authored-by: Pablo Neves Machado <pablo.nevesmachado@elastic.co>
Co-authored-by: semd <sergi.massaneda@elastic.co>
2023-04-21 13:43:08 -06:00
Lisa Cawley
e1b3bc259a
[DOCS] Automate email-params-test.png, add title in connector table rows (#155469) 2023-04-21 12:19:33 -07:00
Philippe Oberti
ec6bc2db15
[Security Solution] add session view component to expandable flyout (#154597) 2023-04-21 14:19:17 -05:00
Alexi Doak
dbb8e2ebec
[ResponseOps][Window Maintenance] Add the stop and archive actions to the maintenance window table (#155201)
Resolves https://github.com/elastic/kibana/issues/154814

## Summary

This pr adds the cancel/archive actions to the Maintenance Windows
table, and adds an archive callout to the create form.
@lcawl I think I need your help with some of the text in the modals 🙂 

**Create Form:**
Callout
<img width="1370" alt="Screen Shot 2023-04-18 at 9 49 58 PM"
src="https://user-images.githubusercontent.com/109488926/232945833-77f01988-e5c4-4d5f-a2f9-b361085964e2.png">

Modal
<img width="1335" alt="Screen Shot 2023-04-18 at 9 50 05 PM"
src="https://user-images.githubusercontent.com/109488926/232945810-dacb3a26-fa59-4e5e-995c-14b7f0977c10.png">

**Cancel Modal:**
<img width="628" alt="Screen Shot 2023-04-18 at 9 52 18 PM"
src="https://user-images.githubusercontent.com/109488926/232946092-c4001ccc-d2f9-475a-bc67-3b2ab6fdf31e.png">

**Cancel and Archive Modal:**
<img width="621" alt="Screen Shot 2023-04-18 at 9 52 56 PM"
src="https://user-images.githubusercontent.com/109488926/232946171-154f8601-d5aa-40f1-824a-bff25b4d3d91.png">

**Archive Modal:**
<img width="611" alt="Screen Shot 2023-04-18 at 9 53 25 PM"
src="https://user-images.githubusercontent.com/109488926/232946240-ee25bcd0-80d6-403c-9fb3-9aec89d11ebd.png">

**Unarchive Modal:**
<img width="620" alt="Screen Shot 2023-04-18 at 9 54 16 PM"
src="https://user-images.githubusercontent.com/109488926/232946350-814d0c05-5511-4fad-8ac4-0c5824d94b8e.png">

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

---------

Co-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>
Co-authored-by: Lisa Cawley <lcawley@elastic.co>
2023-04-21 12:04:54 -07:00
Dominique Clarke
da5a4b08d3
[Synthetics] adjust synthetics enablement doc links (#155340)
## Summary

Adjusts content for Synthetics enablement doc links.
2023-04-21 14:37:10 -04:00
Devon Thomson
81b003d431
[Controls] Use Internal User to Get Value of allow_expensive_queries (#155430)
changes the way we access `allow_expensive_queries` to use the internal user.
2023-04-21 14:19:53 -04:00
Lisa Cawley
da4c42da48
[DOCS] Automate email connector screenshot, edit secrets field label (#155464) 2023-04-21 11:04:09 -07:00
Ignacio Rivas
376c48a7bd
[Watcher] Migrate from EuiCodeEditor to Monaco (#155486) 2023-04-21 18:55:13 +02:00
Ignacio Rivas
791555641c
[Snapshot Restore] Migrate away from EuiCodeEditor in favour of Monaco (#155368) 2023-04-21 18:54:19 +02:00
Jonathan Budzenski
51d5387b8b skip flaky suite (#155534) 2023-04-21 11:48:50 -05:00
Yulia Čech
bc3471cf26
[Guided onboarding] Dynamic URLs for steps (#154572)
## Summary
Fixes https://github.com/elastic/kibana/issues/143322

This PR adds an option to store dynamic parameters when a step is
completed to be used later for dynamically built URLs.

### How to test
1. Add `xpack.cloud.id: 'testID'` to your `/config/kibana.dev.yml` file
2. Start ES with `yarn es snapshot`
3. Start Kibana with `yarn start --run-examples` 
4. Navigate to the guided onboarding example plugin
`http://localhost:5601/app/guidedOnboardingExample`
5. Start the test guide and when completing step 1 provide any value for
the paramter `indexName`
6. Continue the guide until step 4 and check that the correct value is
being used for the url of this step.

### 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: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2023-04-21 18:21:29 +02:00
Stratoula Kalafateli
89258d7a1c
Changes to the unified search save query UI (#155238)
## Summary

Makes the changes described on
https://github.com/elastic/kibana/issues/153809#issuecomment-1513737032

<img width="481" alt="image"
src="https://user-images.githubusercontent.com/17003240/233070006-42d45555-a469-4aa7-969c-b121f9761b76.png">

<img width="435" alt="image"
src="https://user-images.githubusercontent.com/17003240/233070100-9ee0ea02-ce4f-4ee0-904d-f55754d40b56.png">


### 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/packages/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
2023-04-21 18:52:30 +03:00
Hannah Mudge
29ffa177c1
[Dashboard] Add reset button (#154872)
Closes https://github.com/elastic/kibana/issues/132457

## Summary

This PR adds a reset button to the dashboard top navigation in both edit
and view mode - when clicked, if the dashboard has unsaved changes, it
will revert the dashboard to the last saved state:



https://user-images.githubusercontent.com/8698078/232918433-97bac4b0-7472-49e9-9eb3-2cb7c9e6edf6.mov

> **Note**
> The above video contains some old copy for the modals. Please refer to
"All copy changes" below to see the updated copy.

Note that, by adding more buttons to the top nav bar, we are increasing
the risk of someone hitting [this accessibility
issue](https://github.com/elastic/kibana/issues/154414) (where the
breadcrumbs get completely overlapped before the browser is small enough
for the navigation to collapse) - this will either be addressed on the
Shared UX side or will be addressed as part of our [nav bar
redesign](https://github.com/elastic/kibana/issues/154945) 👍


### All Copy Changes

- **Listing Page** 

  | Before | After |
  |--------|-------|
| ![Screenshot 2023-04-18 at 4 29 10
PM](https://user-images.githubusercontent.com/8698078/232919138-7be86e97-ebb4-48a9-b8b1-0b970131aa37.png)
|
![image](https://user-images.githubusercontent.com/8698078/232919166-b7bc7b55-5074-485d-ad0a-2fb695367538.png)
|
|
![image](https://user-images.githubusercontent.com/8698078/232920038-6c8c463e-0c7d-49e7-99c8-86b2ae611844.png)
|
![image](https://user-images.githubusercontent.com/8698078/233412233-a785d99d-9d07-4ee5-a121-646bbd839f7c.png)
|

- **Dashboard - _Edit Mode_** 

  | Before | After |
  |--------|-------|
|
![image](https://user-images.githubusercontent.com/8698078/232920992-2d1b61f4-dff2-4bdd-854b-9cd6fcae07ce.png)
|
![image](https://user-images.githubusercontent.com/8698078/233412732-254a9503-5526-44bc-a2e0-067f8800ad26.png)
|





- **Dashboard - _View Mode_** 

  | Before | After |
  |--------|-------|
| N/A since you couldn't discard changes from view mode previously |
![image](https://user-images.githubusercontent.com/8698078/233413029-9a6b4256-3002-48c5-8620-7596d8f08153.png)
|


###  Flaky Test Runner
- `test/functional/apps/dashboard/group1/dashboard_unsaved_state.ts`
<a
href="https://buildkite.com/elastic/kibana-flaky-test-suite-runner/builds/2144"><img
src="https://user-images.githubusercontent.com/8698078/232622312-8532bc7e-a699-45ee-862d-739d116c5dba.png"></a>
-
`test/functional/apps/dashboard_elements/controls/options_list/options_list_dashboard_interaction.ts`
<a
href="https://buildkite.com/elastic/kibana-flaky-test-suite-runner/builds/2143"><img
src="https://user-images.githubusercontent.com/8698078/232615061-f01439e8-3a69-4190-8b6f-1926e1fa776a.png"></a>


### 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/packages/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] Any UI touched in this PR is usable by keyboard only (learn more
about [keyboard accessibility](https://webaim.org/techniques/keyboard/))
- [x] Any UI touched in this PR does not create any new axe failures
(run axe in browser:
[FF](https://addons.mozilla.org/en-US/firefox/addon/axe-devtools/),
[Chrome](https://chrome.google.com/webstore/detail/axe-web-accessibility-tes/lhdoppojpmngadmnindnejefpokejbdd?hl=en-US))
- [x] This renders correctly on smaller devices using a responsive
layout. (You can test this [in your
browser](https://www.browserstack.com/guide/responsive-testing-on-local-server))
(Refer above)
- [x] This was checked for [cross-browser
compatibility](https://www.elastic.co/support/matrix#matrix_browsers)


### For maintainers

- [ ] This was checked for breaking API changes and was [labeled
appropriately](https://www.elastic.co/guide/en/kibana/master/contributing.html#kibana-release-notes-process)
2023-04-21 09:30:13 -06:00
Chris Cowan
17c6b6ce33
Properly handle NO DATA with multiple conditions with a mix of aggregations and document count thresholds (#154690)
This PR fixes #154553, which arises when a rule containing
aggregation-based conditions is combined with document count conditions.
In such a case, the aggregation-based conditions may return "NO DATA".
Unlike document count-based conditions, which do not typically generate
a "NO DATA" response since this is equivalent to zero and only triggers
if the user defines the condition as `Document count < 0`;
aggregation-based conditions produce a `null` result that is interpreted
as "NO DATA".

This PR also improves the "NO DATA" reason message when a group-by field
is not defined. The reason message before the change looked like
`test.metric.3 reported no data in the last 1m for ` which I changed to
`test.metric.3 reported no data in the last 1m` to be more readable.

This also fixes the context variables for document count-based
conditions by setting the `metric` context variable to `count`.
2023-04-21 09:27:38 -06:00
Marco Liberati
0d37f023f6
[Lens] Apply default label on field change for counter rate (#155509)
## Summary

Fix #154449 


![counter_rate_field_change](https://user-images.githubusercontent.com/924948/233646312-9d7b32af-20ed-426b-970f-6a58697deb2a.gif)

### Checklist

Delete any items that are not applicable to this PR.

- [ ] 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/packages/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
- [ ] Any UI touched in this PR is usable by keyboard only (learn more
about [keyboard accessibility](https://webaim.org/techniques/keyboard/))
- [ ] Any UI touched in this PR does not create any new axe failures
(run axe in browser:
[FF](https://addons.mozilla.org/en-US/firefox/addon/axe-devtools/),
[Chrome](https://chrome.google.com/webstore/detail/axe-web-accessibility-tes/lhdoppojpmngadmnindnejefpokejbdd?hl=en-US))
- [ ] 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 renders correctly on smaller devices using a responsive
layout. (You can test this [in your
browser](https://www.browserstack.com/guide/responsive-testing-on-local-server))
- [ ] This was checked for [cross-browser
compatibility](https://www.elastic.co/support/matrix#matrix_browsers)


### Risk Matrix

Delete this section if it is not applicable to this PR.

Before closing this PR, invite QA, stakeholders, and other developers to
identify risks that should be tested prior to the change/feature
release.

When forming the risk matrix, consider some of the following examples
and how they may potentially impact the change:

| Risk | Probability | Severity | Mitigation/Notes |

|---------------------------|-------------|----------|-------------------------|
| Multiple Spaces&mdash;unexpected behavior in non-default Kibana Space.
| Low | High | Integration tests will verify that all features are still
supported in non-default Kibana Space and when user switches between
spaces. |
| Multiple nodes&mdash;Elasticsearch polling might have race conditions
when multiple Kibana nodes are polling for the same tasks. | High | Low
| Tasks are idempotent, so executing them multiple times will not result
in logical error, but will degrade performance. To test for this case we
add plenty of unit tests around this logic and document manual testing
procedure. |
| Code should gracefully handle cases when feature X or plugin Y are
disabled. | Medium | High | Unit tests will verify that any feature flag
or plugin combination still results in our service operational. |
| [See more potential risk
examples](https://github.com/elastic/kibana/blob/main/RISK_MATRIX.mdx) |


### For maintainers

- [ ] This was checked for breaking API changes and was [labeled
appropriately](https://www.elastic.co/guide/en/kibana/master/contributing.html#kibana-release-notes-process)
2023-04-21 17:22:24 +02:00
Walter Rafelsberger
dcca5a77ee
[ML] Migrate SCSS to emotion for data grid (#155349)
Migrate SCSS to emotion for data grid mini histograms.
2023-04-21 17:20:12 +02:00
Efe Gürkan YALAMAN
0cd7973e1f
[Enterprise Search] Enterprise Search Cypress configuration (#155398)
## Summary

Updated Test configurations to make Enterprise Search run with basic
Cypress tests. In Enterprise Search root folder run `cypress.sh` or
`cypress.sh open` to run tests via FTR servers running.

You can run Cypress manually on a already running stack while developing
with `cypress.sh dev`.


### Checklist

Delete any items that are not applicable to this PR.

- [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: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2023-04-21 17:06:41 +02:00
Sergi Massaneda
3e81f8f093
[SecuritySolution] Fix flaky cypress timeline templates test (#155513)
## Summary

The test was guessing the created template was on page `2` but,
depending on the template data inserted, sometimes it is found on page
`3`.
This PR changes the test approach to search for the template name, so we
don't rely on guessing the page.
2023-04-21 08:02:14 -07:00
Lisa Cawley
a0aae1aa23
[DOCS] Automate rule-flyout-rule-conditions.png (#155461) 2023-04-21 07:51:28 -07:00
Anton Dosov
6aa1491c9e
[CM] Onboard maps to cross-type search (#155148)
## Summary

Part of https://github.com/elastic/kibana/issues/152224
Follow up to https://github.com/elastic/kibana/issues/153256

This PR onboards maps CM integration into the multi-type search
(`msearch`). It isn't actually used anywhere in the user-facing UI yet,
as first other types need to be migrated to CM.

This PR also adds an example app to test the `msearch` end-to-end.
2023-04-21 07:41:08 -07:00
Thom Heymann
cfc01d5444
Hide remote indices role configuration when not supported (#155490)
Resolves #155389

## Summary

Adds feature flag to automatically hide remote index privileges section
when not supported by cluster.
2023-04-21 15:19:25 +01:00
GitStart
f95ebdfb31
[Synthetics] Filtering - location filter counts are off when filter is applied (#155437)
Co-authored-by: Anjola Adeuyi <57623705+anjola-adeuyi@users.noreply.github.com>
Co-authored-by: gitstart_bot <gitstart_bot@users.noreply.github.com>
Co-authored-by: shahzad31 <shahzad31comp@gmail.com>
2023-04-21 16:02:58 +02:00
Dominique Clarke
b494716bdb
[Fleet] Create Synthetics migration for 8.8.0 (#154952)
## Summary

Resolves https://github.com/elastic/kibana/issues/155215
Resolves https://github.com/elastic/kibana/issues/142653

Handles two primary migrations for Synthetics integration policies.

1. Rounds deprecated schedules to supported schedules
2. Transforms old deprecated throttling schema `5u/3u/20l` to support
JSON schema `{ download: 5, upload: 3, latency: 20 }`

Schedule migration
---

Before 16m schedule
<img width="200" alt="Screen Shot 2023-04-19 at 6 17 35 PM"
src="https://user-images.githubusercontent.com/11356435/233211993-086ce51e-a056-407f-900b-15638238a243.png">
After
<img width="214" alt="Screen Shot 2023-04-19 at 6 44 08 PM"
src="https://user-images.githubusercontent.com/11356435/233215688-e049e2b7-6958-4376-9362-a192aa8e94db.png">

Before 4m schedule
<img width="190" alt="Screen Shot 2023-04-19 at 6 17 29 PM"
src="https://user-images.githubusercontent.com/11356435/233211995-6b7b2927-6851-4947-ab8c-7fb041da03e1.png">
After
<img width="208" alt="Screen Shot 2023-04-19 at 6 44 30 PM"
src="https://user-images.githubusercontent.com/11356435/233215685-89f093e6-3308-4103-9b98-5acb7a9b5a0a.png">

Before 8m schedule
<img width="202" alt="Screen Shot 2023-04-19 at 6 17 23 PM"
src="https://user-images.githubusercontent.com/11356435/233211997-9a60c54c-4867-4ccd-a8eb-5b62d59060bf.png">
After
<img width="201" alt="Screen Shot 2023-04-19 at 6 44 22 PM"
src="https://user-images.githubusercontent.com/11356435/233215687-f3a900cf-b3ec-44f5-b84b-d292dbad623d.png">

Before 2m schedule
<img width="193" alt="Screen Shot 2023-04-19 at 6 17 16 PM"
src="https://user-images.githubusercontent.com/11356435/233211999-3d42ad71-b72b-4876-911e-5d79564f2351.png">
After 
<img width="194" alt="Screen Shot 2023-04-19 at 6 43 55 PM"
src="https://user-images.githubusercontent.com/11356435/233215690-fd3f13dc-5e32-4904-b804-cbcfcabf0760.png">

Throttling migration
---
Before throttling: false
<img width="163" alt="Screen Shot 2023-04-19 at 6 17 00 PM"
src="https://user-images.githubusercontent.com/11356435/233212002-3a891b25-fc2e-4cce-a730-abf8695d5423.png">
After
<img width="185" alt="Screen Shot 2023-04-19 at 6 49 50 PM"
src="https://user-images.githubusercontent.com/11356435/233216370-eed97645-26e8-44f2-8f72-8d1e19f39c35.png">

Before custom throttling
<img width="274" alt="Screen Shot 2023-04-19 at 6 16 54 PM"
src="https://user-images.githubusercontent.com/11356435/233212004-a9fe82fc-d23a-4d54-a5ad-20971c3df211.png">
After
<img width="169" alt="Screen Shot 2023-04-19 at 6 49 44 PM"
src="https://user-images.githubusercontent.com/11356435/233216389-f2803ca9-3429-4f85-b1ee-0f5a8e02db92.png">

Before default throttling
<img width="212" alt="Screen Shot 2023-04-19 at 6 16 48 PM"
src="https://user-images.githubusercontent.com/11356435/233212007-d9fbcae7-6f6e-4cd0-b909-629cfc72b7dc.png">
After
<img width="181" alt="Screen Shot 2023-04-19 at 6 49 35 PM"
src="https://user-images.githubusercontent.com/11356435/233216412-70336d0e-1e45-4809-bd92-c4524a144b99.png">


### Testing

1. Check out the 8.7.0 branch
2. Create a Synthetics private location at
`app/synthetics/settings/private-locations`.
3. Create a monitor, configured at that private location, with invalid
schedules, ideally 1 or each type (http, icmp, browser, tcp) with an
invalid schedule (for example, 2, 8, 11, 16, 333, etc) at
`app/uptime/add-monitor`. Note: you must use Uptime to create monitors
with arbitrary schedules. The Synthetics app will not let you.
4. Create a browser monitor, configured with your private location, with
throttling turned off.
5. Create a browser monitor, configured for your private location, with
a custom throttling profile.
6. Check out this PR and wait for saved object migration to run
7. Navigate to the agent policy for your monitor. Confirm the schedules
were updated to supported schedules. Confirm the throttling configs now
appear in yaml. Confirm that `throttling: false` remains for the
throttling config that was turned off.
2023-04-21 09:55:38 -04:00
Ignacio Rivas
3c21b451b3
[Ingest Pipelines] Add attachment processor (#155226) 2023-04-21 15:47:28 +02:00
Saarika Bhasi
d32c867417
[Enterprise Search][Search Application] Update engines to be search application (#155299)
## Summary

* Update 'engines' to be 'Search Application' in UI 
* Navigate to Search application from indices page rather than app search engine
* Pre-select index and open Create Search Application Flyout when navigated from Index page




https://user-images.githubusercontent.com/55930906/233170965-318cdc63-2953-45f8-89d3-b3f15f11ab11.mov





### Checklist

Delete any items that are not applicable to this PR.

- [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/packages/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
2023-04-21 09:24:02 -04:00
Jill Guyonnet
b97b18eecd
[Fleet] Add raw status to Agent details UI (#154826)
## Summary

Make raw agent status discoverable in Fleet UI, under `Agent details`
tab.

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

### Screenshots

<img width="1918" alt="Screenshot 2023-04-19 at 12 14 48"
src="https://user-images.githubusercontent.com/23701614/233059955-7f066ad5-39cd-4685-b76b-41bc31ede4e8.png">
<img width="1918" alt="Screenshot 2023-04-19 at 13 04 06"
src="https://user-images.githubusercontent.com/23701614/233059973-3f1b507f-d0bf-48ab-929b-c567f9814377.png">

### UX checklist

- [ ] Action link title (`View agent JSON`)
- [ ] Flyout title (`{agentName} agent details`)
- [ ] Download button
- [ ] Download button label (`Download JSON`)
- [ ] Downloaded file name (`{agentName}-agent-details.json`)

### Testing steps

1. Run Kibana in dev on this branch.
2. In Fleet, click on an agent to get to the agent details page.
3. There should be a new `View agent JSON` item in the `Actions` menu.
Click it.
4. A new flyout should open with the agent details in JSON format.
Clicking outside of the flyout or on the `Close` button should close the
flyout.
5. The `Download JSON` button should download the JSON correctly.

### 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/packages/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
- [ ] Any UI touched in this PR is usable by keyboard only (learn more
about [keyboard accessibility](https://webaim.org/techniques/keyboard/))
- [ ] Any UI touched in this PR does not create any new axe failures
(run axe in browser:
[FF](https://addons.mozilla.org/en-US/firefox/addon/axe-devtools/),
[Chrome](https://chrome.google.com/webstore/detail/axe-web-accessibility-tes/lhdoppojpmngadmnindnejefpokejbdd?hl=en-US))
- [ ] This renders correctly on smaller devices using a responsive
layout. (You can test this [in your
browser](https://www.browserstack.com/guide/responsive-testing-on-local-server))
- [ ] This was checked for [cross-browser
compatibility](https://www.elastic.co/support/matrix#matrix_browsers)

---------

Co-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>
2023-04-21 15:19:38 +02:00