Commit graph

67455 commits

Author SHA1 Message Date
Dzmitry Lemechko
c48cc24617
[kbn/journeys] fixes to run journeys against ESS cluster (#166923)
## Summary

I had to change `waitForRender` since `page.waitForFunction` tries to
run a script on page and it is not working due to CSP settings on Cloud.
Instead of injecting a script, we use a classical API to find
elements/attributes in the DOM.

Since `PUT /internal/core/_settings` is merged in 8.11.0, journeys run
on Cloud with on-fly labels update is supported starting deployments
8.11.0+. I added error message for 404 code just in case someone runs it
on earlier version.

`many_fields_discover` journey was update since on Cloud the data view
used by scenario is not selected by default.

How it works:

Create a deployment with QAF and re-configure it for journey run:
```
export EC_DEPLOYMENT_NAME=my-run-8.11
qaf elastic-cloud deployments create --stack-version 8.11.0-SNAPSHOT --environment staging --region gcp-us-central1
qaf elastic-cloud deployments configure-for-performance-journeys
```

Run any journey, e.g. many_fields_discover
```
TEST_CLOUD=1 TEST_ES_URL=https://username:pswd@es_url:443 TEST_KIBANA_URL=https://username:pswd@kibana-ur_url node scripts/functional_test_runner --config x-pack/performance/journeys/many_fields_discover.ts
```

You should see a log about labels being updated:

```
Updating telemetry & APM labels: {"testJobId":"local-a3272047-6724-44d1-9a61-5c79781b06a1","testBuildId":"local-d8edbace-f441-4ba9-ac83-5909be3acf2a","journeyName":"many_fields_discover","ftrConfig":"x-pack/performance/journeys/many_fields_discover.ts"}
```

And then able to find APM logs for the journey in
[Ops](https://kibana-ops-e2e-perf.kb.us-central1.gcp.cloud.es.io:9243/app/apm/services?comparisonEnabled=true&environment=ENVIRONMENT_ALL&kuery=labels.testJobId%20%3A%20%22local-d79a878c-cc7a-423b-b884-c9b6b1a8d781%22&latencyAggregationType=avg&offset=1d&rangeFrom=now-24h%2Fh&rangeTo=now&serviceGroup=&transactionType=request)
cluster
2023-09-28 12:06:00 +02:00
Stavros Kroustouris
fdf0ab763b
Change GPCTL dashboard link (#167466) 2023-09-28 11:54:36 +02:00
Walter Rafelsberger
adc9ab9c52
[ML] AIOps: Enable event_generating_elements_should_be_instrumented eslint rule. (#167317)
Implements #153108.

This enables the
`@kbn/telemetry/event_generating_elements_should_be_instrumented` eslint
rule for the `aiops` plugin to enforce `data-test-subj` attributes on
actionable EUI components so they are auto-instrumented by telemetry.

The ids were first auto-created using `node scripts/eslint --fix
x-pack/plugins/aiops` and then adapted.
2023-09-28 11:49:13 +02:00
Carlos Crespo
8a2701cf21
[Type Check] Add newly included AlertStatus item to the infra tests (#167470)
## Summary

This PR fix type check problems caused by the inclusion of a new item in
the AlertStatus union type
2023-09-28 11:12:46 +02:00
Dzmitry Lemechko
2eddd54cdd
[ftr] pass password for UI login + improve login/logout steps with proper wait logic (#166936)
## Summary

Hopefully

closes #167104
closes #167130
closes #167100 
closes #167013
closes #166964

Fixing a few issues with login/logout:

1. Failed to login in "before" hook
<img width="1336" alt="Screenshot 2023-09-25 at 12 37 45"
src="e3b2830e-7b0d-4467-9b90-261b385bf71e">

My theory is that we are loading `/login` route too soon while log out
was not completed yet.
When we navigate to `https://localhost:5620/logout` there are multiple
url re-directions with final page being Cloud login form. This PR makes
sure we wait for this form to be displayed + 2500 ms extra to avoid
"immediate" /login navigation

2. Failed login on MKI:
Updating login via UI for serverless to pass password valid for
deployment: currently FTR uses `changeme` for both Kibana CI & MKI.

3. ES activate user profile call returning 500
We saw some login failures that are preceded with the following logs:
```
[00:03:27]           │ debg Find.clickByCssSelector('[data-test-subj="loginSubmit"]') with timeout=10000
[00:03:27]           │ debg Find.findByCssSelector('[data-test-subj="loginSubmit"]') with timeout=10000
[00:03:27]           │ debg Find.waitForDeletedByCssSelector('.kibanaWelcomeLogo') with timeout=10000
[00:03:27]           │ proc [kibana] [2023-09-19T07:08:26.126+00:00][INFO ][plugins.security.routes] Logging in with provider "basic" (basic)
[00:03:27]           │ info [o.e.x.s.s.SecurityIndexManager] [ftr] security index does not exist, creating [.security-profile-8] with alias [.security-profile]
[00:03:27]           │ proc [kibana] [2023-09-19T07:08:26.140+00:00][ERROR][plugins.security.user-profile] Failed to activate user profile: {"error":{"root_cause":[{"type":"validation_exception","reason":"Validation Failed: 1: this action would add [1] shards, but this cluster currently has [27]/[27] maximum normal shards open;"}],"type":"validation_exception","reason":"Validation Failed: 1: this action would add [1] shards, but this cluster currently has [27]/[27] maximum normal shards open;"},"status":400}.
[00:03:27]           │ proc [kibana] [2023-09-19T07:08:26.140+00:00][ERROR][http] 500 Server Error
[00:03:27]           │ warn browser[SEVERE] http://localhost:5620/internal/security/login - Failed to load resource: the server responded with a status of 500 (Internal Server Error)
```

User activation happens during `POST internal/security/login` call to
Kibana server. ~~The only improvement that we can do from FTR
perspective is to call this end-point via API to makes sure user is
activated and only after proceed with UI login.~~
While working on issue #4 and talking to @jeramysoucy I believe retrying
login via UI will work here as well. We are checking if we are still on
login page (similar to incorrect password login), waiting 2500 ms and
pressing login button again.

4. Failed to login with Kibana reporting UNEXPECTED_SESSION_ERROR and
been re-directed to Cloud login page
```
proc [kibana] [2023-09-25T11:35:12.794+00:00][INFO ][plugins.security.authentication] Authentication attempt failed: UNEXPECTED_SESSION_ERROR
```

Temporary solution is to retry login from scratch (navigation to Kibana
login page & re-login )



Flaky-test-runner for functional obtl tests 50x
https://buildkite.com/elastic/kibana-flaky-test-suite-runner/builds/3215


This PR is not fixing random 401 response when user navigates to some
apps with direct url

---------

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2023-09-28 11:00:22 +02:00
Walter Rafelsberger
0d97cc71fc
[ML] AIOps: Move log pattern analysis fetch code to common to be available via server (#167465)
Follow up to #167237.
Part of #167467.

We plan to reuse some of the queries log pattern analysis does to use
via log rate analysis too. Log pattern analysis mostly does queries from
the client side, late rate analysis has its own API endpoint and does ES
queries via Kibana server. In preparation for the use via log rate
analysis, this moves the code we need to have available server side for
log rate analysis to the `common` area of the plugin so it can be used
both on server/client.
2023-09-28 11:00:05 +02:00
Jordan
df9fd9d030
[Cloud Security] Azure support for dashboard and flyout and PLG for dashboard (#167422) 2023-09-28 11:33:24 +03:00
Panagiota Mitsopoulou
ba31c76f31
[AO] use toMountPoint from react-kibana-mount for header menu portal (#167126)
Fixes https://github.com/elastic/kibana/issues/164366

### Acceptance Criteria
- use `toMountPoint` from `@kbn/react-kibana-mount` for
[kibana/x-pack/plugins/observability/public/pages/overview/components/header_menu/header_menu_portal.tsx](fcf838e1f3/x-pack/plugins/observability/public/pages/overview/components/header_menu/header_menu_portal.tsx (L10))

---------

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2023-09-28 07:22:51 +02:00
Kibana Machine
8e6101e752
[api-docs] 2023-09-28 Daily api_docs build (#167461)
Generated by
https://buildkite.com/elastic/kibana-api-docs-daily/builds/474
2023-09-28 00:43:37 -04:00
Davis McPhee
3e1865513d
[Discover] Add resize support to the Discover field list sidebar (#167066)
## Summary

This PR adds resize support to the Discover field list sidebar, which is
persisted to a user's local storage similar to the resizable chart
height.

Additionally it migrates the resizable layout code from Unified
Histogram to a new package called `kbn-resizable-layout` so it can be
shared between Discover and Unified Histogram, as well as act as a new
platform component that other teams can consume to create their own
resizable layouts.


![resize](71b9a0ae-1795-43c8-acb0-e75fe46e2a8a)

Resolves #9531.

### Checklist

- [ ] ~Any text added follows [EUI's writing
guidelines](https://elastic.github.io/eui/#/guidelines/writing), uses
sentence case text and includes [i18n
support](https://github.com/elastic/kibana/blob/main/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
- [x] 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)~
- [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))
- [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)

---------

Co-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>
2023-09-27 21:52:25 -03:00
Jon
272219ca49
[fleet] Fix key path (#167448)
In https://github.com/elastic/kibana/pull/167148 the filename was
updated. This updates the file read path in the fleet plugin.


Fixes `proc [kibana] [2023-09-27T18:12:07.561+00:00][WARN
][plugins.fleet] Unable to retrieve GPG key from
'/var/lib/buildkite-agent/builds/kb-n2-4-spot-e622c074d3147d71/elastic/kibana-on-merge/kibana-build-xpack/node_modules/@kbn/fleet-plugin/target/keys/GPG-KEY-elasticsearch':
ENOENT`
2023-09-27 19:00:28 -04:00
Kibana Machine
8838ac1d18 skip failing test suite (#167405) 2023-09-27 18:47:11 -04:00
Steph Milovic
bacebd27e0
[Security solution] AWS Bedrock connector (#166662) 2023-09-27 16:44:52 -06:00
Zacqary Adam Xeper
107239c333
[RAM] Mark disabled alerts as Untracked in both Stack and o11y (#164788)
## Summary
Part of #164059 

Implements the `Untracked` lifecycle status, and applies it to alerts
when their corresponding rule is disabled.

<img width="1034" alt="Screenshot 2023-08-24 at 4 24 45 PM"
src="4d31545d-9fc0-4eb3-9972-72685107184d">
<img width="904" alt="Screenshot 2023-08-24 at 4 56 32 PM"
src="3d7cfa19-5aca-4148-a9bc-d0d0c949d84b">
<img width="820" alt="Screenshot 2023-08-24 at 4 56 17 PM"
src="e59870c8-4140-4588-893a-f3f54170f78a">


### 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-09-27 15:28:03 -07:00
Luke G
4fc3a43f79
[Security Solution] Bad user experience when hovering some icons on n… (#167300) 2023-09-27 17:04:35 -05:00
Philippe Oberti
90a8b32393
[Security Solution] expandable flyout - fix footer not always visible (#167074) 2023-09-27 17:01:28 -05:00
Kevin Lacabane
c84248c87d
[asset manager] use metrics data plugin (#166756)
## Summary

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

- use metrics_data_access plugin to dynamically retrieve indices where
needed
- add basic `/assets/hosts` api test

---------

Co-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>
Co-authored-by: Jason Rhodes <jason.rhodes@elastic.co>
2023-09-27 14:56:42 -07:00
Ying Mao
02b7c96247
[Response Ops][Alerting] Using refresh=true instead of refresh='wait_for' when writing alerts (#166296)
Resolves https://github.com/elastic/kibana/issues/163953

## Summary

Changes `refresh='wait_for'` to `refresh=true` when bulk indexing alerts
from the alerting framework and the rule registry. For persistence
alerts, `refresh=false` is used when the rule execution is a preview.

## Notes

I deployed this image to the serverless QA environment and compared
execution times between this branch and the default QA version with an
index threshold rule that creates and active alert each run.

Default QA version:
* avg 8.16 seconds
* P99 15.5 seconds

QA using this image:
* avg: 0.6 seconds
* P99 1.7 seconds

---------

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
Co-authored-by: Ryland Herrick <ryalnd@gmail.com>
2023-09-27 17:32:26 -04:00
christineweng
ac2d3db3ff
[Security Solution] fix change alert status flaky tests (#166538)
## Summary

This PR unskips and fixes some cypress test related to changing alert
status per https://github.com/elastic/kibana/issues/166415
2023-09-27 16:31:12 -05:00
Tim Sullivan
0c680d7783
Project Side Navigation: Use EuiCollapsibleNavBeta component (#164910)
## Summary

Closes https://github.com/elastic/kibana/issues/162507
Relates to https://github.com/elastic/kibana/issues/166545
^ additional IA-related tasks - related to the alignment discussions -
can be found here

## Work for next steps
In this PR, some work items are being saved for a next PR:
1. _Only affects Search solution_: Navigation "group titles" do not
create a breadcrumb item, as sub-items in the group are not
hierarchically under the title. To address this, group titles may be
going away from the design.
https://github.com/elastic/kibana/issues/167323
2. _Only affects Observability solution_: Navigation accordions can not
be collapsed and do not show arrow icons. To address this, in a later PR
we will add internal state management for the open/closed state of each
accordion. https://github.com/elastic/kibana/issues/167328
3. _Affects all solutions:_ The "collapsed" state of the side nav should
show a docked view with icons-only. To address this, in later PRs we
will bring Security solution into the unified nav components.
4. https://github.com/elastic/kibana/issues/167326
5. https://github.com/elastic/kibana/issues/167330
6. https://github.com/elastic/kibana/issues/167332

### Recordings
These videos show a before-and-after with the new UI. 
| project | old | new |
|--|--|--|
|observability|
663765a3-4e4b-416e-b7d5-7d87eece83e8
| <img width="298" alt="CleanShot 2023-09-22 at 14 20 48@2x"
src="d61f6fe0-a6a9-4806-bc27-08b0ff2afb49">
|
|search|
f383773e-27a8-4485-8289-274d8231b960
| <img width="281" alt="CleanShot 2023-09-22 at 14 18 43@2x"
src="901b8fc1-9945-4cee-b566-5e4539f08043">
|
|security|
481f4533-64e5-41db-bc8e-5012f82c188a
| *will change to the new style after this PR and the flyout/panel
support are completed |

### 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
- [ ] 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: Sébastien Loix <sebastien.loix@elastic.co>
2023-09-27 14:22:46 -07:00
Jonathan Budzenski
9fba1e3f24 fix type import 2023-09-27 15:37:16 -05:00
Philippe Oberti
af51e26333
[Security Solution] expandable flyout - fix prevalence query not taking into account fields with multiple values (#166891) 2023-09-27 15:26:36 -05:00
christineweng
7b4e6a6775
[Security Solution] Expandable flyout - clean up loading states and no data messages (#166939)
## Summary

This PR cleaned up the loading and empty state of most components in the
new expandable alerts flyout:

1) Refactor `FlyoutLoading` component to be used across components
2) Updated unit tests to explicitly check no data messages
3) Changed loading spinner in smaller components to be skeleton text
4) Moved error/no data message to table
5) Added loading and/or error messages for:
1) Right panel -> about -> Rule description, note that rule preview is
disabled if no rule is found

![image](11cb7926-ff86-4deb-a9d1-993463fad466)

2) Right panel -> about -> Alert reason, note that the alert reason
preview is disabled if no reason available

![image](9674d81a-ca8b-4fea-981a-23c2cf3f3bfc)

   3) Right panel -> Investigation -> Highlighted fields

![image](d349251a-a027-409d-b94d-2792abe6543c)

   4) Right panel -> Insights -> host and user preview

![image](161340aa-4ca1-4205-9628-87206743f776)

5) Right panel -> Visualization -> analyzer preview (to match error in
analyzer graph)

![image](73b0018d-1f97-4fa3-be4d-b55afeb047b7)

6) Right panel -> About -> show rule summary & show alert reason when
there is an error
- Very uncommon because the button should be disabled if data is not
available, adding as fall back

![image](5088e9f8-bdd1-4e61-8878-dba756b44c32)



### 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-09-27 13:19:25 -07:00
mohamedhamed-ahmed
bb5439f4e1
[Log Explorer] Show Filter controls in compressed style (#167402)
closes https://github.com/elastic/kibana/issues/166440

This PR applies compressed style to the control group container.

<img width="699" alt="Screenshot 2023-09-27 at 14 44 51"
src="7318c0aa-c00e-44e9-9d29-f2f0deb5b791">
2023-09-27 22:18:13 +02:00
Brad White
f9c26208b7
Fix some type issues in x-pack/test (#167343)
## Summary

We're breaking #166813 up into smaller PRs in the interest of getting
PRs through sooner for type fixes. These are the changes for
`x-pack/test`.

---------

Co-authored-by: Thomas Watson <watson@elastic.co>
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
Co-authored-by: Alex Szabo <alex.szabo@elastic.co>
2023-09-27 13:14:01 -07:00
Mashhur
fb13b2181d
Migrate deprecated components in Logstash pipelines section. (#161512)
## Summary

Migrates the deprecated components in Logstash pipelines view based on
[the gude](https://elastic.github.io/eui/#/layout/page-components).
A list of deprecated components in Logstash pipelines can be found
[here](https://github.com/search?q=repo%3Aelastic%2Fkibana+%2FEuiPage%5Ba-zA-Z%5D%2B_Deprecated%2F+path%3A%2F%5Ex-pack%5C%2Fplugins%5C%2Flogstash%2F&type=code).

### Tests
Opened a dev tools and proceeded manual tests on local dev env (based on
[local env setup
guide](https://docs.elastic.dev/kibana-dev-docs/getting-started/setup-dev-env)):
- create pipeline(s)
- check list of pipeline(s)
- delete pipeline(s)
- check alerts when deleting the pipeline
- check Elasticsearch .logstash_pipelines index (`GET
_logstash/pipeline`) to check the data shape which Logstash polls and
uses.


- Closes: #161417 

### 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
~~- [ ] 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))
~~- [ ] If a plugin configuration key changed, check if it needs to be
allowlisted in the cloud and added to the [docker
list](https://github.com/elastic/kibana/blob/main/src/dev/build/tasks/os_packages/docker_generator/resources/base/bin/kibana-docker)~~
- [x] This 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))
- [x] 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)

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2023-09-27 13:44:32 -06:00
Jordan
594cb14a28
[Cloud Security] Azure - AMR Template form (#166910) 2023-09-27 22:35:03 +03:00
Aurélien FOUCRET
f3f1eec08e
Update content indices pipeline management UI with ELSER v2 (wording) (#167401) 2023-09-27 12:11:46 -07:00
Jonathan Budzenski
dac98ef60a skip failing test suite (#166190) 2023-09-27 13:46:47 -05:00
Yulia Čech
e1b37a6aa3
[Index Management] Implement index details page (#165705)
## Summary
This PR removes the feature flag and enables the new index details page
by default. The index details page was implemented in following PRs:
- https://github.com/elastic/kibana/pull/163521
- https://github.com/elastic/kibana/pull/163955
- https://github.com/elastic/kibana/pull/164741
- https://github.com/elastic/kibana/pull/165027
- https://github.com/elastic/kibana/pull/165038
- https://github.com/elastic/kibana/pull/165456

In this PR we completely remove now obsolete code for the old index
details flyout: react components and corresponding redux code. All
related tests are updated and cleaned up. The config value for Index
Management plugin `xpack.index_management.dev.enableIndexDetailsPage` is
deprecated as unused and can be removed in v9.0.


### How to test
1. Start ES and Kibana with `yarn es snapshot` and `yarn start`
3. Navigate to Index Management and create an index
4. Click the index name in the table and check the tabs of the details
page
### Screenshots
#### Stateful
Overview 
<img width="1387" alt="Screenshot 2023-09-27 at 14 41 57"
src="e58b15e7-d10c-4473-873c-d0f128392404">


Mappings
<img width="1392" alt="Screenshot 2023-09-27 at 14 42 05"
src="441157cb-5a26-47c3-8da0-b4df51ebec5d">


Settings 
<img width="1385" alt="Screenshot 2023-09-27 at 14 42 13"
src="da66a2eb-1f21-44c1-9356-484c66caab88">


Statistics
<img width="1380" alt="Screenshot 2023-09-27 at 14 42 22"
src="ec93d85c-e754-4c21-88ab-0124dc114fc9">


Error loading data
<img width="1333" alt="Screenshot 2023-09-26 at 19 05 37"
src="fc1804b3-6aa0-4019-bae6-e7bb40113b28">
<img width="1327" alt="Screenshot 2023-09-26 at 19 06 07"
src="ca711697-cc74-4ba8-b17c-ec9b01f3026e">
<img width="1329" alt="Screenshot 2023-09-26 at 19 06 28"
src="0cb46b09-8542-452a-8845-40d060057e95">
<img width="1331" alt="Screenshot 2023-09-26 at 19 06 48"
src="87de8d3d-b6e5-4e8f-b27c-18a1c6e950d8">


Error saving index settings
<img width="1332" alt="Screenshot 2023-09-26 at 19 07 31"
src="e6e4b3d0-c237-4d0a-995a-4562bc78f88e">


### Serverless
Overview 
<img width="1336" alt="Screenshot 2023-09-26 at 19 51 47"
src="6c76c23b-4be6-4ab3-ae1d-c7ae751e100d">


Mappings
<img width="1336" alt="Screenshot 2023-09-26 at 19 23 51"
src="625fa703-506f-4389-9df0-86441a655074">


Settings
<img width="1332" alt="Screenshot 2023-09-26 at 19 24 02"
src="c496ab09-f2db-4c1b-9fb6-1e9b64b1c142">


# Release note
Index details can now be viewed on a new index details page in Index
Management.
<img width="1387" alt="Screenshot 2023-09-27 at 14 41 57"
src="b90c706d-8b15-49e4-8f6a-cb66f3ed1822">

---------

Co-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>
2023-09-27 11:22:26 -07:00
Kibana Machine
e70181aea5 skip failing test suite (#167188) 2023-09-27 14:17:44 -04:00
Konrad Szwarc
7b85eb2137
[EDR Workflows] Onboarding Update to Skip Integrations Page (#167393)
https://github.com/elastic/security-team/issues/7588

To meet the above requirements, I believe it is sufficient to replace
only the URL with one that directly points to the security integration
instead of the integrations list. This change does not appear to affect
the flow of guided onboarding in any way.


4d1aa943-2dce-4d43-bab1-d7cc024695f8
2023-09-27 20:17:25 +02:00
Paul Tavares
45a28d40e3
[kbn/es serverless] Allow ES serverless resources (ex. users, users_roles, etc) to be overwritten via yarn es serverless command (#167087)
## Summary

### `@kbn/es` package
- Introduces `--resources` option to the `es serverless` command
- Allows for
[`serverless_resources`](https://github.com/elastic/kibana/tree/main/packages/kbn-es/src/serverless_resources)
to be overwritten
 
### Security Solution Plugin

- Added customized `users`, `users_roles` and `roles.yml` files that
includes:
    - Updated `roles.yml` file (sync'ed with project controller version)
- Updated `users` / `users_roles` file that includes one one per
security project role (name the same as the role)
- New CLI script - `node
x-pack/plugins/security_solution/scripts/endpoint/start_es_serverless_with_security_users.js`
- that will start ES in serverless mode and inject the customized
`--resources` into the command
- Any existing option that can be passed to `es` or `es serverless` can
still continue to be passed to this new script. I will pass them along.


closes #167092

__
2023-09-27 11:11:01 -07:00
Cee Chen
581b30b743
Upgrade EUI to v88.5.0 (#166868)
`v88.3.0``v88.5.0`

closes #151514

---

## [`88.5.0`](https://github.com/elastic/eui/tree/v88.5.0)

- Updated `EuiCallOut` with a new `onDismiss` prop
([#7156](https://github.com/elastic/eui/pull/7156))
- Added a new `renderCustomToolbar` prop to `EuiDataGrid`, which allows
custom rendering of the toolbar.
([#7190](https://github.com/elastic/eui/pull/7190))
- Added a new `allowResetButton` prop to
`toolbarVisibility.showDisplaySelector` of `EuiDataGrid`, which allows
hiding the "Reset to default" button from the display settings popover.
([#7190](https://github.com/elastic/eui/pull/7190))
- Added a new `additionalDisplaySettings` prop to
`toolbarVisibility.showDisplaySelector` of `EuiDataGrid`, which allows
rendering extra settings inside the display settings popover.
([#7190](https://github.com/elastic/eui/pull/7190))
- Updated `EuiDataGrid`'s toolbar display settings button icon
([#7190](https://github.com/elastic/eui/pull/7190))
- Updated `EuiTextTruncate` with significantly improved iteration
performance. Removed `measurementRenderAPI` prop, as `EuiTextTruncation`
now only uses more performant canvas render API
([#7210](https://github.com/elastic/eui/pull/7210))
- Updated `EuiPopover` with a new configurable `repositionToCrossAxis`
prop ([#7211](https://github.com/elastic/eui/pull/7211))
- Updated `EuiDatePicker` to support `compressed` input styling
([#7218](https://github.com/elastic/eui/pull/7218))
- Added `gradient` and `palette` icon glyphs.
([#7220](https://github.com/elastic/eui/pull/7220))

**Bug fixes**

- Fixed `EuiPopover`'s missing animations on popover close
([#7211](https://github.com/elastic/eui/pull/7211))
- Fixed `EuiInputPopover` anchoring to the wrong side and missing
shadows on smaller screens
([#7211](https://github.com/elastic/eui/pull/7211))
- Fixed `EuiSuperDatePicker` icon spacing on the quick select button
([#7217](https://github.com/elastic/eui/pull/7217))
- Fixed a missing type in `EuiMarkdownEditor`'s default processing
plugins ([#7221](https://github.com/elastic/eui/pull/7221))


## [`88.4.1`](https://github.com/elastic/eui/tree/v88.4.1)

**Bug fixes**

- Fixed missing `className`s on `EuiTextTruncate`
([#7212](https://github.com/elastic/eui/pull/7212))
- Fixed `title`s on `EuiComboBox` dropdown options to always be present
([#7212](https://github.com/elastic/eui/pull/7212))
- Fixed `EuiComboBox` truncation issues when search is an empty space
([#7212](https://github.com/elastic/eui/pull/7212))

## [`88.4.0`](https://github.com/elastic/eui/tree/v88.4.0)

- Updated `EuiComboBox` to allow configuring text truncation behavior
via `truncationProps`. These props can be set on the entire combobox as
well as on on individual dropdown options.
([#7028](https://github.com/elastic/eui/pull/7028))
- Updated `EuiInMemoryTable` with a new `searchFormat` prop (defaults to
`eql`). When setting this prop to `text`, the built-in search bar will
ignore EQL syntax and allow searching for plain strings with special
characters and symbols.
([#7175](https://github.com/elastic/eui/pull/7175))

**Bug fixes**

- `EuiComboBox` now always shows the highlighted search text, even on
truncated text ([#7028](https://github.com/elastic/eui/pull/7028))
- Fixed missing i18n in `EuiSearchBar`'s default placeholder and
aria-label text ([#7175](https://github.com/elastic/eui/pull/7175))
- Fixed the inline compressed styles of `EuiDescriptionListTitle` to use
a taller line-height for readability
([#7185](https://github.com/elastic/eui/pull/7185))
- Fixed `EuiComboBox` to correctly truncate selected items when
displayed as pills and plain text
([#7193](https://github.com/elastic/eui/pull/7193))

**Accessibility**

- Added `aria-current` attribute to `EuiTablePagination`
([#7186](https://github.com/elastic/eui/pull/7186))

**CSS-in-JS conversions**

- Converted `EuiDroppable` and `EuiDraggable` to Emotion; Removed
`$euiDragAndDropSpacing` Sass variables
([#7187](https://github.com/elastic/eui/pull/7187))

---------

Co-authored-by: Patryk Kopycinski <contact@patrykkopycinski.com>
Co-authored-by: Jan Monschke <jan.monschke@elastic.co>
Co-authored-by: Thomas Watson <watson@elastic.co>
2023-09-27 13:04:45 -05:00
James Gowdy
354efc2fc8
[ML] Retain created_by setting when exporting anomaly detection jobs (#167319)
When exporting an anomaly detection job, it would be useful if the
original `created_by` property was not removed from the job config.


Related to
https://github.com/elastic/kibana/pull/167021#discussion_r1337007611
Related PR https://github.com/elastic/kibana/pull/88898
2023-09-27 18:45:36 +01:00
James Gowdy
55a86ba120
[ML] Changing wording of awaiting ML nodes messages (#167306)
Updates the text for the info callouts which are displayed when anomaly
detection jobs are waiting for a node.

@szabosteve would you mind having a review of the text?

**Jobs list**

![image](2f5e9293-7834-483f-9898-e797150963f8)



**Creating a new job**

![image](dcf594e4-67a1-4b96-95d7-bc832b77b1af)

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

---------

Co-authored-by: István Zoltán Szabó <istvan.szabo@elastic.co>
2023-09-27 18:45:18 +01:00
Kerry Gallagher
b2271a9fd7
[Logs+] Remove configurable redirects to Discover (#167151)
## Summary

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

Removes configurable app targets. Only the standard logs app is
registered (Note: [Infra is disabled in
serverless](https://github.com/elastic/kibana/pull/165289) observability
/ security projects currently).

---------

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2023-09-27 18:02:37 +01:00
Walter Rafelsberger
1b9993eb07
[ML] Move chi2test to package (#167237)
The `chi2test` utils so fare were only used within data comparison view.
We plan to use it with other plugins, so moving it so a separate package
in this PR. `SIGNIFICANCE_LEVELS` was updated to include some more
digits.
2023-09-27 18:43:27 +02:00
Stratoula Kalafateli
93fc80704a
[ES|QL] Do not allow saving in library action on text based panels (#167111)
## Summary

Save to library action should not be present in ES|QL panels. For now we
only allow by value embeddables and we don't want them to be
edited/created in Lens editor

<img width="915" alt="image"
src="d6e5e8a7-459f-4b1d-8461-2863b45db882">


### 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
2023-09-27 09:08:16 -07:00
Kibana Machine
7013a9b750 skip failing test suite (#167320) 2023-09-27 10:38:57 -04:00
Jonathan Budzenski
ecd1cb110f skip failing test suite (#156245) 2023-09-27 08:50:09 -05:00
Maxim Kholod
e801e76643
[Cloud Security] add unit tests for createBenchmarkScoreIndex func (#167121)
## Summary

a follow-up for https://github.com/elastic/kibana/pull/166966 to add
unit tests
2023-09-27 15:44:42 +02:00
Alex Szabo
07570c6847
Fix typescript errors in osquery cypress tsconfig (#167369)
## Summary
Supposedly, this is the error that's causing these type of errors:/
```
Cannot write file '/Users/alex/Git/kibana/x-pack/test/functional/services/random.js' because it would overwrite input file.
```

Separated off from: https://github.com/elastic/kibana/pull/167355

Co-authored-by: Thomas Watson <watson@elastic.co>
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2023-09-27 15:24:36 +02:00
Brad White
563292f0e0
Fix some type issues in x-pack/test_serverless (#167346)
## Summary

We're breaking #166813 up into smaller PRs in the interest of getting
PRs through sooner for type fixes. These are the changes for
`x-pack/test_serverless`.

## Reviewers
There are no code owners for these files, so I'm using the recently
edited suggestions

---------

Co-authored-by: Alex Szabo <delanni.alex@gmail.com>
Co-authored-by: Thomas Watson <w@tson.dk>
Co-authored-by: Alex Szabo <alex.szabo@elastic.co>
Co-authored-by: Thomas Watson <watson@elastic.co>
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2023-09-27 15:22:34 +02:00
Alex Szabo
c666e4d29e
chore(typecheck): clean up unused parameter (#167396)
## Summary
This unused parameter is causing typescript error in many builds:

https://buildkite.com/elastic/kibana-pull-request/builds/162839#018ad64e-f2db-4572-a2df-2a9257777077
```
proc [tsc] x-pack/plugins/transform/public/app/sections/create_transform/components/step_define/step_define_form.tsx:358:19 - error TS2322: Type '{ frozenDataPreference: FrozenTierPreference; setFrozenDataPreference: (value: FrozenTierPreference \| undefined) => void; dataView: DataView; query: undefined; disabled: false; timefilter: TimefilterContract; hideFrozenDataTierChoice: boolean; }' is not assignable to type 'IntrinsicAttributes & FullTimeRangeSelectorProps & { children?: ReactNode; }'.
--
  | proc [tsc]   Property 'hideFrozenDataTierChoice' does not exist on type 'IntrinsicAttributes & FullTimeRangeSelectorProps & { children?: ReactNode; }'.
  | proc [tsc]
  | proc [tsc] 358                   hideFrozenDataTierChoice={!showNodeInfo}
```
2023-09-27 06:19:30 -07:00
Alex Szabo
28fd3ff0b4
[cypress] Trim long cypress configs (#167391)
## Summary 
In cypress tests, when the logs are output in the beginning, some binary
buffers are also stringified, so when looking at logs, we have to scroll
through thousands of lines of logs, that's annoying and doesn't help
debugging.

I'd like that to be somewhat more readable, there are a few options: 
- the replacer should interpret buffers as strings, try to output it
like that
   - not every binary buffer is printable
 - the replacer should redact the exact fields (certificateAuthority?)
   - too specific, might need fixing later
 - trim long arrays after 32 items
   -  I chose this as a solution

Other suggestions are welcome.

<img width="666" alt="Screenshot 2023-09-27 at 12 49 54"
src="7d35e59d-fb14-4d2a-9225-277cc2e1519b">
2023-09-27 15:12:03 +02:00
Julia
255bf6e881
[RAM] Text not localized on rules managament table (#166700)
## Summary

Fixed issue: https://github.com/elastic/kibana/issues/165552 for all
existing locale.

Looked before:
<img width="1049" alt="Screenshot 2023-09-19 at 12 24 08"
src="540af16a-d5e9-4965-b13b-0e28733ed947">


Now looks like this:
<img width="1225" alt="Screenshot 2023-09-19 at 12 19 49"
src="58fdffdb-8516-4690-b026-d59ce02a0374">

---------

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2023-09-27 14:05:04 +02:00
Sid
de0e1eb0d4
Developer documentation for designing feature privileges (#166716)
## Summary

Closes #162263

Introduces a new `Feature Privileges` section to the developer
documentation. The documentation includes a tutorial on how to control
access to features of plugin being developed. Introduces a few sections:

- Controlling access to UI features
- Controlling access to server side APIs
- Documentation for configuration options

## Testing
To build this locally, run ./scripts/dev_docs from a local checkout of
this PR. A server will eventually start on http://localhost:3000 where
you can preview the changes.

---------

Co-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>
2023-09-27 13:43:55 +02:00
Thomas Watson
22fca89861
Improve Type Check Commit Diff script (#167381) 2023-09-27 13:20:47 +02:00
Brad White
3cec6e5ed5
Pick Platform Deployment MGMT from #166813 (#167360)
## Summary

We're breaking https://github.com/elastic/kibana/pull/166813 up into
smaller PRs in the interest of getting PRs through sooner for type
fixes. These are the changes for Platform Deployment Management.

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2023-09-27 13:17:11 +02:00