Commit graph

169 commits

Author SHA1 Message Date
Robert Oskamp 154150732d
[ML] Functional tests - fix and re-activate alerting flyout test (#102368)
This PR fixes the ML alerting flyout tests and re-activates it.
2021-06-16 13:42:44 -04:00
spalger c8256d57bd skip flaky suite (#101984) 2021-06-16 10:07:21 -07:00
Tyler Smalley 035f617b58 skip flaky suite (#102012) 2021-06-15 09:00:30 -07:00
Robert Oskamp 150198404a
[ML] Functional tests - stabilize alerting flyout test (#102030)
This PR stabilizes and re-activates the ML alerting flyout test suite.
2021-06-14 14:55:26 +02:00
Tyler Smalley 344b6310d7 skip flaky suite (#102012) 2021-06-12 06:49:27 -07: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
Shahzad ddccace87e
[Uptime] Unskip alert functional test (#101562) 2021-06-10 20:01:21 +02: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
Spencer f466ebf1a3
[esArchiver] drop support for --dir, use repo-relative paths instead (#101345)
Co-authored-by: spalger <spalger@users.noreply.github.com>
2021-06-08 17:37:42 -04:00
Mikhail Shustov d920682e4e
Update @elastic/elasticsearch to 8.0.0-canary13 (#98266)
* bump @elastic/elasticsearch to canary.7

* address errors in core

* address errors in data plugin

* address errors in Alerting team plugins

* remove outdated messages in Lens

* remove unnecessary comments in ML

* address errors in Observability plugin

* address errors in reporting plugin

* address errors in Rule registry plugin

* fix errors in Security plugins

* fix errors in ES-UI plugin

* remove unnecessary union.

* update core tests

* fix kbn-es-archiver

* update to canary 8

* bump to v9

* use new typings

* fix new errors in core

* fix errors in core typeings

* fix type errors in data plugin

* fix type errors in telemetray plugin

* fix data plugin tests

* fix search examples type error

* fix errors in discover plugin

* fix errors in index_pattern_management

* fix type errors in vis_type_*

* fix errors in typings/elasticsearch

* fix type errors in actions plugin

* fix type errors in alerting and apm plugins

* fix type errors in canvas and cases

* fix errors in event_log

* fix type errors in ILM and ingest_pipelines

* fix errors in lens plugin

* fix errors in lists plugin

* fix errors in logstash

* fix errors in metrics_entities

* fix errors in o11y

* fix errors in watcher

* fix errors in uptime

* fix errors in upgrade_assistant

* fix errors in task_manager

* fix errors in stack_alerts

* fix errors in security_solution

* fix errors in rule_registry

* fix errors in snapshot_restore

* fix remaining errors

* fix search intergration tests

* adjust assetion

* bump version to canary.10

* adapt code to new naming schema

* use mapping types provided by the client library

* Revert "adjust assetion"

This reverts commit 19b8fe0464.

* fix so intergration tests

* fix http integration tests

* bump version to canary 11

* fix login test

* fix http integration test

* fix apm test

* update docs

* fixing some ml types

* fix new errors in data plugin

* fix new errors in alerting plugin

* fix new errors in lists plugin

* fix new errors in reporting

* fix or mute errors in rule_registry plugin

* more ML type fixes

* bump to canary 12

* fix errors after merge conflict

* additional ML fixes

* bump to canary 13

* fix errors in apm plugin

* fix errors in fleet plugin

* fix errors in infra plugin

* fix errors in monitoring plugin

* fix errors in osquery plugin

* fix errors in security solution plugins

* fix errors in transform plugin

* Update type imports for ES

* fix errors in x-pack plugins

* fix errors in tests

* update docs

* fix errors in x-pack/test

* update error description

* fix errors after master merge

* update comment in infra plugin

* fix new errors on xpack tests/

Co-authored-by: James Gowdy <jgowdy@elastic.co>
Co-authored-by: Dario Gieselaar <dario.gieselaar@elastic.co>
2021-06-08 15:06:06 +02:00
ymao1 71379b755a
[Alerting] Split alerting feature privilege between rules and alerts and handle subfeature privilege specification (#100127)
* 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>
2021-05-27 14:59:02 -04:00
Spencer 808b44f2c1
[kbn/test] move types/ftr into src (#99555)
* [kbn/test] move types/ftr into src

* Apply eslint updates

* fix import of Lifecycle type

Co-authored-by: spalger <spalger@users.noreply.github.com>
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-05-17 09:51:53 -07:00
Mike Côté bb7057c343
Rename alert status OK to Recovered and fix some UX issues around disabling a rule while being in an error state (#98135)
* Fix UX when alert is disabled and in an error state

* Reset executionStatus to pending after enabling an alert

* Renames alert instance status OK to Recovered

* Fix end to end test

* Update doc screenshot

* Fix confusing test name

* Remove flakiness in integration test

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-05-13 14:16:36 -04:00
Dima Arnautov 4686f442ee
[ML] Fix alerting rule preview (#98907) 2021-04-30 14:03:05 -04:00
Shahzad 18213b673f
[Uptime] Fix Monitor status toggle alert receovery state (#89273)
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-04-29 18:42:52 +02:00
Yuliia Naumenko 846aed54d9
Fixed Failing test for alerts list disable/mute operations. (#97057)
* Fixed Failing test for alerts list disable/mute operations.

* fixed tests

* removed awating check for switch status changed

* replaced api methos with ui call

* fixed merge

* reopen and close actions item menu

* fixed mute

* Update collapsed_item_actions.tsx

Remove changes

* removed retry

* add retry

* replaced try with try for time

* inceased retry

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-04-23 14:24:41 -07:00
Patrick Mueller 2ebb308753
[alerting] encode rule/connector ids in http requests made from alerting UI (#97854)
resolves: https://github.com/elastic/kibana/issues/97852

Adds `encodeURIComponent()` wrappers around references to rule, alert, and
connector ids.  Without this fix, if an alert id (which can contain
customer-generated data) contains a character that needs to be URL
encoded, the resulting API call from the web UI will fail.
2021-04-23 15:50:24 -04:00
Dima Arnautov 49cdc9066d
[ML] Improve functional tests for Anomaly detection alert rule (#97998)
* [ML] ensureAdvancedSectionOpen for assertion

* [ML] delete alert rules after tests execution

* [ML] add isAdvancedSectionOpened
2021-04-22 11:16:54 -04:00
Spencer fad45022c1
[npm] upgrade all jest related dependencies (#96367)
Co-authored-by: spalger <spalger@users.noreply.github.com>
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-04-21 15:32:10 -04:00
Dima Arnautov 20b585d122
[ML] Anomaly detection rule lookback interval improvements (#97370)
* [ML] add advanced settings

* [ML] default advanced settings

* [ML] advanced settings validators

* [ML] range control for top n buckets

* [ML] execute rule with a new query for most recent anomalies

* [ML] find most anomalous bucket from the top N

* Revert "[ML] range control for top n buckets"

This reverts commit e039f250

* [ML] validate check interval against the lookback interval

* [ML] update descriptions

* [ML] fix test subjects

* [ML] update warning message

* [ML] add functional tests

* [ML] adjust unit tests, mark getLookbackInterval

* [ML] update lookback interval description and warning message

* [ML] update fetchResult tsDoc

* [ML] cleanup

* [ML] fix imports to reduce bundle size

* [ML] round up lookback interval

* [ML] update functional test assertion

* [ML] async import for validator
2021-04-20 10:52:54 +02:00
ymao1 71ed148cfe
[Alerting] Preconfigured alert history index connector (#94909)
* Adding preconfigured alert history index

* Adding functions to build alert history document

* Adding functions to build alert history document

* Moving index template creation to plugin start

* Adding unit tests

* Adding unit tests

* Adding unit tests

* Simplifying

* Revert "Merge branch 'master' of https://github.com/elastic/kibana into alerting/default-es-index-schema"

This reverts commit 957c333aa4, reversing
changes made to 4b1b78761e.

* Reverting some changes

* Reverting some changes

* Adding index override

* Updating UI with index override

* Only allow indexOverride for preconfigured alert history connector

* Handling preconfigured connector id clashes

* Cleanup

* UI unit tests

* Fixing default schema shown in UI

* Fixing functional tests

* Adding functional test

* Fixing functional tests

* Adding docs and link to docs

* Adding config to docker allowlist

* Fixing wrong typescript operator

* Changing default for config to false

* Cleanup

* Adding note about index privileges to docs

* Fixing i18n

* PR fixes

* PR fixes

* PR fixes

* PR fixes - wording

* PR fixes

* Fixing unit and functional tests

* Fixing types check

* ES -> Elasticsearch

* Moving files

* Adding kibana- to beginning of prefix

* Namespacing alert data within schema with kibana

* Fix i18n

* Updating docs

* Fixing unit tests

* Fixing doc links

* Fixing types check

* PR fixes

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-04-08 18:18:44 -04:00
spalger 2a3edb0adb skip flaky suite (#95591) 2021-03-31 13:06:04 -07:00
ymao1 7ef8be6031
Fixes Failing test: Chrome X-Pack UI Functional Tests.x-pack/test/functional_with_es_ssl/apps/triggers_actions_ui/alerts_list·ts - Actions and Triggers app alerts list should unmute single alert (#95808)
* Unskipping test

* Adding retries

* Adding retries

* Adding retries
2021-03-31 07:43:48 -04:00
Mike Côté 3abb79a179
Create new alerting HTTP APIs that use the new terminology (#93977)
* Move current alert HTTP APIs to legacy folder (#93943)

* Move current HTTP APIs to legacy folder

* Rename BASE_ALERT_API_PATH to LEGACY_BASE_ALERT_API_PATH

* Fix failing tests and extra files

* Create new rule HTTP APIs (#93980)

* Move current HTTP APIs to legacy folder

* Rename BASE_ALERT_API_PATH to LEGACY_BASE_ALERT_API_PATH

* Fix failing tests and extra files

* Move current alert HTTP APIs to legacy folder (#93943)

* Move current HTTP APIs to legacy folder

* Rename BASE_ALERT_API_PATH to LEGACY_BASE_ALERT_API_PATH

* Fix failing tests and extra files

* Add necessary files

* Create rule route

* Get rule API

* Update rule API

* Delete rule route

* Aggregate rules API

* Disable rule API

* Enable rule API

* Find rules API

* Fix Update API

* Get rule alert summary API

* Get rule state API

* Health API

* Rule types API

* Mute all API

* Mute alert API

* Unmute all API

* Unmute alert route

* Update API key API

* corrected tpye by making it much more complicated

* removed unneeded cocde

* Fixes

* Add back health route

* mutedInstanceIds -> mutedAlertIds

* lastRun -> last_run

* alert_type_state -> rule_type_state & alert_instances -> alerts

Co-authored-by: Gidi Meir Morris <github@gidi.io>

* Create docs for new rule HTTP APIs, deprecate old docs (#94745)

* Create docs for new APIs, deprecate old docs

* Remove connector_type_id

* Update docs

* Add link to legacy APIs from rules API docs

* Remove connector_type_id references

* [DOCS] Add legacy APIs to index.asciidoc

* Fix camel case

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

* Make alerting tests use new rules APIs (#95159)

* Make API integration tests use new HTTP APIs

* Fix end to end tests

* Fix test failures

* Fix more test failures

* Rename some files

* Add tests for legacy APIs (#95333)

* Initial commit (#95457)

* Move some new alerting APIs to /internal (#95461)

* Initial commit

* Update README.md

* Use internal API

* Merge deprecated warning w/ alternative solution

* Update API docs

Co-authored-by: Gidi Meir Morris <github@gidi.io>
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
Co-authored-by: lcawl <lcawley@elastic.co>
2021-03-30 08:27:28 -04:00
Brian Seeders 173731b342 skip flaky suite (#95590) 2021-03-26 17:23:12 -04:00
Tomas Della Vedova 238791b942
ES client : use the new type definitions (#83808)
* Use client from branch

* Get type checking working in core

* Fix types in other plugins

* Update client types + remove type errors from core

* migrate Task Manager Elasticsearch typing from legacy library to client library

* use SortOrder instead o string in alerts

* Update client types + fix core type issues

* fix maps ts errors

* Update Lens types

* Convert Search Profiler body from a string to an object to conform to SearchRequest type.

* Fix SOT types

* Fix/mute Security/Spaces plugins type errors.

* Fix bootstrap types

* Fix painless_lab

* corrected es typing in Event Log

* Use new types from client for inferred search responses

* Latest type defs

* Integrate latest type defs for APM/UX

* fix core errors

* fix telemetry errors

* fix canvas errors

* fix data_enhanced errors

* fix event_log errors

* mute lens errors

* fix or mute maps errors

* fix reporting errors

* fix security errors

* mute errors in task_manager

* fix errors in telemetry_collection_xpack

* fix errors in data plugins

* fix errors in alerts

* mute errors in index_management

* fix task_manager errors

* mute or fix lens errors

* fix upgrade_assistant errors

* fix or mute errors in index_lifecycle_management

* fix discover errors

* fix core tests

* ML changes

* fix core type errors

* mute error in kbn-es-archiver

* fix error in data plugin

* fix error in telemetry plugin

* fix error in discover

* fix discover errors

* fix errors in task_manager

* fix security errors

* fix wrong conflict resolution

* address errors with upstream code

* update deps to the last commit

* remove outdated comments

* fix core errors

* fix errors after update

* adding more expect errors to ML

* pull the lastest changes

* fix core errors

* fix errors in infra plugin

* fix errors in uptime plugin

* fix errors in ml

* fix errors in xpack telemetry

* fix or mute errors in transform

* fix errors in upgrade assistant

* fix or mute fleet errors

* start fixing apm errors

* fix errors in osquery

* fix telemetry tests

* core cleanup

* fix asMutableArray imports

* cleanup

* data_enhanced cleanup

* cleanup events_log

* cleaup

* fix error in kbn-es-archiver

* fix errors in kbn-es-archiver

* fix errors in kbn-es-archiver

* fix ES typings for Hit

* fix SO

* fix actions plugin

* fix fleet

* fix maps

* fix stack_alerts

* fix eslint problems

* fix event_log unit tests

* fix failures in data_enhanced tests

* fix test failure in kbn-es-archiver

* fix test failures in index_pattern_management

* fixing ML test

* remove outdated comment in kbn-es-archiver

* fix error type in ml

* fix eslint errors in osquery plugin

* fix runtime error in infra plugin

* revert changes to event_log cluser exist check

* fix eslint error in osquery

* fixing ML endpoint argument types

* fx types

* Update api-extractor docs

* attempt fix for ese test

* Fix lint error

* Fix types for ts refs

* Fix data_enhanced unit test

* fix lens types

* generate docs

* Fix a number of type issues in monitoring and ml

* fix triggers_actions_ui

* Fix ILM functional test

* Put search.d.ts typings back

* fix data plugin

* Update typings in typings/elasticsearch

* Update snapshots

* mute errors in task_manager

* mute fleet errors

* lens. remove unnecessary ts-expect-errors

* fix errors in stack_alerts

* mute errors in osquery

* fix errors in security_solution

* fix errors in lists

* fix errors in cases

* mute errors in search_examples

* use KibanaClient to enforce promise-based API

* fix errors in test/ folder

* update comment

* fix errors in x-pack/test folder

* fix errors in ml plugin

* fix optional fields in ml api_integartoon tests

* fix another casting problem in ml tests

* fix another ml test failure

* fix fleet problem after conflict resolution

* rollback changes in security_solution. trying to fix test

* Update type for discover rows

* uncomment runtime_mappings as its outdated

* address comments from Wylie

* remove eslint error due to any

* mute error due to incompatibility

* Apply suggestions from code review

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

* fix type error in lens tests

* Update x-pack/plugins/upgrade_assistant/server/lib/reindexing/reindex_service.ts

Co-authored-by: Alison Goryachev <alisonmllr20@gmail.com>

* Update x-pack/plugins/upgrade_assistant/server/lib/reindexing/reindex_service.test.ts

Co-authored-by: Alison Goryachev <alisonmllr20@gmail.com>

* update deps

* fix errors in core types

* fix errors for the new elastic/elasticsearch version

* remove unused type

* remove unnecessary manual type cast and put optional chaining back

* ML: mute Datafeed is missing indices_options

* Apply suggestions from code review

Co-authored-by: Josh Dover <1813008+joshdover@users.noreply.github.com>

* use canary pacakge instead of git commit

Co-authored-by: Josh Dover <me@joshdover.com>
Co-authored-by: Josh Dover <1813008+joshdover@users.noreply.github.com>
Co-authored-by: Gidi Meir Morris <github@gidi.io>
Co-authored-by: Nathan Reese <reese.nathan@gmail.com>
Co-authored-by: Wylie Conlon <wylieconlon@gmail.com>
Co-authored-by: CJ Cenizal <cj@cenizal.com>
Co-authored-by: Aleh Zasypkin <aleh.zasypkin@gmail.com>
Co-authored-by: Dario Gieselaar <dario.gieselaar@elastic.co>
Co-authored-by: restrry <restrry@gmail.com>
Co-authored-by: James Gowdy <jgowdy@elastic.co>
Co-authored-by: John Schulz <github.com@jfsiii.org>
Co-authored-by: Alison Goryachev <alisonmllr20@gmail.com>
2021-03-25 04:47:16 -04:00
Yuliia Naumenko 25baa3b558
[Connectors UI] Make UI use new connector APIs (#94180)
* [Connectors UI] Make UI use new connector APIs

* fixed tests

* fixed due to comment

* fixed due to comment

* fixed test

* fixed test

* fixed test

* moved rewrite_request_case to the common folder

* fixed due to comments
2021-03-16 12:59:46 -07:00
ymao1 a7c9d3f1e0
[Alerting] Update UI to reflect new terminology (#93597)
* Renaming alerts to rules

* Updating formatted messages

* Updating i18n labels

* Completed renaming in UI

* Updating client routes including redirect

* wip docs update

* Reverting title changes for now

* Fixing types check

* Fixing unit tests

* Fixing functional test

* Fixing functional test

* docs wip

* wip docs update

* Finished first run through docs

* docs docs docs

* Fixing bad merge

* Fixing functional test

* Docs cleanup

* Cleaning up i18n labels

* Fixing functional test

* Updating screenshots

* Updating screenshots

* Updating screenshots

* Updating terminology in alerting examples

* Updating terminology in alerting examples

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-03-15 10:03:39 -04:00
ymao1 023d9a028b
[Alerting] Update alerting action variables to follow new terminology (#93836)
* Removing duplicate ActionVariable interface. Updating common action variables in UI

* Passing in alert values as rule variables in transform_action_params

* Fixing unit tests

* Fixing functional test

* Adding functiional test

* Updating paths

* Fixing i18n

* Fixing i18n

* Fixing api docs

* Plugin api build

* Moving spaceId and tags under rule prefix

* Using top level alert prefix

* Fixing i18n

* build api docs

* Fixing functional test

* Fixing functional test
2021-03-09 07:48:38 -05:00
Mike Côté 23ce8dcfdb
Rename alerts plugin to alerting (#92898)
* Rename alerts plugin to alerting

* Deprecate old config values

* Few more renames

* Update plugin list

* Rename xpack.alerts -> xpack.alerting

* Fix some ESLint rules

* Fix typecheck

* Fix some test failures

* Some more renames

* Fix ESLint

* Fix some test failures

* Fix failing jest test

* Undo exclusive test

* Fix APM deps

* Fix docs

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-03-05 13:59:34 -05:00
spalger e1fa0bfa9c skip flaky suite (#88177) 2021-02-24 09:38:45 -07:00
Shahzad a1a9769f83
[Uptime] increase flaky alert retry time (#91455) 2021-02-16 18:53:33 +01:00
Dima Arnautov 341e9cf2eb
[ML] Anomaly Detection alert type (#89286)
* [ML] init ML alerts

* [ML] job selector

* [ML] move schema server-side

* [ML] fix type 🤦‍

* [ML] severity selector

* [ML] add alerting capabilities

* [ML] add alerting capabilities

* [ML] result type selector

* [ML] time range selector

* [ML] init alert preview endpoint

* [ML] update SeveritySelector component

* [ML] adjust the form

* [ML] adjust the form

* [ML] server-side, preview component

* [ML] update defaultMessage

* [ML] Anomaly explorer URL

* [ML] validate preview interval

* [ML] rename alert type

* [ML] fix i18n

* [ML] fix TS and mocks

* [ML] update licence headers

* [ML] add ts config references

* [ML] init functional tests

* [ML] functional test for creating anomaly detection alert

* [ML] adjust bucket results query

* [ML] fix messages

* [ML] resolve functional tests related issues

* [ML] fix result check

* [ML] change preview layout

* [ML] extend ml client types

* [ML] add missing types, remove unused client variable

* [ML] change to import type

* [ML] handle preview error

* [ML] move error callout

* [ML] better error handling

* [ML] add client-side validation

* [ML] move fake request to the executor

* [ML] revert ml client type changes, set response type manually

* [ML] documentationUrl

* [ML] add extra sentence for interim results

* [ML] use publicBaseUrl

* [ML] adjust the query

* [ML] fix anomaly explorer url

* [ML] adjust the alert params schema

* [ML] remove default severity threshold for records and influencers

* [ML] fix query with filter block

* [ML] fix functional tests

* [ML] remove isInterim check

* [ML] remove redundant fragment

* [ML] fix selected cells hook

* [ML] set query string

* [ML] support sample size by the preview endpoint

* [ML] update counter

* [ML] add check for the bucket span

* [ML] fix effects

* [ML] disable mlExplorerSwimlane

* [ML] refactor functional tests to use setSliderValue

* [ML] add assertTestIntervalValue

* [ML] floor scores
2021-02-11 18:14:14 +01:00
Alejandro Fernández Haro 6bd0a7fcc5
[Plugins Discovery] Enforce camelCase plugin IDs (#90752)
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-02-11 14:36:17 +00:00
Robert Oskamp 523110d4bd
Functional tests - Add esSupertest support for SSL (#90425)
This PR allows the functional test service esSupertest to work correctly in environments that have ES SSL enabled in the Kibana server configuration.
2021-02-09 12:45:19 +01:00
ymao1 4b29e35246
[Alerting] Fixing bug with Index Threshold alert when selecting "Of" expression (#90174)
* Fixing bug

* Updating functional test

* Fixing functional test

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-02-08 11:16:36 -05:00
Brandon Kobel 4584a8b570
Elastic License 2.0 (#90099)
* Updating everything except the license headers themselves

* Applying ESLint rules

* Manually replacing the stragglers
2021-02-03 18:12:39 -08:00
ymao1 f3d7d37294
[Alerting] Allow user to select existing connector of same type when fixing broken connector (#89062)
* Adding dropdown for selecting different connector of same type

* Updating design

* Cleanup and i18n

* Adding functiional test

* Fixing unit test

* Fixing functional test

* Updating design

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-02-02 07:58:02 -05:00
ymao1 049135192e
[Alerting] Search alert (#88528)
* Adding es query alert type to server with commented out executor

* Adding skeleton es query alert to client with JSON editor. Pulled out index popoover into component for reuse between index threshold and es query alert types

* Implementing alert executor that performs query and matches condition against doc count

* Added tests for server side alert type

* Updated alert executor to de-duplicate matches and create instance for every document if threshold is not defined

* Moving more index popover code out of index threshold and es query expression components

* Ability to remove threshold condition from es query alert

* Validation tests

* Adding ability to test out query. Need to add error handling and it looks ugly

* Fixing bug with creating alert with threshold and i18n

* wip

* Fixing tests

* Simplifying executor logic to only handle threshold and store hits in action context

* Adding functional test for es query alert

* Types

* Adding functional test for query testing

* Fixing unit test

* Adding link to ES docs. Cleaning up logger statements

* Adding docs

* Updating docs based on feedback

* PR fixes

* Using ES client typings

* Fixing unit test

* Fixing copy based on comments

* Fixing copy based on comments

* Fixing bug in index select popover

* Fixing unit tests

* Making track_total_hits configurable

* Fixing functional test

* PR fixes

* Added unit test

* Removing unused import

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-01-29 07:45:00 -05:00
Patrick Mueller 14fa82dc54
[alerts] adds support for index threshold index param string type (#88540)
resolves https://github.com/elastic/kibana/issues/68575

The index threshold alert defines an `index` parameter which is
typed as `string | string[]`.  However the UI for this alert has
been typing it as only `string[]`.

This PR changes the UI to work with an incoming string value for
this parameter.  If the parameter is edited in the UI, it will always
be set as an array, even if there is only one element.
2021-01-25 16:43:46 -05:00
Gidi Meir Morris dfd96d62c4
ebsure we always select the correct index (#88876)
At times we find the driver controlling the ComboBox in our UI tests can select the wrong item, this ensures we always select the correct index in the Connector tests.
2021-01-21 12:09:19 +00:00
Tiago Costa 55d4331a2b
skip flaky suite (#88796) 2021-01-20 13:27:37 +00:00
ymao1 6d1c010607
[Alerting] Fixing broken Alerts view when no Global All Kibana privilege (#88727)
* Making kibanaFeatures an optional parameter and catching error on plugin start

* Gracefully handle 404 errors when no access to features endpoint

* Adding functional test
2021-01-19 18:14:56 -05:00
spalger 3953f9647e skip flaky suite (#88177) 2021-01-13 08:38:41 -07:00
ymao1 2c8b518f69
Fixes Failing test: Chrome X-Pack UI Functional Tests.x-pack/test/functional_with_es_ssl/apps/triggers_actions_ui/alerts_list·ts - Actions and Triggers app alerts list should display total alerts by status and error banner only when exists alerts with status error (#88119)
* Unskipping test

* Adding refresh before checking status
2021-01-13 08:01:08 -05:00
ymao1 666af32be4
[Alerting] Showing confirmation modal on Alert Add/Edit when flyout closed without saving and changes made. (#86370)
* Adding hasChanged check and showing confirmation modal if something has changed

* Showing confirmation always on close

* Adding functional test

* Setting name and tags for APM alerts using initial values instead of setAlertProperty

* Checking for alert param changes separately

* Checking for alert param changes separately

* Fixing functional test

* Resetting initial alert params on alert type change

* Fixing duplicate import

* Cloning edited alert

* PR fixes

* PR fixes

* Updating modal wording

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-01-11 16:16:10 -05:00
Tyler Smalley 91d73cf981 skip flaky suite (#87105) 2021-01-07 15:32:01 -08:00
ymao1 ff2d0f4659
[Alerting] Edit alert should show and update all actions with deleted connectors (#86838)
* Showing all broken connectors and updating all matching broken connectors on new connector create

* Adding unit test

* Adding functional test

* Fixing functional test

* Simplifying logic

* Fixing functional test

* Fixing functional test

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-01-06 15:11:28 -05:00
Gidi Meir Morris b99ca969e0
[Alerting] revert the revert of Enforces typing of Alert's ActionGroups (#87382)
The https://github.com/elastic/kibana/pull/86761 PR was reverted due to a small typing issue.

This PR reverts that revert and adds a commit to address the issue: 9e4ab2002c.
2021-01-06 10:38:33 +00:00
Yuliia Naumenko dddd8e4fe7
[Alerting UI] Alert and Connector flyouts Save and Save&Test buttons should be active by default. (#86708)
* Alert and Connector flyouts Save and Save&Test buttons should be active by default.

* fixed typechecks

* fixed typechecks

* refactored repeted code

* fixed typechecks

* fixed typechecks

* fixed typechecks

* fixed due to comments

* fixed failing tests

* fixed due to comments

* fixed due to comments

* fixed due to comments

* fixed typescript checks
2021-01-05 11:49:44 -08:00