Commit graph

41403 commits

Author SHA1 Message Date
Kibana Machine
f759046189
[Enterprise Search] Log warning for Kibana/EntSearch version mismatches (#100809) (#100935)
* Add server log warnings whenever Kibana and Enterprise Search versions are mismatched

* Copy feedback

Co-authored-by: Constance <constancecchen@users.noreply.github.com>
2021-05-28 15:53:04 -04:00
Tyler Smalley
be40e96806
[7.x] [FTR][CI] Use default distribution for all tests (#94968) (#99980)
* [FTR][CI] Use default distribution for all tests (#94968)

Signed-off-by: Tyler Smalley <tyler.smalley@elastic.co>

* Use default output

Signed-off-by: Tyler Smalley <tyler.smalley@elastic.co>

* [FTR] Use importExport for saved_object/basic archive

Signed-off-by: Tyler Smalley <tyler.smalley@elastic.co>

* Update suggestions tests

Signed-off-by: Tyler Smalley <tyler.smalley@elastic.co>

* Fix build

Signed-off-by: Tyler Smalley <tyler.smalley@elastic.co>

* More migrations to kbnArchiver

Signed-off-by: Tyler Smalley <tyler.smalley@elastic.co>
2021-05-28 15:25:52 -04:00
Pete Harverson
7b17455d8c
[ML] Fix categorization job view examples link when datafeed uses multiple indices (#100789) (#100923)
* [ML] Fix categorization job view examples link when datafeed uses multiple indices

* [ML] Fix operator in index pattern check

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

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-05-28 14:41:59 -04:00
Spencer
3ccadb4100
[ftr] migrate screenshots and snapshots services to FtrService class (#100514) (#100921)
Co-authored-by: spalger <spalger@users.noreply.github.com>
# Conflicts:
#	test/functional/services/index.ts
2021-05-28 14:24:04 -04:00
Spencer
2d9dd6aa08
[7.x] [ftr] migrate "browser" to FtrService class (#100507) (#100919)
Co-authored-by: spalger <spalger@users.noreply.github.com>

Co-authored-by: spalger <spalger@users.noreply.github.com>
2021-05-28 14:21:29 -04:00
Kibana Machine
92bc2ec74f
Fixing ES archive mapping failure (#100835) (#100917)
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>

Co-authored-by: Jonathan Buttner <56361221+jonathan-buttner@users.noreply.github.com>
2021-05-28 14:15:43 -04:00
Kibana Machine
499d47a7e6
[Security Solution][Endpoint] Add event filters summary card to the fleet endpoint tab (#100668) (#100915)
* Shows event filters card on fleet page

* Uses aggs instead of while loop to retrieve summary data

* Add request and response types in the lists package

* Fixes old import

* Removes old i18n keys

* Removes more old i18n keys

* Use consts for exception lists url and endpoint event filter list id

* Uses event filters service to retrieve summary data

* Fixes addressed pr comments such as changing the route without underscore, adding aggs type, validating response, and more

* Uses useMemo instead of useState to memoize object

* Add new e2e test for summart endpoint

* Handle api errors on event filters and trusted apps summary api calls

* Add api error message to the toast

* Fix wrong i18n key

* Change span tag by react fragment

* Uses styled components instead of modify compontent style directly and small improvements on test -> ts

* Adds curls script for summary route

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

Co-authored-by: David Sánchez <davidsansol92@gmail.com>
2021-05-28 18:05:42 +00:00
Kibana Machine
3c7b809756
Fix bug with Observability > APM header navigation (#100845) (#100916)
Call `setHeaderActionMenu(undefined)` when the HeaderMenuPortal is unmounted.

Found this line in the docs:

> Calling the handler with `undefined` will unmount the current mount point.

Which we weren't doing before.

Previous behavior:

* Go to /app/observability/alerts
* Click the "View in app" button for an APM alert
* Click back
* Click the "View in app" button for an APM alert
* Get a weird toast error message and the header menu is gone forever

Now:

* Go to /app/observability/alerts
* Click the "View in app" button for an APM alert
* Click back
* Click the "View in app" button for an APM alert
* Get a working header menu

Fixes #97140

Co-authored-by: Nathan L Smith <nathan.smith@elastic.co>
2021-05-28 14:03:10 -04:00
Kibana Machine
ce5145748e
[Actions] Taking space id into account when creating email footer link (#100734) (#100913)
* Taking space id into account when creating email footer link

* Handling undefined space when spaces is disabled

* Handling undefined space when spaces is disabled

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

Co-authored-by: ymao1 <ying.mao@elastic.co>
2021-05-28 13:54:32 -04:00
Kibana Machine
3fa7834ab8
[Security Solution] Improve find rule and find rule status route performance (#99678) (#100912)
* Fetch rule statuses using single aggregation instead of N separate requests

* Optimize _find API and _find_statuses

* Merge alerting framework errors into rule statuses

* Add sortSchema for top hits agg, update terms.order schema

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

Co-authored-by: Marshall Main <55718608+marshallmain@users.noreply.github.com>
2021-05-28 13:47:10 -04:00
gchaps
a3da48de12
Remove recommendation of coordinating only node (#100632) (#100932)
* Remove recommendation of coordinating only node

A documentation should be easy and straight forward and giving the user the easiest possible way to get to a fully functioning cluster.

Running a coordinating only node is a bad idea because:

1. Introduces a single point of failure, especially when it is running on the same host as Kibana.
2. Introduces complexity, because you need to run an additional node.

The easiest way to solve the issue of load balancing is to add multiple hosts in the `Elasticsearch.hosts` array in the `Kibana.yml`. This should be far easier than deploying a coordinating node.

* fixed CI errors, there were references to the deleted `load-balancing-es` https://github.com/elastic/kibana/pull/100632

Co-authored-by: Philipp Kahr <philipp.kahr@elastic.co>
2021-05-28 10:37:37 -07:00
gchaps
ab0030b43a
[DOCS] Adds video to introduction (#100906) (#100928) 2021-05-28 10:34:27 -07:00
Pete Hampton
29e0969601
Update detection rule telemetry field name. (#100256) (#100910)
* Changing variable name of cases_count_daily to cases_count_total.

* Taking comments out of tests and reverting tests to previosu state.

* Changing meta description to be more descriptive.

* Changing meta description to be more descriptive.

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

Co-authored-by: Claire Burn <80253545+clburn-elastic@users.noreply.github.com>
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-05-28 13:21:01 -04:00
Kibana Machine
f6ebf81521
[Fleet] Improve combo box for fleet settings (#100603) (#100909)
Co-authored-by: Nicolas Chaulet <nicolas.chaulet@elastic.co>
2021-05-28 13:18:54 -04:00
Kibana Machine
228cc9458f
[Security Solution][Endpoint] Endpoint generator and data loader support for Host Isolation (#100813) (#100904)
Re-introduces the changes from #100727 which was backed out due to a bug. Changes included:

* Generate random isolation values for endpoint metadata
* Generator for Fleet Actions
* Added creation of actions to the index test data loader

Plus:

* Fix generator `randomBoolean()` to ensure it works with seeded random numbers
* Update resolver snapshots due to additional call to randomizer

Co-authored-by: Paul Tavares <56442535+paul-tavares@users.noreply.github.com>
2021-05-28 12:38:25 -04:00
Kibana Machine
50e63875b2
[TSVB] [Table tab] Fix "Math" aggregation (#100765) (#100896)
Co-authored-by: Alexey Antonov <alexwizp@gmail.com>
2021-05-28 12:08:35 -04:00
Kibana Machine
64528b1851
chore(NA): moving @kbn/io-ts-utils into bazel (#100810) (#100893)
Co-authored-by: Tiago Costa <tiagoffcc@hotmail.com>
2021-05-28 12:02:21 -04:00
Kibana Machine
41ef9ec8a0
[Alerting] Adding feature flag for enabling/disabling rule import and export (#100718) (#100887)
* Adding feature flag for enabling rule import and export

* Removing item from docs

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

Co-authored-by: ymao1 <ying.mao@elastic.co>
2021-05-28 11:48:28 -04:00
Kibana Machine
3fe14f4bd1
[TSVB] Fix Upgrading from 7.12.1 to 7.13.0 breaks TSVB (#100864) (#100883)
Closes: #100778

Co-authored-by: Alexey Antonov <alexwizp@gmail.com>
2021-05-28 15:32:19 +00:00
Kibana Machine
324854c536
[Lens] Adds dynamic table cell coloring (#95217) (#100878)
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
Co-authored-by: Greg Thompson <thompson.glowe@gmail.com>
Co-authored-by: Michael Marcialis <michael@marcial.is>

Co-authored-by: Marco Liberati <dej611@users.noreply.github.com>
Co-authored-by: Greg Thompson <thompson.glowe@gmail.com>
Co-authored-by: Michael Marcialis <michael@marcial.is>
2021-05-28 15:18:56 +00:00
Kibana Machine
0dff3fe05b
[Security Solution][Endpoint] Do not display searchbar in security-trusted apps if there are no items (#100853) (#100877)
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>

Co-authored-by: Esteban Beltran <academo@users.noreply.github.com>
2021-05-28 11:17:30 -04:00
Kaarina Tungseth
0f50198929
[DOCS] Adds Lens video (#100898) (#100900) 2021-05-28 07:47:18 -07:00
Alison Goryachev
fc3814d079
[Infra] Update LogStream component docs (#100795) (#100872) 2021-05-28 10:41:22 -04:00
Pete Hampton
9f19a64a98
Add ML usage collector descriptions to the schema. (#100387) (#100860)
* Add ML usage collector descriptions to the schema.

* Update the telemetry mappings file
2021-05-28 09:09:48 -04:00
Kibana Machine
9d485b5c5b
[Observability] Fix typo in readme for new navigation (#100861) (#100873)
* [Observability] Fix typo in readme for new navigation

* Add rxjs dep

Co-authored-by: Søren Louv-Jansen <sorenlouv@gmail.com>
2021-05-28 05:53:22 -07:00
Marco Vettorello
1c1f05e2d7
Update dependency @elastic/charts to v29.2.0 (#100587) (#100856)
Co-authored-by: Renovate Bot <bot@renovateapp.com>

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Renovate Bot <bot@renovateapp.com>
2021-05-28 08:05:58 -04:00
Kibana Machine
c4ad5d86fa
[Lens] Move app state to redux toolkit (#100338) (#100851)
Co-authored-by: Marta Bondyra <marta.bondyra@gmail.com>
2021-05-28 05:55:40 -04:00
Kibana Machine
e8039e188b
[ftr] migrate "savedObjectManagementComponent" service to FtrService class (#100614) (#100849)
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-05-28 05:01:16 -04:00
Kibana Machine
f1f56d0bd6
[ftr] migrate "queryBar" service to FtrService class (#100612) (#100848)
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-05-28 03:10:31 -04:00
Kibana Machine
bc7adfa40b
[ftr] migrate "MenuToggle" service to FtrService class (#100608) (#100847)
Co-authored-by: spalger <spalger@users.noreply.github.com>
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>

Co-authored-by: Spencer <email@spalger.com>
Co-authored-by: spalger <spalger@users.noreply.github.com>
2021-05-28 03:06:04 -04:00
Kibana Machine
c95c60177c
[ftr] migrate "embedding" and "renderable" services to FtrService class (#100596) (#100846)
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-05-28 03:00:14 -04:00
Marta Bondyra
8a6090849b
[Lens] fix error when adding a new layer (#100766) (#100834)
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-05-27 20:20:17 -04:00
DeDe Morton
112c391a5e
Add known Fleet unenrollment issue (#100829) (#100839) 2021-05-27 16:43:28 -07:00
Yuliia Naumenko
74d3820595
[Actions] Converted rejectUnauthorized config usages to verificationMode. (#100179) (#100830)
* [Actions] Converted `rejectUnauthorized` config usages to `verificationMode`.

* added new verificationMode config options for tls, proxy tls and custom hosts

* added unit tests

* added unit tests

* added kibana docker

* Apply suggestions from code review

Co-authored-by: gchaps <33642766+gchaps@users.noreply.github.com>

* Update alert-action-settings.asciidoc

* Apply suggestions from code review

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

* removed legacyRegectUnauthorized logic from getNodeTLSOptions

* added deprecations

* fixed doc links

* fixed docs

* Update x-pack/plugins/actions/server/builtin_action_types/lib/send_email.ts

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

* [DOCS] Fixes build error

* fixed deprecations to set custom message

* fixed doc

* changed to not throw exception on non existing verification mode

* added tests

* fixed tests

* fixed tests

* added integration tests for legacy rejectUnauthorized fale

* fixed tests

Co-authored-by: gchaps <33642766+gchaps@users.noreply.github.com>
Co-authored-by: Joe Portner <5295965+jportner@users.noreply.github.com>
Co-authored-by: lcawl <lcawley@elastic.co>
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>

Co-authored-by: gchaps <33642766+gchaps@users.noreply.github.com>
Co-authored-by: Joe Portner <5295965+jportner@users.noreply.github.com>
Co-authored-by: lcawl <lcawley@elastic.co>
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-05-27 19:20:58 -04:00
Kibana Machine
93e685e964
Fixes Field used in RDP ML job to event.type (#100000) (#100827)
* Update datafeed_windows_rare_user_type10_remote_login.json

refactor df query to work with newer field values

* Update datafeed_windows_rare_user_type10_remote_login.json

remove event.code test - was failing a test on the build server using the original data b/c this field was not there when the query was first developed.

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

Co-authored-by: Craig Chamberlain <randomuserid@users.noreply.github.com>
2021-05-27 18:40:34 -04:00
Kibana Machine
0b0ac6a87e
[Fleet] Link to docs for Fleet Server and ES hosts (#100698) (#100825)
* [Fleet] Link to docs for Fleet Server and ES hosts

* Fix CN/JP i18n

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

Co-authored-by: Zacqary Adam Xeper <Zacqary@users.noreply.github.com>
2021-05-27 18:11:14 -04:00
Kibana Machine
3d5280471c
[App Search] Added a query tester button (#100560) (#100821)
Co-authored-by: Jason Stoltzfus <jastoltz24@gmail.com>
2021-05-27 21:36:12 +00:00
Kibana Machine
f4756e9dc2
[Observability] Fix README.md link to component (#100801) (#100818)
Co-authored-by: Casper Hübertz <casper@elastic.co>
2021-05-27 17:21:32 -04:00
Kibana Machine
5e7fdbe333
[Alerting] Split alerting feature privilege between rules and alerts and handle subfeature privilege specification (#100127) (#100817)
* WIP - creating alerting authorization client factory and exposing authorization client on plugin start contract

* Updating alerting feature privilege builder to handle different alerting types

* Passing in alerting authorization type to AlertingActions class string builder

* Passing in authorization type in each function call

* Passing in exempt consumer ids. Adding authorization type to audit logger

* Changing alertType to ruleType

* Changing alertType to ruleType

* Updating unit tests

* Updating unit tests

* Passing field names into authorization query builder. Adding kql/es dsl option

* Converting to es query if requested

* Fixing functional tests

* Removing ability to specify feature privilege name in constructor

* Fixing some types and tests

* Consolidating alerting authorization kuery filter options

* Cleanup and tests

* Cleanup and tests

* Initial commit with changes needed for subfeature privilege

* Throwing error when AlertingAuthorizationClientFactory is not defined

* Renaming authorizationType to entity

* Renaming AlertsAuthorization to AlertingAuthorization

* Fixing unit tests

* Changing schema of alerting feature privilege

* Changing schema of alerting feature privilege

* Updating feature privilege iterator

* Updating feature privilege builder

* Fixing types check

* Updating privilege string terminology

* Updating privilege string terminology

* Wip

* Fixing unit tests

* Unit tests

* Updating README and removing stack subfeature privilege changes

* Fixing README

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

Co-authored-by: ymao1 <ying.mao@elastic.co>
2021-05-27 16:55:49 -04:00
Kibana Machine
6b6c48dbcb
Automated package testing (#88900) (#100812)
Co-authored-by: Tyler Smalley <tylersmalley@me.com>
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>

Co-authored-by: Jonathan Budzenski <jon@budzenski.me>
Co-authored-by: Tyler Smalley <tylersmalley@me.com>
2021-05-27 20:33:04 +00:00
Kibana Machine
b8efa8e32c
[Maps] timeslider (#99661) (#100811)
* [Maps timeslider]

* just arrowLeft and arrowRight icons

* tslint

* color icon when timeslider is open, auto select first section on open

* increase width to prevent timeslider from changing sizes during interaction

* fix filters disappearing when timeslice advances

* use shorter date format for ticks

* review feedback

* do not show timeslider button when map is embedded

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

Co-authored-by: Nathan Reese <reese.nathan@gmail.com>
2021-05-27 16:25:21 -04:00
Kibana Machine
72e000f14e
chore(NA): moving @kbn/monaco into bazel (#100709) (#100808)
* chore(NA): moving @kbn/monaco into bazel

* chore(NA): update register globals definitions

* chore(NA): remove build script

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

Co-authored-by: Tiago Costa <tiagoffcc@hotmail.com>
2021-05-27 15:51:54 -04:00
Anton Dosov
64017d65cc
[Index patterns] Default index pattern REST API (#100691) (#100798) 2021-05-27 14:00:43 -04:00
Georgii Gorbachev
d3fbb91a22
[RAC] Rule monitoring: Event Log for Rule Registry (#98353) (#100794)
**Needed for:** rule execution log for Security https://github.com/elastic/kibana/pull/94143
**Related to:**

- alerts-as-data: https://github.com/elastic/kibana/issues/93728, https://github.com/elastic/kibana/issues/93729, https://github.com/elastic/kibana/issues/93730
- RFC for index naming https://github.com/elastic/kibana/issues/98912

## Summary

This PR adds a mechanism for writing to / reading from / bootstrapping indices for RAC project into the `rule_registry` plugin. Particularly, indices for alerts-as-data and rule execution events. This implementation is similar to existing implementations like `event_log` plugin (see https://github.com/elastic/kibana/pull/98353#issuecomment-833045980 for historical perspective), but we're going to converge all of them into 1 or 2 implementations. At least we should have a single one in `rule_registry` itself.

In this PR I tried to incorporate most of the feedback received in the RFC (https://github.com/elastic/kibana/issues/98912), but if you notice I missed/forgot something, please let me know in the comments.

Done in this PR:

- [x] Schema-agnostic APIs for working with Elasticsearch.
- [x] Schema-aware log definition and bootstrapping API (creating hierarchical logs).
- [x] Schema-aware write API (logging events).
- [x] Schema-aware read API (searching logs, filtering, sorting, pagination, aggregation).
- [x] Support for Kibana spaces, space-aware index bootstrapping (either at rule creation or rule execution time).

As for reviewing this PR, perhaps it might be easier to start with:

- checking description of https://github.com/elastic/kibana/issues/98912
- checking usage examples https://github.com/elastic/kibana/pull/98353/files#diff-c049ff2198cc69bd50a69e92d29e88da7e10b9a152bdaceaf3d41826e712c12b
- checking public api https://github.com/elastic/kibana/pull/98353/files#diff-8e9ef0dbcbc60b1861d492a03865b2ae76a56ec38ada61898c991d3a74bd6268

## Next steps

Next steps towards rule execution log in Security (https://github.com/elastic/kibana/pull/94143):

- define actual schema for rule execution events
- inject instance of rule execution log into Security rule executors and route handlers
- implement actual execution logging in rule executors
- update route handlers to start fetching execution events and metrics from the log instead of custom saved objects

Next steps in the context of RAC and unified implementation:

- converge this implementation with `RuleDataService` implementation
  - implement robust index bootstrapping
  - reconsider using FieldMap as a generic type parameter
  - implement validation for documents being indexed
- cover the final implementation with tests
- write comprehensive docs: update plugin README, add JSDoc comments to all public interfaces
2021-05-27 13:33:45 -04:00
Kibana Machine
3f455e8ef6
[Uptime] Waterfall use different styling for number (#97216) (#100793)
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>

Co-authored-by: Shahzad <shahzad.muhammad@elastic.co>
2021-05-27 12:56:16 -04:00
Kibana Machine
39c2a52abc
[Logs UI] Add shared observability page template and navigation (#99380) (#100792)
Co-authored-by: Kerry Gallagher <471693+Kerry350@users.noreply.github.com>
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>

Co-authored-by: Felix Stürmer <weltenwort@users.noreply.github.com>
Co-authored-by: Kerry Gallagher <471693+Kerry350@users.noreply.github.com>
2021-05-27 12:52:41 -04:00
Kibana Machine
9c7006ea59
Add kibana.yml configuration for cases (#100583) (#100788)
Make it so `xpack.observability.unsafe.alertingExperience.enabled` only shows and hides the Alerts page, and `xpack.observability.unsafe.cases.enabled` show and hides the Cases page.

Co-authored-by: Nathan L Smith <nathan.smith@elastic.co>
2021-05-27 12:46:06 -04:00
Anton Dosov
b9115a6122
[Index Patterns] Migrate tests to the new es client (#100760) (#100782) 2021-05-27 11:43:58 -04:00
Candace Park
fad75020d3
[Security Solution][Endpoint][Host Isolation] User can unisolate host from alert details (#100401) (#100777) 2021-05-27 11:26:45 -04:00
Kibana Machine
7b2f4c33b2
[Lens] Improve caching with more stable Elasticsearch requests (#100414) (#100776)
Co-authored-by: Joe Reuter <johannes.reuter@elastic.co>
2021-05-27 15:22:02 +00:00