Commit graph

76 commits

Author SHA1 Message Date
Kibana Machine 63f1a65495
[Security Solutions] (Phase 1) Adds an application cache called metrics entities and integrates it within Security Solutions behind a feature flag (#96446) (#98967)
## Summary

Phase 1 of a multi-phase cautious approach for adding an experimental application cache for Kibana solutions called `metric_entities` and integrates it within Security Solutions.

Phase 1 is putting experimental support into the application without breaking existing features. Lots of TODO's, conversations and a possible RFC from phase 1 to phase 2 approach. Some features are missing, but for phase 1 the general idea and code is all there.

To enable this first phase after checking out the branch add this to your `kibana.dev.yml`

```yml
xpack.metricsEntities.enabled: true
xpack.securitySolution.enableExperimental: ['metricsEntitiesEnabled']
```

Then go into Stack Management -> Advanced Settings (Under Security Solutions) and set the enabled to true like so:
<img width="1229" alt="Screen Shot 2021-04-08 at 2 21 02 PM" src="https://user-images.githubusercontent.com/1151048/114091276-b3cbb700-9875-11eb-9083-5c1d91dd20ed.png">

Next go to the security_solutions page and you will see it being activated and you will have these transforms running if you look under stack management:
<img width="1710" alt="Screen Shot 2021-04-29 at 2 00 27 PM" src="https://user-images.githubusercontent.com/1151048/116611174-4a2e4e00-a8f3-11eb-9e15-55cb504dfb2a.png">

On the hosts page, network, page, etc... You can see them being activated when you have no query/filter and you click on request:
<img width="1405" alt="Screen Shot 2021-04-29 at 2 01 28 PM" src="https://user-images.githubusercontent.com/1151048/116611274-6a5e0d00-a8f3-11eb-9998-9f5b3d1c5c63.png">

You will see in the request the index patterns all starting with `estc_xyz*`

### Checklist

Delete any items that are not applicable to this PR.

- [x] Any text added follows [EUI's writing guidelines](https://elastic.github.io/eui/#/guidelines/writing), uses sentence case text and includes [i18n support](https://github.com/elastic/kibana/blob/master/packages/kbn-i18n/README.md)

We have lots of TODO's but no concrete docs with this just yet.
- [ ] [Documentation](https://www.elastic.co/guide/en/kibana/master/development-documentation.html) was added for features that require explanation or tutorials

Behind a feature flag and this isn't there yet.
- [ ] [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

Co-authored-by: Frank Hassanabad <frank.hassanabad@elastic.co>
2021-04-30 16:42:47 -04:00
Steph Milovic d10e5a0070
resolve conflicts (#98833) 2021-04-29 19:00:59 -04:00
CJ Cenizal 84d8a7d26d
Extract License service from CCR and Watcher into license_api_guard plugin in x-pack (#95973) (#97332)
* Localize error messages.
# Conflicts:
#	.github/CODEOWNERS
2021-04-15 20:12:35 -04:00
Mikhail Shustov ad7866592e
[7.x] Revert "TS Incremental build exclude test files (#95610)" (#96223) (#96281)
* Revert "TS Incremental build exclude test files (#95610)" (#96223)

This reverts commit b6e582c53e.

* code: use base tsconfig
2021-04-06 05:52:22 -04:00
Thomas Neirynck b31ee25c46
[Maps] Enable all zoom levels for all users (#96093) (#96228)
# Conflicts:
#	.github/CODEOWNERS
2021-04-05 14:33:44 -04:00
Kibana Machine 317e1e41d4
[Observability] Exploratory View initial skeleton (#94426) (#96215)
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>

Co-authored-by: Shahzad <shahzad.muhammad@elastic.co>
2021-04-05 11:34:42 -04:00
Mikhail Shustov ebdcd92b05
[7.x] TS Incremental build exclude test files (#95610) (#96041)
* TS Incremental build exclude test files (#95610)

* add base config for all the TS projects

* all the project use new tsconfig.project.json

* compile test files in the high-level tsconfig.json

* fix TS error in maps plugin

* fix TS error in infra plugin

* exclude mote test and test until folders

* uptime. do not import test code within prod code

* expressions. do not import test code within prod code

* data: export mocks from high level folder

* task_manager: comply with es client typings

* infra: remove unused enzyme_helpers

* check_ts_project requires "include" key

* ts_check should handle parent configs

* all ts configs should extend base one

* exclude test folders from plugins

* update patterns to fix ts_check errors

* Apply suggestions from code review

Co-authored-by: Constance <constancecchen@users.noreply.github.com>

* uptime: MountWithReduxProvider to test helpers

Co-authored-by: Constance <constancecchen@users.noreply.github.com>
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>

* fix code plugin tsconfig

Co-authored-by: Constance <constancecchen@users.noreply.github.com>
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-04-02 03:32:47 -04:00
Kevin Qualters 6f22f0c2a4
[Security Solution][RAC][Timeline] Timeline plugin skeleton and test plugin harness (#95683) (#95998)
* [RAC][Security Solution] Initial timeline and test plugin harness

* Change plugin name from timeline to timelines

# Conflicts:
#	.github/CODEOWNERS
2021-03-31 19:54:10 -04:00
Mikhail Shustov b6076d7ca4
Merge tsconfig and x-pack/tsconfig files (#94519) (#94703)
* merge all the typings at root level

* merge x-pack/tsconfig into tsconfig.json

* fix tsconfig after changes in master

* remove unnecessary typings

* update paths to the global typings

* update paths to the global elaticsearch typings

* fix import

* fix path to typings/elasticsearch in fleet plugin

* remove file deleted from master

* fix lint errors
# Conflicts:
#	x-pack/plugins/fleet/server/services/agents/crud.ts
#	x-pack/plugins/fleet/server/services/artifacts/artifacts.ts
#	x-pack/plugins/fleet/server/services/artifacts/mappings.ts
#	x-pack/plugins/fleet/server/services/artifacts/mocks.ts
#	x-pack/tsconfig.json
2021-03-16 12:33:47 -04:00
Matthew Kime 8dff16a0a6
Index pattern field editor (#88995) (#91896)
Index pattern field editor

Co-authored-by: Sébastien Loix <sabee77@gmail.com>
2021-02-18 14:24:38 -06:00
Mikhail Shustov 4e6650113b
TS config cleanup (#90492) (#91173)
* exclude all the plugins from src/plugins

* move all the used fixtures to discover

* remove src/fixtures alias

* remove unused fixtures

* cleanup x-pack/tsconfig.json

* dont compile apm/scripts

* fix tests

* dont include infra in xpack/tsconfig.json

* update list of includes
# Conflicts:
#	src/fixtures/hits.js
2021-02-11 15:16:59 -05:00
Pierre Gayvallet 36ea213f7d
migrate more core-owned plugins to tsproject ref (#89975) (#90018)
* migrate more plugins to tsproject ref

* revert changes for xpack_legacy

* fix IT
# Conflicts:
#	src/dev/code_coverage/ingest_coverage/integration_tests/team_assignment.test.js
2021-02-02 19:57:38 +01:00
Christiane (Tina) Heiligers 04fcaba75b
Migrate indexPatternManagement to TS project ref (#89759) (#89914) 2021-02-01 14:45:23 -07:00
Pierre Gayvallet 43927b8707
migrate legacy_export plugin to tsproject ref (#89858) (#89872) 2021-02-01 17:51:23 +01:00
Clint Andrew Hall 80aae02a90
[7.x] [Presentation Team] Migrate to Typescript Project References (#86019) (#89824)
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-01-31 11:14:28 -06:00
Joe Reuter 06e4a77b47
Add tsconfig ref to vis_type_vega (#89551) (#89696) 2021-01-29 13:13:00 +01:00
Nathan Reese 3f6e020005
[Maps] remove maps_oss TS project (#89502) (#89514) 2021-01-27 18:43:32 -07:00
Nathan Reese 55bfa4f648
Migrate maps_legacy, maps_oss, region_map, and tile_map plugions to TS projects (#89351) (#89429) 2021-01-27 10:40:20 -07:00
Stratoula Kalafateli ddc205821a
[7.x] Cleanup OSS code from visualizations wizard (#89092) (#89409)
* Cleanup OSS code from visualizations wizard (#89092)

* Cleanup OSS code from visualizations wizard

* Remove unecessary translations

* Remove unused translation

* Fix functional test

* Disable the functional test for OSS

* Remove from oss correctly :D

* Fix ci
# Conflicts:
#	.github/CODEOWNERS
#	docs/developer/plugin-list.asciidoc
#	packages/kbn-optimizer/limits.yml

* fix plugin list docs

* Change plugins docs list
2021-01-27 16:01:23 +02:00
Mikhail Shustov 83b3510da8
[DX] SavedObjectsManagement to TS project (#88240) (#88283)
* som to ts project

* global_search_providers to ts projecvt
2021-01-14 08:44:10 +01:00
Mikhail Shustov 4b650e9f5e
[DX] move some ES UI plugins to TS project (#88050) (#88276)
* es_ui_shared to ts project

* console to ts project

* console_extensions to ts project

* searchprofiler to ts project

* update includes
2021-01-14 08:43:10 +01:00
Joe Reuter 0247619e51
Migrate most kibana app plugins to TS projects (#87636) (#88205)
# Conflicts:
#	x-pack/tsconfig.json
2021-01-13 22:01:31 +01:00
Christiane (Tina) Heiligers 9a12f16294
[7.x] Converts Telemetry Management Section to TS project refs (#88073) (#88191) 2021-01-13 10:50:03 -07:00
Joe Reuter dfa0c67f3b
Kibana app and presentation ts projects (#87639) (#88035) 2021-01-13 11:53:40 +01:00
Joe Portner a3d5721f16
Create Spaces OSS plugin (#87585) (#88065) 2021-01-12 17:28:21 -05:00
Christiane (Tina) Heiligers d0ca49ce3f
[7.x] [DX] Management to TS projects (#87660) (#87847)
* Adds management to tsconfig refs

* removes preemptive script fix
2021-01-11 10:45:09 -07:00
Nathan L Smith f480002133
TS project references for apmOss plugin (#87676) (#87722)
References #80508. References #81003.
2021-01-07 17:31:06 -06:00
Mikhail Shustov 1d4164000a
[DX] Home & SO tagging OSS to TS projects (#87610) (#87621)
* so tagging oss to ts project

* home to ts project
2021-01-07 16:19:58 +01:00
Mikhail Shustov 838c0ef754
Migrate App services plugins to TS projects (#87294) (#87604)
* migrate expressions to ts project refs

* bfetch to ts project

* ui_actions to ts project

* move fitures to data plugins

* add data ts project

* remove outdated ts-expect-error

* add data to x-pack tsconfigs

* navigation to ts project

* cleanup licensing tsconfig

* saved_objects to ts project

* embeddable to ts project

* ui_actions_enhanced to ts project

* embeddable_enhanced to ts project

* features to ts project

* data_enhanced to ts project refs

* fix i18n check

* fix find_plugins_ready_to_migrate_to_ts_refs script

* add a comment for bug ignoring json for composite projects

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2021-01-07 11:57:24 +01:00
Mikhail Shustov 4efd1d9493
Cleanup tsconfig files (#84396) (#84568)
* remove unused "paths" from tsconfig

* remove unused test utils, import get-url from kbn/test

* dont pollute globals with jest when importing getUrl

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2020-11-30 23:30:31 +01:00
Mikhail Shustov eadb94b58c
list all the refs in tsconfig.json (#83678) (#83886) 2020-11-20 10:33:56 +01:00
Mikhail Shustov 616d582d1c
disable incremenetal build for legacy tsconfig.json (#82986) (#83711) 2020-11-19 09:52:10 +03:00
Nathan L Smith 3c7e80ed92
TS project references for securityOss plugin (#82135) (#82625) 2020-11-04 13:46:32 -06:00
CJ Cenizal 0e6caa06e7
Convert Dev Tools app to TS project. (#82197) (#82326)
Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>

Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
2020-11-02 11:14:55 -08:00
Nathan L Smith a4982cee8d
TS project references for share plugin (#82051) (#82134) 2020-10-30 10:46:39 -05:00
Nathan L Smith 036622ca0a
Add TS project references for inspector (#81792) (#81903) 2020-10-28 10:57:12 -05:00
Nathan L Smith c9bd1a335b
Add tsconfig for url_forwarding (#81177) (#81854)
Also add missing pieces to kibana_react, as a follow-up to #80992.

References #80508
References #81003
2020-10-27 18:21:45 -05:00
Nathan L Smith a8dd5b8b6c
Add TS config for kibana_legacy (#80992) (#81171)
To support project references.

References #80508.
2020-10-21 18:53:15 -05:00
Christiane (Tina) Heiligers 02ad93fe12
[7.x] Kibana usage collection to ts project refs (#81265) (#81363) 2020-10-21 12:06:44 -07:00
Christiane (Tina) Heiligers 6b6084b2dc
[7.x] Extracts newsfeed plugin to ts project refs (#81254) (#81341) 2020-10-21 10:33:10 -07:00
Christiane (Tina) Heiligers 0bdce6afc1
[7.x] Usage collection plugins to ts project refs (#81090) (#81201)
# Conflicts:
#	tsconfig.json
2020-10-20 11:15:43 -07:00
Mikhail Shustov dac0dc8dd4
build all ts refs in single kbn:bootstrap (#79438) (#79614) 2020-10-06 10:38:48 +02:00
Mikhail Shustov e8a05ae57b
Add TS projects for src/plugins & x-pack/plugins (#78440) (#78946)
* bump query-string version to remove manual type definitions

* remove manual type declaration

* add kibana_utils tsconfig

* add refs to kibana_utils tsconfig

* add kibana_utils to the project list

* add kibana_react project

* add support for x-pack/tsconfig.refs.json

* add ts project for x-pack licensing plugins

* add glob for ts projects in src/plugins & x-pack/plugins

* add refs to projects in examples

* fix ref paths in x-pack/test

* address mistic comments

Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
# Conflicts:
#	src/plugins/kibana_utils/kibana.json
2020-09-30 17:10:04 +02:00
Mikhail Shustov ee8bc62637
Extract src/core in a separate TS project (#76785) (#77509)
* break dependency on data plugin TS code

* move global typings to @kbn/utility-types

* import types from @kbn/utility-types

* remove type dependency on plugins

* add intermediate js files to break dependency on outter TS code

* temp type declaration for query-string

* declare src/core project

* export types to reference in the built d.ts files

* reference core project

* move jest types out of kbn/utility-types due to a clash with mocha types

* fix wrong es_kuery path and ts project paths

* reference core from packages consuming it

* x-pack & oss should use the same lodash version

* Revert "x-pack & oss should use the same lodash version"

This reverts commit 79cec5781e.

* use the same lodash version

* fix @types/lodash TS2300: Duplicate identifier error

* fix wrong imports

* update docs

* update docs

* add a comment why file is needed
# Conflicts:
#	packages/kbn-utility-types/index.ts
#	src/core/public/application/capabilities/capabilities_service.mock.ts
#	src/core/public/chrome/chrome_service.mock.ts
2020-09-16 07:51:42 +02:00
Mikhail Shustov bd66fab861
Introduce TS incremental builds & move src/test_utils to TS project (#76082) (#76632)
* move test_helpers to the core

* create base tsconfig

* all tsconfigs use the base one

* use test_helpers exposed from the src/core

* move getFieldFormatsRegistry to data plugin

* add test_utils project

* compile types after checkout

* add a stub for platform tsconfig.json

* fix broken import

* fix broken path to the base config

* set tsBuildInfoFile for project without outDir

* do not commit tsbuildinfo file

* do not check output d.ts files

* fix type error

* use separate config to build types

* rollback changes to include paths

* mute import zone error

* rename files to avoid references to tsd

* do not use tsd for type tests

* include all ts files in project

* run buildRefs before type check to ensure the latest version

* store tsbuildinfo locally

* update paths to base config

* comment out core/tsconfig.json

* remove ui path

* fix wrong tsbuildinfo path
2020-09-03 23:02:05 +02:00
Pierre Gayvallet b20030187c
[7.x] Delete src/legacy/ui/public folder (#76085) (#76351)
* Delete src/legacy/ui/public folder (#76085)

* delete src/legacy/ui/public folder

* remove jest.mock('ui/XXX'); from tests

* adapt stubbedLogstashIndexPatternService

* remove delete keys from translation files

* fix types import with Capabilities

* remove legacy test utils

* remove dead file referencing ui/newPlatform

* move saved-object-finder styles to timelion plugin
# Conflicts:
#	src/legacy/ui/public/new_platform/new_platform.test.mocks.ts
#	src/legacy/ui/public/new_platform/new_platform.ts
#	src/test_utils/public/no_digest_promises.js
#	x-pack/plugins/snapshot_restore/__jest__/client_integration/home.test.ts
#	x-pack/plugins/snapshot_restore/__jest__/client_integration/policy_edit.test.ts
#	x-pack/plugins/snapshot_restore/__jest__/client_integration/repository_add.test.ts
#	x-pack/plugins/snapshot_restore/__jest__/client_integration/repository_edit.test.ts

* fix 7.x code

* restore legacy docLinks file
2020-09-01 15:53:31 +02:00
patrykkopycinski a352b5acf0
[7.x] Bump jest related packages (#58095) (#69631)
* Bump jest related packages (#58095)

# Conflicts:
#	package.json
#	packages/kbn-pm/dist/index.js
#	packages/kbn-test/package.json
#	x-pack/plugins/upgrade_assistant/public/application/components/tabs/checkup/__snapshots__/checkup_tab.test.tsx.snap
#	x-pack/plugins/uptime/public/components/monitor/location_map/__tests__/location_map.test.tsx
#	yarn.lock

* Update AgentMarker.test.tsx.snap
2020-06-21 01:23:51 +02:00
Nick Partridge dd8eaab229
[Metric] convert mocha tests to jest (#54054) (#55210)
* Add fixtures/* alias to tsconfig and jest config
* Convert metric tests to jest
* Convert remaining js files to ts
2020-01-17 13:33:46 -06:00
Maryia Lapata bef43740c7
[Vis] Move Timelion Vis to vis_type_timelion (#52069) (#55174)
* Deangularize timelion vis

* Refactoring

* Fix path

* Update timelion_controller.ts

* Remove unused deps

* Create vis_type_timelion

* Create ChartComponent

* Render chart in react

* Reactify timelion editor

* Change translation ids

* Use hooks

* Add @types/pegjs into renovate.json5

* Add validation, add hover suggestions

* Style fixes

* Change plugin setup, use kibana context

* Update

* Fix ticks

* Fix plotselected listener

* Fix plothover handler

* Add TS for options

* Update TS

* Restructuring

* Change plugin start

* Remove vis from timelion plugin

* Rename class

* Mock services

* Fix other comments

* Remove duplicate files

* Convert test to jest

* Remove kibana_services from timelion

* Delete visualize_app.ts.~LOCAL

* Refactoring

* Fix TS

* Refactoring, TS

* Import eui variables

* Import styling constants

* Move react components to vis_type_timelion

* Fix TS

* Move ui imports to legacy_imports.ts

* Move chain.peg to vis_type_timelion

* Fix path

* Use KibanaContext instead kibana_services.ts

* Refactoring

* Refactoring

* Add @types/flot

* Fix issue with hovered series color

* Update renovate.json5

* Pass timelionPanels as dependencies

* Move common folder to vis_type_timelion

* Move back tick_formatters.ts

* Rename styles file

* Refactoring

* Update _index.scss

* Move to_milliseconds to common

* Revert yaxes formatting

* Refactoring

* Refactoring

* Use Panel directly

* Refactoring of to_milliseconds.ts

Co-authored-by: Daniil Suleiman <31325372+sulemanof@users.noreply.github.com>
Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>

Co-authored-by: Daniil Suleiman <31325372+sulemanof@users.noreply.github.com>
Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
2020-01-17 17:38:56 +03:00
Sébastien Loix 5f8e60849d
Es ui shared updates (#46570) (#46716) 2019-10-29 11:25:50 +01:00