Commit graph

624 commits

Author SHA1 Message Date
Lukas Olson d7b1cbbed5
[data.search.searchSource] Add fetch$ observable for partial results (#89211)
* [data.search.searchSource] Add fetch$ observable for partial results

* Fix mocks & add tests

* Update docs

* Update docs

* Review feedback
2021-01-29 10:01:35 -07:00
Pierre Gayvallet ec8738a060
add synchronous config access API (#88981)
* add synchronous config accessor

* add `config.get` to plugin context and add tsdoc

* remove useless markAsHandled calls

* fix mocks

* update generated docs

* fix unit tests

* add sync accessor for legacy config
2021-01-28 11:52:38 +01:00
Anton Dosov 07b210e42d
[Search Sessions] Improve session restoration back button (#87635) 2021-01-28 09:54:26 +01:00
Ahmad Bamieh 82902e8918
[Telemetry] Settings Collector: redact sensitive reported values (#88675) 2021-01-27 17:57:53 +02:00
Scotty Bollinger cadcbf8845
[Enterprise Search] Add links to doc links service (#89260)
* [Enterprise Search] Add links to doc links service

* Remove extra slash

* Add types

* Update API docs and API review
2021-01-27 08:52:44 -06:00
Anton Dosov b8947e3e15
[Search Sessions] Make search session indicator UI opt-in, refactor per-app capabilities (#88699) 2021-01-27 11:52:13 +01:00
Tiago Costa 8250b078b4
chore(NA): improve ts build refs performance on kbn bootstrap (#89333)
* chore(NA): improve ts build refs performance on kbn bootstrap

* chore(NA): use skipLibCheck=false by default on typechecking

* docs(NA): commit core docs changes

* fix(NA): eui typings
2021-01-27 00:59:24 +00:00
Peter Pisljar d81ab83c16
[examples] expressions explorer (#88344) 2021-01-22 19:52:47 +01:00
Matthew Kime ae0bd2fbba
Add runtime fields to index patterns and searchsource (#88542)
* Add runtime fields to index patterns and searchsource
2021-01-21 14:10:19 -06:00
Pierre Gayvallet 477d0bbe21
add SavedObject export hooks (#87807)
* initial POC

* fix spaces UT

* address POC feedback, add tests for applyExportTransforms

* add sorting for transforms

* add type validation in SOTR

* add FTR tests

* update documentation

* add explicit so type export for client-side

* update generated doc

* add exporter test

* update license headers

* update generated doc

* fix so import... imports

* update generated doc

* nits

* update generated doc

* rename test plugins

* adding FTR tests on export failures
2021-01-21 15:27:28 +01:00
Mikhail Shustov b3a9754394
[Core] Explicit typings for request handler context (#88718)
* move context to server part. couple with RequestHandlerContext

Context implementation will be simplified in follow-up.

* adopt core code

* adopt bfetch code

* adopt data code

* adopt search examples

* adopt vis_type_timelion

* adopt vis_type_timeseries

* adopt plugin functional tests

* adopt actions

* adopt alerting plugin

* adopt APM plugin

* adopt beats_management

* adopt case plugin

* adopt cross_cluster_replication

* adopt data_enhanced

* adopt event_log

* adopt global_search

* adopt index_management

* adopt infra

* adopt licensing

* adopt lists

* adopt logstash

* adopt reporting

* adopt observability

* adopt monitoring

* adopt rollup

* adopt so tagging

* adopt security

* adopt security_solutions

* adopt watcher

* adopt uptime

* adopt spaces

* adopt snapshot_restore

* adopt features changes

* mute error when null used to extend context

* update docs

* small cleanup

* add type safety for return type

* refactor registerRouteHandlerContext type

* update docs

* update license header

* update docs

* fix type error. fetch body does not accept array of strings

* fix telemetry test

* remove unnecessary ts-ignore

* address comments

* update docs
2021-01-21 15:20:22 +01:00
Joe Portner 25f16db4d9
Sharing saved objects, phase 2 (#80945) 2021-01-20 17:39:21 -05:00
Matthew Kime 1edc799894
[index patterns] improve developer docs (#86416)
* add index pattern docs
2021-01-20 14:21:38 -06:00
Pierre Gayvallet edb338a8ad
Add SO import hook / warnings API (#87996)
* initial commit

* adapt client-side signatures

* more type fixes

* adapt api IT asserts

* fix some unit tests

* fix more test usages

* fix integration tests

* fix FT test assertions

* fix FT test assertions

* add FTR API integ test suite

* create the plugin_api_integration test suite

* adapt and fix flyout tests

* update documentation

* update generated doc

* add unit tests for `executeImportHooks`

* wire resolve_import_errors and add unit tests

* move hooks registration to SO type API

* update generated doc

* design integration

* update generated doc

* Add FTR tests for import warnings

* deletes plugins api integ tests

* self review

* move onImport to management definition

* update license header

* rename actionUrl to actionPath
2021-01-20 19:25:32 +01:00
Marco Liberati 86789dabb5
[Lens] Add more in-editor Advanced documentation (#86821)
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
Co-authored-by: Wylie Conlon <wylieconlon@gmail.com>
Co-authored-by: Michael Marcialis <michael.marcialis@elastic.co>
2021-01-20 17:49:21 +01:00
Brandon Kobel 170a2956c8
Updating the License (#88343)
* Updating the Licenses, except for applying eslint, building

* Applying ESLint rules,building @kbn/pm, regenerating api docs
2021-01-19 17:52:56 -08:00
Ahmad Bamieh f5c73a9ac7
[SavedObjects] Allow migrations to be a function (#88594)
Co-authored-by: Rudolf Meijering <skaapgif@gmail.com>
2021-01-19 18:37:48 +02:00
Mikhail Shustov 6e4c70848d
[Core] Remove public context (#88448)
* remove client side context

* update docs

* fix tests

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-01-18 21:47:53 +01:00
Aleh Zasypkin abfd8bb9d3
Use documentation links service provided by the core directly. (#88158) 2021-01-15 13:31:51 +01:00
Aleh Zasypkin 951aa66fe4
Expose AnonymousAccess service through Security OSS plugin. (#87091) 2021-01-15 10:18:58 +01:00
Joe Portner a62d6939bd
Fixes incomplete client cert chain when using PKI authentication with the login selector (#88229) 2021-01-14 09:15:41 -05:00
Stratoula Kalafateli 633495ef43
[XY axis] Implement new palette service (#86876)
* [XY Axis] New Palette service

* Calculate all Series to map the colors correctly

* remove commented out code

* syncColors on XY plugin

* Reset to false when no embeddable

* Add unit test for getAllSeries function

* Measure the usage of the selected palette

* Minor adjustments

* Update documentation for isSyncColorsEnabled method

* Fix bug on changing palette on charts with no split series

* Fix coloring for multiple y axis visualizations

* Call getPalettes function from the renderer

* Fullwidth palette picker

* Fetch palette registry on the component and not on the renderer

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-01-13 15:56:28 +02:00
Anton Dosov d3303f28bb
[Search] Search Sessions with relative time range (#84405) 2021-01-12 14:51:04 +01:00
Liza Katz 91aed6f961
[Search][Sessions] Rename Background Sessions to Search Sessions (#87500)
* Rename Background Sessions to Search Sessions (with a send to background action)

* doc

* doc

* jest fun

* rename rfc

* translations

* update so name in features

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-01-07 17:28:27 +02:00
Pierre Gayvallet f59711945d
Expose SO import/export APIs from the service's contract instead of exporting static functions (#86264)
* Add user doc for SO tagging

* add link to new page

* handle review feedbacks

* second pass

* create SO exporter class

* adapt spaces code

* typo fix

* adapt tests

* some doc

* update generated doc

* fix spaces tests

* move ALL the import things

* adapt / move types

* create context, adapt core code

* adapt integration tests

* rename for consistency

* adapt spaces usages

* adapt spaces routes usages

* remove unused getImportExportObjectLimit

* fix tsdoc

* update generated doc

* doc nits

* review comments

* add test for fetchByObjects failure

* add custom errors for exporter

* remove `getImportExportObjectLimit` API

* fix IT

* update generated doc

* adapt UT

* forgot one Boom usage

* rename import error to failure

* remove Boom usages from importer

* update generated doc

* fix spaces types
2021-01-07 11:23:28 +01:00
Lisa Cawley 63f7105903
Use doc links service for Dashboard and Discover help links (#87224) 2021-01-06 11:59:44 -08:00
Lukas Olson a2b4517b9e
[data.search.session] Add extend functionality to server-side search service (#86195)
* [data.search.session] Store search strategy in saved object

* [data.search.session] Add extend functionality

* Update docs

* Update unit test to check strategy

* Throw kbnServerError instead of error

* Fix test

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-01-05 08:26:06 -07:00
Lisa Cawley f048ae616a
Add more URLs to documentation link service (#87265) 2021-01-05 06:21:10 -08:00
Larry Gregory d6cf633e4f
Introduce mechanism to request default capabilities (#86473)
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-01-05 07:37:14 -05:00
Josh Dover 0af81310b6
Remove dynamic mapped types from UiActions (#87075)
* Remove dynamic mapped types from UiActions

* Remove import between data <-> embeddables

* remove outdated comments, export action types from discover_enhanced

* fix notice.txt

Co-authored-by: restrry <restrry@gmail.com>
2021-01-05 10:11:05 +01:00
Lisa Cawley e3486648b9
Adds more URLs to the docs links service (#86972)
Co-authored-by: Luke Elmers <lukeelmers@gmail.com>
2020-12-30 11:29:39 -08:00
Devon Thomson 1d856c39b5
Fix Add From Library Flyout Staying Open (#86698)
* Fixed add from library flyout staying open after save or cancel
2020-12-22 11:41:35 -05:00
Joe Reuter 57a72a78f7
[Lens] Configurable color syncing (#86180) 2020-12-22 17:35:27 +01:00
Matthew Kime c129f93083
[index patterns] Fleep app - Keep saved object field list until field caps provides fields (#85370) 2020-12-19 21:56:06 -06:00
Thomas Watson e8b21bc6c1
Upgrade to hapi version 20 (#85406) 2020-12-19 13:10:11 +01:00
Luke Elmers 9a3e2910a3
App Services: Remove remaining uiActions, expressions, data, embeddable circular dependencies. (#82791)
* Move applyFilter, selectRange, valueClick triggers to data/embeddables.

* Update imports.

* Remove embeddable references to non-existent data plugin dependency.

* remove data mocks from embeddable

* Remove query, filters, timeRange from EmbeddableInput and move to apps.

* Remove data plugin imports from embeddable test samples.

* Remove circular dependencies caused by expressions renderer handlers.

* Update circular deps allowList.

* Remove data dependency on embeddable.

* Revert accidental data plugin change.

* Fix new circular deps issues.

* Update generated docs.

* Fix type errors in vis_type_xy

* Fix inspector data table.
2020-12-18 18:34:07 -07:00
Devon Thomson 8ce9b474d6
[Time to Visualize] Fix Dashboard OnAppLeave (#86193)
Added isTransferInProgress to embeddable_state_transfer for apps to determine whether or not to show onAppLeave confirm
2020-12-18 15:07:36 -05:00
Christiane (Tina) Heiligers 3a6e2a31c7
[GS] Allows apps to register searchable keywords for Global Search (#85686) 2020-12-18 08:10:28 -07:00
Peter Pisljar b93034b72c
inspector table adapter cleanup (#84232) 2020-12-17 12:14:07 +01:00
Lisa Cawley 5c64db9695
[ML] Add transforms to doc links service (#86036) 2020-12-16 08:23:39 -08:00
Rudolf Meijering 89bd0fbf1e
Resilient saved object migration algorithm (#78413)
* Initial structure of migration state-action machine

* Fix type import

* Retries with exponential back off

* Use discriminated union for state type

* Either type for actions

* Test exponential retries

* TaskEither types for actions

* Fetch indices instead of aliases so we can collect all index state in one request

* Log document id if transform fails

* WIP: Legacy pre-migrations

* UPDATE_TARGET_MAPPINGS

* WIP OUTDATED_DOCUMENTS_TRANSFORM

* Narrow res types depending on control state

* OUTDATED_DOCUMENTS_TRANSFORM

* Use .kibana instead of .kibana_current

* rename control states TARGET_DOCUMENTS* -> OUTDATED_DOCUMENTS*

* WIP MARK_VERSION_INDEX_READY

* Fix and expand INIT -> * transition tests

* Add alias/index name helper functions

* Add feature flag for enabling v2 migrations

* split state_action_machine, reindex legacy indices

* Don't use a scroll search for migrating outdated documents

* model: test control state progressions

* Action integration tests

* Fix existing tests and type errors

* snapshot_in_progress_exception can only happen when closing/deleting an index

* Retry steps up to 10 times

* Update api.md documentation files

* Further actions integration tests

* Action unit tests

* Fix actions integration tests

* Rename actions to be more domain-specific

* Apply suggestions from code review

Co-authored-by: Josh Dover <me@joshdover.com>

* Review feedback: polish and flesh out inline comments

* Fix unhandled rejections in actions unit tests

* model: only delay retryable_es_client_error, reset for other left responses

* Actions unit tests

* More inline comments

* Actions: Group index settings under 'index' key

* bulkIndex -> bulkOverwriteTransformedDocuments to be more domain specific

* state_action_machine tests, fix and add additional tests

* Action integration tests: updateAndPickupMappings, searchForOutdatedDocuments

* oops: uncomment commented out code

* actions integration tests: rejection for createIndex

* update state properties: clearer names, mark all as readonly

* add state properties currentAlias, versionAlias, legacyIndex and test for invalid version scheme in index names

* Use CONSTANTS for constants :D

* Actions: Clarify behaviour and impact of acknowledged: false responses

* Use consistent vocabulary for action responses

* KibanaMigrator test for migrationsV2

* KibanaMigrator test for FATAL state and action exceptions in v2 migrations

* Fix ts error in test

* Refactor: split index file up into a file per model, next, types

* next: use partial application so we don't generate a nextActionMap on every call

* move logic from index.ts to migrations_state_action_machine.ts and test

* add test

* use `Root` to allow specifying oss mode

* Add fix and todo tests for reindexing with preMigrationScript

* Dump execution log of state transitions and responses if we hit FATAL

* add 7.3 xpack tests

* add 100k test data

* Reindex instead of cloning for migrations

* Skip 100k x-pack integration test

* MARK_VERSION_INDEX_READY_CONFLICT for dealing with different versions migrating in parallel

* Track elapsed time

* Fix tests

* Model: make exhaustiveness checks more explicit

* actions integration tests: add additional tests from CR

* migrations_state_action_machine fix flaky test

* Fix flaky integration test

* Reserve FATAL termination only for situations which we never can recover from such as later version already migrated the index

* Handle incompatible_mapping_exception caused by another instance

* Cleanup logging

* Fix/stabilize integration tests

* Add REINDEX_SOURCE_TO_TARGET_VERIFY step

* Strip tests archives of */.DS_Store and __MAC_OSX

* Task manager migrations: remove invalid kibana property when converting legacy indices

* Add disabled mappings for removed field in map saved object type

* verifyReindex action: use count API

* REINDEX_BLOCK_* to prevent lost deletes (needs tests)

* Split out 100k docs integration test so that it has it's own kibana process

* REINDEX_BLOCK_* action tests

* REINDEX_BLOCK_* model tests

* Include original error message when migration_state_machine throws

* Address some CR nits

* Fix TS errors

* Fix bugs

* Reindex then clone to prevent lost deletes

* Fix tests

Co-authored-by: Josh Dover <me@joshdover.com>
Co-authored-by: pgayvallet <pierre.gayvallet@elastic.co>
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2020-12-15 21:40:02 +01:00
Devon Thomson ee37f6dd91
[Time to Visualize] Transition Embeddable State Transfer to Session Storage (#85688)
* Transitioned embeddable state transfer service to use sessionStorage
2020-12-15 13:18:36 -05:00
Daniil 845f716271
[Data table] Reactify & EUIficate the visualization (#70801)
* Use data grid for table vis

* Create basic table template

* Add table_vis_split component

* Apply cell filtering

* Add aria-label attributes

* Use field formatters for values

* Add no results component

* Remove legacy dependencies

* Add usePagination

* Create usePagination util

* Use percentage column and total row

* Use csv export button

* Update labels

* Fix merge conflicts

* Use split table

* Fix functional tests

* Fix dashboard tests

* Update data table functional tests

* Fix missed test

* Introduce showToolbar option

* Remove useless package

* Fix merge conflicts

* Return back kibanaUtils required bundle

* Revert "Remove useless package"

This reverts commit 144a7cd77c.

* Use feature flag for legacy vis

* Add footer row

* Remove lock files

* Revert "Remove lock files"

This reverts commit 5c5acd79f4.

* Minor fixes

* Use common no result message

* Fix broken tests

* Use ui state sorting

* Fix error

* Fix merge conflicts

* Add legacy functional tests

* Pull pagination footer up to keep with table

and fix column split growing continuously in dashboard

* Comments fixes

* Use cell actions for filtering

* Fix translations

* Fix comments

* Reduce legacy tests amount

* Update sorting

* Update split column layout

* Add telemetry for legacy vis

* Apply latest changes for split table

* Fix eslint errors

* Use aria labels with values

* Use aria label for export btn

* Fix functional test

* Update translations

* Cleanup

* Truncate cells content

* Enhance types in table_vis_response_handler.ts

* Persist columns width on change

* Fix sorting history

* Add a migration script for toolbar

* Export sorted table

* Use reportUiCounter instead of reportUiStats

* Fix integration tests

* Fix typos

* Adjust FieldFormat type

* Hide the density selector

* Update docs

* Fix pagination

* Restrict hiding the toolbar

* Fix column index on filter

* Add closePopover action

Co-authored-by: cchaos <caroline.horn@elastic.co>
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2020-12-15 14:44:20 +03:00
Lisa Cawley 5b723ad206
[ML] More machine learning links in doc_links_service.ts (#85365) 2020-12-14 17:09:16 -08:00
Xavier Mouligneau 0dfcbe92ed
[SECURITY SOLUTIONS] Ask user to save timeline before leaving the app + bugs (#85693)
* fix clicking on host on netwrok detail page

* Fetch signal index at plugin level to avoid weird behavior

* bing back full screen timeline

* Show health check on timeline

* fix focus on modal of description and title

* fix focus on modal of description and title

* allow to know the next appId

* if user leave security solution and timeline has not been saved, ask them if they want to save it before leaving

* fix test + types

* Fix siem signal loading on plugin + UX on timeline with no data

* Add a callback to cleaner from solution + test

* fix bug + improve prompt leaving msg

* update note

* css improvements

* fix code to be true to our test

* miss one test

* update test

* fix unit test

* core review

Co-authored-by: Patryk Kopycinski <contact@patrykkopycinski.com>
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
Co-authored-by: Angela Chuang <yi-chun.chuang@elastic.co>
2020-12-14 10:33:59 -05:00
Vadim Dalecky b01a327076
Row trigger 2 (#83167)
* feat: 🎸 add ROW_CLICK_TRIGGER

* feat: 🎸 wire row click event to UI Actions trigger in Lens

* feat: 🎸 add row click trigger to url drilldown

* feat: 🎸 add datatable to row click context

* feat: 🎸 pass in row index in row click trigger context

* feat: 🎸 add columns to row click trigger context

* feat: 🎸 fill values and keys event scope array

* feat: 🎸 generate correct row scope variables

* fix: 🐛 report triggers from lens embeddable

* feat: 🎸 add sample preview for row click trigger

* feat: 🎸 remove url drilldown preview box

* chore: 🤖 remove mock variable generation functions

* feat: 🎸 generate context and global variable lists

* feat: 🎸 preview event variable list

* feat: 🎸 show empty url error on blur

* feat: 🎸 add ability to always show popup for executed actions

* refactor: 💡 rename multiple action execution method

* fix: 🐛 don't add separator befor group on no main items

* feat: 🎸 wire in uiActions service into datatable renderer

* feat: 🎸 check each row if it has compatible row click actions

* feat: 🎸 allow passing data to expression renderer

* feat: 🎸 add isEmbeddable helper

* feat: 🎸 pass embeddable to lens table renderer

* feat: 🎸 hide lens table row actions which are empty

* feat: 🎸 re-render lens embeddable when dynamic actions chagne

* feat: 🎸 hide actions column if there are no row actions

* feat: 🎸 re-render lens embeddable on view mode chagne

* fix: 🐛 fix TypeScript errors

* chore: 🤖 fix TypeScript errors

* docs: ✏️ update auto-generated docs

* feat: 🎸 add hasCompatibleActions to expression layer

* feat: 🎸 remove "data" from expression renderer handlers

* fix: 🐛 fix TypeScript errors

* test: 💍 fix Jest tests

* docs: ✏️ update autogenerated docs

* fix: 🐛 wrap event payload into data

* test: 💍 add "alwaysShowPopup" test

* chore: 🤖 add comment requested in review

https://github.com/elastic/kibana/pull/83167#discussion_r537340216

* test: 💍 add hasCompatibleActions test

* test: 💍 add datatable renderer test

* test: 💍 add Lens embeddable input change tests

* test: 💍 add embeddable row click test

* fix: 🐛 add url validation

* test: 💍 add url drilldown tests

* docs: ✏️ remove url drilldown preview from docs

* docs: ✏️ remove preview from url templating

* docs: ✏️ add row click description

* chore: 🤖 move 36.5 KB bundle balance to url_drilldown

* test: 💍 simplify test case

* style: 💄 change types places

* refactor: 💡 clean up panel variable generation

* test: 💍 add getPanelVariables() tests

* fix: 🐛 generate runtime variables correctly

* fix: 🐛 improve getVariableList() and add tests for it

* feat: 🎸 add translation, improve types
2020-12-14 13:28:23 +01:00
Pierre Gayvallet a4caffae2f
Improve and cleanup chrome helpMenu links (#82300)
* Improve and cleanup chrome helpMenu links

* update doc due to merge

* remove dev dependencies from test plugin

* update generated doc after merge

* update generated doc

* generated doc

* generated doc
2020-12-11 11:38:25 +01:00
Alejandro Fernández Haro b47fd950f3
Accept doc changes (#85605) 2020-12-10 17:13:12 +00:00
Luke Elmers 3b5ed46c9d
[data.search] Clean up arguments to esaggs. (#84973) 2020-12-10 07:40:50 -07:00
Anton Dosov cb29438b0d
[Search] Fix dashboard embeddables don't refetch on searchSessionId change (#84261) 2020-12-10 14:21:35 +01:00