Commit graph

43425 commits

Author SHA1 Message Date
Yuliia Naumenko e55a93ce58
[Event Log] Populated rule.* ECS fields for alert events. (#101132)
* [Event Log] Populated rule.* ECS fields for alert events.

* added mappings

* changed the params passing

* fixed tests

* fixed type checks

* used kibanaVersion for version event rule

* fixed typos

* fixed tests

* fixed tests

* fixed tests

* fixed tests

* fixed jest tests

* removed references

* removed not populated fields

* fixed tests

* fixed tests

* fixed tests
2021-06-10 12:33:32 -07:00
Oliver Gupte befd30ff6c
[APM] Fleet support for merging input.config values with other nested properties in the policy input (#101690)
* [APM] Improvments in the APM fleet integration (#95501)

* added unit test and line comment

* fixes eslint issues
2021-06-10 15:27:11 -04:00
Stacey Gammon e9a4028005
Add comments to some alerting plugin public API items (#101551)
* Add comments. Remove ruleType as the second param, not needed.

* Add comments. Remove ruleType as the second param, not needed.

* Fix bad type check and update docs

* update docs

* Remove unused import

* change exports to type to avoid increasing bundle size

* Update x-pack/plugins/alerting/public/plugin.ts

Co-authored-by: ymao1 <ying.mao@elastic.co>

* Update x-pack/plugins/alerting/public/plugin.ts

Co-authored-by: ymao1 <ying.mao@elastic.co>

* Update x-pack/plugins/alerting/public/plugin.ts

Co-authored-by: ymao1 <ying.mao@elastic.co>

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
Co-authored-by: ymao1 <ying.mao@elastic.co>
2021-06-10 15:15:53 -04:00
ymao1 5a1f370580
[Alerting][Docs] Moving alerting setup to its own page (#101323)
* Restructuring main alerting page. Adding separate setup page

* Fixing links

* Moving suppressing duplicate notifications section

* Adding redirect

* Reverting redirect. Adding placeholder link

* Adding placeholder text

* Apply suggestions from code review

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

* Setup page PR fixes

* Alerting page PR fixes

* Update docs/user/alerting/alerting-setup.asciidoc

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

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
Co-authored-by: gchaps <33642766+gchaps@users.noreply.github.com>
2021-06-10 15:14:07 -04:00
Stacey Gammon 9417b699b8
remove uptime public API, it's not used. (#101799) 2021-06-10 14:47:55 -04:00
Scotty Bollinger 797c0c90b0
[Enterprise Search] Refactor RoleMappingsTable to use EuiInMemoryTable (#101918)
* Add shared actions component

Both tables use the same actions

* Refactor RoleMappingsTable to use EuiInMemoryTable

This is way better than the bespoke one I wrote and it comes with pagination for free

- Also fixes a typo in the i18n id
2021-06-10 14:20:54 -04:00
Caroline Horn 61677f7a77
Fix AppContainer layout (#101793)
* Fixing app_container
* Use EUI mixin  `euiHeaderAffordForFixed()` to maintain parity
* Adding `aria-busy` when `showSpinner`
* i18n for the loading aria-label
2021-06-10 14:18:35 -04:00
Shahzad ddccace87e
[Uptime] Unskip alert functional test (#101562) 2021-06-10 20:01:21 +02:00
Wylie Conlon 542fe02e1f
Update aggregation reference docs for 7.13 (#101913)
* Update aggregation reference docs for 7.13

* Add more reference about filtered metrics
2021-06-10 13:42:55 -04:00
Scotty Bollinger d7d67df5eb
[Enterprise Search] Create reusable Group and Engine assignment selectors (#101790)
* Create AssignmentSelectors

These components will be used in both the Role Mapping and User flyouts to create and edit role mappings and users, respectively

* Implement AssignmentSelectors in components
2021-06-10 14:36:11 -03:00
Vadim Yakhin a9a834a105
[Workplace Search] Add Account Settings page imported from Security plugin (#99791)
* Copy lazy_wrapper and suspense_error_boundary from Spaces plugin

These components are needed to enable async loading of Security components into Enterprise Search.

The components are copied without any changes except for i18n ids, so it's easier to DRY out in the future if needed.

* Create async versions of personal_info and change_password components

* Create ui_api that allows to load Security components asuncronously

The patterns were mostly copied from Spaces plugin

* Make ui_api available through Security components's lifecycle methods

* Import Security plugin into Enterprise Search

* Add Security plugin and Notifications service to Kibana Logic file

* Export the required components from the Security plugin and
use them in the new AccountSettings component

* Update link to the Account Settings page

* Move getUiApi call to security start and pass core instead of getStartServices

* Simplify import of change_password_async component by providing...
... `notifications` and `userAPIClient` props in the security plugin

* Remove UserAPIClient from ui_api

It's not needed anymore since the components are initiated with this prop already passed

* Export ChangePasswordProps and PersonalInfoProps from account_management/index.ts

This makes it easier to import these props from outside the account_management folder

* Remove notifications service from kibana_logic

It is not needed anymore since we're initializing security components with notifications already provided

* Add UiApi to SecurityPluginStart interface

* Utilize index files for exporting Props types

* Replace Pick<...> with two separate interfaces as it doesn't work well with our docs

* Add a comment explaining why we're not loading async components through index file
2021-06-10 14:20:30 -03:00
Jonathan Budzenski 5ee5720cb7
[plugin cli] Remove settings argument from warnings log (#101824)
The plugin CLI watches for warnings with a function taking the logger as
an argument.  There are two cases where we're passing a settings object
as the first argument, causing syntax errors instead of properly
logging.  This removes the extra argument.
2021-06-10 12:03:37 -05:00
Jonathan Budzenski 00089bf85a skip flaky runtime fields test. #100966 2021-06-10 12:00:38 -05:00
Jean-Louis Leysens 92bd5c6424
[Fleet] Adjustments to the "Add agent" flyout (#101576)
* updated add agent flyout buttons

* move close button to left

* added new optional prop for the add agent flyout and factored out a component from the index.tsx file

* quite a big refactor, moved the agent policy authentication to own component and reused in two places

* fixed layout on view where policy was not selected, also fixed a render cycle

* removed unnecessary filter

* move handler to function body instead of in JSX

* remove unused i18n

* added jest test for agent enrollment flyout steps behaviour

* fix issues after master merge

* Fix bad import in type file

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-06-10 18:17:41 +02:00
Alison Goryachev 7dfb086343
[Upgrade Assistant] Migrate to new page layout (#101691) 2021-06-10 11:50:08 -04:00
István Zoltán Szabó 85fa7c8791
[ML] Adds popover help for multiclass confusion matrix (#101732)
Co-authored-by: Lisa Cawley <lcawley@elastic.co>
2021-06-10 17:37:57 +02:00
Melissa Alvarez 305f12708d
[ML] Anomaly Detection: Visualize delayed - data Part 1 (#101236)
* wip: add datafeed modal for chart

* Add arrows to navigate through time in the chart

* ensure runtime_mapping and indices_options in search query

* move chart data fetching behind single server endpoint

* remove success check as it is not returned in result

* load necessary modal data in modal

* remove extra legend and add text to action icons

* remove unused endpoint and types

* handle job not found and fix types

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-06-10 11:03:17 -04:00
Dima Arnautov ef8eb321cf
[ML] Add usage collection for pages in the ML app (#101886)
* [ML] setup usageCollection provider

* [ML] track page usage
2021-06-10 10:36:14 -04:00
Joe Reuter fe3c761b40
stabilize opening of Lens from listing page (#101569) 2021-06-10 16:30:37 +02:00
Wylie Conlon b35cde568b
[Lens] Formula editor (#99297)
* 💄 Hack to fix suggestion box

* 🐛 Fix validation messages

* 🐛 Relax operations check for managedReferences

* Change completion params

* 🏷️ Fix missing arg issue

*  Add more tinymath fns

* 🐛 Improved validation around math operations + multiple named arguments

* 🐛 Use new onError feature in math expression

* ♻️ Refactor namedArguments validation

* 🐛 Fix circular dependency issue in tests + minor fixes

* Move formula into a tab

* 🔥 Leftovers from previous merge

*  Move over namedArgs from previous function

*  Add tests for transferable scenarios

*  Fixed broken test

*  Use custom label for axis

* Allow switching back and forth to formula tab

* Add a section for the function reference

* Add modal editor and markdown docs

* Change the way math nodes are validated

* Use custom portal to fix monaco positioning

* Fix model sharing issues

* Provide signature help

* 🐛 Fix small test issue

* 🐛 Mark pow arguments as required

* 🐛 validate on first render only if a formula is present

* 🔥 Remove log10 fn for now

*  Improved math validation + add tests for math functions

* Fix mount/unmount issues with Monaco

* [Lens] Fully unmount React when flyout closes

* Fix bug with editor frame unmounting

* Fix type

* Add tests for monaco providers, add hover provider

* Add test for last_value

* Usability improvements

* Add KQL and Lucene named parameters

* Add kql, lucene completion and validation

* Fix autocomplete on weird characters and properly connect KQL

* Highlight functions that have additional requirements after validating

* Fix type error and move help text to popover

* Fix escape characters inside KQL

* 🐛 Fix dataType issue when moving over to Formula

* Automatically insert single quotes on every named param

* Only insert single quotes when typing kql= or lucene=

* Reorganize help popover

* Fix merge issues

* Update grammar for formulas

* Fix bad merge

* Rough fullscreen mode

* Type updates

* Pass through fullscreen state

* Remove more chrome from full screen mode

* Fix minor bugs in formula typing

* 🐛 Decouple column order of references and output

* 🔧 Fix tests and types

*  Add first functional test

* Fix copying formulas and empty formula

* Trigger suggestion prompt when hitting enter on function or typing kql=

* 🐛 Prevent flyout from closing while interacting with monaco

* refactoring

* move main column generation into parse module

* fix tests

* refactor small formula styles and markup

* documentation

* adjustments in formula footer

* Formula refactoring (#12)

* refactoring

* move main column generation into parse module

* fix tests

* more style and markup tweak for custom formula

* Fix tests

* [Expressions] Use table column ID instead of name when set

* [Lens] Create managedReference type for formulas

* Fix test failures

* Fix i18n types

* fix fullscreen flex issues

* Delete managedReference when replacing

* refactor css and markup; add button placeholders

* [Lens] Formulas

* Tests for formula

Co-authored-by: Marco Liberati <marco.liberati@elastic.co>

* added error count placeholder

* Add tooltips

* Refactoring from code review

* Fix some editor issues

* Update ID matching to match by name sometimes

* Improve performance of Monaco, fix formulas with 0, update labels

* Improve performance of full screen toggle

* Fix formula tests

* fix stuff

* Add an extra case to prevent insertion of duplicate column

* Simplify logic and add test for output ID

* add telemetry for Lens formula (#15)

* Respond to review comments

*  Improve the signatures with better documentation and examples

* adjust border styles to account for docs collapse

* refactor docs markup; restructure docs obj; styles

* Fix formula auto reordering (#18)

* fix formula auto reordering

* add unit test

* Fix and improve suggestion experience in Formula (#19)

*  Revisit documentation and suggestions

* 👌 Integrated feedback

*  Add query validation for quotes

* Usability updates & type fixes

* add search to formula

* fix form styles to match designs

* fix text styles; revert to Markdown for control

* 👌 Integrated more feedback

* improve search

* improve suggestions

* improve suggestions even more

* 🐛 Fix i18n issues (#22)

* Persist formula on leave, fix fullscreen and popovers

* Fix documentation tests

* 🏷️ fix type issue

* 🐛 Remove hidden operations from valid functions list

* 🐛 Fix empty string query edge case

* 🐛 Enable more suggestions + extends validation

* Fix tests that depended on setState being called without function

* Error state and text wrapping updates

*  Add new module to CodeEditor for brackets matching (#25)

* Fix type

* show warning

* keep current quick function

*  Improve suggestions within kql query

* 📷 Fix snapshot editor test

* 🐛 Improved suggestion for single quote and refactored debounce

* Fix lodash usage

* Fix tests

* Revert "keep current quick function"

This reverts commit ed477054c5.

* Improve performance of dispatch by using timeout

* Improve memoization of datapanel

* Fix escape characters

* fix reduced suggestions

* fix responsiveness

* fix unit test

* Fix autocomplete on nested math

* Show errors and warnings on first render

* fix transposing column crash

* Update comment

* 🐛 Fix field error message

* fix test types

* 📝 Fix i18n name

* 💄 Manage wordwrap via react component

* Fix selector for palettes that interferes with quick functions

* Use word wrapping by default

* Errors for managed references are handled at the top level

* 🐛 Move the cursor just next to new inserted text

* ⚗️ First pass for performance

* 🐛 Fix unwanted change

*  Memoize as many combobox props as possible

*  More memoization

* Show errors in hover

* Use temporary invalid state when moving away from formula

* Remove setActiveDimension and shouldClose, fixed by async setters

* Fix test dependency

* do not show quick functions tab

* increase documentation popover width

* fix functional test

* Call setActiveDimension when updating visualization

* Simplify handling of flyout with incomplete columns

* Fix test issues

* add description to formula telemetry

* fix schema

* Update from design feedback

* More review comments

* Hide callout border from v7 theme

Co-authored-by: dej611 <dej611@gmail.com>
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
Co-authored-by: Joe Reuter <johannes.reuter@elastic.co>
Co-authored-by: Michael Marcialis <michael.marcialis@elastic.co>
Co-authored-by: Joe Reuter <email@johannes-reuter.de>
Co-authored-by: Marco Liberati <marco.liberati@elastic.co>
Co-authored-by: Marco Liberati <dej611@users.noreply.github.com>
2021-06-10 10:09:16 -04:00
Christiane (Tina) Heiligers 412fe40d74
Uses default distribution for rewriting ids integration test (#101813) 2021-06-10 06:45:37 -07:00
Christiane (Tina) Heiligers 1fe7840ad9
[so-migrations] Integration test fixes: Use default distribution for cleanup fixture creation (#101698) 2021-06-10 06:44:44 -07:00
Michael Dokolin bde81c2090
[Expressions] Create expressions function to get UI settings (#101317) 2021-06-10 15:17:52 +02:00
Marco Liberati 49ea272240
[Lens] Memoize operationMatrix computation (#101745) 2021-06-10 14:53:25 +02:00
Marco Liberati baef85575d
[Lens] Do not use dynamic coloring for array values (#101750) 2021-06-10 14:52:24 +02:00
David Sánchez e0f817c854
Cleans comment state when submiting and when init the store (#101861) 2021-06-10 14:45:38 +02:00
Stacey Gammon b2903e9f8f
Small clean up with Cases plugin API (#101668)
* Clean up public API of cases plugin

1. Don't use export * on index.ts files that define the public API
2. Add comments to the interface show they show up in the API docs
3. Export types that are part of the public API so they show up in the API docs.
4. Fill in information for the up and coming `description` and `owner` items in kibana.json.

* Update returns comments to be more descriptive

* update api docs

* Remove kibana.json attributes, until PR supporting them is merged.

* Change all exports to export type to avoid increase page bundle size
2021-06-10 08:43:07 -04:00
Stacey Gammon 65d3f49f00
address code review comments (#101764) 2021-06-10 08:36:43 -04:00
SoNice! f804585ec7
[FieldFormatters] Human-readable duration inconsistent unit casing (#101479) 2021-06-10 14:16:34 +02:00
Paul Tavares 095f4d0e3b
[Security Solution][Endpoint] Adjust the Pending Actions API types (#101814)
* Adjust Action Status API types
* add lib/service to fetch host pending actions
2021-06-10 08:08:36 -04:00
Tim Roes 45ed0035b6
Allow navigating discover flyout via arrow keys (#101772) 2021-06-10 11:13:45 +02:00
Christos Nasikas 144e014dbf
[Cases] Improve connectors mapping (#101145) 2021-06-10 11:45:25 +03:00
Pete Harverson 0f5620e5c4
[ML] Fixes display of job group badges in recognizer wizard (#101775) 2021-06-10 09:17:22 +01:00
Domenico Andreoli 7b51debbbb
Fix es_archives path (#101737) 2021-06-10 09:39:07 +02:00
Spencer 7917e3c9d9
[kbnArchiver] convert archive names to root-relative paths (#101839)
* [kbnArchiver] convert archive names to root-relative paths

* ensure that newly multiline hooks are explicitly async

* missed a newly multiline hook

* fix exists check

* avoid extra lines by wrapping arrow body in {}

* one block more

* fix errant `name` variable

Co-authored-by: spalger <spalger@users.noreply.github.com>
2021-06-09 20:13:00 -04:00
Tim Sullivan 3559d375b6
[Reporting] Make "ScreenCapturePanel" shareable for Canvas (#100623)
* use ScreenCapturePanel component in Canvas

* use smaller state object

* add comment about canvas-specific shared component

* fix example

* fix toast error

* fix i18n

* fix data-test-subj

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-06-09 17:08:33 -07:00
Yuliia Naumenko 274bbdc628
[Alerting UI] Converted Rules and Connectors management pages to new layout. (#101697)
* [Alerting UI] Converted Rules and Connectors management pages to new layout.

* fixed tests

* fixed tests

* fixed tests

* fixed tests
2021-06-09 16:56:30 -07:00
Jen Huang 5a5cdb90a7
[Fleet] Support granular integrations in policy editor (#101531)
* Adjust packageToPackagePolicy to support multiple policy_templates

* Adjust validatePackagePolicy to support multiple policy templates

* Create input for every policy template input instead of grouping

* Related adjustments for previous commit

* Don't key by policy template when package doesn't have integrations

* Adjust limited package check to support multiple policy templates

* First pass at UI support

* Fix imports, add missing schema

* Fix finding input agent templates, adjust tests

* Only enable specific integrations by default in the UI

* Fix import

* Make breadcrumbs and create package policy page title reflect integration, not package

* Only show specific integration inputs when adding integration to a policy

* Change predicate

* Simplify condition
2021-06-09 18:21:23 -04:00
Frank Hassanabad 1cb17d025b
[Security Solution][Detections] Update detection alert mappings to ECS v1.10.0 (#101680)
## Summary

* Grabbed the ECS mappings from [v1.10.0 tag]( https://github.com/elastic/ecs/blob/v1.10.0/generated/elasticsearch/7/template.json)
* Updated the fields that had `constant_keyword` to `keyword` since we do many to 1 of source to signals index
* Wrote a unit tests which tests to ensure we don't have any `constant_keyword` fields
* Updated the `SIGNALS_TEMPLATE_VERSION` version by an increment of 10.

This should mostly fix:
https://github.com/elastic/kibana/issues/101572

Since agents add their data into `_source` even though they have a `constant_keyword`. When agents do not include the values in `_source` we will have to merge `fields` into `_source` before copying which are still planning on doing before release.

### 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-06-09 18:06:10 -04:00
Kyle Pollich 9a412d3da0
[Fleet] Integrations UI: Adjust policies list UI (#101600)
* Add "Add Agent" button to package policy list

- Add button to open enrollment flyout from package policy list screen
- Move necessary components up into `public` in order to open enrollment
  flyout from within Integrations application

* Create initial package policy table actions

* Fix context menu link + add a few tests

* Fix import in list_layout

* Unify package policy actions menu in shared component

* Update x-pack/plugins/fleet/public/applications/integrations/sections/epm/screens/detail/index.test.tsx

Co-authored-by: Jean-Louis Leysens <jloleysens@gmail.com>

Co-authored-by: Jean-Louis Leysens <jloleysens@gmail.com>
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-06-09 17:07:29 -04:00
Tiago Costa 21d04614ea
chore(NA): moving @kbn/server-route-repository into bazel (#101484)
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-06-09 21:39:31 +01:00
Stacey Gammon 0254ff06b5
Support owner and description attributes inside the Manifest file, use in API docs (#101786)
* Support owner and description in manifest file, add to mdx output for each plugin

* Update parse_kibana_platform_plugin.ts

* edit a couple kibana.jsons

* Update write_plugin_mdx_docs.ts

* update api docs

* Update core server manifest plugin types

* update core docs

* Fix type_check failure
2021-06-09 16:18:21 -04:00
Joey F. Poon 8cf6112999
[Security Solution] fix security empty overview links (#101536) 2021-06-09 15:06:44 -05:00
Frank Hassanabad 8c03ccf1f0
Unskips migration tests now that elastic search is fixed (#101682)
## Summary

Unskips signal migration tests now that elastic search is fixed get alias bug

ES ticket about get alias bug:
https://github.com/elastic/elasticsearch/pull/72953

Tickets related that should be fixed now:
https://github.com/elastic/kibana/issues/99915
https://github.com/elastic/kibana/issues/100305

### 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-06-09 14:02:47 -06:00
Kyle Pollich 845e701487
Fix endpoint -> integrations onboarding link (#101804)
Fixes #101759
2021-06-09 15:58:15 -04:00
ymao1 2fd3c37fdd
[Alerting] Log warning when rules are not rescheduled due to Saved Object not found error (#101591)
* Adding warning to logs when alerting task runner encounters saved object not found and doesn't reschedule rule

* Adding space id to warning message

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-06-09 15:55:01 -04:00
Craig Chamberlain eb3842b283
Update datafeed_high_count_network_denies.json (#101681)
add a boolean OR between the two possible field values
2021-06-09 15:50:10 -04:00
Matthew Kime 3b37b777cf
[Index patterns] Field editor example app (#100524)
* add example app
2021-06-09 14:44:27 -05:00
Lisa Cawley c20815b070
[DOCS] Adding file upload to add data page (#101674) 2021-06-09 12:36:27 -07:00
Paul Tavares 4e0c889b30
[Security Solution][Endpoint] Adds Endpoint Host Isolation Status common component (#101782)
* Common component for displaying Endpoint Host Isolation status
2021-06-09 14:27:47 -04:00