Commit graph

47738 commits

Author SHA1 Message Date
Yulia Čech 8037a1db32
[ILM] Fixed skipped a11y and functional tests (#116207) (#116618)
* [ILM] Fixed ILM a11y test by creating a snapshot repo that is now required in the ILM API

* [ILM] Fixed functional test by creating a snapshot repository

* [ILM] Updated the params after es client update

* [ILM] Added filtering by policy name to the a11y test to find the correct ILM policy in the list

* [ILM] Added filtering by policy name to the a11y test to find the correct ILM policy in the list

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-11-02 11:46:48 +01:00
Kibana Machine b979f40042
Reply with 503 to unknown API requests at the preboot stage. (#116593) (#117069)
Co-authored-by: Aleh Zasypkin <aleh.zasypkin@gmail.com>
2021-11-02 10:23:28 +00:00
Kibana Machine 0a46d03f8e
[load testing] add default package to simulation class (#116375) (#116595)
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>

Co-authored-by: Dzmitry Lemechko <dzmitry.lemechko@elastic.co>
2021-11-01 19:23:19 -06:00
Kibana Machine 7650d58e8d
e2e tests for dependencies (#116369) (#116542)
Also fix a link in testing readme.

References #116290.

Co-authored-by: Nathan L Smith <nathan.smith@elastic.co>
2021-11-01 19:22:40 -06:00
Kibana Machine 8402a88c53
adds import Timeline test (#114703) (#116655)
Co-authored-by: Gloria Hornero <snootchie.boochies@gmail.com>
2021-11-01 19:20:45 -06:00
Kibana Machine bd3ec381d9
[kbn/optimizer] dll @babel/runtime modules used by entry bundles (#113453) (#116869)
Co-authored-by: spalger <spalger@users.noreply.github.com>

Co-authored-by: Spencer <email@spalger.com>
Co-authored-by: spalger <spalger@users.noreply.github.com>
2021-11-02 01:17:15 +00:00
Kibana Machine 0980e431b6
docs: update links to apm docs (#116529) (#117051)
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>

Co-authored-by: Brandon Morelli <brandon.morelli@elastic.co>
2021-11-02 00:51:14 +00:00
Quynh Nguyen 8c7fb01947
[ML] Re-enable explorer link jest test (#116324) (#117050)
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-11-02 00:35:04 +00:00
Kibana Machine 720f879edd
[Security Solution] fix endpoint being visible after unenrolling agent (#116372) (#116516)
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>

Co-authored-by: Joey F. Poon <joey.poon@elastic.co>
2021-11-01 16:43:07 -07:00
Kibana Machine fdb83b860a
Don't show telemetry opt-in/out notice when it has been disabled via yml config. (#116867) (#117039)
Co-authored-by: Luke Elmers <luke.elmers@elastic.co>
2021-11-01 23:36:35 +00:00
Kibana Machine e414cb6b57
Upgrade to EUI v40.1.0 (#116692) (#117037)
* Upgrade EUI to v40.1.0

* [Discover] Remove temp fix + update snapshot

* Fix deprecated `popperPlacement` prop

* Update test snapshots with table cell change

Co-authored-by: Uladzislau Lasitsa <Uladzislau_Lasitsa@epam.com>
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>

Co-authored-by: Constance <constancecchen@users.noreply.github.com>
Co-authored-by: Uladzislau Lasitsa <Uladzislau_Lasitsa@epam.com>
2021-11-01 23:34:53 +00:00
Kibana Machine bd75d8047a
[ML] Fix Transforms not retaining _meta on clone (#116206) (#116598)
* [ML] Retain _meta on clone

* [ML] Fix validation on schema to only check it it's defined/not null

* [ML] Remove validation because es should handle the validation already

* Change type to unknown

Co-authored-by: Quynh Nguyen <43350163+qn895@users.noreply.github.com>
2021-11-01 18:05:35 -05:00
Kibana Machine 02faf630b0
[Fleet] Set keep_policies_up_to_date during package installation (#116993) (#117026)
* Set `keep_policies_up_to_date` during preconfiguration

Don't rely on only our 7.16 migration set this flag, ensure it gets set
to `true` for any package that appears in `DEFAULT_PACKAGES` during
preconfiguration

Closes #116982

* Move default logic to installation

* Revert conflict change in preconfiguration.ts

Co-authored-by: Kyle Pollich <kyle.pollich@elastic.co>
2021-11-01 22:31:24 +00:00
Kaarina Tungseth e49726dc6d
[DOCS] Adds the 8.0.0-beta1 release notes (#116483) (#117046)
* [DOCS] Adds the 8.0.0-beta1 release notes

* Update docs/CHANGELOG.asciidoc

Co-authored-by: Lisa Cawley <lcawley@elastic.co>

* Update docs/CHANGELOG.asciidoc

Co-authored-by: Lisa Cawley <lcawley@elastic.co>

* Vis editor changes

* [DOCS] Adds known ML issue

* [DOCS] Edits ML PRs

* [DOCS] Removes known issue

* Update docs/CHANGELOG.asciidoc

Co-authored-by: Luke Elmers <lukeelmers@gmail.com>

* Update docs/CHANGELOG.asciidoc

Co-authored-by: Luke Elmers <lukeelmers@gmail.com>

* Update docs/CHANGELOG.asciidoc

Co-authored-by: Joe Portner <5295965+jportner@users.noreply.github.com>

* Review comments

Co-authored-by: Lisa Cawley <lcawley@elastic.co>
Co-authored-by: Luke Elmers <lukeelmers@gmail.com>
Co-authored-by: Joe Portner <5295965+jportner@users.noreply.github.com>

Co-authored-by: Lisa Cawley <lcawley@elastic.co>
Co-authored-by: Luke Elmers <lukeelmers@gmail.com>
Co-authored-by: Joe Portner <5295965+jportner@users.noreply.github.com>
2021-11-01 18:08:40 -04:00
Kaarina Tungseth dd50f3cf99
[DOCS] Changes 1h to 8h for #106061 (#117043) 2021-11-01 17:06:00 -05:00
Kibana Machine bbca0e1544
Remove unused isNewInstance code (#116747) (#116938)
Co-authored-by: Josh Dover <1813008+joshdover@users.noreply.github.com>
2021-11-01 21:40:55 +00:00
Kibana Machine 5e16bdf269
[Security Solution][Detections] Fix truncated values in columns for rules table (#115825) (#116795)
* Fix truncated rule name on rules table

* remove empty line

* remove truncateText for all rules table columns

* rename unit tests

* refactor unit tests

* fix ts error

* fix ts error

* remove config line

* fix types after kbn bootstrap

* CR: remove unnecesary tests

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>

Co-authored-by: Vitalii Dmyterko <92328789+vitaliidm@users.noreply.github.com>
2021-11-01 21:19:23 +00:00
Kibana Machine 4fe5b04ed6
Fix bug w/ keep policies up to date setting (#116974) (#117001)
Previously, we were only honoring the "keep policies up to date"
setting for policies generated during preconfiguration. This fix ensure
we honor it for all policies.

Closes #116435

Co-authored-by: Kyle Pollich <kyle.pollich@elastic.co>
2021-11-01 21:18:12 +00:00
Kibana Machine 042785a834
[Fleet] Allow user-configured namespace for managed policies (#116523) (#117011)
* Disable agent monitoring settings in UI for managed policies

* Allow namespace to be changed for preconfigured managed policies

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>

Co-authored-by: Jen Huang <its.jenetic@gmail.com>
2021-11-01 21:13:06 +00:00
Kibana Machine 4359e708b0
[8.0] Revert "[Canvas] By-Value Embeddables (#113827)" (#116527) (#116539)
Co-authored-by: spalger <spalger@users.noreply.github.com>
Co-authored-by: Spencer <email@spalger.com>
2021-11-01 14:17:15 -06:00
Kibana Machine 53372a9f48
[Maps] fix data-mapping switch enabled for vector tiles (#116366) (#116834)
* clean up IField API

* disable switch when using MVTs for es docs

* clean up interface comment style

* implement supportsFieldMetaFromEs and supportsFieldMetaFromLocalData in all Field classes

* fix dynamic_color_property test

* fix jest tests

* mock getRangeFieldMeta instead of passing in VectorLayerMock with MockStyle

* review feedback

* clean up supportsFieldMetaFromLocalData test

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>

Co-authored-by: Nathan Reese <reese.nathan@gmail.com>
2021-11-01 19:04:53 +00:00
Kibana Machine 762c770f3b
replace ts_ignore with ts_expect_error (#113768) (#116956)
Co-authored-by: Or Ouziel <ouzielor@gmail.com>
2021-11-01 18:45:19 +00:00
Kibana Machine b374ad0b22
[Logs UI] Respect the advanced settings for queries (#116485) (#116976)
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>

Co-authored-by: Felix Stürmer <weltenwort@users.noreply.github.com>
2021-11-01 18:38:50 +00:00
Kibana Machine a271e59db7
[Security Solution][Endpoint][Cases] Add cases path to sourcerer init so browser fields load (#116464) (#116967)
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>

Co-authored-by: Candace Park <56409205+parkiino@users.noreply.github.com>
2021-11-01 18:27:10 +00:00
Kibana Machine a3abdebfa5
[Fleet] Use event.ingested where possible for data stream last activity (#116641) (#116977)
* use event.ingested for datastream last activity

* remove ms precision from datastream dates

* add timestamp check to test

* fix type error

* split test out to be less complex and more reliable 🤞

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>

Co-authored-by: Mark Hopkin <mark.hopkin@elastic.co>
2021-11-01 18:24:53 +00:00
Kibana Machine 9ea57f61b1
[Reporting] Remove banner from reports (#116147) (#116965)
* remove banner from reports

* added types file

* updated types references and imports

* added screenshot mode public mock

* added jest tests for when screenshot mode is enabled

* Update x-pack/plugins/banners/public/plugin.test.tsx

Co-authored-by: Michael Dokolin <dokmic@gmail.com>

* Update x-pack/plugins/banners/public/plugin.test.tsx

Co-authored-by: Michael Dokolin <dokmic@gmail.com>

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
Co-authored-by: Michael Dokolin <dokmic@gmail.com>

Co-authored-by: Jean-Louis Leysens <jloleysens@gmail.com>
Co-authored-by: Michael Dokolin <dokmic@gmail.com>
2021-11-01 18:14:58 +00:00
Kibana Machine dc8d64917a
[Canvas] Fixes Reveal Image background is not contained. (#116403) (#116623)
* Fixed the problem with `backgroundSize` and `backgroundRepeat`.

Co-authored-by: Yaroslav Kuznietsov <kuznetsov.yaroslav.yk@gmail.com>
2021-11-01 18:12:02 +00:00
Kibana Machine 6508795986
[Security Solution][Endpoint] Fix display of long description text values (with no spaces) on Artifact Entry Cards (#116780) (#116962)
* New DescriptionField component for artifact cards
* Use new DescriptionField in ArtifactCardEntry
* Added `eui-textBreakWord` class name to TextValueDisplay component in artifact cards
* Use `DescriptionField` in `CardCompressedHeader`
* Fix i18n of Description label on minified card
* Use DescriptionField in ArtifactEntryMinified

Co-authored-by: Paul Tavares <56442535+paul-tavares@users.noreply.github.com>
2021-11-01 17:58:53 +00:00
Kibana Machine 1898822677
[8.0] Include failure reason when packages cannot be installed during setup (#116612) (#116658)
Co-authored-by: Josh Dover <1813008+joshdover@users.noreply.github.com>
2021-11-01 18:08:04 +01:00
Kibana Machine f72d389a5c
[Maps] do not allow label overlap (#116190) (#116798)
* [Maps] do not allow label overlap

* split symbol labels into seperate layer

* clean up comments

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>

Co-authored-by: Nathan Reese <reese.nathan@gmail.com>
2021-11-01 16:48:53 +00:00
Cauê Marcondes cd024b41b7
[APM] Errors api test: error_groups/main_statistics (#116337) (#116681)
* use apmApiClient

* refacroting

* fixing errors groups main statistics tests

* refactoring

* fixing error group detailed stats test

* fixing ts issue

* renaming empty archiver

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-11-01 16:37:36 +00:00
Kibana Machine f241f62aa7
[Security Solution][Detections] Reading last 5 failures from Event Log v1 - raw implementation (#115574) (#116947)
**Ticket:** https://github.com/elastic/kibana/issues/106469, https://github.com/elastic/kibana/issues/101013

## Summary

TL;DR: New internal endpoint for reading data from Event Log (raw version), legacy status SO under the hood.

With this PR we now read the Failure History (last 5 failures) on the Rule Details page from Event Log. We continue getting the Current Status from the legacy `siem-detection-engine-rule-status` saved objects. Rule Management page also gets data from the legacy saved objects.

- [x] Deprecate existing methods for reading data in `IRuleExecutionLogClient`: `.find()` and `.findBulk()`
- [x] Introduce new methods for reading data in IRuleExecutionLogClient:
  - for reading last N execution events for 1 rule from event log
  - for reading current status and metrics for 1 rule from legacy status SOs
  - for reading current statuses and metrics for N rules from legacy status SOs
- [x] New methods should return data in the legacy status SO format.
- [x] Update all the existing endpoints that depend on `IRuleExecutionLogClient` to use the new methods.
- [x] Implement a new internal endpoint for fetching current status of the rule execution and execution events from Event Log for a given rule.
- [x] The API of the new endpoint should be the same as `rules/_find_statuses` to minimise changes in the app.
- [x] Use the new endpoint on the Rule Details page.

## Near-term plan for technical implementation of the Rule Execution Log (https://github.com/elastic/kibana/issues/101013)

**Stage 1. Reading last 5 failures from Event Log v1 - raw implementation** - ✔️ done in this PR

TL;DR: New internal endpoint for reading data from Event Log (raw version), legacy status SO under the hood.

- Deprecate existing methods for reading data in `IRuleExecutionLogClient`: `.find()` and `.findBulk()`
- Introduce new methods for reading data in IRuleExecutionLogClient:
  - for reading last N execution events for 1 rule from event log
  - for reading current status and metrics for 1 rule from legacy status SOs
  - for reading current statuses and metrics for N rules from legacy status SOs
- New methods should return data in the legacy status SO format.
- Update all the existing endpoints that depend on `IRuleExecutionLogClient` to use the new methods.
- Implement a new internal endpoint for fetching current status of the rule execution and execution events from Event Log for a given rule.
- The API of the new endpoint should be the same as `rules/_find_statuses` to minimise changes in the app.
- Use the new endpoint on the Rule Details page.

**Stage 2: Reading last 5 failures from Event Log v2 - clean implementation**

TL;DR: Clean HTTP API, legacy Rule Status SO under the hood.

🚨🚨🚨 Possible breaking changes in Detections API 🚨🚨🚨

- Design a new data model for the Current Rule Execution Info (the TO-BE new SO type and later the TO-BE data in the rule object itself).
- Design a new data model for the Rule Execution Event (read model to be used on the Rule Details page)
- Think over changes in `IRuleExecutionLogClient` to support the new data model.
- Think over changes in all the endpoints that return any data related to rule monitoring (statuses, metrics, etc). Make sure to check our docs to identify what's documented there regarding rule monitoring.
- Update `IRuleExecutionLogClient` to return data in the new format. 
- Update all the endpoints (including the raw new one) to return data in the new format.
- Update Rule Details page to consume data in the new format.
- Update Rule Management page to consume data in the new format.

**Stage 3: Reading last 5 failures from Event Log v3 - new SO**

TL;DR: Clean HTTP API, new Rule Execution Info SO under the hood.

- Implement a new SO type for storing the current rule execution info. Relation type: 1 rule - 1 current execution info.
- Swap the legacy SO with the new SO in the implementation of `IRuleExecutionLogClient`.

**Stage 4: Cleanup and misc**

- Revisit the problem of deterministic ordering ([comment](https://github.com/elastic/kibana/pull/115574#discussion_r735803087))
- Remove rule execution log's glue code: adapters, feature switch.
- Remove the legacy rule status SO.
- Mark the legacy rule status SO as deleted in Kibana Core.
- Encapsulate the current space id in the instance of IRuleExecutionLogClient. Remove it from parameters of its methods.
- Introduce a Rule Execution Logger scoped to a rule instance. For use in rule executors.
- Add test coverage.

### 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: Georgii Gorbachev <georgii.gorbachev@elastic.co>
2021-11-01 16:22:25 +00:00
Nathan L Smith fe35e2372d
Jest and Storybook fixes (#116132) (#116688)
* Fix all broken stories
* In stories that were broken, add an associated Jest test so they if they break in the future we'll know
* Fix all console.error messages that were being printed during Jest test runs
* Add test setup which makes it so `console.error` throws an error so tests will fail if error console messages are printed
# Conflicts:
#	x-pack/plugins/apm/public/components/shared/backend_link.stories.tsx

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-11-01 11:01:03 -05:00
Kibana Machine 50f3b3105b
[ML] Renaming index patterns for job wizards (#116250) (#116935)
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>

Co-authored-by: James Gowdy <jgowdy@elastic.co>
2021-11-01 15:42:04 +00:00
Kibana Machine 79351bab25
retry specific metric suggestion check (#116909) (#116930)
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>

Co-authored-by: Joe Reuter <johannes.reuter@elastic.co>
2021-11-01 15:35:59 +00:00
Kibana Machine b23840daca
[Security Solution] Show searchbar when a search doesn't return results in Host isolation exceptions. (#116767) (#116934)
Co-authored-by: Esteban Beltran <academo@users.noreply.github.com>
2021-11-01 15:26:27 +00:00
Kibana Machine 72625a4e87
Fix skipped test to be more robust in matching relative dates (#116474) (#116830)
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>

Co-authored-by: Paul Tavares <56442535+paul-tavares@users.noreply.github.com>
2021-11-01 14:48:52 +00:00
Kibana Machine 3680130c73
[Security Solution][Endpoint] Fix and un-skip Jest UT for Policy Details remove trusted app modal (#116492) (#116832)
* increase update API response delay

Co-authored-by: Paul Tavares <56442535+paul-tavares@users.noreply.github.com>
2021-11-01 14:47:52 +00:00
Kibana Machine a7feb289c6
[Security Solution][Endpoint] Un-skip Policy Details FTR test suite and fix bug in Policy Details page when saving changes (#115662) (#116643)
* unskip test suite
* Fix functional tests and some refactoring
* Refactor Policy Details test and centralize getting of Agent Policy combined input for endpoint
* Change approach for checking policy data in fleet pages
* Change Policy Settings displayed in Fleet to a) show a loader while retrieving settings and b) show loading errors if any
* Close any visible toasts before clicking on the save button

Co-authored-by: Paul Tavares <56442535+paul-tavares@users.noreply.github.com>
2021-11-01 14:45:16 +00:00
Kibana Machine 1d79ea46cd
[Fleet] Add missing documentation link on integrations page (#116453) (#116600)
* add missing doc link

* node scripts/check_published_api_changes.js --accept

Co-authored-by: Mark Hopkin <mark.hopkin@elastic.co>
2021-11-01 14:43:11 +00:00
Kibana Machine a0a6f0ee73
Update testing dev docs for APM (#116664) (#116952)
Co-authored-by: Giorgos Bamparopoulos <georgios.bamparopoulos@elastic.co>
2021-11-01 10:22:10 -04:00
Kibana Machine 9e1c27458a
[Security Solution][Endpoint] Fix bug where users without superuser role are not able to see Endpoint data on Host Details (#116202) (#116647)
* Add `.catch()` statement to ES calls in order to get better stacktraces
* Improve efficiency of getHostEndpoint() search strategy method
* Refactor `getHostEndpoint()` to use new Metadata service as well as the internal kibana ES client

Co-authored-by: Paul Tavares <56442535+paul-tavares@users.noreply.github.com>
2021-11-01 14:18:07 +00:00
Kibana Machine 85edf7820d
[Security Solution][Endpoint] Add tests for pending status API changes (#115998) (#116924)
* add tests for pending status api changes

related to elastic/kibana/pull/115441

refs elastic/security-team/issues/1705

* update mock

refs elastic/kibana/pull/116214

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>

Co-authored-by: Ashokaditya <am.struktr@gmail.com>
2021-11-01 13:47:04 +00:00
Kibana Machine 23ba4e56f9
[Reporting] Remove Boom (#116289) (#116621)
* remove use of boom from info response handler; also changed unauthd response to forbidden to avoid client logging user out

* rather return 500 with err.message

* added jest tests for common cases on the info route

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>

Co-authored-by: Jean-Louis Leysens <jloleysens@gmail.com>
2021-11-01 14:37:22 +01:00
Kibana Machine 48aa1658f9
[Actions][Docs] Rename isLegacy to usesTableApi (#116922) (#116932)
Co-authored-by: Christos Nasikas <christos.nasikas@elastic.co>
2021-11-01 09:01:51 -04:00
Kibana Machine 43e4b9f9f6
retry reading suggestion list (#116405) (#116559)
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>

Co-authored-by: Joe Reuter <johannes.reuter@elastic.co>
2021-11-01 13:25:54 +01:00
Kibana Machine 244d949982
[Cases] Do not show deprecated callout on deleted connectors (#116615) (#116911)
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>

Co-authored-by: Christos Nasikas <christos.nasikas@elastic.co>
2021-11-01 11:13:16 +00:00
Kibana Machine 5cb1b27526
[ML] Functional tests - remove monitor cluster privilege from test role (#116581) (#116604)
This PR removes the `monitor` cluster privilege from the `ft_ml_ui_extras` test role as it's no longer required by the categorization wizard and we want to stay close to the minimum set of required privileges for our test users.

Co-authored-by: Robert Oskamp <robert.oskamp@elastic.co>
2021-11-01 11:29:25 +01:00
Kibana Machine c49fcc4f00
[Fleet] Fix pipeline with id [*] does not exists (#116707) (#116801)
Co-authored-by: Nicolas Chaulet <nicolas.chaulet@elastic.co>
2021-11-01 03:07:03 +00:00
Kibana Machine 6f372b1c77
[Fleet] Fix edit package policy save button (#116482) (#116668) 2021-11-01 03:04:19 +00:00