Commit graph

356 commits

Author SHA1 Message Date
ymao1
9ba00ee594
[Actions] Allowing service specification in email connector config (#110458)
* Initial commit of serverType in email connector config

* Fleshing in route to get well known email service configs from nodemailer

* Adding elastic cloud to well known server type

* Cleaning up email constants and allowing for empty selection

* Showing error if user doesn't select server type

* Adding hook for setting email config based on server type

* Adding tests and making sure settings are not overwritten on edit

* Fixing functional test

* Adding migration

* Adding functional test for migration

* Repurposing service instead of adding serverType

* Cleanup

* Disabling host/port/secure form fields when settings retrieved from API

* Updating docs for service

* Filtering options based on whether cloud is enabled

* Initialize as disabled

* Fixing types

* Update docs/management/connectors/action-types/email.asciidoc

Co-authored-by: David Kilfoyle <41695641+kilfoyle@users.noreply.github.com>

Co-authored-by: David Kilfoyle <41695641+kilfoyle@users.noreply.github.com>
2021-09-03 09:49:00 -04:00
Spencer
fecdba7eba
[eslint] add rule to prevent export* in plugin index files (#109357)
* [eslint] add rule to prevent export* in plugin index files

* deduplicate export names for types/instances with the same name

* attempt to auto-fix duplicate exports too

* capture exported enums too

* enforce no_export_all for core too

* disable rule by default, allow opting-in for help fixing

* update tests

* reduce yarn.lock duplication

* add rule but no fixes

* disable all existing violations

* update api docs with new line numbers

* revert unnecessary changes to yarn.lock which only had drawbacks

* remove unnecessary eslint-disable

* rework codegen to split type exports and use babel to generate valid code

* check for "export types" deeply

* improve test by using fixtures

* add comments to some helper functions

* disable fix for namespace exports including types

* label all eslint-disable comments with related team-specific issue

* ensure that child exports of `export type` are always tracked as types

Co-authored-by: spalger <spalger@users.noreply.github.com>
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-09-01 18:05:45 -07:00
mgiota
098a797636
[Logs UI] stop accordion chart preview from auto expanding/collapsing (#109581)
* stop propagation to the criterion popovers

* fix toggling issue with criteria popovers

* Fixes for more popovers staying open

* another toggling fix "for the last" popover
2021-08-23 20:08:24 +02:00
Joe Portner
65e04b1380
Remove spacesOss plugin (#109258) 2021-08-23 15:10:09 +02:00
ymao1
48ce73db15
[Alerting] Update rules detail page to resolve SO IDs if necessary (#108091)
* Adding internal resolve API to resolve rules given an ID

* Updating after merge

* Updating after merge

* Adding resolveRule api to client and adding spacesOss plugin dependency

* Handling 404 errors by calling resolve. Updating unit tests

* Handling aliasMatch and conflict results

* Fixing types

* Unit tests for spaces oss components

* Adding audit event for resolve

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-08-18 22:32:19 -04:00
Stacey Gammon
9258ba5147
Adding owners to kibana plugins (#108407)
* Adding owners to kibana plugins

* Fix ui actions enhanced owner

* Account for virtual RAC team owning a plugin

* Fix empty githubTeam for ui actions
2021-08-17 10:21:06 -04:00
Dominique Clarke
c5ec5468c5
[Uptime] migrate legacy alert apis (#107863)
* uptime - migrate legacy alert apis

* update alert fetch actions

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-08-16 14:02:49 -04:00
Chris Roberson
b5bd063f51
Deprecate ability to disable alerting, actions, task manager, stack alerts, and event log plugins (#108281)
* Add deprecation warnings for .enabled config for all our plugins

* Add tests

* Add stackAlerts

* Fix stack alerts

* Add tests

* Add triggers_action_ui

* Add deprecated warning to the docs
2021-08-12 21:34:05 -04:00
Spencer
c0395c9ef6
[build_ts_refs] improve caches, allow building a subset of projects (#107981)
* [build_ts_refs] improve caches, allow building a subset of projects

* cleanup project def script and update refs in type check script

* rename browser_bazel config to avoid kebab-case

* remove execInProjects() helper

* list references for tsconfig.types.json for api-extractor workload

* disable composite features of tsconfig.types.json for api-extractor

* set declaration: true to avoid weird debug error

* fix jest tests

Co-authored-by: spalger <spalger@users.noreply.github.com>
2021-08-10 22:12:45 -07:00
Yuliia Naumenko
538a6d9288
[Actions UI] Fixed Jira Api token label. (#107776)
* [Actions UI] Fixed Jira Api token label.

* fixed tests

* fixed username

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-08-10 17:11:11 -07:00
Yuliia Naumenko
e89d069f09
[Alerting UI] Fixed display permissions for edit/delete buttons when user has read only access. (#107996)
* [Alerting UI] Fixed display permissions for Edit/delete buttons when user has read only access

* fixed due to comments
2021-08-10 17:10:49 -07:00
ymao1
565e07104c
[Alerting UI] Not showing edit button in rule management UI if rule is not editable in UI (#107801)
* Should not show edit button on rule management page if rule not editable in stack

* Disabling edit button in collapsed actions

* Adding tests for collapsed item actions component

* Cleanup

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-08-10 16:18:10 -04:00
Yuliia Naumenko
30f68dda66
[Alerting UI] Added visual indicator when enable switched click is processed on the server side. (#107272)
* [Alerting UI] Added visual indicator when enable switched click is processed on the server side.

* fixed rule details

* fixed functional tests

* fixed unit tests

* fixed due to comments

* fixed due to comments
2021-08-04 14:42:49 -07:00
ymao1
df421f869f
[Alerting] Fix health check to allow access to alerting when ES security is disabled (#107032)
* Using license plugin to check if es security is enabled

* Adding unit tests and updating legacy health route

* Updating UI copy and docs

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-08-02 10:37:30 -04:00
Christos Nasikas
2388ac5de7
[Actions] Swimlane: Fix connectorType schema (#106969)
* Fix connectorType schema

* Add integration test
2021-07-28 08:51:44 -04:00
Yuliia Naumenko
f589c2fc29
[Alerting] Rename alertTypeRegistry to ruleTypeRegistry according to the new terminology. (#106519)
* [Alerting] Renamed Alerting framework AlertsClient to RulesClient according to the new terminology.

* fixed path

* fixed type checks

* fixed type checks

* [Alerting] Rename alertTypeRegistry to ruleTypeRegistry.

* Apply suggestions from code review

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

* fixed type checks

* fixed tests

* fixed merge issues

* fixed merge issues

* fixed tests

* fixed tests

* fixed functional tests

Co-authored-by: ymao1 <ying.mao@elastic.co>
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-07-27 10:03:00 -07:00
Christos Nasikas
e383b57ba1
[Alerting] Pass EuiIcon props to connectors logos (#106449)
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-07-22 11:15:50 +03:00
Yuliia Naumenko
d91c6d0cfb
[Alerting UI]Changed rules table to support visual indication for disabled and muted alerts (#104190)
* [Alerting UI]Changed rules table to support visual indication for disabled or muted alerts

* changed columns styles due to the mockup

* added tests

* fixed quotas

* fixed popover

* fixed due to the lates UI updates

* fixed errors

* moved enabled to a separate component

* fixed tests

* fixed due to comments

* Update x-pack/plugins/triggers_actions_ui/public/application/sections/alerts_list/components/alerts_list.scss

Co-authored-by: Mike Côté <mikecote@users.noreply.github.com>

* removed test code

* fixed tests

* fixed due to comments

* fixed due to comments

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
Co-authored-by: Mike Côté <mikecote@users.noreply.github.com>
2021-07-20 08:41:15 -07:00
Christos Nasikas
604b424212
[Actions] Swimlane: Change API Token field to a password textfield (#105475)
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-07-14 11:21:58 +03:00
Yuliia Naumenko
316e0b36ff
[Alerting UI] Fixed bug when rule state was updated on Edit flyout opening: Index action set empty documents property for non history index. (#105014) 2021-07-09 06:18:38 -07:00
Christos Nasikas
3ac067fc91
[Cases] Swimlane: Fix bug when creating the connector with empty mapping. (#103446) 2021-06-30 11:08:04 -04:00
Yuliia Naumenko
7b8645e0fc
[Alerting] Fixed search results are not updated when search term is removed on Rules and Connectors page (#103663) 2021-06-30 02:17:07 -07:00
Caroline Horn
7d45fcf8ee
[Page layouts] Some light fixes (#103197)
* [Solution Toolbar] Fixing button border on non-text color versions

* [Alerts] Removed extra wrappers and use EuiPageHeader

* [Logstash] Basic conversion to template

* [Reporting] Adding bottomBorder to page header

* [ML] Fix display of main navigation tabs

* [Stack Management] Fix side nav not updating when going back to landing page

* [Tags] Add spacing after page header

* [License Management] Full width on file uploader

* [Page Template] Fixed `emptyState` default template for pages with side nav

* [Infra] Removing some page header displays in empty states

* [Enterprise Search] Fix some error layouts

* [Index Patterns] Quick fix for empty state

* snaps

* [Page Template] Remove forced padding when `centeredBody`

* small hack for tab padding for ml

* scroll ML page to fix test

* fix test method type signature

Co-authored-by: Dave Snider <dave.snider@gmail.com>
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
Co-authored-by: Michail Yasonik <michail.yasonik@elastic.co>
2021-06-29 19:50:15 -05:00
ymao1
2ff2a6fa50
Adding tooltip to rules that are disabled due to license (#103295)
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-06-28 09:47:32 -04:00
Anton Dosov
be1c5bbd72
Don't import react-intl directly to reduce bundle sizes (#102497) 2021-06-24 16:52:55 +02:00
Greg Thompson
136d361703
Upgrade EUI to v34.3.0 (#101334)
* eui to v34.1.0

* styled-components types

* src snapshot updates

* x-pack snapshot updates

* eui to v34.2.0

* styled-components todo

* src snapshot updates

* x-pack snapshot updates

* jest test updates

* collapsible_nav

* Hard-code global nav width for bottom bar’s (for now)

* Update to eui v34.3.0

* flyout unmock

* src flyout snapshots

* remove duplicate euioverlaymask

* xpack flyout snapshots

* remove unused import

* sidenavprops

* attr updates

* trial: flyout ownfocus

* remove unused

* graph selector

* jest

* jest

* flyout ownFocus

* saved objects flyout

* console welcome flyout

* timeline flyout

* clean up

* visible

* colorpicker data-test-subj

* selectors

* selector

* ts

* selector

* snapshot

* Fix `use_security_solution_navigation` TS error

* cypress

Co-authored-by: cchaos <caroline.horn@elastic.co>
Co-authored-by: Chandler Prall <chandler.prall@gmail.com>
2021-06-23 15:10:34 -05:00
Steph Milovic
2dc1715a8a
[Security Solution] [Cases] Swimlane Connector for Cases (#100086)
Co-authored-by: Josh <josh.rickard@swimlane.com>
Co-authored-by: Xavier Mouligneau <189600+XavierM@users.noreply.github.com>
Co-authored-by: Christos Nasikas <christos.nasikas@elastic.co>
Co-authored-by: Jonathan Buttner <jonathan.buttner@elastic.co>
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-06-23 22:14:43 +03:00
Mikhail Shustov
f3ec948bee
Cleanup outdated @elastic/elasticsearch client type errors (#101741)
* fix errors and update comments in Core

* fix errors or update comments in Security plugin

* update spaces test

* update task_manager files

* update comments in monitoring plugin

* fix errors in update comments in security_solutions

* fix errors and update comments in data_enhanced

* update fleet code

* update infra code

* update comment in trigger_actions_ui

* update comment in lens

* update comments in ES-UI code

* update typings for search

* update monitoring

* remove outdated export
2021-06-21 10:03:00 -04:00
ymao1
b242765654
[Alerting][Docs] Combine rule creation and management pages (#101498)
* Combining rule management stuff into single page

* Cleaning up image widths and header sizes

* Adding in placeholder pages

* Adding in placeholder pages

* Apply suggestions from code review

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

* PR and test fixes

* Apply suggestions from code review

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

* PR fixes

* PR fixes

Co-authored-by: gchaps <33642766+gchaps@users.noreply.github.com>
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-06-10 17:46: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
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
Yuliia Naumenko
ff0bcea337
[Alerting UI] Fixed broken ES Index action type validation. (#101504)
* [Alerting UI] Fixed broken ES Index action type validation.

* Revert unnecesary changes
2021-06-08 07:54:49 -07:00
Christos Nasikas
451f64bde0
[Cases] Get connector's information from actionsTypeRegistry (#101279)
Co-authored-by: Yuliia Naumenko <yuliia.naumenko@elastic.com>
2021-06-08 13:35:54 +03:00
Yuliia Naumenko
45ae6cc39b
[Alerting UI] Reduced triggersActionsUi bundle size by making all action types UI validation messages translations asynchronous. (#100525)
* [Alerting UI] Reduced triggersActionsUi bundle size by making all connectors validation messages translations asyncronus.

* changed validation logic to be async

* fixed action form

* fixed tests

* fixed tests

* fixed validation usage in security

* fixed due to comments

* fixed due to comments

* added spinner for the validation awaiting

* fixed typechecks

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-06-02 22:33:43 -07:00
Yuliia Naumenko
5ebded2105
[triggersActionsUi] Reduce page load bundle to under 100kB (#97770)
* [triggersActionsUi] Reduce page load bundle to under 100kB

* removed old code

* removed fragment

* changed svg logo to lazy react components

* fixed type checks and translations

* fixed type checks

* fixed type checks

* fixed type checks

* fixed tests

* fixed tests

* fixed iconClass

* fixed due to comments

* added info about new IconType to readme file

* fixed key errors
2021-05-25 19:00:29 -07:00
Yuliia Naumenko
8a344fa385
[Alerting] Enabling import of rules and connectors (#99857)
* [Alerting] Enabling import of rules and connectors

* changed export to set pending executionStatus for rule

* fixed tests

* added docs

* Apply suggestions from code review

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

* fixed docs

* fixed docs

* Update x-pack/plugins/alerting/server/saved_objects/get_import_warnings.ts

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

* fixed test

* fixed test

Co-authored-by: gchaps <33642766+gchaps@users.noreply.github.com>
2021-05-14 07:43:09 -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
Yuliia Naumenko
9009efaf91
[Connectors][UI] Updated connectors list UI for connectors that need to be updated after import. (#98565)
* [Connectors][UI] Updated connectors list UI for connectors that need to be updated after import

* added ui property isMissingSecrets

* added info for medit form

* fixed tests

* fixed due to comments

* fixed due to comments

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-05-05 19:13:43 -07:00
ymao1
a17d26132a
[Alerting] Handling connectors with missing secrets during rule creation and action execution (#98618)
* [Connectors][API] Updated connectors with enabledAfterImport flag

* fixed functional tests

* added new field to connectors API docs

* added update unit test

* fixed test

* renamed enableAfterImport to isMissingSecrets

* removed onExport

* revert the logic of true/false for isMissingSecrets

* fixed test

* fixed tests

* added unit test

* fixed docs

* fixed import text and button labels

* fixed import text

* fixed text

* Showing placeholder message when connector is missing secrets

* Throwing error on isMissingSecrets = true before executing actions

* Hiding connectors with missing secrets from dropdown

* Checking for connectors with missing secrets during action validation on rule creation/update

* Updating error wording

Co-authored-by: Yuliia Naumenko <yuliia.naumenko@elastic.com>
2021-05-04 12:32:30 -04:00
ymao1
951da754e0
Allowing validation of multiple actions with same connector id (#98065)
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-05-03 10:11:49 -04:00
ymao1
26315aa751
[Alerting] Fixing null accessor error in index threshold alert (#98055)
* Fixing null accessor error in index threshold alert

* PR fixes

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-04-23 16:54:54 -04: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
Yuliia Naumenko
9cf66a78e9
[Docs][Alerting] Changed overall alerting documentation structure (#95004)
* [Docs][Alerting] Changed overall alerting documentation structure

* fixed image link

* moved alerting and connectors under the graph in the menu list

* moved management docs to alerting and connectors

* fixed image link

* fixed connector menu position

* fixed mappings

* fixed mappings

* fixed links

* fixed levels

* move manage connectors before action types

* adjust connectors management

* adjust connectors management

* split domain specific and stack rules

* fixed rule types links

* added connectors ui images

* fixed image links

* fixed image links

* fixed image links

* test

* fixed image links

* fixed broken links

* fixed broken links

* fixed email links

* fixed email links

* fixed email links

* fixed links

* added images to connectors docs

* Update docs/user/alerting/rule-management.asciidoc

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

* Update docs/user/alerting/stack-rules.asciidoc

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

* fixed due to comments

* fixed due to comments

* fixed create connector

* moved connectors to stack management section

* removed bazel files

* fixed managing-alerts-and-actions links

* Revert "fixed managing-alerts-and-actions links"

This reverts commit 0ed228b090.

* fixed code owners

Co-authored-by: gchaps <33642766+gchaps@users.noreply.github.com>
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-04-19 15:54:54 -07:00
Chris Roberson
9a76d34b04
[Alerting] Show more user friendly ES error message when executor fails (#96254)
* WIP for ES error parser

* Fix tests

* Ensure the error shows up in the UI too

* wip

* Handle multiple types here

* Fix tests

* PR feedback

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-04-15 10:15:40 -04:00
ymao1
4f6bd31c91
[Alerting] Fixing notifyWhen terminology (#96490)
* Updating terminology

* Updating wording

* Updating wording
2021-04-12 21:12:45 -04:00
Yuliia Naumenko
b54d5fc909
[Actions UI] Changed PagerDuty action form UI to fill payload fields according to the API docs for Resolve and Acknowledge events. (#96363)
* [Actions UI] Changed PagerDuty action form UI to fill payload fields according to the API docs for Resolve and Acknowledge events.

* fixed test

* fixed test

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-04-08 17:21:26 -07: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
Mike Côté
81ba969cfa
Skip rendering empty add action variables button as disabled (#96342)
* Skip rendering empty add action variables button

* Fix jest tests

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-04-08 05:24:16 -04:00
Yuliia Naumenko
76ed8dbeab
[Alerting UI] Changed alerting UIs use new rule APIs. (#96018)
* [Alerting UI] Changed alerting UIs use new rule APIs.

* added unit tests

* fixed types

* fixed types

* fixed types

* fixed due to comments
2021-04-07 07:54:12 -07:00
ymao1
bb109b533c
[Actions] Hiding time field selector if no field with date mapping in index in Index Connector flyout (#96080)
* Hiding time field selector if no field with date mapping in index

* Fixing types check

* Updating tooltip

* PR fixes
2021-04-07 10:44:12 -04:00