Commit graph

36678 commits

Author SHA1 Message Date
Tyler Smalley da134f3a8f
Aligns several module versions across the repository (#78327)
Signed-off-by: Tyler Smalley <tyler.smalley@elastic.co>

Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
2020-09-28 16:08:22 -07:00
Nathan L Smith a740f7d502
Empty prompt and loading spinner for service map (#78382)
* Empty prompt for service map

To be shown when fetching returns no elements. Match the style of the license prompt.

* Add loading spinner
2020-09-28 17:09:44 -05:00
Ryan Keairns 3094ca1409
Change progress bar to spinner (#78460)
* Change progress bar to spinner

* Add progress bar option for full screen mode

* Update snapshots for router test

* Update snapshots for loading indicator test

* Update header snapshot

* Change progress bar position to fix full screen
2020-09-28 16:27:15 -05:00
Tre 3a73e0b2ac
[QA][Code Coverage] Coverage teams lookup w/o Additional Config (#77111)
* [QA][Code Coverage] Coverage teams lookup

* Fix test per cr.

* Drop unused fn's.

* Add integration test to prove that the sys does indeed
strip the CC prefix and still walks the fs.

* Cleanup "todo" list.

* Use import, like Dima's previous suggestion.

* Add coverage teams only definitions to CODEOWNERS per Lee.

* Add coverage teams for logstash, reporting and security.

* Update description.

* Update names per Lee.

* Drop mutation.

* Fix dupes.

* Add the file check, per Dima

* Add more teams

* Update regex to only match on "build/" and add test.

* More teams

* More teams

* Add print statement of the canonical timestamp,
so we can lookup stuff in gcp during errors.

* CR fixups
2020-09-28 15:27:02 -06:00
Josh Dover 085cac13f2
Slim down core bundle (#75912)
Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
2020-09-28 15:24:23 -06:00
Patrick Mueller feab3e3b02
[Alerting] retry internal OCC calls within alertsClient (#77838)
During development of https://github.com/elastic/kibana/pull/75553,
some issues came up with the optimistic concurrency control (OCC) we
were using internally within the alertsClient, via the `version`
option/property of the saved object. The referenced PR updates new
fields in the alert from the taskManager task after the alertType
executor runs. In some alertsClient methods, OCC is used to update
the alert which are requested via user requests. And so in some
cases, version conflict errors were coming up when the alert was
updated by task manager, in the middle of one of these methods. Note:
the SIEM function test cases stress test this REALLY well.

In this PR, we wrap all the methods using OCC with a function that
will retry them, a short number of times, with a short delay in
between. If the original method STILL has a conflict error, it
will get thrown after the retry limit.  In practice, this eliminated
the version conflict calls that were occurring with the SIEM tests,
once we started updating the saved object in the executor.

For cases where we know only attributes not contributing to AAD are
being updated, a new function is provided that does a partial update
on just those attributes, making partial updates for those attributes
a bit safer. That will be also used by PR #75553.
2020-09-28 16:42:13 -04:00
Spencer f5ca7d82d5
[kbn/optimizer] only build xpack examples when building xpack plugins (#78656)
Co-authored-by: spalger <spalger@users.noreply.github.com>
2020-09-28 13:25:15 -07:00
Jonathan Buttner e75b36a68d
[Ingest Manager] Ingest setup upgrade (#78081)
* Adding bulk upgrade api

* Addressing comments

* Removing todo

* Changing body field

* Adding helper for getting the bulk install route

* Adding request spec

* Pulling in Johns changes

* Removing test for same package upgraded multiple times

* Adding upgrade to setup route

* Adding setup integration test

* Clean up error handling

* Beginning to add tests

* Failing jest mock tests

* Break up tests & modules for easier testing.

Deal with issue described in https://github.com/facebook/jest/issues/1075#issuecomment-221771095

epm/packages/install has functions a, b, c which are independent but a can also call b and c

function a() {
  b();
  c();
}

The linked FB issue describes the cause and rationale (Jest works on "module" boundary) but TL;DR: it's easier if you split up your files

Some related links I found during this journey

 * https://medium.com/@qjli/how-to-mock-specific-module-function-in-jest-715e39a391f4
  * https://stackoverflow.com/questions/52650367/jestjs-how-to-test-function-being-called-inside-another-function
   * https://stackoverflow.com/questions/50854440/spying-on-an-imported-function-that-calls-another-function-in-jest/50855968#50855968

* Add test confirming update error result will throw

* Keep orig error. Add status code in http handler

* Leave error as-is

* Removing accidental code changes. File rename.

* Missed a function when moving to a new file

* Add missing type imports

* Lift .map lambda into named outer function

* Adding additional test

* Fixing type error

Co-authored-by: John Schulz <john.schulz@elastic.co>
Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
2020-09-28 16:12:34 -04:00
Jen Huang 26f2bd204d
[Ingest Manager] Surface saved object client 10,000 limitation to bulk actions UI (#78520)
* Surface saved object client 10,000 limitation to UI

* Update x-pack/plugins/ingest_manager/server/services/saved_object.ts

Co-authored-by: John Schulz <github.com@jfsiii.org>

Co-authored-by: John Schulz <github.com@jfsiii.org>
Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
2020-09-28 13:01:27 -07:00
Xavier Mouligneau 9017d50ffe
fix name without a category or if field end with .text (#78655) 2020-09-28 15:38:16 -04:00
Devin W. Hurley 3f4e9f4bc1
[Security Solution] [Detections] Log message enhancements (#78429)
* adds missing buildRuleMessage to debug logs to display rule id, name, etc. in logs

* add buildRuleMessage fn to params

Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
2020-09-28 15:24:58 -04:00
Melissa Alvarez 25682bf7ce
[ML]DF Analytics exploration: default filter of results page by defaultIsTraining value in url (#78303)
* df exploration page: handle default isTraining filter in url

* default training query updated to match what the searchBar would produce. fixes evaluate panel dataset label

* clear defaultIsTraining filter from url once applied
2020-09-28 15:13:20 -04:00
Constance 3e426a0eab
[Enterprise Search] Remove all instances of KibanaContext to Kea store (#78513)
* Add KibanaLogic store/mount

* Update usage of setBreadcrumbs/setDocTitle to KibanaLogic

* Update usage of Kibana config context to KibanaLogic

* Update usage of navigateToUrl context to KibanaLogic

* 🔥 Remove unused shallow_usecontext mocks, repurpose file to shallow_useeffect

- The file is now no longer used to mock useContext, only unseEffect, hence the rename

* 🔥 Delete/repurpose mount with context helpers

- Remove mountWithKibanaContext completely
- Change mountWithContext to mountWithIntl, since that's the only context remaining, and move it to its own file
- Change mountWithAsyncContext to just mountAsync and move it to its own file
  + add an option to pair it w/ mountWithIntl for formatted date/number support

* 🔥 Delete KibanaContext and mockKibanaContext

+ minor newline linting/grouping tweaks

Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
2020-09-28 12:04:05 -07:00
Melissa Alvarez ac8b8516a6
[ML] DF Analytics creation: ensure job did not fail to start before showing results link (#78200)
* ensure job did not fail to start before showing results link

* simplify job started check

* update job finished check
2020-09-28 14:37:34 -04:00
Pierre Gayvallet 6f1b6907ba
fix createAppNavigationHandler to use navigateToUrl (#78583) 2020-09-28 20:31:44 +02:00
Bhavya RM 9c959947a8
Fixing a11y test failure on discover app (https://github.com/elastic/kibana/issues/59975) (#77614) 2020-09-28 14:21:54 -04:00
Jonathan Buttner 768ae211b5
[Security Solution] Initiate endpoint package upgrade from security app (#77498)
* Working on package update functionality

* Correctly installing package

* Moving upgrade component and working upgrade

* Doing permissions check

* Cleaning up imports

* Adding bulk upgrade api

* Addressing comments

* Removing todo

* Changing body field

* Adding helper for getting the bulk install route

* Adding request spec

* Using bulk install endpoint from ingest

* Moving component to a hook

* Addressing feedback
2020-09-28 14:18:40 -04:00
Spencer 3c85d3d2af
[kbn/es] use a basic build process (#78090)
Co-authored-by: spalger <spalger@users.noreply.github.com>
Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
2020-09-28 11:14:17 -07:00
Spencer c8731205d7
[kbn/optimizer] fix .json extension handling (#78524)
Co-authored-by: spalger <spalger@users.noreply.github.com>
Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
2020-09-28 11:13:58 -07:00
Nathan L Smith 33e3aa2563
Fix APM lodash imports (#78438)
Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
2020-09-28 12:37:33 -05:00
Nathan Reese 54a2c75097
Add deprecated message to tile_map and region_map visualizations. (#77683)
* Add deprecation message to coordinate map and region map

* clean up text

* add default distro link and view in maps link

* move url generation into onClick handler

* create tile map layer descritor

* set metrics and color and scaling

* lazy load createTileMapLayerDescriptor

* tslint fixes

* tslint cleanup for OSS code

* add region map deprecation message

* tslint cleanup

* consolidate logic into LegacyMapDeprecationMessage

* fix jest test

* fix tile-map and region_map in OSS distro

* tslint fixes

* assert urlGenerator exists

* update message text

* ensure legacy-ids get correctly evaluated (#37)

* handle 6.x region map saved objects

* turn off field meta

* fix type

Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
Co-authored-by: Thomas Neirynck <thomas@elastic.co>
2020-09-28 11:31:53 -06:00
Marco Liberati c285287da3
Fix Lens smokescreen flaky tests (#78566)
Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
2020-09-28 18:50:48 +02:00
ncheckin 37d49b0052
updated discover with alt text (#77660)
* Update context.asciidoc

* Update document-data.asciidoc

* Update field-filter.asciidoc

* Update search.asciidoc

* Update set-time-filter.asciidoc

* Update viewing-field-stats.asciidoc

* Update canvas-edit-workpads.asciidoc

* Update canvas-expression-lifecycle.asciidoc

* Update canvas-present-workpad.asciidoc

* Update canvas-share-workpad.asciidoc

* Update canvas-tutorial.asciidoc

* Update docs/canvas/canvas-share-workpad.asciidoc

* Update docs/canvas/canvas-share-workpad.asciidoc

* Update docs/canvas/canvas-tutorial.asciidoc

* Update docs/canvas/canvas-tutorial.asciidoc

* Update docs/canvas/canvas-tutorial.asciidoc

* Update docs/canvas/canvas-tutorial.asciidoc

* Update docs/discover/search.asciidoc

* Update docs/discover/set-time-filter.asciidoc

* Update docs/discover/viewing-field-stats.asciidoc

* Update docs/discover/field-filter.asciidoc

* Update docs/discover/document-data.asciidoc

Co-authored-by: Kaarina Tungseth <kaarina.tungseth@elastic.co>
2020-09-28 10:53:38 -05:00
Daniil Suleiman 93248808b3
Fix types (#78619) 2020-09-28 16:47:53 +01:00
ncheckin 68912875c4
Update tutorial-visualizing.asciidoc (#76977)
* Update tutorial-visualizing.asciidoc

adds alt text to images

* Update docs/getting-started/tutorial-visualizing.asciidoc

* Update docs/getting-started/tutorial-visualizing.asciidoc

* Update docs/getting-started/tutorial-visualizing.asciidoc

* Update docs/getting-started/tutorial-visualizing.asciidoc

* Update docs/getting-started/tutorial-visualizing.asciidoc

* Update docs/getting-started/tutorial-visualizing.asciidoc

Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
Co-authored-by: Kaarina Tungseth <kaarina.tungseth@elastic.co>
2020-09-28 10:41:03 -05:00
ncheckin 8ce96e3ce4
Update tutorial-discovering.asciidoc (#76976)
* Update tutorial-discovering.asciidoc

Adds alt text to images in doc.

* Update docs/getting-started/tutorial-discovering.asciidoc

* Update docs/getting-started/tutorial-discovering.asciidoc

Co-authored-by: Kaarina Tungseth <kaarina.tungseth@elastic.co>
2020-09-28 10:35:33 -05:00
Liza Katz 689e1e32f1
[Search] Error notification alignment (#77788)
* OSS error alignemnt

* Adjust error messages in xpack

* Add getErrorMessage

* Use showError in vizualize
Add original error to expression exception

* Cleanup

* ts, doc and i18n fixes

* Fix jest tests

* Fix functional test

* functional test

* ts

* Update functional tests

* Add unit tests to interceptor and timeout error

* expose toasts test function

* doc

* typos

* review 1

* Code review

* doc

* doc fix

* visualization type fix

* fix jest

* Fix xpack functional test

* fix xpack test

* code review

* delete debubg flag

* Update texts by @gchaps

* docs and ts

Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
2020-09-28 18:33:48 +03:00
ncheckin 97fd0dfbef
Update tutorial-define-index.asciidoc (#76975)
* Update tutorial-define-index.asciidoc

Forgot to update alt text in previous pr. Additionally, it is unclear in the image where the "time field" dropdown is located.

* Update docs/getting-started/tutorial-define-index.asciidoc

Co-authored-by: Kaarina Tungseth <kaarina.tungseth@elastic.co>
2020-09-28 10:27:27 -05:00
Wylie Conlon 0ebaf92a6a
[Lens] Fieldless operations (#78080)
* [Lens] Fieldless operations

* Overhaul types

* Fix invalid state and add tests

* Fix types

* Small cleanup

* Add additional error message

* Reset field selector to empty state when invalid

Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
2020-09-28 11:22:03 -04:00
Alejandro Fernández Haro db78d70df3
[Usage Collection] [schema] Explicit "array" definition (#78141)
Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
2020-09-28 16:13:21 +01:00
ncheckin e111c2ab3e
Update tutorial-define-index.asciidoc (#76973)
* Update tutorial-define-index.asciidoc

* Update docs/getting-started/tutorial-define-index.asciidoc

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

Co-authored-by: Raya Fratkina <raya.fratkina@elastic.co>
Co-authored-by: Kaarina Tungseth <kaarina.tungseth@elastic.co>
2020-09-28 09:57:13 -05:00
Pierre Gayvallet ca48c80c38
Fix --no-basepath references in doc (#78570) 2020-09-28 16:27:53 +02:00
Luke Elmers 786a2d0f4f
Move StubIndexPattern to data plugin and convert to TS. (#78518) 2020-09-28 08:14:33 -06:00
Matthew Kime f0a5ec9877
Index pattern class - remove unused methods (#78538)
* remove unused methods
2020-09-28 09:08:21 -05:00
Steph Milovic 8374f13652
[Security Solution] [ALL] Eliminates all console.error and console.warn from Jest output (#78523) 2020-09-28 07:59:18 -06:00
Gidi Meir Morris 8547b32bab
[Actions] avoids setting a default dedupKey on PagerDuty (#77773)
The PagerDuty Action currently defaults to a dedupKey that's shared between all action executions of the same connector.
To ensure we don't group unrelated executions together this PR avoids setting a default, which means each execution will result in its own incident in PD.

As part of this change we've also made the `dedupKey` a required field whenever a `resolve` or `acknowledge` event_action is chosen. This ensure we don't try to resolve without a dedupKey, which would result in an error in PD.

A migration has been introduced to migrate existing alerts which might not have a `dedupKey` configured.
2020-09-28 14:56:20 +01:00
Rudolf Meijering 8841757874
First stab at developer-focussed saved objects docs (#71430)
* First stab at developer-focussed saved objects docs

* Don't introduce spelling mistakes

* Add docs for SO migrations

* Link to HTTP API documentation

* Grammar fixes

* Rendering fixes

* Migrations should be tested, remove nested migration docs for now

* Drop subtitle field in migration, add notes about migration version, behaviour for corrupt documents and emphasize testing

Co-authored-by: Josh Dover <me@joshdover.com>
2020-09-28 15:53:24 +02:00
Mikhail Shustov e0755a7458
remove unnecessary config validations (#78527) 2020-09-28 15:51:36 +02:00
Jason Stoltzfus 378b8c80ea
[Enterprise Search] Added Logic for the Credentials View (#77626) 2020-09-28 09:39:46 -04:00
Shahzad d7a8641f3a
[CSM] Js errors (#77919)
Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
2020-09-28 15:36:38 +02:00
Pierre Gayvallet aa9774faa0
Add the @kbn/apm-config-loader package (#77855)
* first shot of the apm configuration loader

* revert changes to kibana config

* remove test files for now

* remove `?.` usages

* use lazy config init to avoid crashing integration test runner

* loader improvements

* add config value override via cli args

* add tests for utils package

* add prod/dev config handling + loader tests

* add tests for config

* address josh's comments

* nit on doc
2020-09-28 15:30:59 +02:00
Patryk Kopyciński 2defe88a2c
[Security Solution] Refactor useSelector (#75297) 2020-09-28 15:28:11 +02:00
Daniil Suleiman 53d49381c8
Implement tagcloud renderer (#77910)
* Implement toExpressionAst for tagcloud

* Implement tagcloud vis renderer

* Use resize observer

* Use common no data message

* Update build_pipeline.test

* Update tag cloud tests

* Revert "Use common no data message"

This reverts commit fddf019575.

* Update interpreter functional tests

* Add tests for toExpressionAst fn

* Use throttled chart update

* Update renderer

Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
2020-09-28 16:14:30 +03:00
Cauê Marcondes 966f00ac59
[APM] Alerting: Add global option to create all alert types (#78151)
* adding alert to service page

* sending on alert per service environment and transaction type

* addressing PR comment

* addressing PR comment

Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
2020-09-28 15:12:58 +02:00
Alison Goryachev 88df93bed5
[Ingest pipelines] Upload indexed document to test a pipeline (#77939) 2020-09-28 08:47:05 -04:00
Tim Roes a71d0693dc
TypeScript cleanup in visualizations plugin (#78428)
Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
2020-09-28 14:33:48 +02:00
Daniil Suleiman 3f6c0d688c
Lazy load metric & mardown visualizations (#78391)
* Lazy load metrics vis

* Use common chart spinner

* Simplify markdown renderer

* Update tests

* Update types for metric vis

* Fix tests

* Fix merge conflict

Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
2020-09-28 12:43:34 +03:00
Marshall Main faf4b04004
[Detections][EQL] EQL rule execution in detection engine (#77419)
* First draft of EQL rules in detection engine

* Reorganize functions to separate files

* Start adding eventCategoryOverride option for EQL rules

* Add building block alerts for each event within sequence

* Use eql instead of eql_query for rule type

* Remove unused imports

* Fix tests

* Add basic tests for buildEqlSearchRequest

* Add rulesSchema tests for eql

* Add buildSignalFromSequence test

* Add threat rule fields to buildRuleWithoutOverrides

* Fix buildSignalFromSequence typecheck error

* Add more tests

* Add tests for wrapBuildingBlock and generateSignalId

* Use isEqlRule function and fix import error

* delete frank

* Move sequence interface to types.ts

* Fix import

* Remove EQL execution placeholder, add back language to eql rule type

* allow no indices for eql search

* Fix unit tests for language update

* Fix buildEqlSearchRequest tests

* Replace signal.child with signal.group

* remove unused import

* Move sequence signal group building to separate testable function

* Unbork the merge conflict resolution

Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
2020-09-25 16:23:25 -04:00
ncheckin 500ad8baf0
Update tutorial-full-experience.asciidoc (#75836)
add powershell alternative for curl -O commands at beginning of doc

Co-authored-by: Kaarina Tungseth <kaarina.tungseth@elastic.co>
2020-09-25 16:03:57 -04:00
ncheckin cf18e4637e
Update tutorial-define-index.asciidoc (#75754)
adds windows alternative for curl

Co-authored-by: Kaarina Tungseth <kaarina.tungseth@elastic.co>
2020-09-25 16:03:32 -04:00