Commit graph

41216 commits

Author SHA1 Message Date
Kibana Machine 533d32f7fa
Adds two more packages and moves files into the packages (#100375) (#100418)
## Summary

* Adds package `kbn-securitysolution-list-api`
* Adds package `kbn-securitysolution-list-hooks`
* Moves files into the packages
* Moves a few additional types into the other packages such as the `kbn-securitysolution-io-ts-types` package to remove more things from the shard_export/shared_import between lists and security solution
* Removes more duplicated code

### 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: Frank Hassanabad <frank.hassanabad@elastic.co>
2021-05-20 16:33:34 -04:00
Stacey Gammon 8ee9c3abc4
Fix a bunch of bugs with APIDocs system (#99589) (#100417)
* Remove custom code, add in a hack

* remove artifical limit

* Fix arrow functions in interfaces not having children

* Update docs

* Update api docs after merge from master

* update api docs after merge from master

* update api docs
# Conflicts:
#	api_docs/core.json
#	api_docs/data.json
#	api_docs/data_index_patterns.json
#	api_docs/deprecations.mdx
#	api_docs/features.json
#	api_docs/licensing.json
#	api_docs/reporting.json
#	api_docs/spaces.json
2021-05-20 16:11:31 -04:00
Alison Goryachev 6d234d1765
[CCR] Replace EuiCodeEditor with EuiCodeBlock (#100122) (#100415) 2021-05-20 15:57:43 -04:00
Stratoula Kalafateli e72ddfa483
[TSVB] Update TSVB sample viz with the default timerange mode (#100376) (#100407) 2021-05-20 12:54:03 -04:00
Kibana Machine f820c78760
[Dashboard] Embeddable Migrations for By Value Panels (#99715) (#100364)
* Implemented embeddable by value migrations

Co-authored-by: Devon Thomson <devon.thomson@hotmail.com>
2021-05-20 12:34:15 -04:00
Kibana Machine 3e2b1fb9ab
Add back install button for integrations that aren't installed yet (#100370) (#100400)
Co-authored-by: Jen Huang <its.jenetic@gmail.com>
2021-05-20 15:01:57 +00:00
Kibana Machine ac09981bb6
Refactor away from expected error. Handle 404 as any other error. (#100383) (#100398)
Co-authored-by: Pete Hampton <pjhampton@users.noreply.github.com>
2021-05-20 10:59:53 -04:00
Ignacio Rivas f6b686490d
[Ingest pipelines] fix default paramenter for ignore_missing in csv processor (#100316) (#100396)
* fix: set ignoreMissingField to true by default
* Add missing serializer to trim fieldConfig

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

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-05-20 10:51:59 -04:00
Alison Goryachev 186fdf9733
Rename client integration test folders (#100119) (#100395) 2021-05-20 10:50:26 -04:00
Kaarina Tungseth 0cec744242
[DOCS] Fixes Discover link on runtime fields page (#100335) (#100402) 2021-05-20 06:51:59 -07:00
Pierre Gayvallet 3e1e047bc4
[7.x] Migrate joi to 17.4.0 and adapt the codebase (#99899) (#100378)
* Migrate `joi` to `17.4.0` and adapt the codebase  (#99899)

* bump joi to 17.4.0, start adapting stuff

* remove custom validation rule, adapt instead

* fix error handling

* fix error handling again

* fix strings type & validation

* fix buffers and arrays

* fix bytes

* fix bytes_size type

* update conditional_type error messages in tests

* fix duration and map types

* first attempt to fix union type error messages

* revert conditional type assertions back to master state

* fix object type

* fix record type

* fix stream types

* rename test files to match sources

* fix union type tests

* temporary adapt feature/home usages of Joi

* fix lint

* adapt test assertion

* fix http config schema validation

* fix @kbn/test Config class

* fix config again

* fix reporting schema tests

* fix security solution schema

* adapt url tests

* remove useless comment

* remove space

* typo

* review comments
# Conflicts:
#	src/core/server/http/__snapshots__/http_config.test.ts.snap

* allow '0' value for server.host

* fix config def

* update snapshots
2021-05-20 09:04:31 -04:00
Jean-Louis Leysens 3629e76251
[7.x] [Screenshot mode] Create plugin to provide "screenshot mode" awareness (#99627) (#100331)
* [Screenshot mode] Create plugin to provide "screenshot mode" awareness (#99627)

* initial version of the screenshot mode service

* First iteration of client side of screenshot mode plugin

Also hooked it up to the chromium browser imitating the preload
functionality of electron to set up the environment before
code runs.

* First implementation of server-side logic for detecting
screenshot mode

* fix some type issues and do a small refactor

* fix size limits, docs and ts issues

* fixed types issues and made sure screenshot mode is correctly detected on the client

* Moved the screenshot mode header definition to common
Added a server-side example for screenshot mode
Export the screenshot mode header in both public and server

* move require() to screenshotMode plugin

* Update chromium_driver.ts

* cleaned up some comments, minor refactor in ReportingCore and
changed the screenshotmode detection function to check for a
specific value.

* fix export

* Expanded server-side screenshot mode contract with function that
checks a kibana request to determine whether we in screenshot
mode

* added comments to explain use of literal value rather than external reference

* updated comment

* update reporting example

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
Co-authored-by: Timothy Sullivan <tsullivan@elastic.co>
Co-authored-by: Tim Sullivan <tsullivan@users.noreply.github.com>
# Conflicts:
#	x-pack/plugins/reporting/server/core.ts
#	x-pack/plugins/reporting/server/plugin.ts

* satisfy for tslint formatting

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-05-20 07:58:50 -04:00
Michael Dokolin 58d05a05e3
[Reporting] Add logging of CPU usage and memory consumption by Chromium (#99109) (#100384)
* Add logging of CPU usage by chromium
* Add logging of memory consumption by chromium
* Add PDF report byte length logging
* Add PNG report byte length logging
# Conflicts:
#	x-pack/plugins/reporting/server/browsers/chromium/driver_factory/index.ts
2021-05-20 07:52:21 -04:00
Kibana Machine e0e106516e
Remove PEG.js generator from the timelion runtime (#100327) (#100380)
Co-authored-by: Larry Gregory <larry.gregory@elastic.co>
2021-05-20 07:39:22 -04:00
Pierre Gayvallet e1e68fe949
remove ui settings client-side validation (#100311) (#100379)
* remove ui settings client-side validation

* fix linter

* fix tests

* update generated doc
2021-05-20 07:33:58 -04:00
Kibana Machine 7d0deec6cb
[Security Solutions] Re-arranges and adds more packages to remove copied code (#100310) (#100369)
## Summary

* Creates a `securitysolution-list-utils` packaged and moves the first set of utilities into there
* Fixes a slight bug with `kbn-securitysolution-io-ts-list-types` where the wrong name was used
* Moves _all_ of the lists schemas and types into the package `kbn-securitysolution-io-ts-list-types`
* Removes copied code found in a few places

## Tech debt
* Some spots I have to use an `any` in the package as Kibana kbn packages don't have the types I need
* Some spots I copy constants until we can straighten out those pieces.
* I keep copied mock files until we figure out how to share mocks from these packages without adding weight or we create dedicated mock packages for all of this. 


### 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: Frank Hassanabad <frank.hassanabad@elastic.co>
2021-05-19 19:56:33 -04:00
Kevin Logan 05fc567a28
[Security Solution] Add linux malware config options and migration (#100166) (#100368) 2021-05-19 19:46:58 -04:00
spalger 8fa93a225d skip flaky suite (#100372) (#96997)
(cherry picked from commit be97fae12e)
2021-05-19 15:51:47 -07:00
Kibana Machine 71fd3a793a
Cleanup package.json resolutions. (#99456) (#100365)
Co-authored-by: Aleh Zasypkin <aleh.zasypkin@gmail.com>
2021-05-19 18:33:09 -04:00
liza-mae d83ba4fbb8
Upgrade functional test fixes (#100306) (#100361)
* Upgrade functional test fixes

* Fix lint issues
2021-05-19 17:06:58 -04:00
Kibana Machine eae06dcc01
[Enterprise Search] Upgrade Kea to 2.4.2 (#100299) (#100359)
Co-authored-by: Scotty Bollinger <scotty.bollinger@elastic.co>
2021-05-19 17:04:23 -04:00
Kibana Machine 4aaffe931b
crypto-js 3.3.0 -> 4.0.0 (#100347) (#100356)
Co-authored-by: Joe Portner <5295965+jportner@users.noreply.github.com>
2021-05-19 16:29:06 -04:00
Zacqary Adam Xeper 5e6aeba0b0
[Metrics UI] Replace date_histogram with date_range aggregation in threshold alert (#100004) (#100349)
* [Metrics UI] Replace date_histogram with date_range aggregation in threshold alert

* Remove console.log

* Fix rate aggregation and offset
2021-05-19 14:41:54 -04:00
Kevin Logan 68a3585726
[Security Solution] Add supported field to ransomware (#100135) (#100343) 2021-05-19 13:39:58 -04:00
Kibana Machine 714bd3b7b8
[Maps] Add grid-resolution telemetry (#99808) (#100342)
Co-authored-by: Thomas Neirynck <thomas@elastic.co>
2021-05-19 13:34:01 -04:00
spalger c6639e2cba skip flaky suite (#99581)
(cherry picked from commit 4b0c01a732)
2021-05-19 09:34:35 -07:00
Kibana Machine 9b9f3bec75
Upgrade accept 3.0.2 and @hapi/accept 5.0.1 to @hapi/accept 5.0.2 (#100294) (#100313)
Co-authored-by: Thomas Watson <w@tson.dk>
2021-05-19 05:52:10 -04:00
Nathan Reese 5cc4f999e4
[Maps] convert TooltipControl to typescript (#100059) (#100309)
* [Maps] convert ToolbarControl to typescript

* fix scss import

* remove unused function from APM map tooltip

* apm tslint

* pass loadFeatureGeometry to renderTooltipContent

* security_solution: pass mbProperties to loadFeatureProperties

* security_solution tslint

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

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-05-18 21:13:29 -04:00
Kibana Machine c85ccf909f
[dev docs] Add sample data tutorial. Closes #98297 (#99252) (#100308)
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>

Co-authored-by: Jonathan Budzenski <jon@budzenski.me>
2021-05-18 20:29:42 -04:00
Kibana Machine ae89d1ad36
[Alerting] Refactor alerts authorization client (#99078) (#100307)
* 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

* Throwing error when AlertingAuthorizationClientFactory is not defined

* Renaming authorizationType to entity

* Renaming AlertsAuthorization to AlertingAuthorization

* Fixing unit tests

* Updating privilege string terminology

* Updating privilege string terminology

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

Co-authored-by: ymao1 <ying.mao@elastic.co>
2021-05-19 00:28:53 +00:00
Kibana Machine ef5ebb11f2
refact(NA): remove extra pkg_npm target and add specific target folders for @kbn/i18n on Bazel (#100271) (#100304)
* refact(NA): remove extra pkg_npm target and add specific target folders on @kbn/i18n

* chore(NA): override the browser types

Co-authored-by: Tiago Costa <tiagoffcc@hotmail.com>
2021-05-18 19:46:44 -04:00
Kibana Machine e36a21dd6b
Remove unused module oppsy from package.json (#100295) (#100303)
Co-authored-by: Thomas Watson <w@tson.dk>
2021-05-18 19:42:20 -04:00
Kibana Machine 36f07953ad
[dashboard][labs] Defer loading panels below the fold (#99880) (#100302)
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>

Co-authored-by: Clint Andrew Hall <clint.hall@elastic.co>
2021-05-18 19:40:24 -04:00
Uladzislau Lasitsa 9768ee2a87
[XY axis] Improve expression with explicit params (#98897) (#100264)
* Removed visconfig and using explicit params instead in xy_plugin

* Fix CI

* Fix i18n

* Fix unit test

* Fix some remarks

* move expressions into separate chunk

* fix CI

* Update label.ts

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

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
Co-authored-by: Alexey Antonov <alexwizp@gmail.com>
2021-05-18 14:21:41 -07:00
Frank Hassanabad c17e429b9b
[Security Solution] Re-adds a test that was skipped (#100273) (#100284)
## Summary

Re-adds a test that was skipped. If it goes bonkers again, I will add more debugging information to it. I will keep an eye on the operations channel to see when/if this fails again. Originally this looked to be timeouts waiting, so I increased the global timeout to be 20 seconds instead of the original 10 seconds.

Resolves:
https://github.com/elastic/kibana/issues/89389

### 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
2021-05-18 16:01:59 -04:00
Larry Gregory 0d927696c8
Remove lodash.template from legacy discover doc table (#99836) (#100283)
* remove lodash.template from legacy discover doc table

* fix cell rendering

* remove excess whitespace from rendered output

* adding unit tests

* even more tests

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

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-05-18 15:47:30 -04:00
Larry Gregory 9e30e3454f
Remove lodash.template from point series visualization (#100207) (#100282)
* Remove lodash template from point series visualization

* fix message spacing
2021-05-18 15:45:58 -04:00
Frank Hassanabad c48d613aca
[Security Solutions] Removes commented out "last look back date" code (#100269) (#100281)
## Summary

* Removes commented out code which promises we are going to do something past 7.11. This code has been checked in and the column of `last_look_back_date` has been removed since 7.11, which means we haven't had it for 7.11, 7.12, and now 7.13.

Related: https://github.com/elastic/kibana/pull/89801
2021-05-18 15:42:45 -04:00
David Sánchez be74b11216
[Security Solutions][Endpoint] Fixes weird 'flash' when entries does not exists on event filters page (#100203) (#100279)
* Fixes weird 'flash' when entries does not exists on event filters page. Also fixes a multilang and query when empty string

* Removes old comment

* Use function to retrieve async resource state

* Fix unit test

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

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-05-18 15:25:11 -04:00
Kevin Logan 8709260e86
[Security Solution] Fix policy details test (#100260) (#100276) 2021-05-18 15:05:01 -04:00
Stratoula Kalafateli 62601d2d2f
[Timelion] Changes the version of removal message (#100022) (#100266)
* Change the version of timelion removal on our documentation and warnings

* Remove translations in order to be revisited

* Remove double

* Update docs/user/dashboard/timelion.asciidoc

Co-authored-by: Kaarina Tungseth <kaarina.tungseth@elastic.co>

* Update src/plugins/timelion/public/components/timelion_deprecation.tsx

Co-authored-by: Kaarina Tungseth <kaarina.tungseth@elastic.co>

* Update src/plugins/timelion/server/deprecations.ts

Co-authored-by: Kaarina Tungseth <kaarina.tungseth@elastic.co>

* Update src/plugins/timelion/server/deprecations.ts

Co-authored-by: Kaarina Tungseth <kaarina.tungseth@elastic.co>

Co-authored-by: Kaarina Tungseth <kaarina.tungseth@elastic.co>
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>

Co-authored-by: Kaarina Tungseth <kaarina.tungseth@elastic.co>
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-05-18 12:28:28 -04:00
Kibana Machine 7ec1dbb01b
added check for array (#100164) (#100263)
Co-authored-by: Devon Thomson <devon.thomson@hotmail.com>
2021-05-18 11:34:07 -04:00
Thom Heymann d033f4171e
Simplify deleting spaces (#99960) (#100258)
* Simplify deleting spaces

* Fixed i18n

* Fix functional tests

* Update x-pack/plugins/spaces/public/management/spaces_management_app.tsx

Co-authored-by: Larry Gregory <lgregorydev@gmail.com>

* Fix snapshots

Co-authored-by: Larry Gregory <lgregorydev@gmail.com>
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
# Conflicts:
#	x-pack/plugins/spaces/public/management/spaces_management_app.tsx
2021-05-18 10:26:59 -04:00
Frank Hassanabad 60ef805740
Reduce limits of security solutions to max + 15kb (#100247) (#100257)
## Summary

With recent package changes and fixes we are down to 61kb for page load bundle. General rules are max kilobytes + 15kb for buffer so that would mean we should lower it to be 76kb.

Resolves #95870
# Conflicts:
#	packages/kbn-optimizer/limits.yml
2021-05-18 10:18:27 -04:00
Kibana Machine ac4173058e
[Lens] Specify Y axis extent (#99203) (#100255)
Co-authored-by: Joe Reuter <johannes.reuter@elastic.co>
2021-05-18 08:33:04 -04:00
Kibana Machine ee3c3c6f63
Migrate from Joi to @kbn/config-schema in "home" and "features" plugins (#100201) (#100254)
* add a link for issue to remove circular deps

* features: migrate from joi to config-schema

* update tests

* migrate home tutorials to config-schema

* migrate home dataset validation to config schema

* remove unnecessary type. we cannot guarantee this is a valid SO

* address Pierres comments

Co-authored-by: Mikhail Shustov <restrry@gmail.com>
2021-05-18 08:30:05 -04:00
Mikhail Shustov b66df95440
Improve migration perf (#99773) (#100252)
* Do not clone state, use TypeCheck it's not mutated

* do not recreate context for every migration

* use more optional semver check

* update SavedObjectMigrationContext type

* add a test model returns new state object

* update docs

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

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-05-18 06:52:37 -04:00
Kibana Machine 2fa9800396
[Lens] Debounce axis name inputs mob programming (#100108) (#100251)
Co-authored-by: Marta Bondyra <marta.bondyra@gmail.com>
2021-05-18 06:16:03 -04:00
Kibana Machine 18e6085370
[Security Solutions] Replaces most deprecated io-ts alerting and list types (#100234) (#100246)
## Summary

Replaces most of the deprecated io-ts alerting and list types within securitysolution as part of Phase 3 of 4 phases outlined in earlier PR's such as https://github.com/elastic/kibana/pull/99260

### 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: Frank Hassanabad <frank.hassanabad@elastic.co>
2021-05-18 03:23:28 -04:00
Kibana Machine c0f46471c1
[Uptime] [Synthetics Integration] Add functional tests for Synthetics Integration (#100161) (#100242)
* add functional tests for synthetics fleet package

Co-authored-by: Dominique Clarke <doclarke71@gmail.com>
2021-05-17 18:42:11 -04:00